Package org.drools.base.rule
Class Forall
- java.lang.Object
-
- org.drools.base.rule.ConditionalElement
-
- org.drools.base.rule.Forall
-
- All Implemented Interfaces:
java.io.Externalizable,java.io.Serializable,java.lang.Cloneable,RuleComponent,RuleConditionElement
public class Forall extends ConditionalElement
The forall conditional element.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddRemainingPattern(Pattern pattern)Adds one more pattern to the list of remaining patternsForallclone()Returns a clone from itselfPatterngetBasePattern()java.util.Map<java.lang.String,Declaration>getInnerDeclarations()Forall inner declarations are only provided by the base patterns since it negates the remaining patternsjava.util.List<Pattern>getNestedElements()Returs a list of RuleConditionElement's that are nested inside the current elementjava.util.Map<java.lang.String,Declaration>getOuterDeclarations()Forall does not export any declarationsjava.util.List<Pattern>getRemainingPatterns()booleanisEmptyBetaConstraints()booleanisPatternScopeDelimiter()Returns true in case this RuleConditionElement delimits a pattern visibility scope.voidreadExternal(java.io.ObjectInput in)DeclarationresolveDeclaration(java.lang.String identifier)Forall can only resolve declarations from its base patternvoidsetBasePattern(Pattern basePattern)voidsetEmptyBetaConstraints(boolean emptyBetaConstraints)voidsetRemainingPatterns(java.util.List<Pattern> remainingPatterns)java.lang.StringtoString()voidwriteExternal(java.io.ObjectOutput out)
-
-
-
Method Detail
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException- Throws:
java.io.IOExceptionjava.lang.ClassNotFoundException
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException- Throws:
java.io.IOException
-
clone
public Forall clone()
Description copied from interface:RuleConditionElementReturns a clone from itself- Specified by:
clonein interfaceRuleConditionElement- Specified by:
clonein classConditionalElement- Returns:
-
getInnerDeclarations
public java.util.Map<java.lang.String,Declaration> getInnerDeclarations()
Forall inner declarations are only provided by the base patterns since it negates the remaining patterns- Returns:
-
getOuterDeclarations
public java.util.Map<java.lang.String,Declaration> getOuterDeclarations()
Forall does not export any declarations- Returns:
-
resolveDeclaration
public Declaration resolveDeclaration(java.lang.String identifier)
Forall can only resolve declarations from its base pattern- Returns:
-
getBasePattern
public Pattern getBasePattern()
- Returns:
- the basePattern
-
setBasePattern
public void setBasePattern(Pattern basePattern)
- Parameters:
basePattern- the basePattern to set
-
getRemainingPatterns
public java.util.List<Pattern> getRemainingPatterns()
- Returns:
- the remainingPatterns
-
setRemainingPatterns
public void setRemainingPatterns(java.util.List<Pattern> remainingPatterns)
- Parameters:
remainingPatterns- the remainingPatterns to set
-
addRemainingPattern
public void addRemainingPattern(Pattern pattern)
Adds one more pattern to the list of remaining patterns
-
getNestedElements
public java.util.List<Pattern> getNestedElements()
Description copied from interface:RuleConditionElementReturs a list of RuleConditionElement's that are nested inside the current element- Returns:
-
isPatternScopeDelimiter
public boolean isPatternScopeDelimiter()
Description copied from interface:RuleConditionElementReturns true in case this RuleConditionElement delimits a pattern visibility scope. For instance, AND CE is not a scope delimiter, while NOT CE is a scope delimiter- Returns:
-
isEmptyBetaConstraints
public boolean isEmptyBetaConstraints()
-
setEmptyBetaConstraints
public void setEmptyBetaConstraints(boolean emptyBetaConstraints)
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-