com.espertech.esper.epl.expression.accessagg
Class ExprAggMultiFunctionSortedMinMaxByNode

java.lang.Object
  extended by com.espertech.esper.epl.expression.core.ExprNodeBase
      extended by com.espertech.esper.epl.expression.baseagg.ExprAggregateNodeBase
          extended by com.espertech.esper.epl.expression.accessagg.ExprAggMultiFunctionSortedMinMaxByNode
All Implemented Interfaces:
ExprAggregateAccessMultiValueNode, ExprAggregateNode, ExprEvaluator, ExprEvaluatorEnumeration, ExprNode, ExprValidator, MetaDefItem, java.io.Serializable

public class ExprAggMultiFunctionSortedMinMaxByNode
extends ExprAggregateNodeBase
implements ExprEvaluatorEnumeration, ExprAggregateAccessMultiValueNode

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.espertech.esper.epl.expression.baseagg.ExprAggregateNodeBase
aggregationResultFuture, column, isDistinct, optionalAggregateLocalGroupByDesc, positionalParams
 
Constructor Summary
ExprAggMultiFunctionSortedMinMaxByNode(boolean max, boolean ever, boolean sortedwin)
          Ctor.
 
Method Summary
protected  boolean equalsNodeAggregateMethodOnly(ExprAggregateNode node)
          Return true if a expression aggregate node semantically equals the current node, or false if not.
 EventBean evaluateGetEventBean(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
           
 java.util.Collection<EventBean> evaluateGetROCollectionEvents(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
           
 java.util.Collection evaluateGetROCollectionScalar(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
           
 java.lang.String getAggregationFunctionName()
          Returns the aggregation function name for representation in a generate expression string.
 java.lang.Class getComponentTypeCollection()
           
 EventType getEventTypeCollection(EventAdapterService eventAdapterService, java.lang.String statementId)
           
 EventType getEventTypeSingle(EventAdapterService eventAdapterService, java.lang.String statementId)
           
 boolean isMax()
           
 void toPrecedenceFreeEPL(java.io.StringWriter writer)
           
 AggregationMethodFactory validateAggregationChild(ExprValidationContext validationContext)
          Gives the aggregation node a chance to validate the sub-expression types.
 AggregationMethodFactory validateAggregationParamsWBinding(ExprValidationContext validationContext, TableMetadataColumnAggregation tableAccessColumn)
           
 
Methods inherited from class com.espertech.esper.epl.expression.baseagg.ExprAggregateNodeBase
equalsNode, evaluate, getExprEvaluator, getFactory, getOptionalLocalGroupBy, getPositionalParams, getPrecedence, getType, isConstantResult, isDistinct, isExprTextWildcardWhenNoParams, makeExceptionExpectedParamNum, setAggregationResultFuture, validate, validateFilter, validateNumericChildAllowFilter, validatePositionals
 
Methods inherited from class com.espertech.esper.epl.expression.core.ExprNodeBase
accept, accept, acceptChildnodes, addChildNode, addChildNodes, addChildNodeToFront, getChildNodes, replaceUnlistedChildNode, setChildNode, setChildNodes, toEPL
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.espertech.esper.epl.expression.accessagg.ExprAggregateAccessMultiValueNode
validatePositionals
 
Methods inherited from interface com.espertech.esper.epl.expression.core.ExprNode
accept, accept, acceptChildnodes, addChildNode, addChildNodes, getChildNodes, replaceUnlistedChildNode, setChildNode, setChildNodes, toEPL
 

Constructor Detail

ExprAggMultiFunctionSortedMinMaxByNode

public ExprAggMultiFunctionSortedMinMaxByNode(boolean max,
                                              boolean ever,
                                              boolean sortedwin)
Ctor.

Method Detail

validateAggregationParamsWBinding

public AggregationMethodFactory validateAggregationParamsWBinding(ExprValidationContext validationContext,
                                                                  TableMetadataColumnAggregation tableAccessColumn)
                                                           throws ExprValidationException
Specified by:
validateAggregationParamsWBinding in interface ExprAggregateAccessMultiValueNode
Throws:
ExprValidationException

validateAggregationChild

public AggregationMethodFactory validateAggregationChild(ExprValidationContext validationContext)
                                                  throws ExprValidationException
Description copied from class: ExprAggregateNodeBase
Gives the aggregation node a chance to validate the sub-expression types.

Specified by:
validateAggregationChild in class ExprAggregateNodeBase
Parameters:
validationContext - validation information
Returns:
aggregation function factory to use
Throws:
ExprValidationException - when expression validation failed

getAggregationFunctionName

public java.lang.String getAggregationFunctionName()
Description copied from class: ExprAggregateNodeBase
Returns the aggregation function name for representation in a generate expression string.

Specified by:
getAggregationFunctionName in class ExprAggregateNodeBase
Returns:
aggregation function name

toPrecedenceFreeEPL

public void toPrecedenceFreeEPL(java.io.StringWriter writer)
Overrides:
toPrecedenceFreeEPL in class ExprAggregateNodeBase

evaluateGetROCollectionEvents

public java.util.Collection<EventBean> evaluateGetROCollectionEvents(EventBean[] eventsPerStream,
                                                                     boolean isNewData,
                                                                     ExprEvaluatorContext context)
Specified by:
evaluateGetROCollectionEvents in interface ExprEvaluatorEnumeration

evaluateGetROCollectionScalar

public java.util.Collection evaluateGetROCollectionScalar(EventBean[] eventsPerStream,
                                                          boolean isNewData,
                                                          ExprEvaluatorContext context)
Specified by:
evaluateGetROCollectionScalar in interface ExprEvaluatorEnumeration

getEventTypeCollection

public EventType getEventTypeCollection(EventAdapterService eventAdapterService,
                                        java.lang.String statementId)
Specified by:
getEventTypeCollection in interface ExprEvaluatorEnumeration

getComponentTypeCollection

public java.lang.Class getComponentTypeCollection()
                                           throws ExprValidationException
Specified by:
getComponentTypeCollection in interface ExprEvaluatorEnumeration
Throws:
ExprValidationException

getEventTypeSingle

public EventType getEventTypeSingle(EventAdapterService eventAdapterService,
                                    java.lang.String statementId)
                             throws ExprValidationException
Specified by:
getEventTypeSingle in interface ExprEvaluatorEnumeration
Throws:
ExprValidationException

evaluateGetEventBean

public EventBean evaluateGetEventBean(EventBean[] eventsPerStream,
                                      boolean isNewData,
                                      ExprEvaluatorContext context)
Specified by:
evaluateGetEventBean in interface ExprEvaluatorEnumeration

isMax

public boolean isMax()

equalsNodeAggregateMethodOnly

protected boolean equalsNodeAggregateMethodOnly(ExprAggregateNode node)
Description copied from class: ExprAggregateNodeBase
Return true if a expression aggregate node semantically equals the current node, or false if not.

For use by the equalsNode implementation which compares the distinct flag.

Specified by:
equalsNodeAggregateMethodOnly in class ExprAggregateNodeBase
Parameters:
node - to compare to
Returns:
true if semantically equal, or false if not equals

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