|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.arsdigita.developersupport.Counter
A debugging tool that helps you count how many times a particular action has been executed.
This API is subject to frequent change and should only be used for transient debugging sessions.
Set the "com.arsdigita.developersupport.Counter" log4j logger's
level to DEBUG in order to see the collected stats.
| Nested Class Summary | |
static class |
Counter.Context
|
static class |
Counter.ContextMismatchException
|
| Method Summary | |
void |
end(Counter.Context context)
|
static Counter |
getCounter()
|
void |
increment(String action)
Increments the running count of the action in the current
context. |
void |
log(String message)
Logs the passed in message and the current contents of the
counter. |
Counter.Context |
start(String context)
Creates a new counter context. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Method Detail |
public static Counter getCounter()
public Counter.Context start(String context)
end this context off the
counter.
public void end(Counter.Context context)
ContextMispatchException - if the passed in context does not match
the current context of this counter.
NullPointerException - if expected is nullpublic void increment(String action)
action in the current
context.
action - the name of the action whose number of executions we are
trying to compute.public void log(String message)
message and the current contents of the
counter.
public String toString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||