public abstract class LegAnnotation extends DirectionsJsonObject
| Modifier and Type | Class and Description |
|---|---|
static class |
LegAnnotation.Builder
This builder can be used to set the values describing the
LegAnnotation. |
| Constructor and Description |
|---|
LegAnnotation() |
| Modifier and Type | Method and Description |
|---|---|
static LegAnnotation.Builder |
builder()
Create a new instance of this class by using the
LegAnnotation.Builder class. |
abstract java.util.List<java.lang.String> |
congestion()
The congestion between each pair of coordinates.
|
abstract java.util.List<java.lang.Integer> |
congestionNumeric()
The congestion between each pair of coordinates.
|
abstract java.util.List<java.lang.Integer> |
currentSpeed()
The speed may be either a positive integer in kilometers per hour
or `null` where attribution is missing.
|
abstract java.util.List<java.lang.Double> |
distance()
The distance, in meters, between each pair of coordinates.
|
abstract java.util.List<java.lang.Double> |
duration()
The speed, in meters per second, between each pair of coordinates.
|
abstract java.util.List<java.lang.Integer> |
freeflowSpeed()
The speed may be either a positive integer in kilometers per hour
or `null` where attribution is missing.
|
static LegAnnotation |
fromJson(java.lang.String json)
Create a new instance of this class by passing in a formatted valid JSON String.
|
abstract java.util.List<MaxSpeed> |
maxspeed()
The posted speed limit, between each pair of coordinates.
|
abstract java.util.List<java.lang.Double> |
speed()
The speed, in meters per second, between each pair of coordinates.
|
abstract LegAnnotation.Builder |
toBuilder()
Convert the current
LegAnnotation to its builder holding the currently assigned
values. |
abstract java.util.List<java.lang.Integer> |
trafficTendency() |
static com.google.gson.TypeAdapter<LegAnnotation> |
typeAdapter(com.google.gson.Gson gson)
Gson type adapter for parsing Gson to this class.
|
getUnrecognizedJsonProperties, getUnrecognizedPropertiesNames, getUnrecognizedProperty, toJsonpublic static LegAnnotation.Builder builder()
LegAnnotation.Builder class.LegAnnotation.Builder for creating a new instance@Nullable public abstract java.util.List<java.lang.Double> distance()
@Nullable public abstract java.util.List<java.lang.Double> duration()
@Nullable public abstract java.util.List<java.lang.Double> speed()
@Nullable public abstract java.util.List<MaxSpeed> maxspeed()
MaxSpeed value between two of
the routeLeg geometry coordinates@Nullable public abstract java.util.List<java.lang.String> congestion()
@Nullable @SerializedName(value="congestion_numeric") public abstract java.util.List<java.lang.Integer> congestionNumeric()
@Nullable @SerializedName(value="traffic_tendency") public abstract java.util.List<java.lang.Integer> trafficTendency()
@Nullable @SerializedName(value="freeflow_speed") public abstract java.util.List<java.lang.Integer> freeflowSpeed()
@Nullable @SerializedName(value="current_speed") public abstract java.util.List<java.lang.Integer> currentSpeed()
public abstract LegAnnotation.Builder toBuilder()
LegAnnotation to its builder holding the currently assigned
values. This allows you to modify a single property and then rebuild the object resulting in
an updated and modified LegAnnotation.LegAnnotation.Builder with the same values set to match the ones defined
in this LegAnnotationpublic static com.google.gson.TypeAdapter<LegAnnotation> typeAdapter(com.google.gson.Gson gson)
gson - the built Gson objectpublic static LegAnnotation fromJson(java.lang.String json)
json - a formatted valid JSON string defining a LegAnnotation