Package com.sun.msv.grammar.util
Class ExpressionFinder
java.lang.Object
com.sun.msv.grammar.util.ExpressionFinder
- All Implemented Interfaces:
ExpressionVisitorBoolean
Base class for "finding" something from an expression.
This class visits all reachable expressions and returns boolean.
In any binary expression, if one branch returns true, then the binary
expression itself returns true. Thus it can be used to find something
from an expression.
Note that unless the derived class do something, this implementation
will recurse infinitely.
- Author:
- Kohsuke KAWAGUCHI
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
boolean
onAttribute
(AttributeExp exp) boolean
boolean
boolean
boolean
onElement
(ElementExp exp) boolean
boolean
boolean
boolean
boolean
boolean
onOneOrMore
(OneOrMoreExp exp) boolean
boolean
onRef
(ReferenceExp exp) boolean
onSequence
(SequenceExp exp) boolean
-
Constructor Details
-
ExpressionFinder
public ExpressionFinder()
-
-
Method Details
-
onSequence
- Specified by:
onSequence
in interfaceExpressionVisitorBoolean
-
onInterleave
- Specified by:
onInterleave
in interfaceExpressionVisitorBoolean
-
onConcur
- Specified by:
onConcur
in interfaceExpressionVisitorBoolean
-
onChoice
- Specified by:
onChoice
in interfaceExpressionVisitorBoolean
-
onAttribute
- Specified by:
onAttribute
in interfaceExpressionVisitorBoolean
-
onElement
- Specified by:
onElement
in interfaceExpressionVisitorBoolean
-
onOneOrMore
- Specified by:
onOneOrMore
in interfaceExpressionVisitorBoolean
-
onMixed
- Specified by:
onMixed
in interfaceExpressionVisitorBoolean
-
onList
- Specified by:
onList
in interfaceExpressionVisitorBoolean
-
onRef
- Specified by:
onRef
in interfaceExpressionVisitorBoolean
-
onOther
- Specified by:
onOther
in interfaceExpressionVisitorBoolean
-
onEpsilon
public boolean onEpsilon()- Specified by:
onEpsilon
in interfaceExpressionVisitorBoolean
-
onNullSet
public boolean onNullSet()- Specified by:
onNullSet
in interfaceExpressionVisitorBoolean
-
onAnyString
public boolean onAnyString()- Specified by:
onAnyString
in interfaceExpressionVisitorBoolean
-
onData
- Specified by:
onData
in interfaceExpressionVisitorBoolean
-
onValue
- Specified by:
onValue
in interfaceExpressionVisitorBoolean
-