Class RouteLegStep.Builder

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

public static final class RouteLegStep.Builder extends com.google.protobuf.GeneratedMessage.Builder<RouteLegStep.Builder> implements RouteLegStepOrBuilder
 Contains a segment of a [`RouteLeg`][google.maps.routing.v2.RouteLeg]. A
 step corresponds to a single navigation instruction. Route legs are made up
 of steps.
 
Protobuf type google.maps.routing.v2.RouteLegStep
  • 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<RouteLegStep.Builder>
    • clear

      public RouteLegStep.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<RouteLegStep.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<RouteLegStep.Builder>
    • getDefaultInstanceForType

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

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

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

      public RouteLegStep.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<RouteLegStep.Builder>
    • mergeFrom

      public RouteLegStep.Builder mergeFrom(RouteLegStep other)
    • isInitialized

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

      public RouteLegStep.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<RouteLegStep.Builder>
      Throws:
      IOException
    • getDistanceMeters

      public int getDistanceMeters()
       The travel distance of this step, in meters. In some circumstances, this
       field might not have a value.
       
      int32 distance_meters = 1;
      Specified by:
      getDistanceMeters in interface RouteLegStepOrBuilder
      Returns:
      The distanceMeters.
    • setDistanceMeters

      public RouteLegStep.Builder setDistanceMeters(int value)
       The travel distance of this step, in meters. In some circumstances, this
       field might not have a value.
       
      int32 distance_meters = 1;
      Parameters:
      value - The distanceMeters to set.
      Returns:
      This builder for chaining.
    • clearDistanceMeters

      public RouteLegStep.Builder clearDistanceMeters()
       The travel distance of this step, in meters. In some circumstances, this
       field might not have a value.
       
      int32 distance_meters = 1;
      Returns:
      This builder for chaining.
    • hasStaticDuration

      public boolean hasStaticDuration()
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
      Specified by:
      hasStaticDuration in interface RouteLegStepOrBuilder
      Returns:
      Whether the staticDuration field is set.
    • getStaticDuration

      public com.google.protobuf.Duration getStaticDuration()
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
      Specified by:
      getStaticDuration in interface RouteLegStepOrBuilder
      Returns:
      The staticDuration.
    • setStaticDuration

      public RouteLegStep.Builder setStaticDuration(com.google.protobuf.Duration value)
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
    • setStaticDuration

      public RouteLegStep.Builder setStaticDuration(com.google.protobuf.Duration.Builder builderForValue)
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
    • mergeStaticDuration

      public RouteLegStep.Builder mergeStaticDuration(com.google.protobuf.Duration value)
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
    • clearStaticDuration

      public RouteLegStep.Builder clearStaticDuration()
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
    • getStaticDurationBuilder

      public com.google.protobuf.Duration.Builder getStaticDurationBuilder()
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
    • getStaticDurationOrBuilder

      public com.google.protobuf.DurationOrBuilder getStaticDurationOrBuilder()
       The duration of travel through this step without taking traffic conditions
       into consideration. In some circumstances, this field might not have a
       value.
       
      .google.protobuf.Duration static_duration = 2;
      Specified by:
      getStaticDurationOrBuilder in interface RouteLegStepOrBuilder
    • hasPolyline

      public boolean hasPolyline()
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
      Specified by:
      hasPolyline in interface RouteLegStepOrBuilder
      Returns:
      Whether the polyline field is set.
    • getPolyline

      public Polyline getPolyline()
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
      Specified by:
      getPolyline in interface RouteLegStepOrBuilder
      Returns:
      The polyline.
    • setPolyline

      public RouteLegStep.Builder setPolyline(Polyline value)
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
    • setPolyline

      public RouteLegStep.Builder setPolyline(Polyline.Builder builderForValue)
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
    • mergePolyline

      public RouteLegStep.Builder mergePolyline(Polyline value)
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
    • clearPolyline

      public RouteLegStep.Builder clearPolyline()
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
    • getPolylineBuilder

      public Polyline.Builder getPolylineBuilder()
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
    • getPolylineOrBuilder

      public PolylineOrBuilder getPolylineOrBuilder()
       The polyline associated with this step.
       
      .google.maps.routing.v2.Polyline polyline = 3;
      Specified by:
      getPolylineOrBuilder in interface RouteLegStepOrBuilder
    • hasStartLocation

      public boolean hasStartLocation()
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
      Specified by:
      hasStartLocation in interface RouteLegStepOrBuilder
      Returns:
      Whether the startLocation field is set.
    • getStartLocation

      public Location getStartLocation()
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
      Specified by:
      getStartLocation in interface RouteLegStepOrBuilder
      Returns:
      The startLocation.
    • setStartLocation

      public RouteLegStep.Builder setStartLocation(Location value)
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
    • setStartLocation

      public RouteLegStep.Builder setStartLocation(Location.Builder builderForValue)
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
    • mergeStartLocation

      public RouteLegStep.Builder mergeStartLocation(Location value)
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
    • clearStartLocation

      public RouteLegStep.Builder clearStartLocation()
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
    • getStartLocationBuilder

      public Location.Builder getStartLocationBuilder()
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
    • getStartLocationOrBuilder

      public LocationOrBuilder getStartLocationOrBuilder()
       The start location of this step.
       
      .google.maps.routing.v2.Location start_location = 4;
      Specified by:
      getStartLocationOrBuilder in interface RouteLegStepOrBuilder
    • hasEndLocation

      public boolean hasEndLocation()
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
      Specified by:
      hasEndLocation in interface RouteLegStepOrBuilder
      Returns:
      Whether the endLocation field is set.
    • getEndLocation

      public Location getEndLocation()
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
      Specified by:
      getEndLocation in interface RouteLegStepOrBuilder
      Returns:
      The endLocation.
    • setEndLocation

      public RouteLegStep.Builder setEndLocation(Location value)
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
    • setEndLocation

      public RouteLegStep.Builder setEndLocation(Location.Builder builderForValue)
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
    • mergeEndLocation

      public RouteLegStep.Builder mergeEndLocation(Location value)
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
    • clearEndLocation

      public RouteLegStep.Builder clearEndLocation()
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
    • getEndLocationBuilder

      public Location.Builder getEndLocationBuilder()
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
    • getEndLocationOrBuilder

      public LocationOrBuilder getEndLocationOrBuilder()
       The end location of this step.
       
      .google.maps.routing.v2.Location end_location = 5;
      Specified by:
      getEndLocationOrBuilder in interface RouteLegStepOrBuilder
    • hasNavigationInstruction

      public boolean hasNavigationInstruction()
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
      Specified by:
      hasNavigationInstruction in interface RouteLegStepOrBuilder
      Returns:
      Whether the navigationInstruction field is set.
    • getNavigationInstruction

      public NavigationInstruction getNavigationInstruction()
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
      Specified by:
      getNavigationInstruction in interface RouteLegStepOrBuilder
      Returns:
      The navigationInstruction.
    • setNavigationInstruction

      public RouteLegStep.Builder setNavigationInstruction(NavigationInstruction value)
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
    • setNavigationInstruction

      public RouteLegStep.Builder setNavigationInstruction(NavigationInstruction.Builder builderForValue)
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
    • mergeNavigationInstruction

      public RouteLegStep.Builder mergeNavigationInstruction(NavigationInstruction value)
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
    • clearNavigationInstruction

      public RouteLegStep.Builder clearNavigationInstruction()
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
    • getNavigationInstructionBuilder

      public NavigationInstruction.Builder getNavigationInstructionBuilder()
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
    • getNavigationInstructionOrBuilder

      public NavigationInstructionOrBuilder getNavigationInstructionOrBuilder()
       Navigation instructions.
       
      .google.maps.routing.v2.NavigationInstruction navigation_instruction = 6;
      Specified by:
      getNavigationInstructionOrBuilder in interface RouteLegStepOrBuilder
    • hasTravelAdvisory

      public boolean hasTravelAdvisory()
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
      Specified by:
      hasTravelAdvisory in interface RouteLegStepOrBuilder
      Returns:
      Whether the travelAdvisory field is set.
    • getTravelAdvisory

      public RouteLegStepTravelAdvisory getTravelAdvisory()
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
      Specified by:
      getTravelAdvisory in interface RouteLegStepOrBuilder
      Returns:
      The travelAdvisory.
    • setTravelAdvisory

      public RouteLegStep.Builder setTravelAdvisory(RouteLegStepTravelAdvisory value)
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
    • setTravelAdvisory

      public RouteLegStep.Builder setTravelAdvisory(RouteLegStepTravelAdvisory.Builder builderForValue)
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
    • mergeTravelAdvisory

      public RouteLegStep.Builder mergeTravelAdvisory(RouteLegStepTravelAdvisory value)
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
    • clearTravelAdvisory

      public RouteLegStep.Builder clearTravelAdvisory()
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
    • getTravelAdvisoryBuilder

      public RouteLegStepTravelAdvisory.Builder getTravelAdvisoryBuilder()
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
    • getTravelAdvisoryOrBuilder

      public RouteLegStepTravelAdvisoryOrBuilder getTravelAdvisoryOrBuilder()
       Contains the additional information that the user should be informed
       about, such as possible traffic zone restrictions, on a leg step.
       
      .google.maps.routing.v2.RouteLegStepTravelAdvisory travel_advisory = 7;
      Specified by:
      getTravelAdvisoryOrBuilder in interface RouteLegStepOrBuilder
    • hasLocalizedValues

      public boolean hasLocalizedValues()
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
      Specified by:
      hasLocalizedValues in interface RouteLegStepOrBuilder
      Returns:
      Whether the localizedValues field is set.
    • getLocalizedValues

      public RouteLegStep.RouteLegStepLocalizedValues getLocalizedValues()
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
      Specified by:
      getLocalizedValues in interface RouteLegStepOrBuilder
      Returns:
      The localizedValues.
    • setLocalizedValues

       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
    • setLocalizedValues

      public RouteLegStep.Builder setLocalizedValues(RouteLegStep.RouteLegStepLocalizedValues.Builder builderForValue)
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
    • mergeLocalizedValues

       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
    • clearLocalizedValues

      public RouteLegStep.Builder clearLocalizedValues()
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
    • getLocalizedValuesBuilder

      public RouteLegStep.RouteLegStepLocalizedValues.Builder getLocalizedValuesBuilder()
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
    • getLocalizedValuesOrBuilder

      public RouteLegStep.RouteLegStepLocalizedValuesOrBuilder getLocalizedValuesOrBuilder()
       Text representations of properties of the `RouteLegStep`.
       
      .google.maps.routing.v2.RouteLegStep.RouteLegStepLocalizedValues localized_values = 8;
      Specified by:
      getLocalizedValuesOrBuilder in interface RouteLegStepOrBuilder
    • hasTransitDetails

      public boolean hasTransitDetails()
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
      Specified by:
      hasTransitDetails in interface RouteLegStepOrBuilder
      Returns:
      Whether the transitDetails field is set.
    • getTransitDetails

      public RouteLegStepTransitDetails getTransitDetails()
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
      Specified by:
      getTransitDetails in interface RouteLegStepOrBuilder
      Returns:
      The transitDetails.
    • setTransitDetails

      public RouteLegStep.Builder setTransitDetails(RouteLegStepTransitDetails value)
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
    • setTransitDetails

      public RouteLegStep.Builder setTransitDetails(RouteLegStepTransitDetails.Builder builderForValue)
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
    • mergeTransitDetails

      public RouteLegStep.Builder mergeTransitDetails(RouteLegStepTransitDetails value)
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
    • clearTransitDetails

      public RouteLegStep.Builder clearTransitDetails()
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
    • getTransitDetailsBuilder

      public RouteLegStepTransitDetails.Builder getTransitDetailsBuilder()
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
    • getTransitDetailsOrBuilder

      public RouteLegStepTransitDetailsOrBuilder getTransitDetailsOrBuilder()
       Details pertaining to this step if the travel mode is `TRANSIT`.
       
      .google.maps.routing.v2.RouteLegStepTransitDetails transit_details = 9;
      Specified by:
      getTransitDetailsOrBuilder in interface RouteLegStepOrBuilder
    • getTravelModeValue

      public int getTravelModeValue()
       The travel mode used for this step.
       
      .google.maps.routing.v2.RouteTravelMode travel_mode = 10;
      Specified by:
      getTravelModeValue in interface RouteLegStepOrBuilder
      Returns:
      The enum numeric value on the wire for travelMode.
    • setTravelModeValue

      public RouteLegStep.Builder setTravelModeValue(int value)
       The travel mode used for this step.
       
      .google.maps.routing.v2.RouteTravelMode travel_mode = 10;
      Parameters:
      value - The enum numeric value on the wire for travelMode to set.
      Returns:
      This builder for chaining.
    • getTravelMode

      public RouteTravelMode getTravelMode()
       The travel mode used for this step.
       
      .google.maps.routing.v2.RouteTravelMode travel_mode = 10;
      Specified by:
      getTravelMode in interface RouteLegStepOrBuilder
      Returns:
      The travelMode.
    • setTravelMode

      public RouteLegStep.Builder setTravelMode(RouteTravelMode value)
       The travel mode used for this step.
       
      .google.maps.routing.v2.RouteTravelMode travel_mode = 10;
      Parameters:
      value - The travelMode to set.
      Returns:
      This builder for chaining.
    • clearTravelMode

      public RouteLegStep.Builder clearTravelMode()
       The travel mode used for this step.
       
      .google.maps.routing.v2.RouteTravelMode travel_mode = 10;
      Returns:
      This builder for chaining.