Interface Indexer

All Superinterfaces:
Node
All Known Subinterfaces:
IterableIndexer, ProjectionIndexer
All Known Implementing Classes:
AbstractColumnAggregatorNode.AggregatorOuterIdentityIndexer, AbstractColumnAggregatorNode.AggregatorOuterIndexer, GenericProjectionIndexer, IdentityIndexer, IndexerWithMemory, MemoryIdentityIndexer, MemoryNullIndexer, NullIndexer, OnetimeIndexer, SpecializedProjectionIndexer, StandardIndexer, TimelyMemoryIdentityIndexer, TimelyMemoryNullIndexer, TransitiveClosureNodeIndexer

public interface Indexer extends Node
A node that indexes incoming Tuples by their signatures as specified by a TupleMask. Notifies listeners about such update events through the IndexerListener. Signature tuples are created by transforming the update tuples using the mask. Tuples stored with the same signature are grouped together. The group or a reduction thereof is retrievable.
  • Method Details

    • getMask

      TupleMask getMask()
      Returns:
      the mask by which the contents are indexed.
    • getParent

      Supplier getParent()
      Returns:
      the node whose contents are indexed.
    • get

      Collection<Tuple> get(Tuple signature)
      Returns:
      all stored tuples that conform to the specified signature, null if there are none such. CONTRACT: do not modify!
    • getTimeline

      default Map<Tuple,Timeline<Timestamp>> getTimeline(Tuple signature)
      Since:
      2.4
    • getActiveNode

      Node getActiveNode()
      This 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.
      Returns:
      the active node that operates this indexer
    • getListeners

      Collection<IndexerListener> getListeners()
    • attachListener

      void attachListener(IndexerListener listener)
    • detachListener

      void detachListener(IndexerListener listener)