Package com.espertech.esper.dataflow.ops.epl

Examples of com.espertech.esper.dataflow.ops.epl.EPLSelectViewable


        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect, boolean isRecoveringResilient) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null, null, false, false);
                    }
                };
View Full Code Here


        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null);
                    }
                };
View Full Code Here

        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect, boolean isRecoveringResilient) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null, null);
                    }
                };
View Full Code Here

        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect, boolean isRecoveringResilient) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null, null, false, false);
                    }
                };
View Full Code Here

        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect, boolean isRecoveringResilient) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null, null);
                    }
                };
View Full Code Here

        // create viewable per port
        final EPLSelectViewable[] viewables = new EPLSelectViewable[context.getInputPorts().size()];
        this.viewablesPerPort = viewables;
        for (Map.Entry<Integer, DataFlowOpInputPort> entry : context.getInputPorts().entrySet()) {
            EPLSelectViewable viewable = new EPLSelectViewable(entry.getValue().getTypeDesc().getEventType());
            viewables[entry.getKey()] = viewable;
        }

        ViewableActivatorFactory activatorFactory = new ViewableActivatorFactory() {
            public ViewableActivator createActivator(FilterStreamSpecCompiled filterStreamSpec) {

                EPLSelectViewable found = null;
                for (EPLSelectViewable viewable : viewables) {
                    if (viewable.getEventType() == filterStreamSpec.getFilterSpec().getFilterForEventType()) {
                        found = viewable;
                    }
                }
                if (found == null) {
                    throw new IllegalStateException("Failed to find viewable for filter");
                }
                final EPLSelectViewable viewable = found;
                return new ViewableActivator() {
                    public ViewableActivationResult activate(AgentInstanceContext agentInstanceContext, boolean isSubselect, boolean isRecoveringResilient) {
                        return new ViewableActivationResult(viewable, new StopCallback() {public void stop() {}}, null, null);
                    }
                };
View Full Code Here

TOP

Related Classes of com.espertech.esper.dataflow.ops.epl.EPLSelectViewable

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.