|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jcoderz.commons.tracing.JulTracer
public class JulTracer
A Tracer implementation that used java.util.logging
entering exiting logger as tracing sink.
See Logger.entering(String, String) for an example.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.jcoderz.commons.tracing.Tracer |
|---|
Tracer.TracingToken |
| Method Summary | |
|---|---|
Tracer.TracingToken |
entering(String className,
String methodName)
Delegates to Logger.entering(String, String). |
Tracer.TracingToken |
entering(String className,
String methodName,
Object argument)
Delegates to Logger.entering(String, String, Object). |
Tracer.TracingToken |
entering(String className,
String methodName,
Object[] arguments)
Delegates to Logger.entering(String, String, Object). |
void |
exiting(Tracer.TracingToken token)
Delegates to Logger.exiting(String, String). |
void |
exiting(Tracer.TracingToken token,
Object result)
Delegates to Logger.exiting(String, String). |
String |
getClassName()
Returns the Name of the class where this tracer belongs to. |
static JulTracer |
getTracer(String className)
Factory for a tracer for classes with the given name. |
boolean |
isTracing()
Returns true, if the level of the underlying java logger is Level.FINER or below. |
boolean |
isTracingArguments()
Returns always true. |
void |
throwing(Tracer.TracingToken token,
Throwable thrown)
Delegates to Logger.throwing(String, String, Throwable). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public static JulTracer getTracer(String className)
className - the name of the class that uses this tracer.
public boolean isTracing()
Level.FINER or below.
isTracing in interface TracerTracer.isTracing()public boolean isTracingArguments()
isTracingArguments in interface TracerTracer.isTracingArguments()public String getClassName()
public Tracer.TracingToken entering(String className,
String methodName)
Logger.entering(String, String).
The className is expected to be the same as the tracer name and
is silently ignored.
entering in interface TracerclassName - name of the classmethodName - name of the method entered.
Tracer.entering(java.lang.String, java.lang.String)
public Tracer.TracingToken entering(String className,
String methodName,
Object argument)
Logger.entering(String, String, Object).
The className is expected to be the same as the tracer name and
is silently ignored.
entering in interface TracerTracer.entering(String, String, Object)
public Tracer.TracingToken entering(String className,
String methodName,
Object[] arguments)
Logger.entering(String, String, Object).
The className is expected to be the same as the tracer name and
is silently ignored.
entering in interface TracerTracer.entering(String, String, Object[])public void exiting(Tracer.TracingToken token)
Logger.exiting(String, String).
If the token is not a JulTracingToken the call is
silently ignored.
exiting in interface TracerTracer.exiting(TracingToken)
public void exiting(Tracer.TracingToken token,
Object result)
Logger.exiting(String, String).
If the token is not a JulTracingToken the call is
silently ignored.
exiting in interface TracerTracer.exiting(TracingToken, java.lang.Object)
public void throwing(Tracer.TracingToken token,
Throwable thrown)
Logger.throwing(String, String, Throwable).
If the token is not a JulTracingToken the call is
silently ignored.
throwing in interface TracerTracer.throwing(TracingToken, java.lang.Throwable)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||