Methods Summary |
---|
public void | add(java.lang.String tag, LiveTraceListener l)Registers a listener for tracepoints identified by this tag. When a
tracepoint is hit whose tag matches this one, the listener is called.
Replaces any listener that might already exist for this tag.
listeners.put(tag, l);
|
public void | clear()Clears all listeners from the tracer.
listeners.clear();
|
public void | remove(java.lang.String tag)Unregisters the indicated listener from the tracer.
listeners.remove(tag);
|
public void | trace(java.lang.String tag)Indicates a tracepoint identified by this tag. If there is a listener
registered for this tag, the listener is called.
LiveTraceListener l =
(LiveTraceListener)listeners.get(tag);
if (l != null) {
l.call(tag);
}
|