com.kuka.nav.fleet
Interface CoordinatedGraphMotionContainer

All Superinterfaces:
GraphMotionContainerBase

public interface CoordinatedGraphMotionContainer
extends GraphMotionContainerBase

Status container for a set of graph motions that have been commanded in a coordinate way.


Method Summary
 GraphMotionResult awaitFinalized()
          Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINALIZED or an interrupted exception occurs.
 GraphMotionResult awaitFinalized(long timeout, TimeUnit unit)
          Blocks the calling thread until this coordinated graph motion changes its state to GraphMotionState.FINALIZED, the given timeout has passed, or an interrupted exception occurs.
 void awaitFinished()
          Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINISHED or GraphMotionState.FINALIZED or an interrupted exception occurs.
 void awaitFinished(long timeout, TimeUnit unit)
          Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINISHED or GraphMotionState.FINALIZED, the given timeout has passed, or an interrupted exception occurs.
 void cancel()
          Cancels the execution of all associated fleet motions by calling the respective GraphMotionContainer.cancel() methods.
 GraphMotionContainer getContainer(GraphMotion graphMotion)
          Gets the graph motion container of the given graph motion.
 GraphMotionContainer getContainer(GraphMotionIdentifier graphMotionId)
          Gets the graph motion container of the given graph motion identifier.
 Collection<GraphMotionContainer> getContainers()
          Gets the GraphMotionContainers for all graph motions that are part of this coordinated graph motion container.
 
Methods inherited from interface com.kuka.nav.fleet.GraphMotionContainerBase
getPathLengthToGoal, getResult, getState, getTimeInActive, getTimeInActivePercent, getTimeToGoal, getTravelledDistance, getTravelledDistancePercent, replan
 

Method Detail

getContainer

GraphMotionContainer getContainer(GraphMotion graphMotion)
Gets the graph motion container of the given graph motion.

Note that if coordinated planning failed this coordinated container does not contain containers for the individual GraphMotions. Therefore calling this method will fail. Coordinated planning failed if the state, which can be retrieved by GraphMotionContainerBase.getState(), of this container is NavExecutionState.FINALIZED an the result, which can be retrieved by GraphMotionContainerBase.getResult(), has an error. If the result has an error can be checked by NavExecutionResult.hasError().

Calling this method is equal to calling getContainer(graphMotion.getIdentifier()).

Parameters:
graphMotion - the graph motion for which the container should be retrieved
Returns:
the graph motion container
Throws:
IllegalArgumentException - if the provided GraphMotion is not part of this coordinated container, e.g. this is the case when coordinated planning failed
See Also:
getContainer(GraphMotionIdentifier)

getContainer

GraphMotionContainer getContainer(GraphMotionIdentifier graphMotionId)
Gets the graph motion container of the given graph motion identifier.

Note that if coordinated planning failed this coordinated container does not contain containers for the individual GraphMotions. Therefore calling this method will fail. Coordinated planning failed if the state, which can be retrieved by GraphMotionContainerBase.getState(), of this container is NavExecutionState.FINALIZED an the result, which can be retrieved by GraphMotionContainerBase.getResult(), has an error. If the result has an error can be checked by NavExecutionResult.hasError().

Parameters:
graphMotionId - the graph motion identifier for which the container should be retrieved
Returns:
the graph motion container
Throws:
IllegalArgumentException - if the provided identifier is not part of this coordinated container, e.g. this is the case when coordinated planning failed
See Also:
getContainer(GraphMotion), GraphMotion.getIdentifier()

getContainers

Collection<GraphMotionContainer> getContainers()
Gets the GraphMotionContainers for all graph motions that are part of this coordinated graph motion container.

Returns:
a collection of the graph motion containers.

cancel

void cancel()
Cancels the execution of all associated fleet motions by calling the respective GraphMotionContainer.cancel() methods.


awaitFinished

void awaitFinished()
Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINISHED or GraphMotionState.FINALIZED or an interrupted exception occurs.

If the calling thread has paused (by calling FleetManager.plan(GraphMotion) or FleetManager.replan(GraphMotionContainer)) and not yet resumed the fleet manager an IllegalStateException will be thrown.


awaitFinished

void awaitFinished(long timeout,
                   TimeUnit unit)
                   throws TimeoutException
Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINISHED or GraphMotionState.FINALIZED, the given timeout has passed, or an interrupted exception occurs.

If the calling thread has paused (by calling FleetManager.plan(GraphMotion) or FleetManager.replan(GraphMotionContainer)) and not yet resumed the fleet manager an IllegalStateException will be thrown.

Parameters:
timeout - the timeout
unit - the time unit
Throws:
TimeoutException - if the coordinated graph motion container was not finished in time

awaitFinalized

GraphMotionResult awaitFinalized()
Blocks the calling thread until this coordinated graph motion container changes its state to GraphMotionState.FINALIZED or an interrupted exception occurs.

If the calling thread has paused (by calling FleetManager.plan(GraphMotion) or FleetManager.replan(GraphMotionContainer)) and not yet resumed the fleet manager an IllegalStateException will be thrown.

Returns:
the graph motion result

awaitFinalized

GraphMotionResult awaitFinalized(long timeout,
                                 TimeUnit unit)
                                 throws TimeoutException
Blocks the calling thread until this coordinated graph motion changes its state to GraphMotionState.FINALIZED, the given timeout has passed, or an interrupted exception occurs.

If the calling thread has paused (by calling FleetManager.plan(GraphMotion) or FleetManager.replan(GraphMotionContainer)) and not yet resumed the fleet manager an IllegalStateException will be thrown.

Parameters:
timeout - the timeout
unit - the time unit
Returns:
the graph motion result
Throws:
TimeoutException - if the coordinated graph motion container was not finalized in time


Copyright © 2019. All rights reserved.