public class DefaultXPathHandler extends java.lang.Object implements XPathHandler
XPathHandler
.
Application writers can extend this class when they need to
implement only part of the XPathHandler
interface. Parser writers can instantiate
this class to provide default handlers when the application has not
supplied its own.Constructor and Description |
---|
DefaultXPathHandler() |
Modifier and Type | Method and Description |
---|---|
void |
endAbsoluteLocationPath()
Receive notification of the end of an absolute location path expression.
|
void |
endAdditiveExpr(int operator)
Receive notification of the end of an additive ('+' or '-') expression.
|
void |
endAllNodeStep()
Receive notification of the end of a node() step.
|
void |
endAndExpr(boolean create)
Receive notification of the end of an 'and' expression.
|
void |
endCommentNodeStep()
Receive notification of the end of a comment() step.
|
void |
endEqualityExpr(int operator)
Receive notification of the end of an equality ('=' or '!=') expression.
|
void |
endFilterExpr()
Receive notification of the end of a filter expression.
|
void |
endFunction()
Receive notification of the end of a function call
|
void |
endMultiplicativeExpr(int operator)
Receive notification of the start of a multiplicative ('*', 'div' or 'mod') expression.
|
void |
endNameStep()
Receive notification of the end of a NameStep
|
void |
endOrExpr(boolean create)
Receive notification of the end of an 'or' expression.
|
void |
endPathExpr()
Receive notification of the end of a path expression.
|
void |
endPredicate()
Receive notification of the end of a predicate.
|
void |
endProcessingInstructionNodeStep()
Receive notification of the end of a processing-instruction(...) step.
|
void |
endRelationalExpr(int operator)
Receive notification of the start of a relational ('<', '>', '<=', or '>=') expression.
|
void |
endRelativeLocationPath()
Receive notification of the end of a relative location path expression.
|
void |
endTextNodeStep()
Receive notification of the end of a text() step.
|
void |
endUnaryExpr(int operator)
Receive notification of the end of a unary ('+' or '-') expression.
|
void |
endUnionExpr(boolean create)
Receive notification of the end of a union ('|') expression.
|
void |
endXPath()
Receive notification of the end of an XPath expression parse.
|
void |
literal(java.lang.String literal)
Receive notification of a literal expression.
|
void |
number(double number)
Receive notification of a number expression.
|
void |
number(int number)
Receive notification of a number expression.
|
void |
startAbsoluteLocationPath()
Receive notification of the start of an absolute location path expression.
|
void |
startAdditiveExpr()
Receive notification of the start of an additive ('+' or '-') expression.
|
void |
startAllNodeStep(int axis)
Receive notification of the start of a node() step.
|
void |
startAndExpr()
Receive notification of the start of an 'and' expression.
|
void |
startCommentNodeStep(int axis)
Receive notification of the start of a comment() step.
|
void |
startEqualityExpr()
Receive notification of the start of an equality ('=' or '!=') expression.
|
void |
startFilterExpr()
Receive notification of the start of a filter expression.
|
void |
startFunction(java.lang.String prefix,
java.lang.String functionName)
Receive notification of a function call.
|
void |
startMultiplicativeExpr()
Receive notification of the start of a multiplicative ('*', 'div' or 'mod') expression.
|
void |
startNameStep(int axis,
java.lang.String prefix,
java.lang.String localName)
Receive notification of the start of a name step.
|
void |
startOrExpr()
Receive notification of the start of an 'or' expression.
|
void |
startPathExpr()
Receive notification of the start of a path expression.
|
void |
startPredicate()
Receive notification of the start of a predicate.
|
void |
startProcessingInstructionNodeStep(int axis,
java.lang.String name)
Receive notification of the start of a processing-instruction(...) step.
|
void |
startRelationalExpr()
Receive notification of the start of a relational ('<', '>', '<=', or '>=') expression.
|
void |
startRelativeLocationPath()
Receive notification of the start of a relative location path expression.
|
void |
startTextNodeStep(int axis)
Receive notification of the start of a text() step.
|
void |
startUnaryExpr()
Receive notification of the start of a unary ('+' or '-') expression.
|
void |
startUnionExpr()
Receive notification of the start of a union ('|') expression.
|
void |
startXPath()
Receive notification of the start of an XPath expression parse.
|
void |
variableReference(java.lang.String prefix,
java.lang.String variableName)
Receive notification of a variable-reference expression.
|
public void startXPath() throws SAXPathException
XPathHandler
startXPath
in interface XPathHandler
SAXPathException
public void endXPath() throws SAXPathException
XPathHandler
endXPath
in interface XPathHandler
SAXPathException
public void startPathExpr() throws SAXPathException
XPathHandler
startPathExpr
in interface XPathHandler
SAXPathException
public void endPathExpr() throws SAXPathException
XPathHandler
endPathExpr
in interface XPathHandler
SAXPathException
public void startAbsoluteLocationPath() throws SAXPathException
XPathHandler
startAbsoluteLocationPath
in interface XPathHandler
SAXPathException
public void endAbsoluteLocationPath() throws SAXPathException
XPathHandler
endAbsoluteLocationPath
in interface XPathHandler
SAXPathException
public void startRelativeLocationPath() throws SAXPathException
XPathHandler
startRelativeLocationPath
in interface XPathHandler
SAXPathException
public void endRelativeLocationPath() throws SAXPathException
XPathHandler
endRelativeLocationPath
in interface XPathHandler
SAXPathException
public void startNameStep(int axis, java.lang.String prefix, java.lang.String localName) throws SAXPathException
XPathHandler
startNameStep
in interface XPathHandler
axis
- the axis of this stepprefix
- the namespace prefix for the name to test,
or the empty string if no prefix is specifiedlocalName
- the local part of the name to testSAXPathException
public void endNameStep() throws SAXPathException
XPathHandler
endNameStep
in interface XPathHandler
SAXPathException
public void startTextNodeStep(int axis) throws SAXPathException
XPathHandler
startTextNodeStep
in interface XPathHandler
axis
- the axis of this stepSAXPathException
public void endTextNodeStep() throws SAXPathException
XPathHandler
endTextNodeStep
in interface XPathHandler
SAXPathException
public void startCommentNodeStep(int axis) throws SAXPathException
XPathHandler
startCommentNodeStep
in interface XPathHandler
axis
- the axis of this stepSAXPathException
public void endCommentNodeStep() throws SAXPathException
XPathHandler
endCommentNodeStep
in interface XPathHandler
SAXPathException
public void startAllNodeStep(int axis) throws SAXPathException
XPathHandler
startAllNodeStep
in interface XPathHandler
axis
- the axis of this stepSAXPathException
public void endAllNodeStep() throws SAXPathException
XPathHandler
endAllNodeStep
in interface XPathHandler
SAXPathException
public void startProcessingInstructionNodeStep(int axis, java.lang.String name) throws SAXPathException
XPathHandler
startProcessingInstructionNodeStep
in interface XPathHandler
axis
- the axis of this stepname
- the name of the processing-instruction, or
the empty string if none is specifiedSAXPathException
public void endProcessingInstructionNodeStep() throws SAXPathException
XPathHandler
endProcessingInstructionNodeStep
in interface XPathHandler
SAXPathException
public void startPredicate() throws SAXPathException
XPathHandler
startPredicate
in interface XPathHandler
SAXPathException
public void endPredicate() throws SAXPathException
XPathHandler
endPredicate
in interface XPathHandler
SAXPathException
public void startFilterExpr() throws SAXPathException
XPathHandler
startFilterExpr
in interface XPathHandler
SAXPathException
public void endFilterExpr() throws SAXPathException
XPathHandler
endFilterExpr
in interface XPathHandler
SAXPathException
public void startOrExpr() throws SAXPathException
XPathHandler
startOrExpr
in interface XPathHandler
SAXPathException
public void endOrExpr(boolean create) throws SAXPathException
XPathHandler
endOrExpr
in interface XPathHandler
create
- flag that indicates if this expression
should truly be instantiated, or if it was just
a pass-through, based upon the grammar productionsSAXPathException
public void startAndExpr() throws SAXPathException
XPathHandler
startAndExpr
in interface XPathHandler
SAXPathException
public void endAndExpr(boolean create) throws SAXPathException
XPathHandler
endAndExpr
in interface XPathHandler
create
- flag that indicates if this expression
should truly be instantiated, or if it was just
a pass-through, based upon the grammar productionsSAXPathException
public void startEqualityExpr() throws SAXPathException
XPathHandler
startEqualityExpr
in interface XPathHandler
SAXPathException
public void endEqualityExpr(int operator) throws SAXPathException
XPathHandler
endEqualityExpr
in interface XPathHandler
operator
- the operator specific to this particular
equality expression. If null, this expression
is only a pass-through, and should not actually
be instantiated.SAXPathException
public void startRelationalExpr() throws SAXPathException
XPathHandler
startRelationalExpr
in interface XPathHandler
SAXPathException
public void endRelationalExpr(int operator) throws SAXPathException
XPathHandler
endRelationalExpr
in interface XPathHandler
operator
- the operator specific to this particular
relational expression. If NO_OP, this expression
is only a pass-through, and should not actually
be instantiated.SAXPathException
public void startAdditiveExpr() throws SAXPathException
XPathHandler
startAdditiveExpr
in interface XPathHandler
SAXPathException
public void endAdditiveExpr(int operator) throws SAXPathException
XPathHandler
endAdditiveExpr
in interface XPathHandler
operator
- the operator specific to this particular
additive expression. If NO_OP, this expression
is only a pass-through, and should not actually
be instantiated.SAXPathException
public void startMultiplicativeExpr() throws SAXPathException
XPathHandler
startMultiplicativeExpr
in interface XPathHandler
SAXPathException
public void endMultiplicativeExpr(int operator) throws SAXPathException
XPathHandler
endMultiplicativeExpr
in interface XPathHandler
operator
- the operator specific to this particular
multiplicative expression. If null, this expression
is only a pass-through, and should not actually
be instantiated.SAXPathException
public void startUnaryExpr() throws SAXPathException
XPathHandler
startUnaryExpr
in interface XPathHandler
SAXPathException
public void endUnaryExpr(int operator) throws SAXPathException
XPathHandler
endUnaryExpr
in interface XPathHandler
operator
- the operator specific to this particular
unary expression. If NO_OP, this expression is only
a pass-through, and should not actually be instantiated.
If not Operator.NO_OP
, it will
always be Operator.NEGATIVE
.SAXPathException
public void startUnionExpr() throws SAXPathException
XPathHandler
startUnionExpr
in interface XPathHandler
SAXPathException
public void endUnionExpr(boolean create) throws SAXPathException
XPathHandler
endUnionExpr
in interface XPathHandler
create
- flag that indicates if this expression
should truly be instantiated, or if it was just
a pass-through, based upon the grammar productionsSAXPathException
public void number(int number) throws SAXPathException
XPathHandler
number
in interface XPathHandler
number
- the number valueSAXPathException
public void number(double number) throws SAXPathException
XPathHandler
number
in interface XPathHandler
number
- the number valueSAXPathException
public void literal(java.lang.String literal) throws SAXPathException
XPathHandler
literal
in interface XPathHandler
literal
- the string literal valueSAXPathException
public void variableReference(java.lang.String prefix, java.lang.String variableName) throws SAXPathException
XPathHandler
variableReference
in interface XPathHandler
prefix
- the namespace prefix of the variablevariableName
- the local name of the variableSAXPathException
public void startFunction(java.lang.String prefix, java.lang.String functionName) throws SAXPathException
XPathHandler
startFunction
in interface XPathHandler
prefix
- the namespace prefix of the functionfunctionName
- the local name of the functionSAXPathException
public void endFunction() throws SAXPathException
XPathHandler
endFunction
in interface XPathHandler
SAXPathException