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

java.lang.Object
  extended by com.espertech.esper.epl.agg.service.AggregationServiceFactoryFactory

public class AggregationServiceFactoryFactory
extends java.lang.Object

Factory for aggregation service instances.

Consolidates aggregation nodes such that result futures point to a single instance and no re-evaluation of the same result occurs.


Constructor Summary
AggregationServiceFactoryFactory()
           
 
Method Summary
static AggregationServiceFactoryDesc getService(java.util.List<ExprAggregateNode> selectAggregateExprNodes, java.util.List<ExprAggregateNode> havingAggregateExprNodes, java.util.List<ExprAggregateNode> orderByAggregateExprNodes, boolean hasGroupByClause, ExprEvaluatorContext exprEvaluatorContext, java.lang.annotation.Annotation[] annotations, VariableService variableService, boolean isJoin, ExprNode whereClause, ExprNode havingClause, AggregationServiceFactoryService factoryService, EventType[] typesPerStream)
          Returns an instance to handle the aggregation required by the aggregation expression nodes, depending on whether there are any group-by nodes.
static AggregationServiceMatchRecognizeFactoryDesc getServiceMatchRecognize(int numStreams, java.util.Map<java.lang.Integer,java.util.List<ExprAggregateNode>> measureExprNodesPerStream, ExprEvaluatorContext exprEvaluatorContext)
          Produces an aggregation service for use with match-recognice.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AggregationServiceFactoryFactory

public AggregationServiceFactoryFactory()
Method Detail

getServiceMatchRecognize

public static AggregationServiceMatchRecognizeFactoryDesc getServiceMatchRecognize(int numStreams,
                                                                                   java.util.Map<java.lang.Integer,java.util.List<ExprAggregateNode>> measureExprNodesPerStream,
                                                                                   ExprEvaluatorContext exprEvaluatorContext)
Produces an aggregation service for use with match-recognice.

Parameters:
numStreams - number of streams
measureExprNodesPerStream - measure nodes
exprEvaluatorContext - context for expression evaluatiom
Returns:
service

getService

public static AggregationServiceFactoryDesc getService(java.util.List<ExprAggregateNode> selectAggregateExprNodes,
                                                       java.util.List<ExprAggregateNode> havingAggregateExprNodes,
                                                       java.util.List<ExprAggregateNode> orderByAggregateExprNodes,
                                                       boolean hasGroupByClause,
                                                       ExprEvaluatorContext exprEvaluatorContext,
                                                       java.lang.annotation.Annotation[] annotations,
                                                       VariableService variableService,
                                                       boolean isJoin,
                                                       ExprNode whereClause,
                                                       ExprNode havingClause,
                                                       AggregationServiceFactoryService factoryService,
                                                       EventType[] typesPerStream)
                                                throws ExprValidationException
Returns an instance to handle the aggregation required by the aggregation expression nodes, depending on whether there are any group-by nodes.

Parameters:
selectAggregateExprNodes - - aggregation nodes extracted out of the select expression
havingAggregateExprNodes - - aggregation nodes extracted out of the select expression
orderByAggregateExprNodes - - aggregation nodes extracted out of the select expression
hasGroupByClause - - indicator on whethere there is group-by required, or group-all
exprEvaluatorContext - context for expression evaluatiom
annotations - - statement annotations
variableService - - variable
isJoin - - true for joins
whereClause - the where-clause function if any
havingClause - the having-clause function if any
Returns:
instance for aggregation handling
Throws:
ExprValidationException - if validation fails

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