Class ExprDeclaredForgeBase
java.lang.Object
com.espertech.esper.common.internal.epl.expression.declared.compiletime.ExprDeclaredForgeBase
- All Implemented Interfaces:
ExprEnumerationEval
,ExprEnumerationForge
,ExprEvaluator
,ExprForge
,ExprForgeInstrumentable
,ExprTypableReturnEval
,ExprTypableReturnForge
- Direct Known Subclasses:
ExprDeclaredForgeNoRewrite
,ExprDeclaredForgeRewrite
,ExprDeclaredForgeRewriteWValue
public abstract class ExprDeclaredForgeBase
extends Object
implements ExprForgeInstrumentable, ExprTypableReturnForge, ExprTypableReturnEval, ExprEnumerationForge, ExprEnumerationEval
-
Field Summary
Fields inherited from interface com.espertech.esper.common.internal.epl.expression.core.ExprEvaluator
EPTYPE, EPTYPEARRAY
-
Constructor Summary
ConstructorDescriptionExprDeclaredForgeBase
(ExprDeclaredNodeImpl parent, ExprForge innerForge, boolean isCache, boolean audit, String statementName) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract CodegenExpression
codegenEventsPerStreamRewritten
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) final Object
evaluate
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) Evaluate event tuple and return result.evaluateCodegen
(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) evaluateCodegenUninstrumented
(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) evaluateGetEventBean
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) evaluateGetEventBeanCodegen
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) final Collection<EventBean>
evaluateGetROCollectionEvents
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) evaluateGetROCollectionEventsCodegen
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) evaluateGetROCollectionScalar
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) evaluateGetROCollectionScalarCodegen
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) Object[][]
evaluateTypableMulti
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) evaluateTypableMultiCodegen
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) Object[]
evaluateTypableSingle
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) evaluateTypableSingleCodegen
(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) abstract EventBean[]
getEventsPerStreamRewritten
(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) getEventTypeCollection
(StatementRawInfo statementRawInfo, StatementCompileTimeServices compileTimeServices) getEventTypeSingle
(StatementRawInfo statementRawInfo, StatementCompileTimeServices compileTimeServices) protected static CodegenExpression[]
getInstrumentationQParams
(ExprDeclaredNodeImpl parent, CodegenClassScope codegenClassScope) Return null to indicate no row-type result available, or a map of property names and types to indicate a row-type result is available.Return true for multi-row return, return false for return of single row only
-
Constructor Details
-
ExprDeclaredForgeBase
public ExprDeclaredForgeBase(ExprDeclaredNodeImpl parent, ExprForge innerForge, boolean isCache, boolean audit, String statementName)
-
-
Method Details
-
getEventsPerStreamRewritten
public abstract EventBean[] getEventsPerStreamRewritten(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) -
codegenEventsPerStreamRewritten
protected abstract CodegenExpression codegenEventsPerStreamRewritten(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) -
getTypableReturnEvaluator
-
getExprEvaluatorEnumeration
- Specified by:
getExprEvaluatorEnumeration
in interfaceExprEnumerationForge
-
getExprEvaluator
- Specified by:
getExprEvaluator
in interfaceExprForge
-
getEvaluationType
- Specified by:
getEvaluationType
in interfaceExprForge
-
getInnerForge
-
getRowProperties
Description copied from interface:ExprTypableReturnForge
Return null to indicate no row-type result available, or a map of property names and types to indicate a row-type result is available.- Specified by:
getRowProperties
in interfaceExprTypableReturnForge
- Returns:
- map of property names and types or null
- Throws:
ExprValidationException
- if the expression is invalid
-
isMultirow
Description copied from interface:ExprTypableReturnForge
Return true for multi-row return, return false for return of single row only- Specified by:
isMultirow
in interfaceExprTypableReturnForge
- Returns:
- multi-row flag
-
evaluateTypableSingle
public Object[] evaluateTypableSingle(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) - Specified by:
evaluateTypableSingle
in interfaceExprTypableReturnEval
-
evaluateTypableSingleCodegen
public CodegenExpression evaluateTypableSingleCodegen(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateTypableSingleCodegen
in interfaceExprTypableReturnForge
-
evaluateTypableMulti
public Object[][] evaluateTypableMulti(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) - Specified by:
evaluateTypableMulti
in interfaceExprTypableReturnEval
-
evaluateTypableMultiCodegen
public CodegenExpression evaluateTypableMultiCodegen(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateTypableMultiCodegen
in interfaceExprTypableReturnForge
-
evaluate
public final Object evaluate(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) Description copied from interface:ExprEvaluator
Evaluate event tuple and return result.- Specified by:
evaluate
in interfaceExprEvaluator
- Parameters:
eventsPerStream
- - event tupleisNewData
- - indicates whether we are dealing with new data (istream) or old data (rstream)context
- context for expression evaluation- Returns:
- evaluation result, a boolean value for OR/AND-type evalution nodes.
-
evaluateCodegenUninstrumented
public CodegenExpression evaluateCodegenUninstrumented(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateCodegenUninstrumented
in interfaceExprForgeInstrumentable
-
getForgeConstantType
- Specified by:
getForgeConstantType
in interfaceExprForge
-
evaluateCodegen
public CodegenExpression evaluateCodegen(EPTypeClass requiredType, CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateCodegen
in interfaceExprForge
-
getInstrumentationQParams
protected static CodegenExpression[] getInstrumentationQParams(ExprDeclaredNodeImpl parent, CodegenClassScope codegenClassScope) -
evaluateGetROCollectionEvents
public final Collection<EventBean> evaluateGetROCollectionEvents(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) - Specified by:
evaluateGetROCollectionEvents
in interfaceExprEnumerationEval
-
evaluateGetROCollectionEventsCodegen
public CodegenExpression evaluateGetROCollectionEventsCodegen(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateGetROCollectionEventsCodegen
in interfaceExprEnumerationForge
-
evaluateGetROCollectionScalar
public Collection evaluateGetROCollectionScalar(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) - Specified by:
evaluateGetROCollectionScalar
in interfaceExprEnumerationEval
-
evaluateGetROCollectionScalarCodegen
public CodegenExpression evaluateGetROCollectionScalarCodegen(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateGetROCollectionScalarCodegen
in interfaceExprEnumerationForge
-
getComponentTypeCollection
- Specified by:
getComponentTypeCollection
in interfaceExprEnumerationForge
- Throws:
ExprValidationException
-
getEventTypeCollection
public EventType getEventTypeCollection(StatementRawInfo statementRawInfo, StatementCompileTimeServices compileTimeServices) throws ExprValidationException - Specified by:
getEventTypeCollection
in interfaceExprEnumerationForge
- Throws:
ExprValidationException
-
getEventTypeSingle
public EventType getEventTypeSingle(StatementRawInfo statementRawInfo, StatementCompileTimeServices compileTimeServices) throws ExprValidationException - Specified by:
getEventTypeSingle
in interfaceExprEnumerationForge
- Throws:
ExprValidationException
-
evaluateGetEventBean
public EventBean evaluateGetEventBean(EventBean[] eventsPerStream, boolean isNewData, ExprEvaluatorContext context) - Specified by:
evaluateGetEventBean
in interfaceExprEnumerationEval
-
evaluateGetEventBeanCodegen
public CodegenExpression evaluateGetEventBeanCodegen(CodegenMethodScope codegenMethodScope, ExprForgeCodegenSymbol exprSymbol, CodegenClassScope codegenClassScope) - Specified by:
evaluateGetEventBeanCodegen
in interfaceExprEnumerationForge
-
getForgeRenderable
- Specified by:
getForgeRenderable
in interfaceExprEnumerationForge
- Specified by:
getForgeRenderable
in interfaceExprForge
-