public abstract class Table extends Object implements FindableProcessor
InMemoryTable. Table
will support basic operations of add, delete, update, update or add and contains. *| Modifier and Type | Field and Description |
|---|---|
protected org.wso2.siddhi.query.api.definition.TableDefinition |
tableDefinition |
| Constructor and Description |
|---|
Table() |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
add(ComplexEventChunk<StreamEvent> addingEventChunk) |
void |
addEvents(ComplexEventChunk<StreamEvent> addingEventChunk) |
abstract CompiledUpdateSet |
compileUpdateSet(org.wso2.siddhi.query.api.execution.query.output.stream.UpdateSet updateSet,
MatchingMetaInfoHolder matchingMetaInfoHolder,
SiddhiAppContext siddhiAppContext,
List<VariableExpressionExecutor> variableExpressionExecutors,
Map<String,Table> tableMap,
String queryName)
Builds the "compiled" set clause of an update query.
|
protected abstract void |
connect() |
void |
connectWithRetry() |
protected abstract boolean |
contains(StateEvent matchingEvent,
CompiledCondition compiledCondition) |
boolean |
containsEvent(StateEvent matchingEvent,
CompiledCondition compiledCondition) |
protected abstract void |
delete(ComplexEventChunk<StateEvent> deletingEventChunk,
CompiledCondition compiledCondition) |
void |
deleteEvents(ComplexEventChunk<StateEvent> deletingEventChunk,
CompiledCondition compiledCondition) |
protected abstract void |
destroy() |
protected abstract void |
disconnect() |
protected abstract StreamEvent |
find(CompiledCondition compiledCondition,
StateEvent matchingEvent) |
StreamEvent |
find(StateEvent matchingEvent,
CompiledCondition compiledCondition)
To find events from the processor event pool, that the matches the matchingEvent based on finder logic.
|
RecordTableHandler |
getHandler() |
org.wso2.siddhi.query.api.definition.TableDefinition |
getTableDefinition() |
protected abstract void |
init(org.wso2.siddhi.query.api.definition.TableDefinition tableDefinition,
StreamEventPool storeEventPool,
StreamEventCloner storeEventCloner,
ConfigReader configReader,
SiddhiAppContext siddhiAppContext,
RecordTableHandler recordTableHandler) |
void |
initTable(org.wso2.siddhi.query.api.definition.TableDefinition tableDefinition,
StreamEventPool storeEventPool,
StreamEventCloner storeEventCloner,
ConfigReader configReader,
SiddhiAppContext siddhiAppContext,
RecordTableHandler recordTableHandler) |
void |
shutdown() |
protected abstract void |
update(ComplexEventChunk<StateEvent> updatingEventChunk,
CompiledCondition compiledCondition,
CompiledUpdateSet compiledUpdateSet) |
void |
updateEvents(ComplexEventChunk<StateEvent> updatingEventChunk,
CompiledCondition compiledCondition,
CompiledUpdateSet compiledUpdateSet) |
protected abstract void |
updateOrAdd(ComplexEventChunk<StateEvent> updateOrAddingEventChunk,
CompiledCondition compiledCondition,
CompiledUpdateSet compiledUpdateSet,
AddingStreamEventExtractor addingStreamEventExtractor) |
void |
updateOrAddEvents(ComplexEventChunk<StateEvent> updateOrAddingEventChunk,
CompiledCondition compiledCondition,
CompiledUpdateSet compiledUpdateSet,
AddingStreamEventExtractor addingStreamEventExtractor) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcompileConditionprotected org.wso2.siddhi.query.api.definition.TableDefinition tableDefinition
public void initTable(org.wso2.siddhi.query.api.definition.TableDefinition tableDefinition,
StreamEventPool storeEventPool,
StreamEventCloner storeEventCloner,
ConfigReader configReader,
SiddhiAppContext siddhiAppContext,
RecordTableHandler recordTableHandler)
protected abstract void init(org.wso2.siddhi.query.api.definition.TableDefinition tableDefinition,
StreamEventPool storeEventPool,
StreamEventCloner storeEventCloner,
ConfigReader configReader,
SiddhiAppContext siddhiAppContext,
RecordTableHandler recordTableHandler)
public org.wso2.siddhi.query.api.definition.TableDefinition getTableDefinition()
public void addEvents(ComplexEventChunk<StreamEvent> addingEventChunk)
protected abstract void add(ComplexEventChunk<StreamEvent> addingEventChunk) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic StreamEvent find(StateEvent matchingEvent, CompiledCondition compiledCondition)
FindableProcessorfind in interface FindableProcessormatchingEvent - the event to be matched with the events at the processorcompiledCondition - the execution element responsible for matching the corresponding events that matches
the matchingEvent based on pool of events at Processorprotected abstract StreamEvent find(CompiledCondition compiledCondition, StateEvent matchingEvent) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic void deleteEvents(ComplexEventChunk<StateEvent> deletingEventChunk, CompiledCondition compiledCondition)
protected abstract void delete(ComplexEventChunk<StateEvent> deletingEventChunk, CompiledCondition compiledCondition) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic void updateEvents(ComplexEventChunk<StateEvent> updatingEventChunk, CompiledCondition compiledCondition, CompiledUpdateSet compiledUpdateSet)
protected abstract void update(ComplexEventChunk<StateEvent> updatingEventChunk, CompiledCondition compiledCondition, CompiledUpdateSet compiledUpdateSet) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic void updateOrAddEvents(ComplexEventChunk<StateEvent> updateOrAddingEventChunk, CompiledCondition compiledCondition, CompiledUpdateSet compiledUpdateSet, AddingStreamEventExtractor addingStreamEventExtractor)
protected abstract void updateOrAdd(ComplexEventChunk<StateEvent> updateOrAddingEventChunk, CompiledCondition compiledCondition, CompiledUpdateSet compiledUpdateSet, AddingStreamEventExtractor addingStreamEventExtractor) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic boolean containsEvent(StateEvent matchingEvent, CompiledCondition compiledCondition)
protected abstract boolean contains(StateEvent matchingEvent, CompiledCondition compiledCondition) throws ConnectionUnavailableException
ConnectionUnavailableExceptionpublic void connectWithRetry()
public abstract CompiledUpdateSet compileUpdateSet(org.wso2.siddhi.query.api.execution.query.output.stream.UpdateSet updateSet, MatchingMetaInfoHolder matchingMetaInfoHolder, SiddhiAppContext siddhiAppContext, List<VariableExpressionExecutor> variableExpressionExecutors, Map<String,Table> tableMap, String queryName)
updateSet - the set of assignment expressions, each containing the table column to be
updated and the expression to be assigned.matchingMetaInfoHolder - the meta structure of the incoming matchingEventsiddhiAppContext - current siddhi app contextvariableExpressionExecutors - the list of variable ExpressionExecutors already createdtableMap - map of event tablesqueryName - query name to which the update statement belongs.protected abstract void connect()
throws ConnectionUnavailableException
ConnectionUnavailableExceptionprotected abstract void disconnect()
protected abstract void destroy()
public RecordTableHandler getHandler()
public void shutdown()
Copyright © 2017 WSO2. All rights reserved.