Package com.werken.blissed

Examples of com.werken.blissed.ProcessContext


    public void doTag(XMLOutput output) throws Exception
    {
        checkObjectAttribute( "process",
                              getProcess() );

        ProcessContext context = getProcessContext();

        if ( context == null )
        {
            throw new JellyException( "No process context" );
        }
        ProcessEngine  engine  = context.getProcessEngine();

        engine.call( getProcess(),
                     context );
    }
View Full Code Here


    public void doTag(XMLOutput output) throws Exception
    {
        checkObjectAttribute( "process",
                              this.process );

        ProcessContext context = getProcessContext();

        ProcessEngine  engine  = null;
        ProcessContext spawned = null;

        if ( context == null )
        {
            engine = getEngine();
View Full Code Here

        anotherProcess.setStartState( anotherState1 );

        ProcessEngine engine = new ProcessEngine();

        ProcessContext context = engine.spawn( this.process );

        assertSame( this.process,
                    context.getCurrentProcess() );

        assertSame( this.state,
                    context.getCurrentState() );

        CallActivity activity = new CallActivity( anotherProcess );

        activity.perform( context );

        assertSame( anotherProcess,
                    context.getCurrentProcess() );

        assertSame( anotherState1,
                    context.getCurrentState() );
    }
View Full Code Here

        anotherProcess.setStartState( anotherState1 );

        ProcessEngine engine = new ProcessEngine();

        ProcessContext context = engine.spawn( this.process );

        assertSame( this.process,
                    context.getCurrentProcess() );

        assertSame( this.state,
                    context.getCurrentState() );

        SpawnActivity activity = new SpawnActivity( anotherProcess );

        activity.perform( context );

        assertSame( this.process,
                    context.getCurrentProcess() );

        assertSame( this.state,
                    context.getCurrentState() );

        engine.start();

        Thread.sleep( 1000 );

        Set children = context.getChildren();

        assertEquals( 1,
                      children.size() );

        ProcessContext child = (ProcessContext) children.iterator().next();

        assertSame( anotherProcess,
                    child.getCurrentProcess() );

        assertSame( anotherState1,
                    child.getCurrentState() );
    }
View Full Code Here

TOP

Related Classes of com.werken.blissed.ProcessContext

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.