Package org.drools.runtime.pipeline

Examples of org.drools.runtime.pipeline.Action


        ksession.setGlobal( "list1",
                            list1 );
        ksession.setGlobal( "list2",
                            list2 );

        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        KnowledgeRuntimeCommand insertStage = PipelineFactory.newStatefulKnowledgeSessionInsert();
        insertStage.setReceiver( executeResultHandler );

        Splitter splitter = PipelineFactory.newIterateSplitter();
View Full Code Here


//        assertXMLEqual( expectedXml,
//                        outXml );
//    }

    private Pipeline getPipeline(StatelessKnowledgeSession ksession) {
        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        Action assignResult = PipelineFactory.newAssignObjectAsResult();
        assignResult.setReceiver( executeResultHandler );

        Transformer outTransformer = PipelineFactory.newXStreamToXmlTransformer( BatchExecutionHelper.newXStreamMarshaller() );
        outTransformer.setReceiver( assignResult );

        KnowledgeRuntimeCommand batchExecution = PipelineFactory.newCommandExecutor();
View Full Code Here

        return pipeline;
    }

    private Pipeline getPipelineSessionStateful(GridNode node, XStreamResolverStrategy xstreamResolverStrategy) {
        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        Action assignResult = PipelineFactory.newAssignObjectAsResult();
        assignResult.setReceiver( executeResultHandler );

        //Transformer outTransformer = PipelineFactory.newXStreamToXmlTransformer( BatchExecutionHelper.newXStreamMarshaller() );
        Transformer outTransformer = new XStreamToXmlGridTransformer();
        outTransformer.setReceiver( assignResult );
View Full Code Here

        return pipeline;
    }

    private Pipeline getPipelineStateful(StatefulKnowledgeSession ksession) {
        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        Action assignResult = PipelineFactory.newAssignObjectAsResult();
        assignResult.setReceiver( executeResultHandler );

        Transformer outTransformer = PipelineFactory.newXStreamToXmlTransformer( BatchExecutionHelper.newXStreamMarshaller() );
        outTransformer.setReceiver( assignResult );

        KnowledgeRuntimeCommand batchExecution = PipelineFactory.newCommandExecutor();
View Full Code Here

       
         List list = new ArrayList();
         ksession.setGlobal( "list",
                             list );

         Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

         Action assignResult = PipelineFactory.newAssignObjectAsResult();
         assignResult.setReceiver( executeResultHandler );

         KnowledgeRuntimeCommand batchExecution = PipelineFactory.newCommandExecutor();
         batchExecution.setReceiver( assignResult );

         KnowledgeRuntimeCommand insertStage = PipelineFactory.newInsertObjectCommand();
View Full Code Here

        StatelessKnowledgeSession ksession = kbase.newStatelessKnowledgeSession();
        List list = new ArrayList();
        ksession.setGlobal( "list",
                            list );

        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();
       
        Action assignResult = PipelineFactory.newAssignObjectAsResult();
        assignResult.setReceiver( executeResultHandler );

        KnowledgeRuntimeCommand batchExecution = PipelineFactory.newCommandExecutor();
        batchExecution.setReceiver( assignResult );
       
        KnowledgeRuntimeCommand insertStage = PipelineFactory.newInsertObjectCommand();
View Full Code Here

        StatelessKnowledgeSession ksession = kbase.newStatelessKnowledgeSession();
        List list = new ArrayList();
        ksession.setGlobal( "list",
                            list );

        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();
       
        Action assignResult = PipelineFactory.newAssignObjectAsResult();
        assignResult.setReceiver( executeResultHandler );

        KnowledgeRuntimeCommand batchExecution = PipelineFactory.newCommandExecutor();
        batchExecution.setReceiver( assignResult );
       
        KnowledgeRuntimeCommand insertElementsStage = PipelineFactory.newInsertElementsCommand();
View Full Code Here

        StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();
        List list = new ArrayList();
        ksession.setGlobal( "list",
                            list );

        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        KnowledgeRuntimeCommand insertStage = PipelineFactory.newStatefulKnowledgeSessionInsert();
        insertStage.setReceiver( executeResultHandler );

        // Instantiate Smooks with the config...
View Full Code Here

        StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();
        List list = new ArrayList();
        ksession.setGlobal( "list",
                            list );

        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();

        KnowledgeRuntimeCommand insertStage = PipelineFactory.newStatefulKnowledgeSessionInsert();
        insertStage.setReceiver( executeResultHandler );

        Splitter splitter = PipelineFactory.newIterateSplitter();
View Full Code Here

       
        KnowledgeBase kbase = KnowledgeBaseFactory.newKnowledgeBase();
        kbase.addKnowledgePackages( kbuilder.getKnowledgePackages() );
        StatelessKnowledgeSession ksession = kbase.newStatelessKnowledgeSession();
       
        Action executeResultHandler = PipelineFactory.newExecuteResultHandler();
       
        KnowledgeRuntimeCommand execute = PipelineFactory.newStatelessKnowledgeSessionExecute();
        execute.setReceiver( executeResultHandler );
       
        Action assignParameters = PipelineFactory.newMvelAction( "context.parameters.globalParams.setInOut( ['list' : new java.util.ArrayList()] )");
        assignParameters.setReceiver( execute );
       
        Action assignIterable = PipelineFactory.newMvelAction( "context.setIterable( this )");               
        assignIterable.setReceiver( assignParameters );
               
        Pipeline pipeline = PipelineFactory.newStatelessKnowledgeSessionPipeline(ksession);
        pipeline.setReceiver( assignIterable );
       
        ResultHandlerImpl handler = new ResultHandlerImpl();
View Full Code Here

TOP

Related Classes of org.drools.runtime.pipeline.Action

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.