Package org.drools.base.rule
Class Collect
- java.lang.Object
-
- org.drools.base.rule.ConditionalElement
-
- org.drools.base.rule.Collect
-
- All Implemented Interfaces:
java.io.Externalizable,java.io.Serializable,java.lang.Cloneable,PatternSource,RuleComponent,RuleConditionElement
public class Collect extends ConditionalElement implements PatternSource
- See Also:
- Serialized Form
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Collectclone()Returns a clone from itselfbooleanequals(java.lang.Object o)java.util.Map<java.lang.String,Declaration>getInnerDeclarations()Returns a Map of declarations that are visible inside this conditional elementjava.util.List<Pattern>getNestedElements()Returs a list of RuleConditionElement's that are nested inside the current elementjava.util.Map<java.lang.String,Declaration>getOuterDeclarations()Returns a Map of declarations that are visible outside this conditional element.PatterngetResultPattern()PatterngetSourcePattern()inthashCode()java.util.Collection<java.lang.Object>instantiateResultObject(ValueResolver valueResolver)booleanisPatternScopeDelimiter()Returns true in case this RuleConditionElement delimits a pattern visibility scope.voidreadExternal(java.io.ObjectInput in)booleanrequiresLeftActivation()DeclarationresolveDeclaration(java.lang.String identifier)Resolves the given identifier in the current scope and returns the Declaration object for the declaration.voidwriteExternal(java.io.ObjectOutput out)
-
-
-
Method Detail
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException- Specified by:
readExternalin interfacejava.io.Externalizable- Throws:
java.io.IOExceptionjava.lang.ClassNotFoundException
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException- Specified by:
writeExternalin interfacejava.io.Externalizable- Throws:
java.io.IOException
-
clone
public Collect clone()
Description copied from interface:RuleConditionElementReturns a clone from itself- Specified by:
clonein interfaceRuleConditionElement- Specified by:
clonein classConditionalElement- Returns:
-
getResultPattern
public Pattern getResultPattern()
-
getSourcePattern
public Pattern getSourcePattern()
-
instantiateResultObject
public java.util.Collection<java.lang.Object> instantiateResultObject(ValueResolver valueResolver) throws java.lang.RuntimeException
- Throws:
java.lang.RuntimeException
-
getInnerDeclarations
public java.util.Map<java.lang.String,Declaration> getInnerDeclarations()
Description copied from interface:RuleConditionElementReturns a Map of declarations that are visible inside this conditional element- Specified by:
getInnerDeclarationsin interfaceRuleConditionElement- Returns:
-
getOuterDeclarations
public java.util.Map<java.lang.String,Declaration> getOuterDeclarations()
Description copied from interface:RuleConditionElementReturns a Map of declarations that are visible outside this conditional element.- Specified by:
getOuterDeclarationsin interfaceRuleConditionElement- Returns:
-
resolveDeclaration
public Declaration resolveDeclaration(java.lang.String identifier)
Description copied from interface:RuleConditionElementResolves the given identifier in the current scope and returns the Declaration object for the declaration. Returns null if identifier can not be resolved.- Specified by:
resolveDeclarationin interfaceRuleConditionElement- Returns:
-
getNestedElements
public java.util.List<Pattern> getNestedElements()
Description copied from interface:RuleConditionElementReturs a list of RuleConditionElement's that are nested inside the current element- Specified by:
getNestedElementsin interfaceRuleConditionElement- 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- Specified by:
isPatternScopeDelimiterin interfaceRuleConditionElement- Returns:
-
requiresLeftActivation
public boolean requiresLeftActivation()
- Specified by:
requiresLeftActivationin interfacePatternSource
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
-