|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.espertech.esper.core.StatementResultServiceImpl
public class StatementResultServiceImpl
Implements tracking of statement listeners and subscribers for a given statement such as to efficiently dispatch in situations where 0, 1 or more listeners are attached and/or 0 or 1 subscriber (such as iteration-only statement).
Field Summary | |
---|---|
protected ThreadLocal<ArrayDequeJDK6Backport<UniformPair<EventBean[]>>> |
lastResults
Buffer for holding dispatchable events. |
Constructor Summary | |
---|---|
StatementResultServiceImpl(StatementLifecycleSvc statementLifecycleSvc)
Ctor. |
Method Summary | |
---|---|
void |
dispatchOnStop()
Dispatches when the statement is stopped any remaining results. |
void |
execute()
Execution of result indication. |
EventBean |
getLastIterableEvent()
Returns the last iterable event, for use by patterns since these are not iterable. |
void |
indicate(UniformPair<EventBean[]> results)
Stores for dispatching the statement results. |
boolean |
isMakeNatural()
Returns true to indicate that natural events should be produced, for use in select expression processing. |
boolean |
isMakeSynthetic()
Returns true to indicate that synthetic events should be produced, for use in select expression processing. |
void |
setContext(EPStatementSPI epStatement,
EPServiceProvider epServiceProvider,
boolean isInsertInto,
boolean isPattern)
For initialization of the service to provide statement context. |
void |
setSelectClause(Class[] selectClauseTypes,
String[] selectClauseColumnNames)
For initialize of the service providing select clause column types and names. |
void |
setUpdateListeners(EPStatementListenerSet statementListenerSet)
Indicate a change in update listener. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected ThreadLocal<ArrayDequeJDK6Backport<UniformPair<EventBean[]>>> lastResults
Constructor Detail |
---|
public StatementResultServiceImpl(StatementLifecycleSvc statementLifecycleSvc)
statementLifecycleSvc
- handles persistence for statementsMethod Detail |
---|
public void setContext(EPStatementSPI epStatement, EPServiceProvider epServiceProvider, boolean isInsertInto, boolean isPattern)
StatementResultService
setContext
in interface StatementResultService
epStatement
- the statementepServiceProvider
- the engine instanceisInsertInto
- true if this is insert intoisPattern
- true if this is a pattern statementpublic void setSelectClause(Class[] selectClauseTypes, String[] selectClauseColumnNames)
StatementResultService
setSelectClause
in interface StatementResultService
selectClauseTypes
- types of columns in the select clauseselectClauseColumnNames
- column namespublic boolean isMakeSynthetic()
StatementResultService
isMakeSynthetic
in interface StatementResultService
public boolean isMakeNatural()
StatementResultService
isMakeNatural
in interface StatementResultService
public EventBean getLastIterableEvent()
StatementResultService
getLastIterableEvent
in interface StatementResultService
public void setUpdateListeners(EPStatementListenerSet statementListenerSet)
StatementResultService
setUpdateListeners
in interface StatementResultService
statementListenerSet
- is the new listeners and subscriberpublic void indicate(UniformPair<EventBean[]> results)
StatementResultService
indicate
in interface StatementResultService
results
- is the insert and remove stream datapublic void execute()
StatementResultService
execute
in interface StatementResultService
public void dispatchOnStop()
dispatchOnStop
in interface StatementResultService
|
© 2007 EsperTech Inc. All rights reserved. Visit us at espertech.com |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |