Interface RouteOrBuilder

All Superinterfaces:
com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder
All Known Implementing Classes:
Route, Route.Builder

@Generated public interface RouteOrBuilder extends com.google.protobuf.MessageOrBuilder
  • Method Summary

    Modifier and Type
    Method
    Description
    A description of the route.
    com.google.protobuf.ByteString
    A description of the route.
    int
    The travel distance of the route, in meters.
    com.google.protobuf.Duration
    The length of time needed to navigate the route.
    com.google.protobuf.DurationOrBuilder
    The length of time needed to navigate the route.
    getLegs(int index)
    A collection of legs (path segments between waypoints) that make up the route.
    int
    A collection of legs (path segments between waypoints) that make up the route.
    A collection of legs (path segments between waypoints) that make up the route.
    getLegsOrBuilder(int index)
    A collection of legs (path segments between waypoints) that make up the route.
    A collection of legs (path segments between waypoints) that make up the route.
    Text representations of properties of the `Route`.
    Text representations of properties of the `Route`.
    int
    If you set [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order] to true, this field contains the optimized ordering of intermediate waypoints.
    int
    If you set [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order] to true, this field contains the optimized ordering of intermediate waypoints.
    If you set [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order] to true, this field contains the optimized ordering of intermediate waypoints.
    The overall route polyline.
    Contains information about details along the polyline.
    Contains information about details along the polyline.
    The overall route polyline.
    getRouteLabels(int index)
    Labels for the `Route` that are useful to identify specific properties of the route to compare against others.
    int
    Labels for the `Route` that are useful to identify specific properties of the route to compare against others.
    Labels for the `Route` that are useful to identify specific properties of the route to compare against others.
    int
    Labels for the `Route` that are useful to identify specific properties of the route to compare against others.
    Labels for the `Route` that are useful to identify specific properties of the route to compare against others.
    An opaque token that can be passed to [Navigation SDK](https://developers.google.com/maps/documentation/mobility/driver-sdk/navigation) to reconstruct the route during navigation, and, in the event of rerouting, honor the original intention when the route was created.
    com.google.protobuf.ByteString
    An opaque token that can be passed to [Navigation SDK](https://developers.google.com/maps/documentation/mobility/driver-sdk/navigation) to reconstruct the route during navigation, and, in the event of rerouting, honor the original intention when the route was created.
    com.google.protobuf.Duration
    The duration of travel through the route without taking traffic conditions into consideration.
    com.google.protobuf.DurationOrBuilder
    The duration of travel through the route without taking traffic conditions into consideration.
    Additional information about the route.
    Additional information about the route.
    The viewport bounding box of the polyline.
    The viewport bounding box of the polyline.
    getWarnings(int index)
    An array of warnings to show when displaying the route.
    com.google.protobuf.ByteString
    getWarningsBytes(int index)
    An array of warnings to show when displaying the route.
    int
    An array of warnings to show when displaying the route.
    An array of warnings to show when displaying the route.
    boolean
    The length of time needed to navigate the route.
    boolean
    Text representations of properties of the `Route`.
    boolean
    The overall route polyline.
    boolean
    Contains information about details along the polyline.
    boolean
    The duration of travel through the route without taking traffic conditions into consideration.
    boolean
    Additional information about the route.
    boolean
    The viewport bounding box of the polyline.

    Methods inherited from interface com.google.protobuf.MessageLiteOrBuilder

    isInitialized

    Methods inherited from interface com.google.protobuf.MessageOrBuilder

    findInitializationErrors, getAllFields, getDefaultInstanceForType, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
  • Method Details

    • getRouteLabelsList

      List<RouteLabel> getRouteLabelsList()
       Labels for the `Route` that are useful to identify specific properties
       of the route to compare against others.
       
      repeated .google.maps.routing.v2.RouteLabel route_labels = 13;
      Returns:
      A list containing the routeLabels.
    • getRouteLabelsCount

      int getRouteLabelsCount()
       Labels for the `Route` that are useful to identify specific properties
       of the route to compare against others.
       
      repeated .google.maps.routing.v2.RouteLabel route_labels = 13;
      Returns:
      The count of routeLabels.
    • getRouteLabels

      RouteLabel getRouteLabels(int index)
       Labels for the `Route` that are useful to identify specific properties
       of the route to compare against others.
       
      repeated .google.maps.routing.v2.RouteLabel route_labels = 13;
      Parameters:
      index - The index of the element to return.
      Returns:
      The routeLabels at the given index.
    • getRouteLabelsValueList

      List<Integer> getRouteLabelsValueList()
       Labels for the `Route` that are useful to identify specific properties
       of the route to compare against others.
       
      repeated .google.maps.routing.v2.RouteLabel route_labels = 13;
      Returns:
      A list containing the enum numeric values on the wire for routeLabels.
    • getRouteLabelsValue

      int getRouteLabelsValue(int index)
       Labels for the `Route` that are useful to identify specific properties
       of the route to compare against others.
       
      repeated .google.maps.routing.v2.RouteLabel route_labels = 13;
      Parameters:
      index - The index of the value to return.
      Returns:
      The enum numeric value on the wire of routeLabels at the given index.
    • getLegsList

      List<RouteLeg> getLegsList()
       A collection of legs (path segments between waypoints) that make up the
       route. Each leg corresponds to the trip between two non-`via`
       [`Waypoints`][google.maps.routing.v2.Waypoint]. For example, a route with
       no intermediate waypoints has only one leg. A route that includes one
       non-`via` intermediate waypoint has two legs. A route that includes one
       `via` intermediate waypoint has one leg. The order of the legs matches the
       order of waypoints from `origin` to `intermediates` to `destination`.
       
      repeated .google.maps.routing.v2.RouteLeg legs = 1;
    • getLegs

      RouteLeg getLegs(int index)
       A collection of legs (path segments between waypoints) that make up the
       route. Each leg corresponds to the trip between two non-`via`
       [`Waypoints`][google.maps.routing.v2.Waypoint]. For example, a route with
       no intermediate waypoints has only one leg. A route that includes one
       non-`via` intermediate waypoint has two legs. A route that includes one
       `via` intermediate waypoint has one leg. The order of the legs matches the
       order of waypoints from `origin` to `intermediates` to `destination`.
       
      repeated .google.maps.routing.v2.RouteLeg legs = 1;
    • getLegsCount

      int getLegsCount()
       A collection of legs (path segments between waypoints) that make up the
       route. Each leg corresponds to the trip between two non-`via`
       [`Waypoints`][google.maps.routing.v2.Waypoint]. For example, a route with
       no intermediate waypoints has only one leg. A route that includes one
       non-`via` intermediate waypoint has two legs. A route that includes one
       `via` intermediate waypoint has one leg. The order of the legs matches the
       order of waypoints from `origin` to `intermediates` to `destination`.
       
      repeated .google.maps.routing.v2.RouteLeg legs = 1;
    • getLegsOrBuilderList

      List<? extends RouteLegOrBuilder> getLegsOrBuilderList()
       A collection of legs (path segments between waypoints) that make up the
       route. Each leg corresponds to the trip between two non-`via`
       [`Waypoints`][google.maps.routing.v2.Waypoint]. For example, a route with
       no intermediate waypoints has only one leg. A route that includes one
       non-`via` intermediate waypoint has two legs. A route that includes one
       `via` intermediate waypoint has one leg. The order of the legs matches the
       order of waypoints from `origin` to `intermediates` to `destination`.
       
      repeated .google.maps.routing.v2.RouteLeg legs = 1;
    • getLegsOrBuilder

      RouteLegOrBuilder getLegsOrBuilder(int index)
       A collection of legs (path segments between waypoints) that make up the
       route. Each leg corresponds to the trip between two non-`via`
       [`Waypoints`][google.maps.routing.v2.Waypoint]. For example, a route with
       no intermediate waypoints has only one leg. A route that includes one
       non-`via` intermediate waypoint has two legs. A route that includes one
       `via` intermediate waypoint has one leg. The order of the legs matches the
       order of waypoints from `origin` to `intermediates` to `destination`.
       
      repeated .google.maps.routing.v2.RouteLeg legs = 1;
    • getDistanceMeters

      int getDistanceMeters()
       The travel distance of the route, in meters.
       
      int32 distance_meters = 2;
      Returns:
      The distanceMeters.
    • hasDuration

      boolean hasDuration()
       The length of time needed to navigate the route. If you set the
       `routing_preference` to `TRAFFIC_UNAWARE`, then this value is the same as
       `static_duration`. If you set the `routing_preference` to either
       `TRAFFIC_AWARE` or `TRAFFIC_AWARE_OPTIMAL`, then this value is calculated
       taking traffic conditions into account.
       
      .google.protobuf.Duration duration = 3;
      Returns:
      Whether the duration field is set.
    • getDuration

      com.google.protobuf.Duration getDuration()
       The length of time needed to navigate the route. If you set the
       `routing_preference` to `TRAFFIC_UNAWARE`, then this value is the same as
       `static_duration`. If you set the `routing_preference` to either
       `TRAFFIC_AWARE` or `TRAFFIC_AWARE_OPTIMAL`, then this value is calculated
       taking traffic conditions into account.
       
      .google.protobuf.Duration duration = 3;
      Returns:
      The duration.
    • getDurationOrBuilder

      com.google.protobuf.DurationOrBuilder getDurationOrBuilder()
       The length of time needed to navigate the route. If you set the
       `routing_preference` to `TRAFFIC_UNAWARE`, then this value is the same as
       `static_duration`. If you set the `routing_preference` to either
       `TRAFFIC_AWARE` or `TRAFFIC_AWARE_OPTIMAL`, then this value is calculated
       taking traffic conditions into account.
       
      .google.protobuf.Duration duration = 3;
    • hasStaticDuration

      boolean hasStaticDuration()
       The duration of travel through the route without taking traffic
       conditions into consideration.
       
      .google.protobuf.Duration static_duration = 4;
      Returns:
      Whether the staticDuration field is set.
    • getStaticDuration

      com.google.protobuf.Duration getStaticDuration()
       The duration of travel through the route without taking traffic
       conditions into consideration.
       
      .google.protobuf.Duration static_duration = 4;
      Returns:
      The staticDuration.
    • getStaticDurationOrBuilder

      com.google.protobuf.DurationOrBuilder getStaticDurationOrBuilder()
       The duration of travel through the route without taking traffic
       conditions into consideration.
       
      .google.protobuf.Duration static_duration = 4;
    • hasPolyline

      boolean hasPolyline()
       The overall route polyline. This polyline is the combined polyline of
       all `legs`.
       
      .google.maps.routing.v2.Polyline polyline = 5;
      Returns:
      Whether the polyline field is set.
    • getPolyline

      Polyline getPolyline()
       The overall route polyline. This polyline is the combined polyline of
       all `legs`.
       
      .google.maps.routing.v2.Polyline polyline = 5;
      Returns:
      The polyline.
    • getPolylineOrBuilder

      PolylineOrBuilder getPolylineOrBuilder()
       The overall route polyline. This polyline is the combined polyline of
       all `legs`.
       
      .google.maps.routing.v2.Polyline polyline = 5;
    • getDescription

      String getDescription()
       A description of the route.
       
      string description = 6;
      Returns:
      The description.
    • getDescriptionBytes

      com.google.protobuf.ByteString getDescriptionBytes()
       A description of the route.
       
      string description = 6;
      Returns:
      The bytes for description.
    • getWarningsList

      List<String> getWarningsList()
       An array of warnings to show when displaying the route.
       
      repeated string warnings = 7;
      Returns:
      A list containing the warnings.
    • getWarningsCount

      int getWarningsCount()
       An array of warnings to show when displaying the route.
       
      repeated string warnings = 7;
      Returns:
      The count of warnings.
    • getWarnings

      String getWarnings(int index)
       An array of warnings to show when displaying the route.
       
      repeated string warnings = 7;
      Parameters:
      index - The index of the element to return.
      Returns:
      The warnings at the given index.
    • getWarningsBytes

      com.google.protobuf.ByteString getWarningsBytes(int index)
       An array of warnings to show when displaying the route.
       
      repeated string warnings = 7;
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the warnings at the given index.
    • hasViewport

      boolean hasViewport()
       The viewport bounding box of the polyline.
       
      .google.geo.type.Viewport viewport = 8;
      Returns:
      Whether the viewport field is set.
    • getViewport

      Viewport getViewport()
       The viewport bounding box of the polyline.
       
      .google.geo.type.Viewport viewport = 8;
      Returns:
      The viewport.
    • getViewportOrBuilder

      ViewportOrBuilder getViewportOrBuilder()
       The viewport bounding box of the polyline.
       
      .google.geo.type.Viewport viewport = 8;
    • hasTravelAdvisory

      boolean hasTravelAdvisory()
       Additional information about the route.
       
      .google.maps.routing.v2.RouteTravelAdvisory travel_advisory = 9;
      Returns:
      Whether the travelAdvisory field is set.
    • getTravelAdvisory

      RouteTravelAdvisory getTravelAdvisory()
       Additional information about the route.
       
      .google.maps.routing.v2.RouteTravelAdvisory travel_advisory = 9;
      Returns:
      The travelAdvisory.
    • getTravelAdvisoryOrBuilder

      RouteTravelAdvisoryOrBuilder getTravelAdvisoryOrBuilder()
       Additional information about the route.
       
      .google.maps.routing.v2.RouteTravelAdvisory travel_advisory = 9;
    • getOptimizedIntermediateWaypointIndexList

      List<Integer> getOptimizedIntermediateWaypointIndexList()
       If you set
       [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order]
       to true, this field contains the optimized ordering of intermediate
       waypoints. Otherwise, this field is empty.
       For example, if you give an input of Origin: LA; Intermediate waypoints:
       Dallas, Bangor, Phoenix; Destination: New York; and the optimized
       intermediate waypoint order is Phoenix, Dallas, Bangor, then this field
       contains the values [2, 0, 1]. The index starts with 0 for the first
       intermediate waypoint provided in the input.
       
      repeated int32 optimized_intermediate_waypoint_index = 10;
      Returns:
      A list containing the optimizedIntermediateWaypointIndex.
    • getOptimizedIntermediateWaypointIndexCount

      int getOptimizedIntermediateWaypointIndexCount()
       If you set
       [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order]
       to true, this field contains the optimized ordering of intermediate
       waypoints. Otherwise, this field is empty.
       For example, if you give an input of Origin: LA; Intermediate waypoints:
       Dallas, Bangor, Phoenix; Destination: New York; and the optimized
       intermediate waypoint order is Phoenix, Dallas, Bangor, then this field
       contains the values [2, 0, 1]. The index starts with 0 for the first
       intermediate waypoint provided in the input.
       
      repeated int32 optimized_intermediate_waypoint_index = 10;
      Returns:
      The count of optimizedIntermediateWaypointIndex.
    • getOptimizedIntermediateWaypointIndex

      int getOptimizedIntermediateWaypointIndex(int index)
       If you set
       [`optimize_waypoint_order`][google.maps.routing.v2.ComputeRoutesRequest.optimize_waypoint_order]
       to true, this field contains the optimized ordering of intermediate
       waypoints. Otherwise, this field is empty.
       For example, if you give an input of Origin: LA; Intermediate waypoints:
       Dallas, Bangor, Phoenix; Destination: New York; and the optimized
       intermediate waypoint order is Phoenix, Dallas, Bangor, then this field
       contains the values [2, 0, 1]. The index starts with 0 for the first
       intermediate waypoint provided in the input.
       
      repeated int32 optimized_intermediate_waypoint_index = 10;
      Parameters:
      index - The index of the element to return.
      Returns:
      The optimizedIntermediateWaypointIndex at the given index.
    • hasLocalizedValues

      boolean hasLocalizedValues()
       Text representations of properties of the `Route`.
       
      .google.maps.routing.v2.Route.RouteLocalizedValues localized_values = 11;
      Returns:
      Whether the localizedValues field is set.
    • getLocalizedValues

      Route.RouteLocalizedValues getLocalizedValues()
       Text representations of properties of the `Route`.
       
      .google.maps.routing.v2.Route.RouteLocalizedValues localized_values = 11;
      Returns:
      The localizedValues.
    • getLocalizedValuesOrBuilder

      Route.RouteLocalizedValuesOrBuilder getLocalizedValuesOrBuilder()
       Text representations of properties of the `Route`.
       
      .google.maps.routing.v2.Route.RouteLocalizedValues localized_values = 11;
    • getRouteToken

      String getRouteToken()
       An opaque token that can be passed to [Navigation
       SDK](https://developers.google.com/maps/documentation/mobility/driver-sdk/navigation)
       to reconstruct the route during navigation, and, in the event of rerouting,
       honor the original intention when the route was created. Treat this token
       as an opaque blob.  Don't compare its value across requests as its value
       may change even if the service returns the exact same route.
      
       NOTE: `Route.route_token` is only available for requests that have set
       `ComputeRoutesRequest.routing_preference` to `TRAFFIC_AWARE` or
       `TRAFFIC_AWARE_OPTIMAL`. `Route.route_token` is not supported for requests
       that have Via waypoints.
       
      string route_token = 12;
      Returns:
      The routeToken.
    • getRouteTokenBytes

      com.google.protobuf.ByteString getRouteTokenBytes()
       An opaque token that can be passed to [Navigation
       SDK](https://developers.google.com/maps/documentation/mobility/driver-sdk/navigation)
       to reconstruct the route during navigation, and, in the event of rerouting,
       honor the original intention when the route was created. Treat this token
       as an opaque blob.  Don't compare its value across requests as its value
       may change even if the service returns the exact same route.
      
       NOTE: `Route.route_token` is only available for requests that have set
       `ComputeRoutesRequest.routing_preference` to `TRAFFIC_AWARE` or
       `TRAFFIC_AWARE_OPTIMAL`. `Route.route_token` is not supported for requests
       that have Via waypoints.
       
      string route_token = 12;
      Returns:
      The bytes for routeToken.
    • hasPolylineDetails

      boolean hasPolylineDetails()
       Contains information about details along the polyline.
       
      .google.maps.routing.v2.PolylineDetails polyline_details = 14;
      Returns:
      Whether the polylineDetails field is set.
    • getPolylineDetails

      PolylineDetails getPolylineDetails()
       Contains information about details along the polyline.
       
      .google.maps.routing.v2.PolylineDetails polyline_details = 14;
      Returns:
      The polylineDetails.
    • getPolylineDetailsOrBuilder

      PolylineDetailsOrBuilder getPolylineDetailsOrBuilder()
       Contains information about details along the polyline.
       
      .google.maps.routing.v2.PolylineDetails polyline_details = 14;