Package com.yahoo.searchlib.treenet.rule
Class Condition
- java.lang.Object
-
- com.yahoo.searchlib.treenet.rule.TreeNode
-
- com.yahoo.searchlib.treenet.rule.Condition
-
- Direct Known Subclasses:
ComparisonCondition
,SetMembershipCondition
public abstract class Condition extends TreeNode
Represents a condition- Author:
- bratseth
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract String
conditionToRankingExpression()
Returns the ranking expression string for the condition part of this condition, i.e the ...String
getFalseLabel()
Return the label to jump to if this condition is false.String
getLeftValue()
Returns the name of the feature to compare to a constant.String
getTrueLabel()
Return the label to jump to if this condition is true.String
toRankingExpression()
Returns a ranking expression equivalent of this net.
-
-
-
Method Detail
-
getLeftValue
public String getLeftValue()
Returns the name of the feature to compare to a constant.
-
getTrueLabel
public String getTrueLabel()
Return the label to jump to if this condition is true.
-
getFalseLabel
public String getFalseLabel()
Return the label to jump to if this condition is false.
-
toRankingExpression
public final String toRankingExpression()
Description copied from class:TreeNode
Returns a ranking expression equivalent of this net.- Specified by:
toRankingExpression
in classTreeNode
-
conditionToRankingExpression
protected abstract String conditionToRankingExpression()
Returns the ranking expression string for the condition part of this condition, i.e the ... part ofif(leftValue ..., trueExpression, falseExpression)
-
-