Package org.smooks.benchmark
Class CounterVisitor
- java.lang.Object
-
- org.smooks.benchmark.CounterVisitor
-
- All Implemented Interfaces:
ContentHandler
,PreExecutionLifecycle
,BeforeVisitor
,SaxNgVisitor
,Visitor
public class CounterVisitor extends Object implements BeforeVisitor, PreExecutionLifecycle
-
-
Constructor Summary
Constructors Constructor Description CounterVisitor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
onPreExecution(ExecutionContext executionContext)
Initialize the resources allocated by this resource for the specified ExecutionContext.void
visitBefore(Element element, ExecutionContext executionContext)
Visits the beginning of anElement
.
-
-
-
Method Detail
-
visitBefore
public void visitBefore(Element element, ExecutionContext executionContext)
Description copied from interface:BeforeVisitor
Visits the beginning of anElement
.- Specified by:
visitBefore
in interfaceBeforeVisitor
- Parameters:
element
- theElement
representing the beginning of the fragment. TheElement
's ancestors are traversable unless the global configuration parametermaintain.element.stack
is set to false. TheElement
's child nodes are not traversable.executionContext
- the currentExecutionContext
-
onPreExecution
public void onPreExecution(ExecutionContext executionContext)
Description copied from interface:PreExecutionLifecycle
Initialize the resources allocated by this resource for the specified ExecutionContext. Executes the initialization at the start of the filter execution.- Specified by:
onPreExecution
in interfacePreExecutionLifecycle
- Parameters:
executionContext
- The ExecutionContext.
-
-