Package org.drools.base.rule
Class MutableTypeConstraint<C>
java.lang.Object
org.drools.base.rule.MutableTypeConstraint<C>
- All Implemented Interfaces:
Externalizable,Serializable,Cloneable,AlphaNodeFieldConstraint,BetaConstraint<C>,Constraint,RuleComponent
- Direct Known Subclasses:
XpathConstraint
public abstract class MutableTypeConstraint<C>
extends Object
implements AlphaNodeFieldConstraint, BetaConstraint<C>, Externalizable
A base class for constraints
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.drools.base.rule.constraint.Constraint
Constraint.ConstraintType -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract MutableTypeConstraintclone()Clones the constraintClone this constraints only if it is already used by a different node, otherwise returns thisgetType()Returns the type of the constraint, either ALPHA, BETA or UNKNOWNvoidbooleansetInUse()voidvoidMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.drools.base.rule.constraint.AlphaNodeFieldConstraint
isAllowedMethods inherited from interface org.drools.base.rule.constraint.BetaConstraint
createContext, isAllowedCachedLeft, isAllowedCachedRightMethods inherited from interface org.drools.base.rule.constraint.Constraint
addPackageNames, equals, getListenedPropertyMask, getPackageNames, getRequiredDeclarations, isTemporal, mergeEvaluationContext, registerEvaluationContext, replaceDeclaration
-
Constructor Details
-
MutableTypeConstraint
public MutableTypeConstraint()
-
-
Method Details
-
setType
-
getType
Description copied from interface:ConstraintReturns the type of the constraint, either ALPHA, BETA or UNKNOWN- Specified by:
getTypein interfaceConstraint- Returns:
-
readExternal
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
writeExternal
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
clone
Description copied from interface:ConstraintClones the constraint- Specified by:
clonein interfaceConstraint- Overrides:
clonein classObject- Returns:
-
cloneIfInUse
Description copied from interface:AlphaNodeFieldConstraintClone this constraints only if it is already used by a different node, otherwise returns this- Specified by:
cloneIfInUsein interfaceAlphaNodeFieldConstraint- Specified by:
cloneIfInUsein interfaceBetaConstraint<C>
-
setInUse
public boolean setInUse()
-