Package org.jbpm.simulation.impl

Examples of org.jbpm.simulation.impl.SimulateProcessPathCommand


           
            for (int i = 0; i < instancesOfPath; i++) {
                f.newStep( interval * i )
                    .newKieSession( releaseId, "TestKbase.KSession1" )
                        .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("defaultPackage.test", context, path));
            }
           
            counter++;
        }
        f.runSimulation();
View Full Code Here


                       
                for (int i = 0; i < instancesOfPath; i++) {
                    f.newStep( interval * i )
                        .newKieSession( releaseId, "TestKbase.KSession1" )
                            .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                        .addCommand(new SimulateProcessPathCommand(processId, context, path));
                }
            } else {
                f.newStep( interval )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand(processId, context, path));
                break;
            }
           
            counter++;
        }
View Full Code Here

                       
                for (int i = 0; i < instancesOfPath; i++) {
                    f.newStep( interval * i )
                        .newKieSession( releaseId, "TestKbase.KSession1" )
                            .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                        .addCommand(new SimulateProcessPathCommand(processId, context, path));
                }
            } else {
                f.newStep( interval )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand(processId, context, path));
                break;
            }
           
            counter++;
        }
View Full Code Here

                       
                for (int i = 0; i < instancesOfPath; i++) {
                    f.newStep( interval * i )
                        .newKieSession( releaseId, null)
                            .end()
                        .addCommand(new SimulateProcessPathCommand(processId, context, path))
                        .addCommand( new SetVariableCommandFromLastReturn( StatefulKnowledgeSession.class.getName() ))
                        .addCommand(new DisposeCommand());
                }
            } else {
                f.newStep(interval)
                .newKieSession(releaseId, null)
                    .end()
                .addCommand(new SimulateProcessPathCommand(processId, context, path))
                .addCommand( new SetVariableCommandFromLastReturn( StatefulKnowledgeSession.class.getName() ))
                .addCommand(new DisposeCommand());
                break;
            }
           
View Full Code Here

                       
                for (int i = 0; i < instancesOfPath; i++) {
                    f.newStep( interval * i )
                        .newKieSession( releaseId, "TestKbase.KSession1" )
                            .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                        .addCommand(new SimulateProcessPathCommand(processId, context, path));
                }
            } else {
                f.newStep( interval )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand(processId, context, path));
                break;
            }
           
            counter++;
        }
View Full Code Here

           
            for (int i = 0; i < instancesOfPath; i++) {
                f.newStep( interval * i )
                    .newKieSession( releaseId, "TestKbase.KSession1" )
                        .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("defaultPackage.test", context, path));
            }
           
            counter++;
        }
        f.runSimulation();
View Full Code Here

           
            for (int i = 0; i < instancesOfPath; i++) {
                f.newStep( interval * i )
                    .newKieSession( releaseId, "TestKbase.KSession1" )
                        .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("defaultPackage.test", context, path));
            }
           
            counter++;
        }
        f.runSimulation();
View Full Code Here

        // @formatter:off
        f.newPath("path1")
            .newStep( 0 )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("com.sample.test", context, paths.get(0)))
        .newPath("path2")
            .newStep( 10, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("com.sample.test", context, paths.get(1)))
        .runSimulation();
        // @formatter:on
    }
View Full Code Here

        // @formatter:off
        f.newPath("path1")
            .newStep( 0 )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 5, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 10, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 15, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 20, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 25, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
        .runSimulation();
        // @formatter:on
       
        System.out.println("Resource utilization for UserTask Hello: " + context.getStaffPoolManager().getActivityPool("Hello").getResourceUtilization());
    }
View Full Code Here

        // @formatter:off       
        f.newPath("path1")
            .newStep( 0 )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 5, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 10, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                    .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 15, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 20, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
            .newStep( 25, TimeUnit.MINUTES )
                .newKieSession( releaseId, "TestKbase.KSession1" )
                    .end(World.ROOT, StatefulKnowledgeSession.class.getName())
                .addCommand(new SimulateProcessPathCommand("UserTask", context, paths.get(0)))
        .runSimulation();
        // @formatter:on
       
        System.out.println("Resource utilization for UserTask Hello: " + context.getStaffPoolManager().getActivityPool("Hello").getResourceUtilization());
    }
View Full Code Here

TOP

Related Classes of org.jbpm.simulation.impl.SimulateProcessPathCommand

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.