Package net.sf.saxon.event
Class ContentHandlerProxy.ContentHandlerProxyTraceListener
- java.lang.Object
-
- net.sf.saxon.event.ContentHandlerProxy.ContentHandlerProxyTraceListener
-
- All Implemented Interfaces:
java.util.EventListener
,TraceListener
- Enclosing class:
- ContentHandlerProxy
public static class ContentHandlerProxy.ContentHandlerProxyTraceListener extends java.lang.Object implements TraceListener
Create a TraceListener that will collect information about the current location in the source document. This is used to provide information to the receiving application for diagnostic purposes.
-
-
Constructor Summary
Constructors Constructor Description ContentHandlerProxyTraceListener()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Method called at the end of execution, that is, when the run-time execution endsvoid
endCurrentItem(Item currentItem)
Method that is called when an instruction has finished processing a new current item and is ready to select a new current item or revert to the previous current item.java.util.Stack
getContextItemStack()
Get the context item stackvoid
open(Controller controller)
Method called at the start of execution, that is, when the run-time transformation startsvoid
setOutputDestination(Logger stream)
Method called to supply the destination for outputvoid
startCurrentItem(Item currentItem)
Method that is called by an instruction that changes the current item in the source document: that is, xsl:for-each, xsl:apply-templates, xsl:for-each-group.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sf.saxon.lib.TraceListener
endRuleSearch, enter, leave, startRuleSearch
-
-
-
-
Method Detail
-
setOutputDestination
public void setOutputDestination(Logger stream)
Description copied from interface:TraceListener
Method called to supply the destination for output- Specified by:
setOutputDestination
in interfaceTraceListener
- Parameters:
stream
- a Logger to which any output produced by the TraceListener should be written
-
getContextItemStack
public java.util.Stack getContextItemStack()
Get the context item stack- Returns:
- the context item stack
-
open
public void open(Controller controller)
Method called at the start of execution, that is, when the run-time transformation starts- Specified by:
open
in interfaceTraceListener
- Parameters:
controller
- identifies the transformation controller, and provides the listener with access to context and configuration information
-
close
public void close()
Method called at the end of execution, that is, when the run-time execution ends- Specified by:
close
in interfaceTraceListener
-
startCurrentItem
public void startCurrentItem(Item currentItem)
Method that is called by an instruction that changes the current item in the source document: that is, xsl:for-each, xsl:apply-templates, xsl:for-each-group. The method is called after the enter method for the relevant instruction, and is called once for each item processed.- Specified by:
startCurrentItem
in interfaceTraceListener
- Parameters:
currentItem
- the new current item. Item objects are not mutable; it is safe to retain a reference to the Item for later use.
-
endCurrentItem
public void endCurrentItem(Item currentItem)
Method that is called when an instruction has finished processing a new current item and is ready to select a new current item or revert to the previous current item. The method will be called before the leave() method for the instruction that made this item current.- Specified by:
endCurrentItem
in interfaceTraceListener
- Parameters:
currentItem
- the item that was current, whose processing is now complete. This will represent the same underlying item as the corresponding startCurrentItem() call, though it will not necessarily be the same actual object.
-
-