public class MVELAccumulatorFunctionExecutor extends Object implements MVELCompileable, Externalizable, MvelAccumulator
Accumulator.SafeAccumulator| Constructor and Description |
|---|
MVELAccumulatorFunctionExecutor() |
MVELAccumulatorFunctionExecutor(MVELCompilationUnit unit,
org.kie.api.runtime.rule.AccumulateFunction function) |
| Modifier and Type | Method and Description |
|---|---|
void |
accumulate(Object workingMemoryContext,
Object context,
Tuple tuple,
InternalFactHandle handle,
Declaration[] declarations,
Declaration[] innerDeclarations,
WorkingMemory workingMemory)
Executes the accumulate (action) code for the given fact handle
|
void |
compile(MVELDialectRuntimeData runtimeData) |
void |
compile(MVELDialectRuntimeData runtimeData,
RuleImpl rule) |
Serializable |
createContext()
Creates the context object for an accumulator session.
|
Object |
createWorkingMemoryContext()
Creates and return a context object for each working memory instance
|
Declaration[] |
getRequiredDeclarations() |
Object |
getResult(Object workingMemoryContext,
Object context,
Tuple leftTuple,
Declaration[] declarations,
WorkingMemory workingMemory)
Gets the result of the accummulation
|
void |
init(Object workingMemoryContext,
Object context,
Tuple leftTuple,
Declaration[] declarations,
WorkingMemory workingMemory)
Executes the initialization block of code
|
void |
readExternal(ObjectInput in) |
void |
replaceDeclaration(Declaration declaration,
Declaration resolved) |
void |
reverse(Object workingMemoryContext,
Object context,
Tuple leftTuple,
InternalFactHandle handle,
Declaration[] declarations,
Declaration[] innerDeclarations,
WorkingMemory workingMemory)
Reverses the accumulate action for the given fact handle
|
boolean |
supportsReverse()
Returns true if this accumulator supports operation reversal
|
void |
writeExternal(ObjectOutput out) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitisCompiledInvokerpublic MVELAccumulatorFunctionExecutor()
public MVELAccumulatorFunctionExecutor(MVELCompilationUnit unit, org.kie.api.runtime.rule.AccumulateFunction function)
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal in interface ExternalizableIOExceptionClassNotFoundExceptionpublic void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizableIOExceptionpublic void compile(MVELDialectRuntimeData runtimeData)
compile in interface MVELCompileablepublic void compile(MVELDialectRuntimeData runtimeData, RuleImpl rule)
compile in interface MVELCompileablepublic Serializable createContext()
AccumulatorcreateContext in interface Accumulatorpublic void init(Object workingMemoryContext, Object context, Tuple leftTuple, Declaration[] declarations, WorkingMemory workingMemory) throws Exception
Accumulatorinit in interface AccumulatorleftTuple - tuple causing the rule firedeclarations - previous declarationsExceptionpublic void accumulate(Object workingMemoryContext, Object context, Tuple tuple, InternalFactHandle handle, Declaration[] declarations, Declaration[] innerDeclarations, WorkingMemory workingMemory) throws Exception
Accumulatoraccumulate in interface AccumulatorExceptionpublic void reverse(Object workingMemoryContext, Object context, Tuple leftTuple, InternalFactHandle handle, Declaration[] declarations, Declaration[] innerDeclarations, WorkingMemory workingMemory) throws Exception
Accumulatorreverse in interface AccumulatorExceptionpublic Object getResult(Object workingMemoryContext, Object context, Tuple leftTuple, Declaration[] declarations, WorkingMemory workingMemory) throws Exception
AccumulatorgetResult in interface AccumulatorExceptionpublic boolean supportsReverse()
AccumulatorsupportsReverse in interface Accumulatorpublic Object createWorkingMemoryContext()
AccumulatorcreateWorkingMemoryContext in interface Accumulatorpublic Declaration[] getRequiredDeclarations()
getRequiredDeclarations in interface MvelAccumulatorpublic void replaceDeclaration(Declaration declaration, Declaration resolved)
Copyright © 2001–2019 JBoss by Red Hat. All rights reserved.