Package org.eclipse.viatra.query.runtime.rete.index

## Class StandardIndexer

- java.lang.Object
- - org.eclipse.viatra.query.runtime.rete.network.BaseNode
  - - org.eclipse.viatra.query.runtime.rete.index.StandardIndexer

- All Implemented Interfaces:
    `Indexer`, `NetworkStructureChangeSensitiveNode`, `Node`
  Direct Known Subclasses:
    `AbstractColumnAggregatorNode.AggregatorOuterIdentityIndexer`, `AbstractColumnAggregatorNode.AggregatorOuterIndexer`, `IndexerWithMemory`, `SpecializedProjectionIndexer`, `TransitiveClosureNodeIndexer`

      public abstract class StandardIndexer
      extends BaseNode
      implements Indexer, NetworkStructureChangeSensitiveNode

  An abstract standard implementation of the Indexer interface, providing common bookkeeping functionality.

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `protected TupleMask` | `mask` |
    `protected Supplier` | `parent` |

    - ### Fields inherited from class org.eclipse.viatra.query.runtime.rete.network.BaseNode

      `nodeId, reteContainer, tag, traceInfos`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `StandardIndexer​(ReteContainer reteContainer, TupleMask mask)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `assignTraceInfo​(TraceInfo traceInfo)` | assigns new traceability info to this node
    `void` | `attachListener​(IndexerListener listener)` |
    `void` | `detachListener​(IndexerListener listener)` |
    `ReteContainer` | `getContainer()` |
    `java.util.Collection<IndexerListener>` | `getListeners()` |
    `TupleMask` | `getMask()` |
    `Supplier` | `getParent()` |
    `void` | `networkStructureChanged()` | At the time of the invocation, the dependency graph has already been updated.
    `protected void` | `propagate​(Direction direction, Tuple updateElement, Tuple signature, boolean change, Timestamp timestamp)` |
    `protected java.lang.String` | `toStringCore()` | clients should override this to append before the tag / trace indicators

    - ### Methods inherited from class org.eclipse.viatra.query.runtime.rete.network.BaseNode

      `acceptPropagatedTraceInfo, getNodeId, getTag, getTraceInfoPatternsEnumerated, getTraceInfos, setTag, toString`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface org.eclipse.viatra.query.runtime.rete.index.Indexer

      `get, getActiveNode, getTimeline`

    - ### Methods inherited from interface org.eclipse.viatra.query.runtime.rete.network.Node

      `acceptPropagatedTraceInfo, getCommunicationTracker, getNodeId, getTag, getTraceInfos, setTag`

- - ### Field Detail

    - #### parent

          protected Supplier parent

    - #### mask

          protected TupleMask mask

  - ### Constructor Detail

    - #### StandardIndexer

          public StandardIndexer​(ReteContainer reteContainer,
                                 TupleMask mask)

  - ### Method Detail

    - #### propagate

          protected void propagate​(Direction direction,
                                   Tuple updateElement,
                                   Tuple signature,
                                   boolean change,
                                   Timestamp timestamp)

      Since:
        2.4

    - #### getMask

          public TupleMask getMask()

      Specified by:
        `getMask` in interface `Indexer`
      Returns:
        the mask by which the contents are indexed.

    - #### getParent

          public Supplier getParent()

      Specified by:
        `getParent` in interface `Indexer`
      Returns:
        the node whose contents are indexed.

    - #### attachListener

          public void attachListener​(IndexerListener listener)

      Specified by:
        `attachListener` in interface `Indexer`

    - #### detachListener

          public void detachListener​(IndexerListener listener)

      Specified by:
        `detachListener` in interface `Indexer`

    - #### networkStructureChanged

          public void networkStructureChanged()

      Description copied from interface: `NetworkStructureChangeSensitiveNode`
      At the time of the invocation, the dependency graph has already been updated.
      Specified by:
        `networkStructureChanged` in interface `NetworkStructureChangeSensitiveNode`

    - #### getListeners

          public java.util.Collection<IndexerListener> getListeners()

      Specified by:
        `getListeners` in interface `Indexer`

    - #### getContainer

          public ReteContainer getContainer()

      Specified by:
        `getContainer` in interface `Node`
      Overrides:
        `getContainer` in class `BaseNode`
      Returns:
        the network this node belongs to.

    - #### toStringCore

          protected java.lang.String toStringCore()

      Description copied from class: `BaseNode`
      clients should override this to append before the tag / trace indicators
      Overrides:
        `toStringCore` in class `BaseNode`

    - #### assignTraceInfo

          public void assignTraceInfo​(TraceInfo traceInfo)

      Description copied from interface: `Node`
      assigns new traceability info to this node
      Specified by:
        `assignTraceInfo` in interface `Node`
      Overrides:
        `assignTraceInfo` in class `BaseNode`