@Override
        public byte[] doInTransform(Instrumentor instrumentor, ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) throws InstrumentException {
            InstrumentClass target = instrumentor.getInstrumentClass(loader, className, classfileBuffer);
            target.addField(AsyncContextAccessor.class);

            final InstrumentMethod onStatusReceivedMethod = target.getDeclaredMethod("onStatusReceived", "org.asynchttpclient.HttpResponseStatus");
            if (onStatusReceivedMethod != null) {
                onStatusReceivedMethod.addInterceptor(AsyncHandlerOnStatusReceivedInterceptor.class);
            }
            final InstrumentMethod onThrowableMethod = target.getDeclaredMethod("onThrowable", "java.lang.Throwable");
            if (onThrowableMethod != null) {
                onThrowableMethod.addInterceptor(AsyncHandlerOnThrowableInterceptor.class);
            }
            final InstrumentMethod onCompletedMethod = target.getDeclaredMethod("onCompleted");
            if (onCompletedMethod != null) {
                onCompletedMethod.addInterceptor(AsyncHandlerOnCompletedInterceptor.class);
            }

            return target.toBytecode();
        }
@author netspider
@author emeroad
@author minwoo.jung
@author jaehong.kim
agent-module/plugins/ning-asynchttpclient/src/main/java/com/navercorp/pinpoint/plugin/ning/asynchttpclient/NingAsyncHttpClientPlugin.java