Class SpecializedProjectionIndexer
java.lang.Object
tools.refinery.interpreter.rete.network.BaseNode
tools.refinery.interpreter.rete.index.StandardIndexer
tools.refinery.interpreter.rete.index.SpecializedProjectionIndexer
- All Implemented Interfaces:
Iterable<Tuple>,Indexer,IterableIndexer,ProjectionIndexer,NetworkStructureChangeSensitiveNode,Node
- Direct Known Subclasses:
IdentityIndexer,NullIndexer
public abstract class SpecializedProjectionIndexer
extends StandardIndexer
implements ProjectionIndexer
A specialized projection indexer that can be memory-less (relying on an external source of information).
All specialized projection indexers of a single node will share the same listener list, so that notification order is maintained (see Bug 518434).
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classInfrastructure to share subscriptions between specialized indexers of the same parent node. -
Field Summary
FieldsFields inherited from class tools.refinery.interpreter.rete.index.StandardIndexer
mask, parentFields inherited from class tools.refinery.interpreter.rete.network.BaseNode
nodeId, reteContainer, tag, traceInfos -
Constructor Summary
ConstructorsConstructorDescriptionSpecializedProjectionIndexer(ReteContainer reteContainer, TupleMask mask, Supplier parent, Node activeNode, List<SpecializedProjectionIndexer.ListenerSubscription> subscriptions) -
Method Summary
Modifier and TypeMethodDescriptionvoidattachListener(IndexerListener listener) voiddetachListener(IndexerListener listener) This indexer will be updated whenever a Rete update is sent to the active node (or an equivalent time slot allotted to it).voidAt the time of the invocation, the dependency graph has already been updated.protected voidpropagate(Direction direction, Tuple updateElement, Tuple signature, boolean change, Timestamp timestamp) abstract voidpropagateToListener(IndexerListener listener, Direction direction, Tuple updateElement, Timestamp timestamp) Methods inherited from class tools.refinery.interpreter.rete.index.StandardIndexer
assignTraceInfo, getContainer, getListeners, getMask, getParent, toStringCoreMethods inherited from class tools.refinery.interpreter.rete.network.BaseNode
acceptPropagatedTraceInfo, getNodeId, getTag, getTraceInfoPatternsEnumerated, getTraceInfos, setTag, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface tools.refinery.interpreter.rete.index.Indexer
get, getListeners, getMask, getParent, getTimelineMethods inherited from interface java.lang.Iterable
forEach, iterator, spliteratorMethods inherited from interface tools.refinery.interpreter.rete.index.IterableIndexer
getBucketCount, getSignaturesMethods inherited from interface tools.refinery.interpreter.rete.network.Node
acceptPropagatedTraceInfo, assignTraceInfo, getCommunicationTracker, getContainer, getNodeId, getTag, getTraceInfos, setTag
-
Field Details
-
activeNode
-
subscriptions
-
-
Constructor Details
-
SpecializedProjectionIndexer
public SpecializedProjectionIndexer(ReteContainer reteContainer, TupleMask mask, Supplier parent, Node activeNode, List<SpecializedProjectionIndexer.ListenerSubscription> subscriptions) - Since:
- 1.7
-
-
Method Details
-
getSubscriptions
-
getActiveNode
Description copied from interface:IndexerThis indexer will be updated whenever a Rete update is sent to the active node (or an equivalent time slot allotted to it). The active node is typically the indexer itself, but it can be a different node such as its parent.- Specified by:
getActiveNodein interfaceIndexer- Returns:
- the active node that operates this indexer
-
propagate
protected void propagate(Direction direction, Tuple updateElement, Tuple signature, boolean change, Timestamp timestamp) - Overrides:
propagatein classStandardIndexer
-
attachListener
- Specified by:
attachListenerin interfaceIndexer- Overrides:
attachListenerin classStandardIndexer
-
detachListener
- Specified by:
detachListenerin interfaceIndexer- Overrides:
detachListenerin classStandardIndexer
-
networkStructureChanged
public void networkStructureChanged()Description copied from interface:NetworkStructureChangeSensitiveNodeAt the time of the invocation, the dependency graph has already been updated.- Specified by:
networkStructureChangedin interfaceNetworkStructureChangeSensitiveNode- Overrides:
networkStructureChangedin classStandardIndexer
-
propagateToListener
public abstract void propagateToListener(IndexerListener listener, Direction direction, Tuple updateElement, Timestamp timestamp) - Since:
- 2.4
-