use of org.wso2.siddhi.core.query.input.stream.state.PreStateProcessor in project siddhi by wso2.
the class AbsentLogicalPreStateProcessor method cloneProcessor.
@Override
public PreStateProcessor cloneProcessor(String key) {
AbsentLogicalPreStateProcessor logicalPreStateProcessor = new AbsentLogicalPreStateProcessor(logicalType, stateType, withinStates, waitingTimeConstant);
cloneProperties(logicalPreStateProcessor, key);
logicalPreStateProcessor.init(siddhiAppContext, queryName);
// Set the scheduler
siddhiAppContext.addEternalReferencedHolder(logicalPreStateProcessor);
EntryValveProcessor entryValveProcessor = new EntryValveProcessor(siddhiAppContext);
entryValveProcessor.setToLast(logicalPreStateProcessor);
Scheduler scheduler = SchedulerParser.parse(siddhiAppContext.getScheduledExecutorService(), entryValveProcessor, siddhiAppContext);
logicalPreStateProcessor.setScheduler(scheduler);
return logicalPreStateProcessor;
}
use of org.wso2.siddhi.core.query.input.stream.state.PreStateProcessor in project siddhi by wso2.
the class AbsentStreamPreStateProcessor method cloneProcessor.
@Override
public PreStateProcessor cloneProcessor(String key) {
AbsentStreamPreStateProcessor streamPreStateProcessor = new AbsentStreamPreStateProcessor(stateType, withinStates, waitingTimeConstant);
cloneProperties(streamPreStateProcessor, key);
streamPreStateProcessor.init(siddhiAppContext, queryName);
// Set the scheduler
siddhiAppContext.addEternalReferencedHolder(streamPreStateProcessor);
EntryValveProcessor entryValveProcessor = new EntryValveProcessor(siddhiAppContext);
entryValveProcessor.setToLast(streamPreStateProcessor);
Scheduler scheduler = SchedulerParser.parse(siddhiAppContext.getScheduledExecutorService(), entryValveProcessor, siddhiAppContext);
streamPreStateProcessor.setScheduler(scheduler);
return streamPreStateProcessor;
}
Aggregations