Package org.opentcs.data.order

# Class Route

java.lang.Object
org.opentcs.data.order.Route

All Implemented Interfaces:
  `java.io.Serializable`

    public class Route
    extends java.lang.Object
    implements java.io.Serializable

A route for a `Vehicle`, consisting of a sequence of steps (pairs of `Path`s and `Point`s) that need to be processed in their given order.

See Also:
  Serialized Form

- ## Nested Class Summary

  Nested Classes
  Modifier and Type | Class | Description
  --- | --- | ---
  `static class` | `Route.Step` | A single step in a route.

- ## Constructor Summary

  Constructors
  Constructor | Description
  --- | ---
  `Route​(java.util.List<Route.Step> routeSteps, long routeCosts)` | Creates a new Route.

- ## Method Summary

  Modifier and Type | Method | Description
  --- | --- | ---
  `boolean` | `equals​(java.lang.Object o)` |
  `long` | `getCosts()` | Returns the costs for travelling this route.
  `Point` | `getFinalDestinationPoint()` | Returns the final destination point that is reached by travelling this route.
  `java.util.List<Route.Step>` | `getSteps()` | Returns the sequence of steps this route consists of.
  `int` | `hashCode()` |
  `java.lang.String` | `toString()` |

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- ## Constructor Details

  - ### Route

    public Route​(@Nonnull java.util.List<Route.Step> routeSteps, long routeCosts)
    Creates a new Route.
    Parameters:
      `routeSteps` - The sequence of steps this route consists of.
      `routeCosts` - The costs for travelling this route.

- ## Method Details

  - ### getSteps

    @Nonnull public java.util.List<Route.Step> getSteps()
    Returns the sequence of steps this route consists of.
    Returns:
      The sequence of steps this route consists of. May be empty. The returned `List` is unmodifiable.

  - ### getCosts

    public long getCosts()
    Returns the costs for travelling this route.
    Returns:
      The costs for travelling this route.

  - ### getFinalDestinationPoint

    @Nonnull public Point getFinalDestinationPoint()
    Returns the final destination point that is reached by travelling this route. (I.e. returns the destination point of this route's last step.)
    Returns:
      The final destination point that is reached by travelling this route.

  - ### equals

    public boolean equals​(java.lang.Object o)
    Overrides:
      `equals` in class `java.lang.Object`

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `java.lang.Object`

  - ### toString

    public java.lang.String toString()
    Overrides:
      `toString` in class `java.lang.Object`