com.gargoylesoftware.base.trace
public class TraceItemDispatcher extends Object implements Runnable
Internal use only.
.A dispatcher for TraceItems
Version: $Revision: 1.8 $
| Field Summary | |
|---|---|
| static int | bufferStatus_ |
| static int | BUFFER_DISABLED |
| static int | BUFFER_ENABLED |
| static int | BUFFER_SHUTTING_DOWN |
| int | cacheMaxSize_ |
| TraceItemQueue | cacheTraceItemQueue_ |
| TraceItemQueue | traceQueue_ |
| static Format | TIMESTAMP_FORMAT |
| Constructor Summary | |
|---|---|
| TraceItemDispatcher() | |
| Method Summary | |
|---|---|
| protected void | assertNotNull(String fieldName, Object fieldValue)
Verify that the specified value is not null. |
| static void | defaultTraceWriter(TraceItem item)
Provide default behaviour |
| void | dispatch(TraceItem item)
Add an item to the trace queue. |
| void | disposeTraceItem(TraceItem item)
Dispose of a trace item. |
| void | dumpTraceElement(TraceItem item)
Format an item and print it to standard out. |
| void | flush() |
| TraceItem | getNewTraceItem()
Return a trace item |
| TraceItemQueue | getTraceItemQueue()
Get the queue. |
| boolean | isBufferingEnabled()
Return true if buffering is enabled. |
| void | run() |
| void | setBufferingEnabled(boolean enabled)
Set whether or not to buffer the output of the trace calls. |
| void | waitForQueueToEmpty() |
Parameters: fieldName The name of the field to check fieldValue The value of the field to check
Throws: DetailedNullPointerException If fieldValue is null
Parameters: item The item to print
Parameters: item The item to add.
Parameters: item The item to dispose.
Parameters: item the item to print.
Returns: The new trace item.
Returns: The queue.
Returns: true if buffering is enabled.
Parameters: enabled True if buffering should be enabled