public abstract class IndexerBasedAggregatorNode extends StandardNode implements IAggregatorNode
children
nodeId, reteContainer, tag, traceInfos
Constructor and Description |
---|
IndexerBasedAggregatorNode(ReteContainer reteContainer)
MUST call initializeWith() afterwards!
|
Modifier and Type | Method and Description |
---|---|
protected Tuple |
aggregateAndPack(Tuple signature,
java.util.Collection<Tuple> group) |
abstract java.lang.Object |
aggregateGroup(Tuple signature,
java.util.Collection<Tuple> group)
Aggregates (reduces) a group of tuples.
|
java.lang.Object |
aggregateGroupAfterUpdate(Tuple signature,
java.util.Collection<Tuple> currentGroup,
java.lang.Object oldAggregate,
Direction direction,
Tuple updateElement,
boolean change)
Aggregates (reduces) a group of tuples, having access to the previous aggregated value (before the update) and
the update definition.
|
protected void |
aggregateUpdate(Direction direction,
Tuple updateElement,
Tuple signature,
boolean change) |
void |
assignTraceInfo(TraceInfo traceInfo)
assigns new traceability info to this node
|
Indexer |
getAggregatorOuterIdentityIndexer(int resultPositionInSignature) |
Indexer |
getAggregatorOuterIndexer() |
void |
initializeWith(ProjectionIndexer projection) |
protected Tuple |
packResult(Tuple signature,
java.lang.Object result) |
void |
pullInto(java.util.Collection<Tuple> collector)
pulls the contents of this object in this particular moment into a target collection
|
appendChild, constructIndex, getPulledContents, getReceivers, issueError, propagateUpdate, removeChild
acceptPropagatedTraceInfo, getContainer, getNodeId, getTag, getTraceInfoPatternsEnumerated, getTraceInfos, setTag, toString, toStringCore
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
acceptPropagatedTraceInfo, getContainer, getNodeId, getTag, getTraceInfos, setTag
public IndexerBasedAggregatorNode(ReteContainer reteContainer)
public void initializeWith(ProjectionIndexer projection)
projection
- the projection indexer whose tuple groups should be aggregatedpublic abstract java.lang.Object aggregateGroup(Tuple signature, java.util.Collection<Tuple> group)
public java.lang.Object aggregateGroupAfterUpdate(Tuple signature, java.util.Collection<Tuple> currentGroup, java.lang.Object oldAggregate, Direction direction, Tuple updateElement, boolean change)
protected Tuple aggregateAndPack(Tuple signature, java.util.Collection<Tuple> group)
public Indexer getAggregatorOuterIndexer()
getAggregatorOuterIndexer
in interface IAggregatorNode
public Indexer getAggregatorOuterIdentityIndexer(int resultPositionInSignature)
getAggregatorOuterIdentityIndexer
in interface IAggregatorNode
public void pullInto(java.util.Collection<Tuple> collector)
Supplier
protected void aggregateUpdate(Direction direction, Tuple updateElement, Tuple signature, boolean change)
public void assignTraceInfo(TraceInfo traceInfo)
Node
assignTraceInfo
in interface Node
assignTraceInfo
in class BaseNode