当前位置: 首页>>代码示例>>Java>>正文


Java EPStatementDispatch类代码示例

本文整理汇总了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;
}
 
开发者ID:espertechinc,项目名称:esper,代码行数:60,代码来源:StatementAgentInstanceFactorySelect.java

示例2: getOptionalDispatchable

import com.espertech.esper.core.service.EPStatementDispatch; //导入依赖的package包/类
public EPStatementDispatch getOptionalDispatchable() {
    return optionalDispatchable;
}
 
开发者ID:espertechinc,项目名称:esper,代码行数:4,代码来源:EPStatementAgentInstanceHandle.java

示例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;
}
 
开发者ID:espertechinc,项目名称:esper,代码行数:11,代码来源:EPStatementAgentInstanceHandle.java

示例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;
}
 
开发者ID:mobile-event-processing,项目名称:Asper,代码行数:11,代码来源:EPStatementAgentInstanceHandle.java


注:本文中的com.espertech.esper.core.service.EPStatementDispatch类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。