All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.networkbench.newlens.agent.android.NetworkBenchNewLensDeinstrumentTask.groovy Maven / Gradle / Ivy

package com.networkbench.newlens.agent.android

import org.gradle.api.tasks.TaskAction

class NetworkBenchNewLensDeinstrumentTask extends NetworkBenchNewLensTask {

	@TaskAction
	def networkBenchNewLensDeinstrumentTask() {
		try{
			String extraArgs =System.getProperty("NewLens.AgentArgs");
			String agentArgs = "deinstrument=true";  
			if(extraArgs!=null){
				agentArgs=agentArgs+";"+extraArgs
			}		
			this.logger.info("[NewLens] Attaching to process for deinstrumentation "+this.pid.toString())
			this.injectAgent(agentArgs)
		}catch(Exception e){
			this.logger.error("[NewLens] Error encountered while loading the NetworkBench NewLens Android agent", e)
			throw new RuntimeException(e)
		}
	}
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy