|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.espertech.esper.epl.agg.service.AggSvcGroupAllAccessOnlyImpl
public class AggSvcGroupAllAccessOnlyImpl
Aggregation service for use when only first/last/window aggregation functions are used an none other.
Field Summary | |
---|---|
protected AggregationState[] |
states
|
Constructor Summary | |
---|---|
AggSvcGroupAllAccessOnlyImpl(AggregationAccessorSlotPair[] accessors,
AggregationState[] states,
AggregationStateFactory[] accessAggSpecs)
|
Method Summary | |
---|---|
void |
accept(AggregationServiceVisitor visitor)
|
void |
acceptGroupDetail(AggregationServiceVisitorWGroupDetail visitor)
|
void |
applyEnter(EventBean[] eventsPerStream,
java.lang.Object groupKey,
ExprEvaluatorContext exprEvaluatorContext)
Apply events as entering a window (new events). |
void |
applyLeave(EventBean[] eventsPerStream,
java.lang.Object groupKey,
ExprEvaluatorContext exprEvaluatorContext)
Apply events as leaving a window (old events). |
void |
clearResults(ExprEvaluatorContext exprEvaluatorContext)
Clear current aggregation state. |
java.util.Collection<EventBean> |
getCollectionOfEvents(int column,
EventBean[] eventsPerStream,
boolean isNewData,
ExprEvaluatorContext context)
|
java.util.Collection<java.lang.Object> |
getCollectionScalar(int column,
EventBean[] eventsPerStream,
boolean isNewData,
ExprEvaluatorContext context)
|
EventBean |
getEventBean(int column,
EventBean[] eventsPerStream,
boolean isNewData,
ExprEvaluatorContext context)
|
java.lang.Object |
getGroupKey(int agentInstanceId)
|
java.util.Collection<java.lang.Object> |
getGroupKeys(ExprEvaluatorContext exprEvaluatorContext)
|
java.lang.Object |
getValue(int column,
int agentInstanceId,
EventBean[] eventsPerStream,
boolean isNewData,
ExprEvaluatorContext exprEvaluatorContext)
Returns current aggregation state, for use by expression node representing an aggregation function. |
boolean |
isGrouped()
|
void |
setCurrentAccess(java.lang.Object groupKey,
int agentInstanceId,
AggregationGroupByRollupLevel rollupLevel)
Set the current aggregation state row - for use when evaluation nodes are asked to evaluate. |
void |
setRemovedCallback(AggregationRowRemovedCallback callback)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final AggregationState[] states
Constructor Detail |
---|
public AggSvcGroupAllAccessOnlyImpl(AggregationAccessorSlotPair[] accessors, AggregationState[] states, AggregationStateFactory[] accessAggSpecs)
Method Detail |
---|
public void applyEnter(EventBean[] eventsPerStream, java.lang.Object groupKey, ExprEvaluatorContext exprEvaluatorContext)
AggregationService
applyEnter
in interface AggregationService
eventsPerStream
- - events for each stream entering windowgroupKey
- - can be null if grouping without keys is desired, else the keys
or array of keys to use for grouping, each distinct key value results in a new row of aggregation state.exprEvaluatorContext
- context for expression evaluatiompublic void applyLeave(EventBean[] eventsPerStream, java.lang.Object groupKey, ExprEvaluatorContext exprEvaluatorContext)
AggregationService
applyLeave
in interface AggregationService
eventsPerStream
- - events for each stream entering windowgroupKey
- - can be null if grouping without keys is desired, else the keys
or array of keys to use for grouping, each distinct key value results in a new row of aggregation state.exprEvaluatorContext
- context for expression evaluatiompublic void setCurrentAccess(java.lang.Object groupKey, int agentInstanceId, AggregationGroupByRollupLevel rollupLevel)
AggregationService
setCurrentAccess
in interface AggregationService
groupKey
- - single key identifying the row of aggregation statesagentInstanceId
- context partition idpublic java.lang.Object getValue(int column, int agentInstanceId, EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext exprEvaluatorContext)
AggregationResultFuture
getValue
in interface AggregationResultFuture
column
- is assigned to the aggregation expression node and passed as an column (index) into a rowagentInstanceId
- the context partition id
public EventBean getEventBean(int column, EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
getEventBean
in interface AggregationResultFuture
public java.util.Collection<EventBean> getCollectionOfEvents(int column, EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
getCollectionOfEvents
in interface AggregationResultFuture
public java.util.Collection<java.lang.Object> getCollectionScalar(int column, EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
getCollectionScalar
in interface AggregationResultFuture
public void clearResults(ExprEvaluatorContext exprEvaluatorContext)
AggregationService
clearResults
in interface AggregationService
public void setRemovedCallback(AggregationRowRemovedCallback callback)
setRemovedCallback
in interface AggregationService
public void accept(AggregationServiceVisitor visitor)
accept
in interface AggregationService
public void acceptGroupDetail(AggregationServiceVisitorWGroupDetail visitor)
acceptGroupDetail
in interface AggregationService
public boolean isGrouped()
isGrouped
in interface AggregationService
public java.lang.Object getGroupKey(int agentInstanceId)
getGroupKey
in interface AggregationResultFuture
public java.util.Collection<java.lang.Object> getGroupKeys(ExprEvaluatorContext exprEvaluatorContext)
getGroupKeys
in interface AggregationResultFuture
|
© 2006-2015 EsperTech Inc. All rights reserved. Visit us at espertech.com |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |