public class OrConstraint extends Object implements Constraint
OrConstraint
implements an OR constraint.Constructor and Description |
---|
OrConstraint(Constraint left,
Constraint right)
Creates a new OR constraint.
|
Modifier and Type | Method and Description |
---|---|
boolean |
evaluate(ScoreNode[] row,
Name[] selectorNames,
EvaluationContext context)
Evaluates this constraint for the given row.
|
public OrConstraint(Constraint left, Constraint right)
left
- the left operand.right
- the right operand.public boolean evaluate(ScoreNode[] row, Name[] selectorNames, EvaluationContext context) throws IOException
evaluate
in interface Constraint
row
- the current row of score nodes.selectorNames
- the selector names associated with row
.context
- the evaluation context.true
if the row satisfies the constraint,
false
otherwise.IOException
- if an error occurs while evaluating the constraint.Copyright © 2004–2024 The Apache Software Foundation. All rights reserved.