|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.drools.common.BaseNode
org.drools.reteoo.AbstractTerminalNode
org.drools.reteoo.RuleTerminalNode
public class RuleTerminalNode
Leaf Rete-OO node responsible for enacting Action s on a
matched Rule.
Rule,
Serialized Form| Nested Class Summary | |
|---|---|
static class |
RuleTerminalNode.RTNCleanupAdapter
|
static class |
RuleTerminalNode.SortDeclarations
|
| Field Summary |
|---|
| Fields inherited from class org.drools.common.BaseNode |
|---|
associations, id, partitionId, partitionsEnabled |
| Constructor Summary | |
|---|---|
RuleTerminalNode()
|
|
RuleTerminalNode(int id,
LeftTupleSource source,
Rule rule,
GroupElement subrule,
int subruleIndex,
BuildContext context)
|
|
| Method Summary | |
|---|---|
void |
assertLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
Assert a new ReteTuple. |
void |
attach(BuildContext context)
Attaches the node into the network. |
LeftTuple |
createLeftTuple(InternalFactHandle factHandle,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
|
LeftTuple |
createLeftTuple(LeftTuple leftTuple,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
|
LeftTuple |
createLeftTuple(LeftTuple leftTuple,
RightTuple rightTuple,
LeftTuple currentLeftChild,
LeftTuple currentRightChild,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
|
LeftTuple |
createLeftTuple(LeftTuple leftTuple,
RightTuple rightTuple,
LeftTupleSink sink)
|
protected void |
doRemove(RuleRemovalContext context,
ReteooBuilder builder,
BaseNode node,
InternalWorkingMemory[] workingMemories)
Removes the node from teh network. |
boolean |
equals(Object object)
|
Declaration[] |
getDeclarations()
|
Declaration[] |
getEnabledDeclarations()
|
int |
getLeftInputOtnId()
|
LeftTupleSinkNode |
getNextLeftTupleSinkNode()
Returns the next node |
protected ObjectTypeNode |
getObjectTypeNode()
|
LeftTupleSinkNode |
getPreviousLeftTupleSinkNode()
Returns the previous node |
Rule |
getRule()
Retrieve the Action associated with this node. |
Declaration[] |
getSalienceDeclarations()
|
int |
getSequence()
|
GroupElement |
getSubRule()
|
Declaration[] |
getTimerDelayDeclarations()
|
Declaration[] |
getTimerPeriodDeclarations()
|
short |
getType()
|
int |
hashCode()
The hashCode return is simply the unique id of the node. |
boolean |
isFireDirect()
|
boolean |
isInUse()
Returns true in case the current node is in use (is referenced by any other node) |
boolean |
isLeftTupleMemoryEnabled()
|
void |
modifyLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
|
void |
networkUpdated(UpdateContext updateContext)
A method that is called for all nodes whose network below them changed, after the change is complete, providing them with an oportunity for state update |
void |
readExternal(ObjectInput in)
|
void |
retractLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
|
void |
setDeclarations(Declaration[] declarations)
|
void |
setDeclarations(Map<String,Declaration> decls)
|
void |
setEnabledDeclarations(Declaration[] enabledDeclarations)
|
void |
setFireDirect(boolean fireDirect)
|
void |
setLeftInputOtnId(int leftInputOtnId)
|
void |
setLeftTupleMemoryEnabled(boolean tupleMemoryEnabled)
|
void |
setNextLeftTupleSinkNode(LeftTupleSinkNode next)
Sets the next node |
void |
setPreviousLeftTupleSinkNode(LeftTupleSinkNode previous)
Sets the previous node |
void |
setSalienceDeclarations(Declaration[] salienceDeclarations)
|
void |
setSequence(int seq)
|
void |
setTimerDelayDeclarations(Declaration[] timerDelayDeclarations)
|
void |
setTimerPeriodDeclarations(Declaration[] timerPeriodDeclarations)
|
String |
toString()
|
void |
writeExternal(ObjectOutput out)
|
| Methods inherited from class org.drools.reteoo.AbstractTerminalNode |
|---|
getDeclaredMask, getInferredMask, getLeftTupleSource, getNegativeMask, initDeclaredMask, initInferredMask, modifyLeftTuple, setDeclaredMask, setInferredMask, setNegativeMask, unwrapTupleSource |
| Methods inherited from class org.drools.common.BaseNode |
|---|
addAssociation, attach, getAssociations, getId, getPartitionId, remove, removeAssociation, setPartitionId |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.drools.common.NetworkNode |
|---|
getId, getPartitionId |
| Constructor Detail |
|---|
public RuleTerminalNode()
public RuleTerminalNode(int id,
LeftTupleSource source,
Rule rule,
GroupElement subrule,
int subruleIndex,
BuildContext context)
id - source - rule - subrule - subruleIndex - context - | Method Detail |
|---|
public void setDeclarations(Map<String,Declaration> decls)
public void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface ExternalizablereadExternal in class AbstractTerminalNodeIOException
ClassNotFoundException
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface ExternalizablewriteExternal in class AbstractTerminalNodeIOExceptionpublic Rule getRule()
Action associated with this node.
Action associated with this node.public GroupElement getSubRule()
public void setSequence(int seq)
public int getSequence()
public void assertLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
LeftTupleSinkReteTuple.
leftTuple - The ReteTuple to propagate.context - The PropagationContext of the WorkingMemory actionworkingMemory - the WorkingMemory session.
public void modifyLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
public void retractLeftTuple(LeftTuple leftTuple,
PropagationContext context,
InternalWorkingMemory workingMemory)
public String toString()
toString in class BaseNodepublic void attach(BuildContext context)
BaseNodeObjectSource or TupleSource
attach in class BaseNodepublic void networkUpdated(UpdateContext updateContext)
BaseNode
networkUpdated in class BaseNode
protected void doRemove(RuleRemovalContext context,
ReteooBuilder builder,
BaseNode node,
InternalWorkingMemory[] workingMemories)
BaseNodeObjectSource or TupleSource
doRemove in class BaseNodepublic boolean isInUse()
BaseNode
isInUse in class BaseNodepublic boolean isLeftTupleMemoryEnabled()
public void setLeftTupleMemoryEnabled(boolean tupleMemoryEnabled)
public void setDeclarations(Declaration[] declarations)
public Declaration[] getDeclarations()
public Declaration[] getTimerDelayDeclarations()
public void setTimerDelayDeclarations(Declaration[] timerDelayDeclarations)
public Declaration[] getTimerPeriodDeclarations()
public void setTimerPeriodDeclarations(Declaration[] timerPeriodDeclarations)
public Declaration[] getSalienceDeclarations()
public void setSalienceDeclarations(Declaration[] salienceDeclarations)
public Declaration[] getEnabledDeclarations()
public void setEnabledDeclarations(Declaration[] enabledDeclarations)
public LeftTupleSinkNode getNextLeftTupleSinkNode()
public void setNextLeftTupleSinkNode(LeftTupleSinkNode next)
next - The next TupleSinkNodepublic LeftTupleSinkNode getPreviousLeftTupleSinkNode()
public void setPreviousLeftTupleSinkNode(LeftTupleSinkNode previous)
previous - The previous TupleSinkNodepublic int hashCode()
BaseNode
hashCode in class BaseNodepublic boolean equals(Object object)
equals in class Objectpublic short getType()
public LeftTuple createLeftTuple(InternalFactHandle factHandle,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
public LeftTuple createLeftTuple(LeftTuple leftTuple,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
public LeftTuple createLeftTuple(LeftTuple leftTuple,
RightTuple rightTuple,
LeftTupleSink sink)
public LeftTuple createLeftTuple(LeftTuple leftTuple,
RightTuple rightTuple,
LeftTuple currentLeftChild,
LeftTuple currentRightChild,
LeftTupleSink sink,
boolean leftTupleMemoryEnabled)
public int getLeftInputOtnId()
public void setLeftInputOtnId(int leftInputOtnId)
public boolean isFireDirect()
public void setFireDirect(boolean fireDirect)
protected ObjectTypeNode getObjectTypeNode()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||