public class QueryTerminalNode extends AbstractTerminalNode implements LeftTupleSinkNode
Action
s on a
matched Rule
.Rule
,
Serialized FormModifier and Type | Field and Description |
---|---|
protected QueryImpl |
query
The rule to invoke upon match.
|
static short |
type |
associations, hashcode, id, partitionId, partitionsEnabled
Constructor and Description |
---|
QueryTerminalNode() |
QueryTerminalNode(int id,
LeftTupleSource source,
RuleImpl rule,
GroupElement subrule,
int subruleIndex,
BuildContext context)
Constructor
|
createMemory, doRemove, getDeclaredMask, getInferredMask, getLeftInferredMask, getLeftTupleSource, getNegativeMask, getPathEndNodes, getPathNodes, getPathNodes, getPositionInPath, getSinkPropagator, hasPathNode, initDeclaredMask, initInferredMask, initPathMemory, isInUse, isLeftTupleMemoryEnabled, isTerminalNodeOf, modifyLeftTuple, networkUpdated, setDeclaredMask, setInferredMask, setLeftTupleMemoryEnabled, setNegativeMask, setPathEndNodes, unwrapTupleSource
addAssociation, addAssociation, getAssociatedRuleSize, getAssociationsSize, getAssociationsSize, getId, getPartitionId, hashCode, isAssociatedWith, isStreamMode, remove, removeAssociation, setId, setPartitionId, setStreamMode, thisNodeEquals
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
getLeftInferredMask, isLeftTupleMemoryEnabled, modifyLeftTuple, setLeftTupleMemoryEnabled
getLeftTupleSource, getPositionInPath, getSinkPropagator
getAssociatedRuleSize, getAssociationsSize, getAssociationsSize, getId, getPartitionId, isAssociatedWith, thisNodeEquals
getId
public static final short type
protected QueryImpl query
public QueryTerminalNode()
public QueryTerminalNode(int id, LeftTupleSource source, RuleImpl rule, GroupElement subrule, int subruleIndex, BuildContext context)
id
- node IDsource
- the tuple source for this noderule
- the rule this node belongs tosubrule
- the subrule this node belongs tocontext
- the current build contextpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
readExternal
in class AbstractTerminalNode
IOException
ClassNotFoundException
public void writeExternal(ObjectOutput out) throws IOException
writeExternal
in interface Externalizable
writeExternal
in class AbstractTerminalNode
IOException
public QueryImpl getQuery()
public RuleImpl getRule()
getRule
in interface TerminalNode
getRule
in class AbstractTerminalNode
protected boolean internalEquals(Object object)
internalEquals
in class BaseNode
public GroupElement getSubRule()
getSubRule
in interface TerminalNode
public boolean isFireDirect()
isFireDirect
in interface TerminalNode
public Declaration[] getAllDeclarations()
getAllDeclarations
in interface TerminalNode
public Declaration[] getRequiredDeclarations()
getRequiredDeclarations
in interface TerminalNode
public int getSubruleIndex()
public LeftTupleSinkNode getPreviousLeftTupleSinkNode()
getPreviousLeftTupleSinkNode
in interface LeftTupleSinkNode
public void setPreviousLeftTupleSinkNode(LeftTupleSinkNode previous)
setPreviousLeftTupleSinkNode
in interface LeftTupleSinkNode
previous
- The previous TupleSinkNodepublic LeftTupleSinkNode getNextLeftTupleSinkNode()
getNextLeftTupleSinkNode
in interface LeftTupleSinkNode
public void setNextLeftTupleSinkNode(LeftTupleSinkNode next)
setNextLeftTupleSinkNode
in interface LeftTupleSinkNode
next
- The next TupleSinkNodepublic short getType()
getType
in interface NetworkNode
public LeftTuple createLeftTuple(InternalFactHandle factHandle, Sink sink, boolean leftTupleMemoryEnabled)
createLeftTuple
in interface LeftTupleSink
public LeftTuple createLeftTuple(InternalFactHandle factHandle, LeftTuple leftTuple, Sink sink)
createLeftTuple
in interface LeftTupleSink
public LeftTuple createLeftTuple(LeftTuple leftTuple, Sink sink, PropagationContext pctx, boolean leftTupleMemoryEnabled)
createLeftTuple
in interface LeftTupleSink
public LeftTuple createLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, Sink sink)
createLeftTuple
in interface LeftTupleSink
public LeftTuple createLeftTuple(LeftTuple leftTuple, RightTuple rightTuple, LeftTuple currentLeftChild, LeftTuple currentRightChild, Sink sink, boolean leftTupleMemoryEnabled)
createLeftTuple
in interface LeftTupleSink
public ObjectTypeNode.Id getLeftInputOtnId()
getLeftInputOtnId
in interface LeftTupleSink
public void setLeftInputOtnId(ObjectTypeNode.Id leftInputOtnId)
setLeftInputOtnId
in interface LeftTupleSink
public LeftTuple createPeer(LeftTuple original)
createPeer
in interface LeftTupleSink
createPeer
in class AbstractTerminalNode
public Declaration[] getSalienceDeclarations()
getSalienceDeclarations
in interface TerminalNode
public Declaration[][] getTimerDeclarations()
getTimerDeclarations
in interface TerminalNode
public void assertLeftTuple(LeftTuple leftTuple, PropagationContext context, InternalWorkingMemory workingMemory)
LeftTupleSink
ReteTuple
.assertLeftTuple
in interface LeftTupleSink
leftTuple
- The ReteTuple
to propagate.context
- The PropagationContext
of the WorkingMemory action
workingMemory
- the WorkingMemory
session.public void retractLeftTuple(LeftTuple leftTuple, PropagationContext context, InternalWorkingMemory workingMemory)
retractLeftTuple
in interface LeftTupleSink
public void modifyLeftTuple(LeftTuple leftTuple, PropagationContext context, InternalWorkingMemory workingMemory)
modifyLeftTuple
in interface LeftTupleSink
public void attach(BuildContext context)
BaseNode
ObjectSource
or TupleSource
Copyright © 2001–2017 JBoss by Red Hat. All rights reserved.