Package com.yahoo.prelude.semantics.rule
Class ComparisonCondition
java.lang.Object
com.yahoo.prelude.semantics.rule.Condition
com.yahoo.prelude.semantics.rule.CompositeCondition
com.yahoo.prelude.semantics.rule.ComparisonCondition
A condition which is true of the values of its two subconditions are true
and both have the same value
- Author:
- bratseth
-
Nested Class Summary
Nested classes/interfaces inherited from class com.yahoo.prelude.semantics.rule.Condition
Condition.Anchor -
Constructor Summary
ConstructorsConstructorDescriptionComparisonCondition(Condition leftCondition, String operatorString, Condition rightCondition) -
Method Summary
Modifier and TypeMethodDescriptionprotected booleandoesMatch(RuleEvaluation evaluation) Returns whether this condition matches the given evaluation at the current location of the evaluation.voidsetLeftCondition(Condition leftCondition) voidsetRightCondition(Condition rightCondition) protected StringAll instances of this produces a parseable string outputprotected voidtraceResult(boolean matches, RuleEvaluation e) protected voidtraceResult(boolean matches, RuleEvaluation e, Object left, Object right) Methods inherited from class com.yahoo.prelude.semantics.rule.CompositeCondition
addCondition, allSubConditionsMatches, conditionIterator, conditions, conditionSize, conditionsToString, getCondition, hasOpenChoicepoint, makeReferences, postMatchHook, preMatchHook, removeCondition, setCondition, toInnerString, useParenthesesMethods inherited from class com.yahoo.prelude.semantics.rule.Condition
getAnchor, getContextName, getLabel, getLabelString, getMatchInfo, getMatchInfoString, getNameSpace, getParent, isDefaultContextName, isReferable, labelMatches, labelMatches, matches, matchesEndAnchor, matchesStartAnchor, setAnchor, setContextName, setLabel, setNameSpace, toString
-
Constructor Details
-
ComparisonCondition
-
-
Method Details
-
doesMatch
Description copied from class:ConditionReturns whether this condition matches the given evaluation at the current location of the evaluation. If there is a match, the evaluation must be advanced to the location beyond the matching item(s) before this method returns. -
traceResult
- Overrides:
traceResultin classCondition
-
traceResult
-
getLeftCondition
-
setLeftCondition
-
getRightCondition
-
setRightCondition
-
toInnerString
Description copied from class:ConditionAll instances of this produces a parseable string output- Specified by:
toInnerStringin classCondition
-