StepInfo

public class StepInfo extends Object

Information about a single step along a navigation route.

THIS API IS A BETA RELEASE.
IT IS SUBJECT TO CHANGE AND BACKWARDS COMPATIBILITY IS NOT GUARANTEED

Nested Class Summary

class StepInfo.Builder Builder for StepInfo. 

Public Method Summary

static StepInfo.Builder
builder()
Returns a builder for StepInfo.
Integer
getDistanceFromPrevStepMeters()
Returns the distance in meters from the previous step to this step.
int
getDrivingSide()
Returns whether this step is on a drive-on-right or drive-on-left route.
String
getExitNumber()
Returns the exit number if it exists.
String
getFullInstructionText()
Returns the full text of the instruction for this step.
String
getFullRoadName()
Returns the full road name for this step.
List<Lane>
getLanes()
Returns the list of available lanes at the end of this route step.
Bitmap
getLanesBitmap()
Returns a Bitmap that represents the lane guidance for this step.
int
getManeuver()
Returns the Maneuver for this step.
Bitmap
getManeuverBitmap()
Returns a Bitmap that represents the maneuver for this step.
Integer
getRoundaboutTurnNumber()
Returns the counted number of the exit to take relative to the location where the roundabout was entered.
String
getSimpleRoadName()
Returns the simplified version of the road name.
Integer
getStepNumber()
The index of the step in the list of all steps in the route.
Integer
getTimeFromPrevStepSeconds()
Returns time in seconds from the previous step to this step.
StepInfo.Builder

Inherited Method Summary

Public Methods

public static StepInfo.Builder builder ()

Returns a builder for StepInfo.

Returns
  • a builder for StepInfo.

public Integer getDistanceFromPrevStepMeters ()

Returns the distance in meters from the previous step to this step.

Returns
  • distance in meters from the previous step to this step.

public int getDrivingSide ()

Returns whether this step is on a drive-on-right or drive-on-left route. May be unspecified.

Returns
  • whether this step is on a drive-on-right or drive-on-left route.

public String getExitNumber ()

Returns the exit number if it exists.

Returns
  • the exit number if it exists and null if there is no exit number for the step.

public String getFullInstructionText ()

Returns the full text of the instruction for this step.

Examples (each line is a separate step):

Turn left onto Lean Ave

Use the right lane to take the CA-85 ramp to Mtn View

Use the 2nd from the right lane to take exit 9A toward North First Street

Returns
  • the full text of the instruction for this step.

public String getFullRoadName ()

Returns the full road name for this step. This contains all identifying information for the road including direction.

Examples (each line is a separate step):

Lean Ave

CA-85 / Mtn View

Exit 9A / North First Street

Returns
  • the full road name for the step.

public List<Lane> getLanes ()

Returns the list of available lanes at the end of this route step. List is null if Lane guidance is not available for this step.

public Bitmap getLanesBitmap ()

Returns a Bitmap that represents the lane guidance for this step. Result will be null if there is no lane guidance available for this step or the service is registered with a com.google.android.libraries.navigation.NavigationUpdatesOptions.GeneratedStepImagesType value of NONE.

public int getManeuver ()

Returns the Maneuver for this step.

Returns

public Bitmap getManeuverBitmap ()

Returns a Bitmap that represents the maneuver for this step. Result will be null if there is no maneuver available for this step or the service is registered with a com.google.android.libraries.navigation.NavigationUpdatesOptions.GeneratedStepImagesType value of NONE.

public Integer getRoundaboutTurnNumber ()

Returns the counted number of the exit to take relative to the location where the roundabout was entered. Only set for roundabouts, otherwise -1.

Returns
  • the counted number of the exit to take relative to where the roundabout was entered.

public String getSimpleRoadName ()

Returns the simplified version of the road name. This is shorter than the full road name and may not contain all pieces of identifying information about the road such as direction or name of exit.

Examples (each line is a separate step):

Lean Ave

CA-85

Exit 9A

Returns
  • the simplified road name for the step.

public Integer getStepNumber ()

The index of the step in the list of all steps in the route. The first step has step number 0. Negative step numbers should be considered invalid.

Returns
  • the index of the step in the list of all steps in the route.

public Integer getTimeFromPrevStepSeconds ()

Returns time in seconds from the previous step to this step.

Returns
  • time in seconds from the previous step to this step.

public StepInfo.Builder toBuilder ()