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 ExprValidationException getRollupReclaimEx()
           
static AggregationServiceFactoryDesc getService(java.util.List<ExprAggregateNode> selectAggregateExprNodes, java.util.Map<ExprNode,java.lang.String> selectClauseNamedNodes, java.util.List<ExprDeclaredNode> declaredExpressions, ExprNode[] groupByNodes, java.util.List<ExprAggregateNode> havingAggregateExprNodes, java.util.List<ExprAggregateNode> orderByAggregateExprNodes, java.util.List<ExprAggregateNodeGroupKey> groupKeyExpressions, boolean hasGroupByClause, java.lang.annotation.Annotation[] annotations, VariableService variableService, boolean isJoin, boolean isDisallowNoReclaim, ExprNode whereClause, ExprNode havingClause, AggregationServiceFactoryService factoryService, EventType[] typesPerStream, MethodResolutionService methodResolutionService, AggregationGroupByRollupDesc groupByRollupDesc, java.lang.String optionalContextName, IntoTableSpec intoTableSpec, TableService tableService)
          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, EventType[] typesPerStream)
          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,
                                                                                   EventType[] typesPerStream)
                                                                            throws ExprValidationException
Produces an aggregation service for use with match-recognice.

Parameters:
numStreams - number of streams
measureExprNodesPerStream - measure nodes
Returns:
service
Throws:
ExprValidationException

getService

public static AggregationServiceFactoryDesc getService(java.util.List<ExprAggregateNode> selectAggregateExprNodes,
                                                       java.util.Map<ExprNode,java.lang.String> selectClauseNamedNodes,
                                                       java.util.List<ExprDeclaredNode> declaredExpressions,
                                                       ExprNode[] groupByNodes,
                                                       java.util.List<ExprAggregateNode> havingAggregateExprNodes,
                                                       java.util.List<ExprAggregateNode> orderByAggregateExprNodes,
                                                       java.util.List<ExprAggregateNodeGroupKey> groupKeyExpressions,
                                                       boolean hasGroupByClause,
                                                       java.lang.annotation.Annotation[] annotations,
                                                       VariableService variableService,
                                                       boolean isJoin,
                                                       boolean isDisallowNoReclaim,
                                                       ExprNode whereClause,
                                                       ExprNode havingClause,
                                                       AggregationServiceFactoryService factoryService,
                                                       EventType[] typesPerStream,
                                                       MethodResolutionService methodResolutionService,
                                                       AggregationGroupByRollupDesc groupByRollupDesc,
                                                       java.lang.String optionalContextName,
                                                       IntoTableSpec intoTableSpec,
                                                       TableService tableService)
                                                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
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

getRollupReclaimEx

public static ExprValidationException getRollupReclaimEx()

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