Package org.drools.mvel.expr
Class MVELAccumulator
- java.lang.Object
-
- org.drools.mvel.expr.MVELAccumulator
-
- All Implemented Interfaces:
Externalizable,Serializable,org.drools.core.rule.accessor.Accumulator,org.drools.core.rule.accessor.Invoker,org.drools.core.rule.RuleComponent,MVELCompileable
public class MVELAccumulator extends Object implements MVELCompileable, org.drools.core.rule.accessor.Accumulator, Externalizable
An MVEL accumulator implementation- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description MVELAccumulator()MVELAccumulator(MVELCompilationUnit initUnit, MVELCompilationUnit actionUnit, MVELCompilationUnit reverseUnit, MVELCompilationUnit resultUnit)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Objectaccumulate(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.common.InternalFactHandle handle, org.drools.core.rule.Declaration[] declarations, org.drools.core.rule.Declaration[] innerDeclarations, org.drools.core.common.ReteEvaluator reteEvaluator)voidcompile(MVELDialectRuntimeData runtimeData)voidcompile(MVELDialectRuntimeData runtimeData, org.drools.core.definitions.rule.impl.RuleImpl rule)ObjectcreateContext()ObjectcreateWorkingMemoryContext()org.drools.core.rule.Declaration[]getRequiredDeclarations()ObjectgetResult(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.rule.Declaration[] declarations, org.drools.core.common.ReteEvaluator reteEvaluator)Objectinit(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.rule.Declaration[] declarations, org.drools.core.common.ReteEvaluator reteEvaluator)voidreadExternal(ObjectInput in)booleansupportsReverse()booleantryReverse(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple leftTuple, org.drools.core.common.InternalFactHandle handle, Object value, org.drools.core.rule.Declaration[] declarations, org.drools.core.rule.Declaration[] innerDeclarations, org.drools.core.common.ReteEvaluator reteEvaluator)voidwriteExternal(ObjectOutput out)
-
-
-
Constructor Detail
-
MVELAccumulator
public MVELAccumulator()
-
MVELAccumulator
public MVELAccumulator(MVELCompilationUnit initUnit, MVELCompilationUnit actionUnit, MVELCompilationUnit reverseUnit, MVELCompilationUnit resultUnit)
-
-
Method Detail
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
compile
public void compile(MVELDialectRuntimeData runtimeData)
- Specified by:
compilein interfaceMVELCompileable
-
compile
public void compile(MVELDialectRuntimeData runtimeData, org.drools.core.definitions.rule.impl.RuleImpl rule)
- Specified by:
compilein interfaceMVELCompileable
-
createContext
public Object createContext()
- Specified by:
createContextin interfaceorg.drools.core.rule.accessor.Accumulator
-
init
public Object init(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.rule.Declaration[] declarations, org.drools.core.common.ReteEvaluator reteEvaluator)
- Specified by:
initin interfaceorg.drools.core.rule.accessor.Accumulator
-
accumulate
public Object accumulate(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.common.InternalFactHandle handle, org.drools.core.rule.Declaration[] declarations, org.drools.core.rule.Declaration[] innerDeclarations, org.drools.core.common.ReteEvaluator reteEvaluator)
- Specified by:
accumulatein interfaceorg.drools.core.rule.accessor.Accumulator
-
tryReverse
public boolean tryReverse(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple leftTuple, org.drools.core.common.InternalFactHandle handle, Object value, org.drools.core.rule.Declaration[] declarations, org.drools.core.rule.Declaration[] innerDeclarations, org.drools.core.common.ReteEvaluator reteEvaluator)
- Specified by:
tryReversein interfaceorg.drools.core.rule.accessor.Accumulator
-
getResult
public Object getResult(Object workingMemoryContext, Object context, org.drools.core.reteoo.Tuple tuple, org.drools.core.rule.Declaration[] declarations, org.drools.core.common.ReteEvaluator reteEvaluator)
- Specified by:
getResultin interfaceorg.drools.core.rule.accessor.Accumulator
-
supportsReverse
public boolean supportsReverse()
- Specified by:
supportsReversein interfaceorg.drools.core.rule.accessor.Accumulator
-
createWorkingMemoryContext
public Object createWorkingMemoryContext()
- Specified by:
createWorkingMemoryContextin interfaceorg.drools.core.rule.accessor.Accumulator
-
getRequiredDeclarations
public org.drools.core.rule.Declaration[] getRequiredDeclarations()
- Specified by:
getRequiredDeclarationsin interfaceorg.drools.core.rule.accessor.Accumulator
-
-