public class Window extends Object implements FindableProcessor, MemoryCalculable
Constructor and Description |
---|
Window(io.siddhi.query.api.definition.WindowDefinition windowDefinition,
SiddhiAppContext siddhiAppContext)
Construct a Window object.
|
Modifier and Type | Method and Description |
---|---|
void |
add(ComplexEventChunk complexEventChunk)
Add the given ComplexEventChunk to the Window.
|
CompiledCondition |
compileCondition(io.siddhi.query.api.expression.Expression condition,
MatchingMetaInfoHolder matchingMetaInfoHolder,
List<VariableExpressionExecutor> variableExpressionExecutors,
Map<String,Table> tableMap,
SiddhiQueryContext siddhiQueryContext)
To construct a finder having the capability of finding events at the processor that corresponds to the incoming
matchingEvent and the given matching expression logic.
|
StreamEvent |
find(StateEvent matchingEvent,
CompiledCondition compiledCondition)
To find events from the processor event pool, that the matches the matchingEvent based on finder logic.
|
LockWrapper |
getLock() |
ProcessingMode |
getProcessingMode() |
io.siddhi.query.api.definition.WindowDefinition |
getWindowDefinition()
Return the
WindowDefinition used to construct this Window. |
void |
init(Map<String,Table> tableMap,
Map<String,Window> eventWindowMap,
String windowName,
boolean findToBeExecuted)
Initialize the WindowEvent table by creating
WindowProcessor to handle the events. |
void |
setPublisher(StreamJunction.Publisher publisher)
Set Publisher to which the the output events from internal window have to be sent.
|
public Window(io.siddhi.query.api.definition.WindowDefinition windowDefinition, SiddhiAppContext siddhiAppContext)
windowDefinition
- definition of the windowsiddhiAppContext
- siddhi app context of Siddhipublic void init(Map<String,Table> tableMap, Map<String,Window> eventWindowMap, String windowName, boolean findToBeExecuted)
WindowProcessor
to handle the events.tableMap
- map of Table
seventWindowMap
- map of EventWindowswindowName
- name of the query window belongs to.findToBeExecuted
- will find will be executed on the window.public void setPublisher(StreamJunction.Publisher publisher)
publisher
- output publisherpublic io.siddhi.query.api.definition.WindowDefinition getWindowDefinition()
WindowDefinition
used to construct this Window.public void add(ComplexEventChunk complexEventChunk)
complexEventChunk
- the event chunk to be addedpublic StreamEvent find(StateEvent matchingEvent, CompiledCondition compiledCondition)
find
in interface FindableProcessor
matchingEvent
- 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 Processorpublic CompiledCondition compileCondition(io.siddhi.query.api.expression.Expression condition, MatchingMetaInfoHolder matchingMetaInfoHolder, List<VariableExpressionExecutor> variableExpressionExecutors, Map<String,Table> tableMap, SiddhiQueryContext siddhiQueryContext)
compileCondition
in interface FindableProcessor
condition
- the matching conditionmatchingMetaInfoHolder
- the meta structure of the incoming matchingEventvariableExpressionExecutors
- the list of variable ExpressionExecutors already createdtableMap
- map of event tablessiddhiQueryContext
- current siddhi query contextpublic LockWrapper getLock()
public ProcessingMode getProcessingMode()
Copyright © 2019. All rights reserved.