public class PredicateConstraint extends MutableTypeConstraint implements Restriction, Wireable, Externalizable
Modifier and Type | Class and Description |
---|---|
static class |
PredicateConstraint.PredicateContextEntry |
static class |
PredicateConstraint.SafePredicateExpression |
Constraint.ConstraintType
Constructor and Description |
---|
PredicateConstraint() |
PredicateConstraint(Declaration[] previousDeclarations,
Declaration[] localDeclarations) |
PredicateConstraint(PredicateExpression evaluator) |
PredicateConstraint(PredicateExpression expression,
Declaration[] previousDeclarations,
Declaration[] localDeclarations,
String[] requiredGlobals,
String[] requiredOperators) |
cloneIfInUse, getType, setInUse, setType
public PredicateConstraint()
public PredicateConstraint(PredicateExpression evaluator)
public PredicateConstraint(Declaration[] previousDeclarations, Declaration[] localDeclarations)
public PredicateConstraint(PredicateExpression expression, Declaration[] previousDeclarations, Declaration[] localDeclarations, String[] requiredGlobals, String[] requiredOperators)
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
readExternal
in class MutableTypeConstraint
IOException
ClassNotFoundException
public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
writeExternal
in class MutableTypeConstraint
IOException
public Declaration[] getRequiredDeclarations()
Constraint
getRequiredDeclarations
in interface Constraint
getRequiredDeclarations
in interface Restriction
public Declaration[] getPreviousDeclarations()
public Declaration[] getLocalDeclarations()
public String[] getGlobals()
public String[] getOperators()
public void replaceDeclaration(Declaration oldDecl, Declaration newDecl)
Restriction
replaceDeclaration
in interface Constraint
replaceDeclaration
in interface Restriction
public void setPredicateExpression(PredicateExpression expression)
public PredicateExpression getPredicateExpression()
public boolean isTemporal()
Restriction
isTemporal
in interface Constraint
isTemporal
in interface Restriction
public ContextEntry createContextEntry()
createContextEntry
in interface BetaNodeFieldConstraint
createContextEntry
in interface Restriction
public boolean isAllowed(InternalFactHandle handle, InternalWorkingMemory workingMemory)
isAllowed
in interface AlphaNodeFieldConstraint
public boolean isAllowed(InternalReadAccessor extractor, InternalFactHandle handle, InternalWorkingMemory workingMemory, ContextEntry context)
isAllowed
in interface Restriction
public boolean isAllowedCachedLeft(ContextEntry context, InternalFactHandle handle)
isAllowedCachedLeft
in interface BetaNodeFieldConstraint
isAllowedCachedLeft
in interface Restriction
public boolean isAllowedCachedRight(Tuple tuple, ContextEntry context)
isAllowedCachedRight
in interface BetaNodeFieldConstraint
isAllowedCachedRight
in interface Restriction
public PredicateConstraint clone()
Constraint
clone
in interface Constraint
clone
in interface Restriction
clone
in class MutableTypeConstraint
public Evaluator getEvaluator()
getEvaluator
in interface Restriction
Copyright © 2001–2017 JBoss by Red Hat. All rights reserved.