com.espertech.esper.epl.agg.service
Class AggregationServiceMatchRecognizeImpl

java.lang.Object
  extended by com.espertech.esper.epl.agg.service.AggregationServiceMatchRecognizeImpl
All Implemented Interfaces:
AggregationResultFuture, AggregationServiceMatchRecognize

public class AggregationServiceMatchRecognizeImpl
extends java.lang.Object
implements AggregationServiceMatchRecognize

Implements an aggregation service for match recognize.


Constructor Summary
AggregationServiceMatchRecognizeImpl(ExprEvaluator[][] evaluatorsEachStream, AggregationMethod[][] aggregatorsEachStream, AggregationMethod[] aggregatorsAll)
           
 
Method Summary
 void applyEnter(EventBean[] eventsPerStream, int streamId, ExprEvaluatorContext exprEvaluatorContext)
          Enter a single event row consisting of one or more events per stream (each stream representing a variable).
 void clearResults()
          Clear current aggregation state.
 java.util.Collection<EventBean> getCollection(int column, ExprEvaluatorContext context)
           
 EventBean getEventBean(int column, ExprEvaluatorContext context)
           
 java.lang.Object getValue(int column, int agentInstanceId)
          Returns current aggregation state, for use by expression node representing an aggregation function.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AggregationServiceMatchRecognizeImpl

public AggregationServiceMatchRecognizeImpl(ExprEvaluator[][] evaluatorsEachStream,
                                            AggregationMethod[][] aggregatorsEachStream,
                                            AggregationMethod[] aggregatorsAll)
Method Detail

applyEnter

public void applyEnter(EventBean[] eventsPerStream,
                       int streamId,
                       ExprEvaluatorContext exprEvaluatorContext)
Description copied from interface: AggregationServiceMatchRecognize
Enter a single event row consisting of one or more events per stream (each stream representing a variable).

Specified by:
applyEnter in interface AggregationServiceMatchRecognize
Parameters:
eventsPerStream - events per stream
streamId - variable number that is the base
exprEvaluatorContext - context for expression evaluatiom

getValue

public java.lang.Object getValue(int column,
                                 int agentInstanceId)
Description copied from interface: AggregationResultFuture
Returns current aggregation state, for use by expression node representing an aggregation function.

Specified by:
getValue in interface AggregationResultFuture
Parameters:
column - is assigned to the aggregation expression node and passed as an column (index) into a row
agentInstanceId - the context partition id
Returns:
current aggragation state

getCollection

public java.util.Collection<EventBean> getCollection(int column,
                                                     ExprEvaluatorContext context)
Specified by:
getCollection in interface AggregationResultFuture

getEventBean

public EventBean getEventBean(int column,
                              ExprEvaluatorContext context)
Specified by:
getEventBean in interface AggregationResultFuture

clearResults

public void clearResults()
Description copied from interface: AggregationServiceMatchRecognize
Clear current aggregation state.

Specified by:
clearResults in interface AggregationServiceMatchRecognize

© 2006-2011 EsperTech Inc.
All rights reserved.
Visit us at espertech.com