public abstract static class LegAnnotation.Builder
extends java.lang.Object
LegAnnotation.| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
abstract LegAnnotation |
build()
Build a new
LegAnnotation object. |
abstract LegAnnotation.Builder |
congestion(java.util.List<java.lang.String> congestion)
The congestion between each pair of coordinates.
|
abstract LegAnnotation.Builder |
congestionNumeric(java.util.List<java.lang.Integer> congestionNumeric)
The congestion between each pair of coordinates.
|
abstract LegAnnotation.Builder |
currentSpeed(java.util.List<java.lang.Integer> currentSpeed) |
abstract LegAnnotation.Builder |
distance(java.util.List<java.lang.Double> distance)
The distance, in meters, between each pair of coordinates.
|
abstract LegAnnotation.Builder |
duration(java.util.List<java.lang.Double> duration)
The speed, in meters per second, between each pair of coordinates.
|
abstract LegAnnotation.Builder |
freeflowSpeed(java.util.List<java.lang.Integer> freeflowSpeed) |
abstract LegAnnotation.Builder |
maxspeed(java.util.List<MaxSpeed> maxspeed)
The posted speed limit, between each pair of coordinates.
|
abstract LegAnnotation.Builder |
speed(java.util.List<java.lang.Double> speed)
The speed, in meters per second, between each pair of coordinates.
|
abstract LegAnnotation.Builder |
trafficTendency(java.util.List<java.lang.Integer> trafficTendency) |
T |
unrecognizedJsonProperties(java.util.Map<java.lang.String,com.google.gson.JsonElement> unrecognizedProperties)
Use this method to add parameters which are not present in the model yet but are supported
on the Directions API side in the response.
|
public abstract LegAnnotation.Builder distance(@Nullable java.util.List<java.lang.Double> distance)
distance - a list with each entry being a distance value between two of the routeLeg
geometry coordinatespublic abstract LegAnnotation.Builder duration(@Nullable java.util.List<java.lang.Double> duration)
duration - a list with each entry being a speed value between two of the routeLeg
geometry coordinatespublic abstract LegAnnotation.Builder speed(@Nullable java.util.List<java.lang.Double> speed)
speed - a list with each entry being a speed value between two of the routeLeg geometry
coordinatespublic abstract LegAnnotation.Builder maxspeed(@Nullable java.util.List<MaxSpeed> maxspeed)
maxspeed - list of speeds between each pair of coordinatespublic abstract LegAnnotation.Builder congestion(@Nullable java.util.List<java.lang.String> congestion)
congestion - a list of Strings with each entry being a congestion value between two of
the routeLeg geometry coordinatespublic abstract LegAnnotation.Builder congestionNumeric(@Nullable java.util.List<java.lang.Integer> congestionNumeric)
congestionNumeric - a list of Integers with each entry being a congestion value between
two of the routeLeg geometry coordinates@NonNull public abstract LegAnnotation.Builder trafficTendency(@Nullable java.util.List<java.lang.Integer> trafficTendency)
@NonNull public abstract LegAnnotation.Builder freeflowSpeed(@Nullable java.util.List<java.lang.Integer> freeflowSpeed)
freeflowSpeed - speed for each line segment along the route geometry.
The speed may be either a positive integer in kilometers per hour or
`null` where attribution is missing.@NonNull public abstract LegAnnotation.Builder currentSpeed(@Nullable java.util.List<java.lang.Integer> currentSpeed)
currentSpeed - The current speed for each line segment along the route geometry.
The speed may be either a positive integer in kilometers per hour
or `null` where attribution is missing.public abstract LegAnnotation build()
LegAnnotation object.LegAnnotation using the provided values in this builder@NonNull
public T unrecognizedJsonProperties(@Nullable
java.util.Map<java.lang.String,com.google.gson.JsonElement> unrecognizedProperties)
unrecognizedProperties - parameters to add to request