net.sf.joost.trace
Class TraceManager

java.lang.Object
  extended by net.sf.joost.trace.TraceManager

public class TraceManager
extends Object

This class manages a collection of TraceListener, and acts as an interface for the tracing functionality in Joost.

Version:
$Revision: 1.8 $ $Date: 2004/11/07 13:47:05 $
Author:
Zubow

Field Summary
private  Vector traceListeners
          Collection of registered listeners (must be synchronized).
 
Constructor Summary
TraceManager()
          Default constructor for the tracemanager.
 
Method Summary
 void addTraceListener(TraceListener newTraceListener)
          Add a tracelistener (debugging and profiling).
 void fireEndResultCDATA()
          Indicates the end CDATA event of the result document.
 void fireEndResultDocument()
          Indicates the end of the result document.
 void fireEndResultElement(SAXEvent saxevent)
          Indicates the start of an element of the result document.
 void fireEndSourceDocument()
          Fire at the end of processing (close).
 void fireEndSourceElement(SAXEvent saxevent)
          Fire after a node of the source tree got processed.
 void fireEnterInstructionNode(AbstractInstruction inst, SAXEvent event)
          Fire when an element of the stylesheet gets processed.
 void fireLeaveInstructionNode(AbstractInstruction inst, SAXEvent event)
          Fire after an element of the stylesheet got processed.
 void fireResultComment(SAXEvent saxevent)
          Indicates the comment event of the result document.
 void fireResultPI(SAXEvent saxevent)
          Indicates the PI event of the result document.
 void fireResultText(SAXEvent saxevent)
          Indicates the text event of the result document.
 void fireSourceComment(SAXEvent saxevent)
          Called when a comment event of the source was received.
 void fireSourceMapping(SAXEvent saxevent)
          Called when a namespace mapping event of the source was received.
 void fireSourcePI(SAXEvent saxevent)
          Fire when a PI-Event of the source was received.
 void fireSourceText(SAXEvent saxevent)
          Fire when a text event of the source was received.
 void fireStartResultCDATA()
          Indicates the start CDATA event of the result document.
 void fireStartResultDocument()
          Indicates the begin of the result document.
 void fireStartResultElement(SAXEvent saxevent)
          Indicates the start of an element of the result document.
 void fireStartSourceDocument()
          Fire a start processing event (open).
 void fireStartSourceElement(SAXEvent saxevent)
          Fire if a startelement event of the source gets processed.
 boolean hasTraceListeners()
          Check if tracelisteners are available.
 void removeTraceListener(TraceListener oldTraceListener)
          Remove a tracelistener.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

traceListeners

private Vector traceListeners
Collection of registered listeners (must be synchronized).

Constructor Detail

TraceManager

public TraceManager()
Default constructor for the tracemanager.

Method Detail

hasTraceListeners

public boolean hasTraceListeners()
Check if tracelisteners are available.

Returns:
True if there are registered tracelisteners

addTraceListener

public void addTraceListener(TraceListener newTraceListener)
Add a tracelistener (debugging and profiling).

Parameters:
newTraceListener - A tracelistener to be added.

removeTraceListener

public void removeTraceListener(TraceListener oldTraceListener)
Remove a tracelistener.

Parameters:
oldTraceListener - A tracelistener to be removed.

fireStartSourceDocument

public void fireStartSourceDocument()
Fire a start processing event (open).


fireEndSourceDocument

public void fireEndSourceDocument()
Fire at the end of processing (close).


fireStartSourceElement

public void fireStartSourceElement(SAXEvent saxevent)
Fire if a startelement event of the source gets processed.


fireEndSourceElement

public void fireEndSourceElement(SAXEvent saxevent)
Fire after a node of the source tree got processed.


fireSourceText

public void fireSourceText(SAXEvent saxevent)
Fire when a text event of the source was received.


fireSourcePI

public void fireSourcePI(SAXEvent saxevent)
Fire when a PI-Event of the source was received.


fireSourceMapping

public void fireSourceMapping(SAXEvent saxevent)
Called when a namespace mapping event of the source was received.


fireSourceComment

public void fireSourceComment(SAXEvent saxevent)
Called when a comment event of the source was received.


fireEnterInstructionNode

public void fireEnterInstructionNode(AbstractInstruction inst,
                                     SAXEvent event)
Fire when an element of the stylesheet gets processed.


fireLeaveInstructionNode

public void fireLeaveInstructionNode(AbstractInstruction inst,
                                     SAXEvent event)
Fire after an element of the stylesheet got processed.


fireStartResultDocument

public void fireStartResultDocument()
Indicates the begin of the result document.


fireEndResultDocument

public void fireEndResultDocument()
Indicates the end of the result document.


fireStartResultElement

public void fireStartResultElement(SAXEvent saxevent)
Indicates the start of an element of the result document.


fireEndResultElement

public void fireEndResultElement(SAXEvent saxevent)
Indicates the start of an element of the result document.


fireResultText

public void fireResultText(SAXEvent saxevent)
Indicates the text event of the result document.


fireResultPI

public void fireResultPI(SAXEvent saxevent)
Indicates the PI event of the result document.


fireResultComment

public void fireResultComment(SAXEvent saxevent)
Indicates the comment event of the result document.


fireStartResultCDATA

public void fireStartResultCDATA()
Indicates the start CDATA event of the result document.


fireEndResultCDATA

public void fireEndResultCDATA()
Indicates the end CDATA event of the result document.