public class AggregationAccessorFirstLastIndex extends java.lang.Object implements AggregationAccessor
Constructor and Description |
---|
AggregationAccessorFirstLastIndex(int streamNum,
ExprEvaluator childNode,
ExprEvaluator indexNode,
int constant,
boolean isFirst)
Ctor.
|
Modifier and Type | Method and Description |
---|---|
EventBean |
getEnumerableEvent(AggregationState state)
Return the aggregation state value consisting of a single event.
|
java.util.Collection<EventBean> |
getEnumerableEvents(AggregationState state)
Return the aggregation state value consisting of a collection of events.
|
java.lang.Object |
getValue(AggregationState state)
Return the aggregation state value either as a scalar value or any other object.
|
public AggregationAccessorFirstLastIndex(int streamNum, ExprEvaluator childNode, ExprEvaluator indexNode, int constant, boolean isFirst)
streamNum
- stream idchildNode
- expressionindexNode
- index expressionconstant
- constant indexisFirst
- true if returning first, false for returning lastpublic java.lang.Object getValue(AggregationState state)
AggregationAccessor
For enumeration over scalar values or objects return an array or collection of scalar or object values.
Use the #getEnumerableEvents method to return a collection of events.
Use the #getEnumerableEvent to return a single events.
getValue
in interface AggregationAccessor
state
- aggregation state, downcast as neededpublic java.util.Collection<EventBean> getEnumerableEvents(AggregationState state)
AggregationAccessor
getEnumerableEvents
in interface AggregationAccessor
state
- aggregation state, downcast as neededpublic EventBean getEnumerableEvent(AggregationState state)
AggregationAccessor
getEnumerableEvent
in interface AggregationAccessor
state
- aggregation state, downcast as needed