Package com.sun.msv.grammar.util
Class ExpressionFinder
- java.lang.Object
-
- com.sun.msv.grammar.util.ExpressionFinder
-
- All Implemented Interfaces:
ExpressionVisitorBoolean
public abstract class ExpressionFinder extends java.lang.Object implements 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.
-
-
Constructor Summary
Constructors Constructor Description ExpressionFinder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanonAnyString()booleanonAttribute(AttributeExp exp)booleanonChoice(ChoiceExp exp)booleanonConcur(ConcurExp exp)booleanonData(DataExp exp)booleanonElement(ElementExp exp)booleanonEpsilon()booleanonInterleave(InterleaveExp exp)booleanonList(ListExp exp)booleanonMixed(MixedExp exp)booleanonNullSet()booleanonOneOrMore(OneOrMoreExp exp)booleanonOther(OtherExp exp)booleanonRef(ReferenceExp exp)booleanonSequence(SequenceExp exp)booleanonValue(ValueExp exp)
-
-
-
Method Detail
-
onSequence
public boolean onSequence(SequenceExp exp)
- Specified by:
onSequencein interfaceExpressionVisitorBoolean
-
onInterleave
public boolean onInterleave(InterleaveExp exp)
- Specified by:
onInterleavein interfaceExpressionVisitorBoolean
-
onConcur
public boolean onConcur(ConcurExp exp)
- Specified by:
onConcurin interfaceExpressionVisitorBoolean
-
onChoice
public boolean onChoice(ChoiceExp exp)
- Specified by:
onChoicein interfaceExpressionVisitorBoolean
-
onAttribute
public boolean onAttribute(AttributeExp exp)
- Specified by:
onAttributein interfaceExpressionVisitorBoolean
-
onElement
public boolean onElement(ElementExp exp)
- Specified by:
onElementin interfaceExpressionVisitorBoolean
-
onOneOrMore
public boolean onOneOrMore(OneOrMoreExp exp)
- Specified by:
onOneOrMorein interfaceExpressionVisitorBoolean
-
onMixed
public boolean onMixed(MixedExp exp)
- Specified by:
onMixedin interfaceExpressionVisitorBoolean
-
onList
public boolean onList(ListExp exp)
- Specified by:
onListin interfaceExpressionVisitorBoolean
-
onRef
public boolean onRef(ReferenceExp exp)
- Specified by:
onRefin interfaceExpressionVisitorBoolean
-
onOther
public boolean onOther(OtherExp exp)
- Specified by:
onOtherin interfaceExpressionVisitorBoolean
-
onEpsilon
public boolean onEpsilon()
- Specified by:
onEpsilonin interfaceExpressionVisitorBoolean
-
onNullSet
public boolean onNullSet()
- Specified by:
onNullSetin interfaceExpressionVisitorBoolean
-
onAnyString
public boolean onAnyString()
- Specified by:
onAnyStringin interfaceExpressionVisitorBoolean
-
onData
public boolean onData(DataExp exp)
- Specified by:
onDatain interfaceExpressionVisitorBoolean
-
onValue
public boolean onValue(ValueExp exp)
- Specified by:
onValuein interfaceExpressionVisitorBoolean
-
-