Examples of DeriveUpdatedRouteSpecification


Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

        add( new FeedbackPanel( "feedback" ) );

        try
        {
            // Temporary routeSpec to get correct route candidates
            RouteSpecification tempRouteSpec = new DeriveUpdatedRouteSpecification( trackingIdString ).getRouteSpec();

            add( new ListView<IModel<Itinerary>>( "routes", query( BookingQueries.class ).routeCandidates( tempRouteSpec ) )
            {
                @Override
                protected void populateItem( ListItem<IModel<Itinerary>> item )
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

                                        ROUTED, directed, itinerary.eta(), leg2,
                                        nextHandlingEvent( LOAD, CHICAGO, DAY5, V201 ) ) );

        assertRouteSpec( HONGKONG, STOCKHOLM, TODAY, DAY24 );

        newRouteSpec = new DeriveUpdatedRouteSpecification( cargo ).getRouteSpec();
        cargo.routeSpecification().set( newRouteSpec );

        assertRouteSpec( CHICAGO,   // Current location
                         STOCKHOLM, // Unchanged
                         DAY5,      // Last completion time
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

                    throw new ChangeDestinationException( "New destination is same as old destination." );
                }

                // Step 2 - Derive new route specification

                newRouteSpec = new DeriveUpdatedRouteSpecification( cargo, newDestination ).getRouteSpec();

                // Step 3 - Assign new route specification to cargo

                cargo.routeSpecification().set( newRouteSpec );
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

            public void assignCargoToRoute()
                throws CannotCreateRouteSpecificationException, UnsatisfyingRouteException, InspectionException
            {
                // Step 1 - Derive updated route specification

                newRouteSpec = new DeriveUpdatedRouteSpecification( cargo ).getRouteSpec();

                // Step 2 - Verify that route satisfies route specification

                if( !newRouteSpec.isSatisfiedBy( c.itinerary ) )
                {
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

                                        ROUTED, directed, itinerary.eta(), leg1,
                                        nextHandlingEvent( LOAD, HONGKONG, DAY1, V201 ) ) );

        assertRouteSpec( HONGKONG, STOCKHOLM, TODAY, DAY24 );

        newRouteSpec = new DeriveUpdatedRouteSpecification( cargo, ROTTERDAM ).getRouteSpec();
        cargo.routeSpecification().set( newRouteSpec );

        assertRouteSpec( HONGKONG,  // Unchanged
                         ROTTERDAM, // New destination
                         DAY1,      // Completion time of last handling event
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

                                        ROUTED, directed, itinerary.eta(), leg1,
                                        nextHandlingEvent( LOAD, HONGKONG, DAY1, V201 ) ) );

        assertRouteSpec( HONGKONG, STOCKHOLM, TODAY, DAY24 );

        newRouteSpec = new DeriveUpdatedRouteSpecification( cargo ).getRouteSpec();
        cargo.routeSpecification().set( newRouteSpec );

        assertRouteSpec( HONGKONG,  // Unchanged
                         STOCKHOLM, // Unchanged
                         DAY1,      // Completion time of last handling event
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

        cargo.routeSpecification().set( routeSpec );
        cargo.delivery().set( delivery( TODAY, NOT_RECEIVED, ROUTED, unknownLeg ) );

        assertRouteSpec( HONGKONG, STOCKHOLM, TODAY, DAY24 );

        newRouteSpec = new DeriveUpdatedRouteSpecification( cargo ).getRouteSpec();
        cargo.routeSpecification().set( newRouteSpec );

        assertRouteSpec( HONGKONG,  // Unchanged
                         STOCKHOLM, // Unchanged
                         TODAY,     // Unchanged
View Full Code Here

Examples of org.qi4j.sample.dcicargo.sample_b.context.interaction.booking.specification.DeriveUpdatedRouteSpecification

                                        ROUTED, directed, itinerary.eta(), leg1,
                                        nextHandlingEvent( UNLOAD, CHICAGO, DAY5, V201 ) ) );

        assertRouteSpec( HONGKONG, STOCKHOLM, TODAY, DAY24 );

        newRouteSpec = new DeriveUpdatedRouteSpecification( cargo ).getRouteSpec();
        cargo.routeSpecification().set( newRouteSpec );

        assertRouteSpec( CHICAGO,   // Arrival location of current carrier movement
                         STOCKHOLM, // Unchanged
                         DAY5,      // Arrival time of current carrier movement
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.