Package org.drools.core.reteoo
Class RuleTerminalNodeLeftTuple
- java.lang.Object
-
- org.drools.core.reteoo.AbstractTuple
-
- org.drools.core.reteoo.LeftTuple
-
- org.drools.core.reteoo.RuleTerminalNodeLeftTuple
-
- All Implemented Interfaces:
java.io.Serializable,org.drools.base.reteoo.BaseTuple,Tuple,InternalMatch,Entry<AbstractTuple>,Queue.QueueEntry,org.kie.api.runtime.rule.Match
public class RuleTerminalNodeLeftTuple extends LeftTuple implements InternalMatch
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected RuleAgendaItemruleAgendaItem-
Fields inherited from class org.drools.core.reteoo.AbstractTuple
handle, handleNext, handlePrevious, stagedNext, stagedPrevious
-
-
Constructor Summary
Constructors Constructor Description RuleTerminalNodeLeftTuple()RuleTerminalNodeLeftTuple(InternalFactHandle factHandle, LeftTuple leftTuple, Sink sink)RuleTerminalNodeLeftTuple(InternalFactHandle factHandle, Sink sink, boolean leftTupleMemoryEnabled)RuleTerminalNodeLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, LeftTuple currentLeftChild, LeftTuple currentRightChild, Sink sink, boolean leftTupleMemoryEnabled)RuleTerminalNodeLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, Sink sink)RuleTerminalNodeLeftTuple(LeftTuple leftTuple, Sink sink, PropagationContext pctx, boolean leftTupleMemoryEnabled)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcancelActivation(ActivationsManager activationsManager)voiddequeue()booleanequals(java.lang.Object o)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()java.util.List<java.lang.String>getDeclarationIds()java.lang.ObjectgetDeclarationValue(java.lang.String variableName)java.util.List<org.kie.api.runtime.rule.FactHandle>getFactHandles()java.util.List<java.lang.Object>getObjects()java.util.List<java.lang.Object>getObjectsDeep()intgetQueueIndex()org.drools.base.definitions.rule.impl.RuleImplgetRule()Retrieve the rule.RuleAgendaItemgetRuleAgendaItem()intgetSalience()TerminalNodegetTerminalNode()LeftTuplegetTuple()Retrieve the tuple.booleanhasBlockers()inthashCode()voidinit(long activationNumber, int salience, PropagationContext pctx, RuleAgendaItem ruleAgendaItem, InternalAgendaGroup agendaGroup)booleanisActive()booleanisMatched()booleanisQueued()voidremove()Cancel theActivationby removing it from theAgenda.voidsetActivationFactHandle(InternalFactHandle factHandle)voidsetActivationGroupNode(ActivationGroupNode activationNode)voidsetActivationNode(ActivationNode activationNode)voidsetActive(boolean active)voidsetCallback(java.lang.Runnable callback)voidsetMatched(boolean matched)voidsetQueued(boolean queued)voidsetQueueIndex(int queueIndex)voidsetSalience(int salience)protected voidsetSink(Sink sink)java.lang.StringtoExternalForm()java.lang.StringtoString()voidupdate(int salience, PropagationContext pctx)-
Methods inherited from class org.drools.core.reteoo.LeftTuple
clear, clearBlocker, clearStaged, get, getAccumulatedObjects, getBlockedNext, getBlockedPrevious, getBlocker, getFirstChild, getHandleNext, getHandlePrevious, getIndex, getInputOtnId, getLastChild, getLeftParent, getMemory, getNextParentWithHandle, getObject, getParent, getPeer, getRightParent, getRightParentNext, getRightParentPrevious, getStagedNext, getStagedPrevious, getStagedTypeForQueries, getSubTuple, getTupleSink, getTupleSource, initPeer, isStagedOnRight, reAdd, reAddLeft, reAddRight, setBlockedNext, setBlockedPrevious, setBlocker, setFirstChild, setLastChild, setLeftParent, setLeftTupleSink, setMemory, setPeer, setRightParent, setRightParentNext, setRightParentPrevious, setStagedTypeForQueries, size, toExternalString, toFactHandles, toObjects, unlinkFromLeftParent, unlinkFromRightParent
-
Methods inherited from class org.drools.core.reteoo.AbstractTuple
get, getContextObject, getFactHandle, getNext, getObject, getOriginalFactHandle, getPrevious, getPropagationContext, getRootTuple, getSink, getStagedType, getTuple, isExpired, setContextObject, setExpired, setFactHandle, setHandleNext, setHandlePrevious, setNext, setPrevious, setPropagationContext, setStagedNext, setStagedPrevious, setStagedType, skipEmptyHandles
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.drools.core.rule.consequence.InternalMatch
checkProcessInstance, getFactHandles, getObjects, getObjectsDeep, getPropagationContext
-
Methods inherited from interface org.drools.core.reteoo.Tuple
findMostRecentPropagationContext, isDeleted, toObjects
-
-
-
-
Field Detail
-
ruleAgendaItem
protected RuleAgendaItem ruleAgendaItem
-
-
Constructor Detail
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple()
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple(InternalFactHandle factHandle, Sink sink, boolean leftTupleMemoryEnabled)
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple(InternalFactHandle factHandle, LeftTuple leftTuple, Sink sink)
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple(LeftTuple leftTuple, Sink sink, PropagationContext pctx, boolean leftTupleMemoryEnabled)
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, Sink sink)
-
RuleTerminalNodeLeftTuple
public RuleTerminalNodeLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, LeftTuple currentLeftChild, LeftTuple currentRightChild, Sink sink, boolean leftTupleMemoryEnabled)
-
-
Method Detail
-
init
public void init(long activationNumber, int salience, PropagationContext pctx, RuleAgendaItem ruleAgendaItem, InternalAgendaGroup agendaGroup)
-
update
public void update(int salience, PropagationContext pctx)
-
setSink
protected void setSink(Sink sink)
- Overrides:
setSinkin classAbstractTuple
-
getRule
public org.drools.base.definitions.rule.impl.RuleImpl getRule()
Retrieve the rule.- Specified by:
getRulein interfaceInternalMatch- Specified by:
getRulein interfaceorg.kie.api.runtime.rule.Match- Returns:
- The rule.
-
getConsequence
public org.drools.base.rule.consequence.Consequence getConsequence()
- Specified by:
getConsequencein interfaceInternalMatch
-
getTuple
public LeftTuple getTuple()
Retrieve the tuple.- Specified by:
getTuplein interfaceInternalMatch- Returns:
- The tuple.
-
getSalience
public int getSalience()
- Specified by:
getSaliencein interfaceorg.kie.api.runtime.rule.Match
-
setSalience
public void setSalience(int salience)
-
getActivationFactHandle
public InternalFactHandle getActivationFactHandle()
- Specified by:
getActivationFactHandlein interfaceInternalMatch
-
setActivationFactHandle
public void setActivationFactHandle(InternalFactHandle factHandle)
- Specified by:
setActivationFactHandlein interfaceInternalMatch
-
getRuleAgendaItem
public RuleAgendaItem getRuleAgendaItem()
- Specified by:
getRuleAgendaItemin interfaceInternalMatch
-
getActivationNumber
public long getActivationNumber()
Description copied from interface:InternalMatchEach 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.- Specified by:
getActivationNumberin interfaceInternalMatch- Returns:
- The activation number
-
isQueued
public boolean isQueued()
- Specified by:
isQueuedin interfaceQueue.QueueEntry
-
setQueued
public void setQueued(boolean queued)
- Specified by:
setQueuedin interfaceQueue.QueueEntry
-
setQueueIndex
public void setQueueIndex(int queueIndex)
- Specified by:
setQueueIndexin interfaceQueue.QueueEntry
-
getQueueIndex
public int getQueueIndex()
- Specified by:
getQueueIndexin interfaceQueue.QueueEntry
-
dequeue
public void dequeue()
- Specified by:
dequeuein interfaceQueue.QueueEntry
-
remove
public void remove()
Description copied from interface:InternalMatchCancel theActivationby removing it from theAgenda.- Specified by:
removein interfaceInternalMatch
-
getActivationGroupNode
public ActivationGroupNode getActivationGroupNode()
- Specified by:
getActivationGroupNodein interfaceInternalMatch
-
setActivationGroupNode
public void setActivationGroupNode(ActivationGroupNode activationNode)
- Specified by:
setActivationGroupNodein interfaceInternalMatch
-
getAgendaGroup
public InternalAgendaGroup getAgendaGroup()
- Specified by:
getAgendaGroupin interfaceInternalMatch
-
getActivationNode
public ActivationNode getActivationNode()
- Specified by:
getActivationNodein interfaceInternalMatch
-
setActivationNode
public void setActivationNode(ActivationNode activationNode)
- Specified by:
setActivationNodein interfaceInternalMatch
-
getTerminalNode
public TerminalNode getTerminalNode()
- Specified by:
getTerminalNodein interfaceInternalMatch
-
getFactHandles
public java.util.List<org.kie.api.runtime.rule.FactHandle> getFactHandles()
- Specified by:
getFactHandlesin interfaceorg.kie.api.runtime.rule.Match
-
toExternalForm
public java.lang.String toExternalForm()
- Specified by:
toExternalFormin interfaceInternalMatch
-
getObjects
public java.util.List<java.lang.Object> getObjects()
- Specified by:
getObjectsin interfaceorg.kie.api.runtime.rule.Match
-
getObjectsDeep
public java.util.List<java.lang.Object> getObjectsDeep()
- Specified by:
getObjectsDeepin interfaceInternalMatch
-
getDeclarationValue
public java.lang.Object getDeclarationValue(java.lang.String variableName)
- Specified by:
getDeclarationValuein interfaceorg.kie.api.runtime.rule.Match
-
getDeclarationIds
public java.util.List<java.lang.String> getDeclarationIds()
- Specified by:
getDeclarationIdsin interfaceorg.kie.api.runtime.rule.Match
-
isMatched
public boolean isMatched()
- Specified by:
isMatchedin interfaceInternalMatch
-
setMatched
public void setMatched(boolean matched)
- Specified by:
setMatchedin interfaceInternalMatch
-
isActive
public boolean isActive()
- Specified by:
isActivein interfaceInternalMatch
-
setActive
public void setActive(boolean active)
- Specified by:
setActivein interfaceInternalMatch
-
hasBlockers
public boolean hasBlockers()
-
getCallback
public java.lang.Runnable getCallback()
- Specified by:
getCallbackin interfaceInternalMatch
-
setCallback
public void setCallback(java.lang.Runnable callback)
- Specified by:
setCallbackin interfaceInternalMatch
-
cancelActivation
public void cancelActivation(ActivationsManager activationsManager)
-
-