com.espertech.esper.epl.expression.subquery
Class ExprSubselectRowNode

java.lang.Object
  extended by com.espertech.esper.epl.expression.core.ExprNodeBase
      extended by com.espertech.esper.epl.expression.subquery.ExprSubselectNode
          extended by com.espertech.esper.epl.expression.subquery.ExprSubselectRowNode
All Implemented Interfaces:
ExprEvaluator, ExprEvaluatorEnumeration, ExprEvaluatorTypableReturn, ExprNode, ExprValidator, MetaDefItem, java.io.Serializable

public class ExprSubselectRowNode
extends ExprSubselectNode

Represents a subselect in an expression tree.

See Also:
Serialized Form

Nested Class Summary
protected static class ExprSubselectRowNode.SubselectMultirowType
           
 
Nested classes/interfaces inherited from class com.espertech.esper.epl.expression.subquery.ExprSubselectNode
ExprSubselectNode.SubqueryAggregationType
 
Field Summary
static ExprSubselectRowEvalStrategy FILTERED_SELECTED
           
static ExprSubselectRowEvalStrategy FILTERED_UNSELECTED
           
protected  ExprSubselectRowNode.SubselectMultirowType subselectMultirowType
           
static ExprSubselectRowEvalStrategy UNFILTERED_SELECTED
           
static ExprSubselectRowEvalStrategy UNFILTERED_SELECTED_GROUPED
           
static ExprSubselectRowEvalStrategy UNFILTERED_UNSELECTED
           
 
Fields inherited from class com.espertech.esper.epl.expression.subquery.ExprSubselectNode
EMPTY_SUBSELECT_ARRAY, filterExpr, rawEventType, selectAsNames, selectClause, selectClauseEvaluator, statementName, subselectAggregationService, subselectNumber
 
Constructor Summary
ExprSubselectRowNode(StatementSpecRaw statementSpec)
          Ctor.
 
Method Summary
 java.lang.Object evaluate(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext exprEvaluatorContext)
          Evaluate the lookup expression returning an evaluation result object.
 java.util.Collection<EventBean> evaluateGetCollEvents(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext context)
           
 java.util.Collection evaluateGetCollScalar(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext context)
           
 EventBean evaluateGetEventBean(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext exprEvaluatorContext)
           
protected  java.util.Map<java.lang.String,java.lang.Object> evaluateRow(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context)
           
 java.lang.Object[][] evaluateTypableMulti(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext exprEvaluatorContext)
           
 java.lang.Object[] evaluateTypableSingle(EventBean[] eventsPerStream, boolean isNewData, java.util.Collection<EventBean> matchingEvents, ExprEvaluatorContext exprEvaluatorContext)
           
 java.lang.Class getComponentTypeCollection()
           
 EventType getEventTypeCollection(EventAdapterService eventAdapterService, java.lang.String statementId)
           
 EventType getEventTypeSingle(EventAdapterService eventAdapterService, java.lang.String statementId)
           
 java.lang.Object getMultirowMessage()
           
 java.lang.Class getType()
          Returns the type that the node's evaluate method returns an instance of.
 boolean isAllowMultiColumnSelect()
           
 java.util.LinkedHashMap<java.lang.String,java.lang.Object> typableGetRowProperties()
           
 void validateSubquery(ExprValidationContext validationContext)
           
 
Methods inherited from class com.espertech.esper.epl.expression.subquery.ExprSubselectNode
equalsNode, evaluate, evaluateGetEventBean, evaluateGetROCollectionEvents, evaluateGetROCollectionScalar, evaluateTypableMulti, evaluateTypableSingle, getExprEvaluator, getFilterExpr, getFilterSubqueryStreamTypes, getPrecedence, getRawEventType, getRowProperties, getSelectClause, getStatementSpecCompiled, getStatementSpecRaw, getSubselectAggregationService, getSubselectAggregationType, getSubselectNumber, isConstantResult, isFilterStreamSubselect, isMultirow, setFilterExpr, setFilterStreamSubselect, setFilterSubqueryStreamTypes, setRawEventType, setSelectAsNames, setSelectClause, setStatementSpecCompiled, setStrategy, setSubselectAggregationService, setSubselectAggregationType, toArray, toPrecedenceFreeEPL, validate
 
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
 

Field Detail

UNFILTERED_UNSELECTED

public static final ExprSubselectRowEvalStrategy UNFILTERED_UNSELECTED

UNFILTERED_SELECTED

public static final ExprSubselectRowEvalStrategy UNFILTERED_SELECTED

FILTERED_UNSELECTED

public static final ExprSubselectRowEvalStrategy FILTERED_UNSELECTED

FILTERED_SELECTED

public static final ExprSubselectRowEvalStrategy FILTERED_SELECTED

UNFILTERED_SELECTED_GROUPED

public static final ExprSubselectRowEvalStrategy UNFILTERED_SELECTED_GROUPED

subselectMultirowType

protected transient ExprSubselectRowNode.SubselectMultirowType subselectMultirowType
Constructor Detail

ExprSubselectRowNode

public ExprSubselectRowNode(StatementSpecRaw statementSpec)
Ctor.

Parameters:
statementSpec - is the lookup statement spec from the parser, unvalidated
Method Detail

getType

public java.lang.Class getType()
Description copied from interface: ExprEvaluator
Returns the type that the node's evaluate method returns an instance of.

Returns:
type returned when evaluated

validateSubquery

public void validateSubquery(ExprValidationContext validationContext)
                      throws ExprValidationException
Specified by:
validateSubquery in class ExprSubselectNode
Throws:
ExprValidationException

evaluate

public java.lang.Object evaluate(EventBean[] eventsPerStream,
                                 boolean isNewData,
                                 java.util.Collection<EventBean> matchingEvents,
                                 ExprEvaluatorContext exprEvaluatorContext)
Description copied from class: ExprSubselectNode
Evaluate the lookup expression returning an evaluation result object.

Specified by:
evaluate in class ExprSubselectNode
Parameters:
eventsPerStream - is the events for each stream in a join
isNewData - is true for new data, or false for old data
matchingEvents - is filtered results from the table of stored lookup events
exprEvaluatorContext - context for expression evalauation
Returns:
evaluation result

evaluateGetCollEvents

public java.util.Collection<EventBean> evaluateGetCollEvents(EventBean[] eventsPerStream,
                                                             boolean isNewData,
                                                             java.util.Collection<EventBean> matchingEvents,
                                                             ExprEvaluatorContext context)
Specified by:
evaluateGetCollEvents in class ExprSubselectNode

evaluateGetCollScalar

public java.util.Collection evaluateGetCollScalar(EventBean[] eventsPerStream,
                                                  boolean isNewData,
                                                  java.util.Collection<EventBean> matchingEvents,
                                                  ExprEvaluatorContext context)
Specified by:
evaluateGetCollScalar in class ExprSubselectNode

evaluateGetEventBean

public EventBean evaluateGetEventBean(EventBean[] eventsPerStream,
                                      boolean isNewData,
                                      java.util.Collection<EventBean> matchingEvents,
                                      ExprEvaluatorContext exprEvaluatorContext)
Specified by:
evaluateGetEventBean in class ExprSubselectNode

evaluateTypableSingle

public java.lang.Object[] evaluateTypableSingle(EventBean[] eventsPerStream,
                                                boolean isNewData,
                                                java.util.Collection<EventBean> matchingEvents,
                                                ExprEvaluatorContext exprEvaluatorContext)
Specified by:
evaluateTypableSingle in class ExprSubselectNode

evaluateTypableMulti

public java.lang.Object[][] evaluateTypableMulti(EventBean[] eventsPerStream,
                                                 boolean isNewData,
                                                 java.util.Collection<EventBean> matchingEvents,
                                                 ExprEvaluatorContext exprEvaluatorContext)
Specified by:
evaluateTypableMulti in class ExprSubselectNode

typableGetRowProperties

public java.util.LinkedHashMap<java.lang.String,java.lang.Object> typableGetRowProperties()
                                                                                   throws ExprValidationException
Specified by:
typableGetRowProperties in class ExprSubselectNode
Throws:
ExprValidationException

getEventTypeSingle

public EventType getEventTypeSingle(EventAdapterService eventAdapterService,
                                    java.lang.String statementId)
                             throws ExprValidationException
Throws:
ExprValidationException

getEventTypeCollection

public EventType getEventTypeCollection(EventAdapterService eventAdapterService,
                                        java.lang.String statementId)
                                 throws ExprValidationException
Throws:
ExprValidationException

getComponentTypeCollection

public java.lang.Class getComponentTypeCollection()
                                           throws ExprValidationException
Throws:
ExprValidationException

isAllowMultiColumnSelect

public boolean isAllowMultiColumnSelect()
Specified by:
isAllowMultiColumnSelect in class ExprSubselectNode

getMultirowMessage

public java.lang.Object getMultirowMessage()

evaluateRow

protected java.util.Map<java.lang.String,java.lang.Object> evaluateRow(EventBean[] eventsPerStream,
                                                                       boolean isNewData,
                                                                       ExprEvaluatorContext context)

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