Package java.com.intergral.deep
Class ProxyCallback
- java.lang.Object
-
- java.com.intergral.deep.ProxyCallback
-
public class ProxyCallback extends Object
This type is here to allow us to access it from anywhere (once it is loaded into the boot class path).This will simply act as a proxy to the
Callback
which is where we do the real work.This split is to allow us to support Lucee and other OSGi style environments that use isolated class loaders.
-
-
Constructor Summary
Constructors Constructor Description ProxyCallback()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
callBack(List<String> bpIds, String filename, int lineNo, Map<String,Object> map)
The main entry point for non CF ASM injected breakpoints.static void
callBackCF(List<String> bpIds, String filename, int lineNo, Map<String,Object> map)
The main entry point for CF ASM injected breakpoints.static void
callBackException(Throwable e)
This is called when an exception is caught on a wrapped line, this is not always called.static void
callBackFinally(List<String> bpIds, String filename, int lineNo, Map<String,Object> variables)
This is called when the visited line is completed.static void
methodEnd(String methodName, String filename, int lineNo, List<String> bpIds, Map<String,Object> variables)
This method is called when a wrapped method has completed.static void
methodEntry(String methodName, String filename, int lineNo, List<String> bpIds, Map<String,Object> variables, String spanOnlyIds)
This method is called when a tracepoint has triggered a method entry type.static void
methodException(Throwable t)
This is called when an exception is captured from a wrapped method.static void
methodRet(Object value)
This is called when the returned value from the wrapped method is captured.
-
-
-
Method Detail
-
callBackCF
public static void callBackCF(List<String> bpIds, String filename, int lineNo, Map<String,Object> map)
The main entry point for CF ASM injected breakpoints.- Parameters:
bpIds
- the bp ids to triggerfilename
- the filename of the breakpoint hitlineNo
- the line number of the breakpoint hitmap
- the map of local variables.
-
callBack
public static void callBack(List<String> bpIds, String filename, int lineNo, Map<String,Object> map)
The main entry point for non CF ASM injected breakpoints.- Parameters:
bpIds
- the bp ids to triggerfilename
- the filename of the breakpoint hitlineNo
- the line number of the breakpoint hitmap
- the map of local variables.
-
callBackException
public static void callBackException(Throwable e)
This is called when an exception is caught on a wrapped line, this is not always called.- Parameters:
e
- the exception caught
-
callBackFinally
public static void callBackFinally(List<String> bpIds, String filename, int lineNo, Map<String,Object> variables)
This is called when the visited line is completed.- Parameters:
bpIds
- the tracepoint ids that triggered thisfilename
- the source file namelineNo
- the line number we are onvariables
- the captured local variables
-
methodEntry
public static void methodEntry(String methodName, String filename, int lineNo, List<String> bpIds, Map<String,Object> variables, String spanOnlyIds)
This method is called when a tracepoint has triggered a method entry type.This method will Always return a closable. This way the injected code never deals with anything but calling close. Even if close doesn't do anything.
We use
Closeable
here, so we can stick to java types in the injected code. This makes testing and injected code simpler.- Parameters:
methodName
- the method name we have enteredfilename
- the file name the method is inlineNo
- the line number the method is onbpIds
- the tracepoint ids that have been triggered by this entryvariables
- the map of variables capturedspanOnlyIds
- the CSV of the tracepoints ids that just want a span
-
methodException
public static void methodException(Throwable t)
This is called when an exception is captured from a wrapped method.- Parameters:
t
- the captured throwable
-
methodRet
public static void methodRet(Object value)
This is called when the returned value from the wrapped method is captured.This method is not called on void methods.
- Parameters:
value
- the captured return value.
-
methodEnd
public static void methodEnd(String methodName, String filename, int lineNo, List<String> bpIds, Map<String,Object> variables)
This method is called when a wrapped method has completed.- Parameters:
methodName
- the method namefilename
- the source file namelineNo
- the line numberbpIds
- the triggering tracepoints idsvariables
- the captured local variables
-
-