|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.drools.util.AbstractBaseLinkedListNode
org.drools.util.BaseMultiLinkedListNode
org.drools.reteoo.ReteTuple
Rete-OO
Each
Tuple implementation. A ReteTuple implements LinkedListNode so that it can referenced
in a LinkedList, this allows for fast removal, without searching; as ReteTuples are add sequentially to a nodes
memory (LinkedList), but removed randomly.
Each ReteTuple has a Map of matches. The key is the matching FactHandleImpl and the value
is the TupleMatch, which is also referenced in the ObjectMatches LinkedList.
ReteTuple also reference a TupleKey which is special array of FactHandles
representing the Columns in a Rule. The TupleKey also provide the
hashCode implementation for ReteTuple.
Tuple,
TupleMatch,
TupleKey,
Serialized Form




Constructor Summary
ReteTuple(DefaultFactHandle handle)
Creates a ReteTuple with the handle at the specified column in the TupleKey.
Method Summary
voidaddLinkedTuple(LinkedListNode node)
Specifies the tuple as the result of NotNode propagation.
voidaddTupleMatch(DefaultFactHandle handle,
TupleMatch node)
voidclearLinkedTuple()
booleandependsOn(FactHandle handle)
Determine if this tuple depends upon a specified object.
booleanequals(java.lang.Object object)
InternalFactHandleget(Declaration declaration)
Returns the FactHandle for the given Declaration, which in turn
specifcy the Column that they depend on.
InternalFactHandleget(int col)
Returns the FactHandle for the given column index.
ActivationgetActivation()
InternalFactHandle[]getFactHandles()
LinkedListgetLinkedTuples()
Returns the tuple from the result of NotNode propagation.
longgetRecency()
TupleMatchgetTupleMatch(DefaultFactHandle handle)
java.util.MapgetTupleMatches()
inthashCode()
intmatchesSize()
TupleMatchremoveMatch(DefaultFactHandle handle)
voidsetActivation(Activation activation)
java.lang.StringtoString()
Methods inherited from class org.drools.util.BaseMultiLinkedListNode
getChild, getOuterList, setChild, setOuterList
Methods inherited from class org.drools.util.AbstractBaseLinkedListNode
getNext, getPrevious, setNext, setPrevious
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.drools.util.LinkedListNode
getNext, getPrevious, setNext, setPrevious
Constructor Detail
ReteTuple
public ReteTuple(DefaultFactHandle handle)
ReteTuple with the handle at the specified column in the TupleKey.
handle - The FactHandleImpl to be placed in the TupleKey at the given column position.
Method Detail
getRecency
public long getRecency()
getRecency in interface Tuple
getFactHandles
public InternalFactHandle[] getFactHandles()
getFactHandles in interface Tuple
dependsOn
public boolean dependsOn(FactHandle handle)
handle - The object handle to test.
true if this tuple depends upon the specified
object, otherwise false.
get
public InternalFactHandle get(int col)
TupleFactHandle for the given column index. If the column is empty
It returns null.
col - The index of the column from which the FactHandleImpl is to be returned
FactHandle
get
public InternalFactHandle get(Declaration declaration)
TupleFactHandle for the given Declaration, which in turn
specifcy the Column that they depend on.
declaration - The Declaration which specifies the Column
FactHandle
setActivation
public void setActivation(Activation activation)
setActivation in interface Tuple
getActivation
public Activation getActivation()
addLinkedTuple
public void addLinkedTuple(LinkedListNode node)
NotNode propagation.
getLinkedTuples
public LinkedList getLinkedTuples()
NotNode propagation. If there has been no
NotNode propagation then it returns null.
ReteTuple
clearLinkedTuple
public void clearLinkedTuple()
addTupleMatch
public void addTupleMatch(DefaultFactHandle handle,
TupleMatch node)
matchesSize
public int matchesSize()
getTupleMatches
public java.util.Map getTupleMatches()
getTupleMatch
public TupleMatch getTupleMatch(DefaultFactHandle handle)
removeMatch
public TupleMatch removeMatch(DefaultFactHandle handle)
equals
public boolean equals(java.lang.Object object)
hashCode
public int hashCode()
toString
public java.lang.String toString()
Overview
Package
Class
Tree
Deprecated
Index
Help
PREV CLASS
NEXT CLASS
FRAMES
NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD
DETAIL: FIELD | CONSTR | METHOD