Package org.drools.core.rule
Class Forall
- java.lang.Object
-
- org.drools.core.rule.ConditionalElement
-
- org.drools.core.rule.Forall
-
- All Implemented Interfaces:
Externalizable,Serializable,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()Map<String,Declaration>getInnerDeclarations()Forall inner declarations are only provided by the base patterns since it negates the remaining patternsList<Pattern>getNestedElements()Returs a list of RuleConditionElement's that are nested inside the current elementMap<String,Declaration>getOuterDeclarations()Forall does not export any declarationsList<Pattern>getRemainingPatterns()booleanisEmptyBetaConstraints()booleanisPatternScopeDelimiter()Returns true in case this RuleConditionElement delimits a pattern visibility scope.voidreadExternal(ObjectInput in)DeclarationresolveDeclaration(String identifier)Forall can only resolve declarations from its base patternvoidsetBasePattern(Pattern basePattern)voidsetEmptyBetaConstraints(boolean emptyBetaConstraints)voidsetRemainingPatterns(List<Pattern> remainingPatterns)StringtoString()voidwriteExternal(ObjectOutput out)
-
-
-
Method Detail
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Throws:
IOExceptionClassNotFoundException
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Throws:
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 Map<String,Declaration> getInnerDeclarations()
Forall inner declarations are only provided by the base patterns since it negates the remaining patterns- Returns:
-
getOuterDeclarations
public Map<String,Declaration> getOuterDeclarations()
Forall does not export any declarations- Returns:
-
resolveDeclaration
public Declaration resolveDeclaration(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
-
setRemainingPatterns
public void setRemainingPatterns(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 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)
-
-