public class InstanceNotEqualsConstraint extends Object implements BetaNodeFieldConstraint
Modifier and Type | Class and Description |
---|---|
static class |
InstanceNotEqualsConstraint.InstanceNotEqualsConstraintContextEntry |
Constraint.ConstraintType
Constructor and Description |
---|
InstanceNotEqualsConstraint() |
InstanceNotEqualsConstraint(Pattern otherPattern) |
Modifier and Type | Method and Description |
---|---|
InstanceNotEqualsConstraint |
clone()
Clones the constraint
|
BetaNodeFieldConstraint |
cloneIfInUse()
Clone this constraints only if it is already used by a different node, otherwise returns this
|
ContextEntry |
createContextEntry() |
boolean |
equals(Object object) |
Pattern |
getOtherPattern() |
Declaration[] |
getRequiredDeclarations()
Returns all the declarations required by the given
constraint implementation.
|
Constraint.ConstraintType |
getType()
Returns the type of the constraint, either ALPHA, BETA or UNKNOWN
|
int |
hashCode() |
boolean |
isAllowed(ContextEntry entry) |
boolean |
isAllowedCachedLeft(ContextEntry context,
InternalFactHandle handle) |
boolean |
isAllowedCachedRight(LeftTuple tuple,
ContextEntry context) |
boolean |
isTemporal()
Returns true in case this constraint is a temporal constraint
|
void |
readExternal(ObjectInput in) |
void |
replaceDeclaration(Declaration oldDecl,
Declaration newDecl)
When a rule contains multiple logical branches, i.e., makes
use of 'OR' CE, it is required to clone patterns and declarations
for each logical branch.
|
String |
toString() |
void |
writeExternal(ObjectOutput out) |
public InstanceNotEqualsConstraint()
public InstanceNotEqualsConstraint(Pattern otherPattern)
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
IOException
ClassNotFoundException
public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
IOException
public Declaration[] getRequiredDeclarations()
Constraint
getRequiredDeclarations
in interface Constraint
public void replaceDeclaration(Declaration oldDecl, Declaration newDecl)
Constraint
replaceDeclaration
in interface Constraint
public Pattern getOtherPattern()
public boolean isTemporal()
Constraint
isTemporal
in interface Constraint
public ContextEntry createContextEntry()
createContextEntry
in interface BetaNodeFieldConstraint
public boolean isAllowed(ContextEntry entry)
public boolean isAllowedCachedLeft(ContextEntry context, InternalFactHandle handle)
isAllowedCachedLeft
in interface BetaNodeFieldConstraint
public boolean isAllowedCachedRight(LeftTuple tuple, ContextEntry context)
isAllowedCachedRight
in interface BetaNodeFieldConstraint
public InstanceNotEqualsConstraint clone()
Constraint
clone
in interface Constraint
clone
in class Object
public Constraint.ConstraintType getType()
Constraint
getType
in interface Constraint
public BetaNodeFieldConstraint cloneIfInUse()
BetaNodeFieldConstraint
cloneIfInUse
in interface BetaNodeFieldConstraint
Copyright © 2001-2015 JBoss by Red Hat. All Rights Reserved.