Class ReteMemory
- java.lang.Object
-
- jadex.rules.rulesystem.rete.nodes.ReteMemory
-
public class ReteMemory extends java.lang.Object
The rete memory for all nodes.
-
-
Constructor Summary
Constructors Constructor Description ReteMemory(IOAVState state)
Create a new rete memory.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
getNodeMemory(INode node)
Get the memory for a node.int
getTotalMemorySize()
Get the total memory sizeTuple
getTuple(IOAVState state, Tuple left, java.lang.Object right)
Get a tuple.boolean
hasNodeMemory(INode node)
Test if there is a memory for a node.java.lang.String
toString()
Get the string representation.
-
-
-
Field Detail
-
memory
protected java.util.Map memory
The memory.
-
state
protected IOAVState state
The state.
-
-
Constructor Detail
-
ReteMemory
public ReteMemory(IOAVState state)
Create a new rete memory.
-
-
Method Detail
-
hasNodeMemory
public boolean hasNodeMemory(INode node)
Test if there is a memory for a node.- Parameters:
node
- The node.- Returns:
- True, if there is a memory.
-
getNodeMemory
public java.lang.Object getNodeMemory(INode node)
Get the memory for a node.- Parameters:
node
- The node.- Returns:
- The memory.
-
getTuple
public Tuple getTuple(IOAVState state, Tuple left, java.lang.Object right)
Get a tuple. Returns an existing tuple from the cache, if present. Otherwise a new one is created.
-
getTotalMemorySize
public int getTotalMemorySize()
Get the total memory size- Returns:
- The memory size.
-
toString
public java.lang.String toString()
Get the string representation.- Overrides:
toString
in classjava.lang.Object
- Returns:
- The string representation.
-
-