本文整理匯總了Java中com.espertech.esper.core.service.EPStatementDispatch類的典型用法代碼示例。如果您正苦於以下問題:Java EPStatementDispatch類的具體用法?Java EPStatementDispatch怎麽用?Java EPStatementDispatch使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
EPStatementDispatch類屬於com.espertech.esper.core.service包,在下文中一共展示了EPStatementDispatch類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: handleSimpleSelect
import com.espertech.esper.core.service.EPStatementDispatch; //導入依賴的package包/類
private Viewable handleSimpleSelect(Viewable view,
ResultSetProcessor resultSetProcessor,
AgentInstanceContext agentInstanceContext,
EvalRootMatchRemover evalRootMatchRemover,
boolean suppressSameEventMatches,
boolean discardPartialsOnMatch) {
Viewable finalView = view;
// Add filter view that evaluates the filter expression
if (filterRootNodeEvaluator != null) {
FilterExprView filterView = new FilterExprView(statementSpec.getFilterRootNode(), filterRootNodeEvaluator, agentInstanceContext);
finalView.addView(filterView);
finalView = filterView;
}
Deque<EPStatementDispatch> dispatches = null;
if (evalRootMatchRemover != null && (suppressSameEventMatches || discardPartialsOnMatch)) {
PatternRemoveDispatchView v = new PatternRemoveDispatchView(evalRootMatchRemover, suppressSameEventMatches, discardPartialsOnMatch);
dispatches = new ArrayDeque<EPStatementDispatch>(2);
dispatches.add(v);
finalView.addView(v);
finalView = v;
}
// for ordered deliver without output limit/buffer
if (statementSpec.getOrderByList().length > 0 && (statementSpec.getOutputLimitSpec() == null)) {
SingleStreamDispatchView bf = new SingleStreamDispatchView();
if (dispatches == null) {
dispatches = new ArrayDeque<EPStatementDispatch>(1);
}
dispatches.add(bf);
finalView.addView(bf);
finalView = bf;
}
if (dispatches != null) {
EPStatementAgentInstanceHandle handle = agentInstanceContext.getEpStatementAgentInstanceHandle();
if (dispatches.size() == 1) {
handle.setOptionalDispatchable(dispatches.getFirst());
} else {
final EPStatementDispatch[] dispatchArray = dispatches.toArray(new EPStatementDispatch[dispatches.size()]);
handle.setOptionalDispatchable(new EPStatementDispatch() {
public void execute() {
for (EPStatementDispatch dispatch : dispatchArray) {
dispatch.execute();
}
}
});
}
}
com.espertech.esper.view.View selectView = outputProcessViewFactory.makeView(resultSetProcessor, agentInstanceContext);
finalView.addView(selectView);
finalView = selectView;
return finalView;
}
示例2: getOptionalDispatchable
import com.espertech.esper.core.service.EPStatementDispatch; //導入依賴的package包/類
public EPStatementDispatch getOptionalDispatchable() {
return optionalDispatchable;
}
示例3: setOptionalDispatchable
import com.espertech.esper.core.service.EPStatementDispatch; //導入依賴的package包/類
/**
* Provides a callback for use when statement processing for filters and schedules is done,
* for use by join statements that require an explicit indicator that all
* joined streams results have been processed.
*
* @param optionalDispatchable is the instance for calling onto after statement callback processing
*/
public void setOptionalDispatchable(EPStatementDispatch optionalDispatchable) {
this.optionalDispatchable = optionalDispatchable;
}
示例4: setOptionalDispatchable
import com.espertech.esper.core.service.EPStatementDispatch; //導入依賴的package包/類
/**
* Provides a callback for use when statement processing for filters and schedules is done,
* for use by join statements that require an explicit indicator that all
* joined streams results have been processed.
* @param optionalDispatchable is the instance for calling onto after statement callback processing
*/
public void setOptionalDispatchable(EPStatementDispatch optionalDispatchable)
{
this.optionalDispatchable = optionalDispatchable;
}