public abstract class IndexerWithMemory extends StandardIndexer implements Receiver, NetworkStructureChangeSensitiveNode, org.eclipse.viatra.query.runtime.rete.network.communication.timely.ResumableNode
Modifier and Type | Class and Description |
---|---|
protected static class |
IndexerWithMemory.NetworkStructureChangeSensitiveLogic |
Modifier and Type | Field and Description |
---|---|
protected CommunicationGroup |
group |
protected IndexerWithMemory.NetworkStructureChangeSensitiveLogic |
logic |
protected Mailbox |
mailbox |
protected MaskedTupleMemory<Timestamp> |
memory |
mask, parent
nodeId, reteContainer, tag, traceInfos
Constructor and Description |
---|
IndexerWithMemory(ReteContainer reteContainer,
TupleMask mask) |
Modifier and Type | Method and Description |
---|---|
void |
appendParent(Supplier supplier)
appends a parent that will continuously send insert and revoke updates to this supplier
|
protected IndexerWithMemory.NetworkStructureChangeSensitiveLogic |
createLogic() |
CommunicationGroup |
getCurrentGroup() |
Mailbox |
getMailbox()
Returns the
Mailbox of this receiver. |
MaskedTupleMemory<Timestamp> |
getMemory() |
java.util.Collection<Supplier> |
getParents()
access active parent
|
Timestamp |
getResumableTimestamp()
Returns the smallest timestamp where lazy folding shall be resumed, or null if there is no more folding to do in this
resumable.
|
protected Mailbox |
instantiateMailbox()
Instantiates the
Mailbox of this receiver. |
void |
networkStructureChanged()
At the time of the invocation, the dependency graph has already been updated.
|
void |
removeParent(Supplier supplier)
removes a parent
|
void |
resumeAt(Timestamp timestamp)
When called, the folding of the state shall be resumed at the given timestamp.
|
void |
setCurrentGroup(CommunicationGroup group)
Sets the current group of the mailbox
|
void |
update(Direction direction,
Tuple updateElement,
Timestamp timestamp)
Updates the receiver with a newly found or lost partial matching.
|
protected abstract void |
update(Direction direction,
Tuple updateElement,
Tuple signature,
boolean change,
Timestamp timestamp)
Refined version of update
|
assignTraceInfo, attachListener, detachListener, getContainer, getListeners, getMask, getParent, propagate, toStringCore
acceptPropagatedTraceInfo, getNodeId, getTag, getTraceInfoPatternsEnumerated, getTraceInfos, setTag, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
batchUpdate
acceptPropagatedTraceInfo, assignTraceInfo, getCommunicationTracker, getContainer, getNodeId, getTag, getTraceInfos, setTag
get, getActiveNode, getTimeline
protected MaskedTupleMemory<Timestamp> memory
protected IndexerWithMemory.NetworkStructureChangeSensitiveLogic logic
protected final Mailbox mailbox
protected CommunicationGroup group
public IndexerWithMemory(ReteContainer reteContainer, TupleMask mask)
public CommunicationGroup getCurrentGroup()
getCurrentGroup
in interface IGroupable
public void setCurrentGroup(CommunicationGroup group)
IGroupable
setCurrentGroup
in interface IGroupable
public void networkStructureChanged()
NetworkStructureChangeSensitiveNode
networkStructureChanged
in interface NetworkStructureChangeSensitiveNode
networkStructureChanged
in class StandardIndexer
protected Mailbox instantiateMailbox()
Mailbox
of this receiver. Subclasses may override this method to provide their own
mailbox implementation.public Mailbox getMailbox()
Receiver
Mailbox
of this receiver.getMailbox
in interface Receiver
public MaskedTupleMemory<Timestamp> getMemory()
public void update(Direction direction, Tuple updateElement, Timestamp timestamp)
Receiver
protected abstract void update(Direction direction, Tuple updateElement, Tuple signature, boolean change, Timestamp timestamp)
public void appendParent(Supplier supplier)
Receiver
appendParent
in interface Receiver
public void removeParent(Supplier supplier)
Receiver
removeParent
in interface Receiver
public java.util.Collection<Supplier> getParents()
Receiver
getParents
in interface Receiver
public void resumeAt(Timestamp timestamp)
org.eclipse.viatra.query.runtime.rete.network.communication.timely.ResumableNode
resumeAt
in interface org.eclipse.viatra.query.runtime.rete.network.communication.timely.ResumableNode
public Timestamp getResumableTimestamp()
org.eclipse.viatra.query.runtime.rete.network.communication.timely.ResumableNode
getResumableTimestamp
in interface org.eclipse.viatra.query.runtime.rete.network.communication.timely.ResumableNode
protected IndexerWithMemory.NetworkStructureChangeSensitiveLogic createLogic()