Class ComputeRoutesResponse.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder>
com.google.maps.routing.v2.ComputeRoutesResponse.Builder
All Implemented Interfaces:
ComputeRoutesResponseOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
ComputeRoutesResponse

public static final class ComputeRoutesResponse.Builder extends com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder> implements ComputeRoutesResponseOrBuilder
 ComputeRoutes the response message.
 
Protobuf type google.maps.routing.v2.ComputeRoutesResponse
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder>
    • getDefaultInstanceForType

      public ComputeRoutesResponse getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public ComputeRoutesResponse build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public ComputeRoutesResponse buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public ComputeRoutesResponse.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<ComputeRoutesResponse.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<ComputeRoutesResponse.Builder>
    • mergeFrom

      public ComputeRoutesResponse.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<ComputeRoutesResponse.Builder>
      Throws:
      IOException
    • getRoutesList

      public List<Route> getRoutesList()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
      Specified by:
      getRoutesList in interface ComputeRoutesResponseOrBuilder
    • getRoutesCount

      public int getRoutesCount()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
      Specified by:
      getRoutesCount in interface ComputeRoutesResponseOrBuilder
    • getRoutes

      public Route getRoutes(int index)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
      Specified by:
      getRoutes in interface ComputeRoutesResponseOrBuilder
    • setRoutes

      public ComputeRoutesResponse.Builder setRoutes(int index, Route value)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • setRoutes

      public ComputeRoutesResponse.Builder setRoutes(int index, Route.Builder builderForValue)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addRoutes

      public ComputeRoutesResponse.Builder addRoutes(Route value)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addRoutes

      public ComputeRoutesResponse.Builder addRoutes(int index, Route value)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addRoutes

      public ComputeRoutesResponse.Builder addRoutes(Route.Builder builderForValue)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addRoutes

      public ComputeRoutesResponse.Builder addRoutes(int index, Route.Builder builderForValue)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addAllRoutes

      public ComputeRoutesResponse.Builder addAllRoutes(Iterable<? extends Route> values)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • clearRoutes

      public ComputeRoutesResponse.Builder clearRoutes()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • removeRoutes

      public ComputeRoutesResponse.Builder removeRoutes(int index)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • getRoutesBuilder

      public Route.Builder getRoutesBuilder(int index)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • getRoutesOrBuilder

      public RouteOrBuilder getRoutesOrBuilder(int index)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
      Specified by:
      getRoutesOrBuilder in interface ComputeRoutesResponseOrBuilder
    • getRoutesOrBuilderList

      public List<? extends RouteOrBuilder> getRoutesOrBuilderList()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
      Specified by:
      getRoutesOrBuilderList in interface ComputeRoutesResponseOrBuilder
    • addRoutesBuilder

      public Route.Builder addRoutesBuilder()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • addRoutesBuilder

      public Route.Builder addRoutesBuilder(int index)
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • getRoutesBuilderList

      public List<Route.Builder> getRoutesBuilderList()
       Contains an array of computed routes (up to three) when you specify
       `compute_alternatives_routes`, and contains just one route when you don't.
       When this array contains multiple entries, the first one is the most
       recommended route. If the array is empty, then it means no route could be
       found.
       
      repeated .google.maps.routing.v2.Route routes = 1;
    • hasFallbackInfo

      public boolean hasFallbackInfo()
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
      Specified by:
      hasFallbackInfo in interface ComputeRoutesResponseOrBuilder
      Returns:
      Whether the fallbackInfo field is set.
    • getFallbackInfo

      public FallbackInfo getFallbackInfo()
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
      Specified by:
      getFallbackInfo in interface ComputeRoutesResponseOrBuilder
      Returns:
      The fallbackInfo.
    • setFallbackInfo

      public ComputeRoutesResponse.Builder setFallbackInfo(FallbackInfo value)
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
    • setFallbackInfo

      public ComputeRoutesResponse.Builder setFallbackInfo(FallbackInfo.Builder builderForValue)
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
    • mergeFallbackInfo

      public ComputeRoutesResponse.Builder mergeFallbackInfo(FallbackInfo value)
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
    • clearFallbackInfo

      public ComputeRoutesResponse.Builder clearFallbackInfo()
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
    • getFallbackInfoBuilder

      public FallbackInfo.Builder getFallbackInfoBuilder()
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
    • getFallbackInfoOrBuilder

      public FallbackInfoOrBuilder getFallbackInfoOrBuilder()
       In some cases when the server is not able to compute the route results with
       all of the input preferences, it may fallback to using a different way of
       computation. When fallback mode is used, this field contains detailed info
       about the fallback response. Otherwise this field is unset.
       
      .google.maps.routing.v2.FallbackInfo fallback_info = 2;
      Specified by:
      getFallbackInfoOrBuilder in interface ComputeRoutesResponseOrBuilder
    • hasGeocodingResults

      public boolean hasGeocodingResults()
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
      Specified by:
      hasGeocodingResults in interface ComputeRoutesResponseOrBuilder
      Returns:
      Whether the geocodingResults field is set.
    • getGeocodingResults

      public GeocodingResults getGeocodingResults()
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
      Specified by:
      getGeocodingResults in interface ComputeRoutesResponseOrBuilder
      Returns:
      The geocodingResults.
    • setGeocodingResults

      public ComputeRoutesResponse.Builder setGeocodingResults(GeocodingResults value)
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
    • setGeocodingResults

      public ComputeRoutesResponse.Builder setGeocodingResults(GeocodingResults.Builder builderForValue)
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
    • mergeGeocodingResults

      public ComputeRoutesResponse.Builder mergeGeocodingResults(GeocodingResults value)
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
    • clearGeocodingResults

      public ComputeRoutesResponse.Builder clearGeocodingResults()
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
    • getGeocodingResultsBuilder

      public GeocodingResults.Builder getGeocodingResultsBuilder()
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
    • getGeocodingResultsOrBuilder

      public GeocodingResultsOrBuilder getGeocodingResultsOrBuilder()
       Contains geocoding response info for waypoints specified as addresses.
       
      .google.maps.routing.v2.GeocodingResults geocoding_results = 3;
      Specified by:
      getGeocodingResultsOrBuilder in interface ComputeRoutesResponseOrBuilder