Package org.drools.core.rule.consequence
Interface InternalMatch
-
- All Superinterfaces:
org.kie.api.runtime.rule.Match,Queue.QueueEntry,java.io.Serializable
- All Known Implementing Classes:
RuleTerminalNodeLeftTuple
public interface InternalMatch extends java.io.Serializable, Queue.QueueEntry, org.kie.api.runtime.rule.Match
When aTuplefully matches a rule it is added to theAgendaAs anActivation. EachActivationis assigned a number, this number is determined by theWorkingMemoryallActivationscreated from a single insert, update, retract are assigned the same Activation number.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default booleancheckProcessInstance(ReteEvaluator workingMemory, java.lang.String processInstanceId)InternalFactHandlegetActivationFactHandle()ActivationGroupNodegetActivationGroupNode()ActivationNodegetActivationNode()longgetActivationNumber()Each PropagationContext is assigned an id from a counter for the WorkingMemory action it represents.InternalAgendaGroupgetAgendaGroup()java.lang.RunnablegetCallback()org.drools.base.rule.consequence.ConsequencegetConsequence()default java.util.List<org.kie.api.runtime.rule.FactHandle>getFactHandles(Tuple tuple)default java.util.List<java.lang.Object>getObjects(Tuple tuple)default java.util.List<java.lang.Object>getObjectsDeep()default java.util.List<java.lang.Object>getObjectsDeep(LeftTuple entry)PropagationContextgetPropagationContext()Retrieve thePropagationContextfor theActivationorg.drools.base.definitions.rule.impl.RuleImplgetRule()RuleAgendaItemgetRuleAgendaItem()TerminalNodegetTerminalNode()TuplegetTuple()Retrieve theTuplethat was activated.booleanisActive()booleanisMatched()voidremove()Cancel theActivationby removing it from theAgenda.voidsetActivationFactHandle(InternalFactHandle factHandle)voidsetActivationGroupNode(ActivationGroupNode activationGroupNode)voidsetActivationNode(ActivationNode ruleFlowGroupNode)voidsetActive(boolean active)voidsetCallback(java.lang.Runnable callback)voidsetMatched(boolean matched)java.lang.StringtoExternalForm()-
Methods inherited from interface org.kie.api.runtime.rule.Match
getDeclarationIds, getDeclarationValue, getFactHandles, getObjects, getSalience
-
Methods inherited from interface org.drools.core.util.Queue.QueueEntry
dequeue, getQueueIndex, isQueued, setQueued, setQueueIndex
-
-
-
-
Method Detail
-
getRule
org.drools.base.definitions.rule.impl.RuleImpl getRule()
- Specified by:
getRulein interfaceorg.kie.api.runtime.rule.Match- Returns:
- The rule that was activated.
-
getConsequence
org.drools.base.rule.consequence.Consequence getConsequence()
-
getActivationNumber
long getActivationNumber()
Each PropagationContext is assigned an id from a counter for the WorkingMemory action it represents. All Activations return this id as the ActivationNumber, thus all Activations created from the same PropagationContext will return the same long for this method.- Returns:
- The activation number
-
getCallback
java.lang.Runnable getCallback()
-
setCallback
void setCallback(java.lang.Runnable callback)
-
getObjectsDeep
default java.util.List<java.lang.Object> getObjectsDeep()
-
getTuple
Tuple getTuple()
Retrieve theTuplethat was activated.- Returns:
- The tuple.
-
getPropagationContext
PropagationContext getPropagationContext()
Retrieve thePropagationContextfor theActivation- Returns:
- The propagation context
-
remove
void remove()
Cancel theActivationby removing it from theAgenda.
-
getAgendaGroup
InternalAgendaGroup getAgendaGroup()
-
getActivationGroupNode
ActivationGroupNode getActivationGroupNode()
-
setActivationGroupNode
void setActivationGroupNode(ActivationGroupNode activationGroupNode)
-
getActivationNode
ActivationNode getActivationNode()
-
setActivationNode
void setActivationNode(ActivationNode ruleFlowGroupNode)
-
getActivationFactHandle
InternalFactHandle getActivationFactHandle()
-
isMatched
boolean isMatched()
-
setMatched
void setMatched(boolean matched)
-
isActive
boolean isActive()
-
setActive
void setActive(boolean active)
-
setActivationFactHandle
void setActivationFactHandle(InternalFactHandle factHandle)
-
getRuleAgendaItem
RuleAgendaItem getRuleAgendaItem()
-
getTerminalNode
TerminalNode getTerminalNode()
-
toExternalForm
java.lang.String toExternalForm()
-
getFactHandles
default java.util.List<org.kie.api.runtime.rule.FactHandle> getFactHandles(Tuple tuple)
-
getObjectsDeep
default java.util.List<java.lang.Object> getObjectsDeep(LeftTuple entry)
-
getObjects
default java.util.List<java.lang.Object> getObjects(Tuple tuple)
-
checkProcessInstance
default boolean checkProcessInstance(ReteEvaluator workingMemory, java.lang.String processInstanceId)
-
-