İngilizce dilinde oku

Aracılığıyla paylaş


RouteLegSummary Class

  • java.lang.Object
    • com.azure.maps.route.models.RouteLegSummary

Implements

public final class RouteLegSummary
implements JsonSerializable<RouteLegSummary>

Summary object for route section.

Constructor Summary

Constructor Description
RouteLegSummary()

Creates an instance of RouteLegSummary class.

Method Summary

Modifier and Type Method and Description
static RouteLegSummary fromJson(JsonReader jsonReader)

Reads an instance of RouteLegSummary from the JsonReader.

OffsetDateTime getArrivalTime()

Get the arrivalTime property: The estimated arrival time for the route or leg.

Double getBatteryConsumptionInKwH()

Get the batteryConsumptionInKwH property: Estimated electric energy consumption in kilowatt hours (kWh) using the Electric Consumption Model.

OffsetDateTime getDepartureTime()

Get the departureTime property: The estimated departure time for the route or leg.

Double getFuelConsumptionInLiters()

Get the fuelConsumptionInLiters property: Estimated fuel consumption in liters using the Combustion Consumption Model.

Integer getHistoricTrafficTravelTimeInSeconds()

Get the historicTrafficTravelTimeInSeconds property: Estimated travel time calculated using time-dependent historic traffic data.

Integer getLengthInMeters()

Get the lengthInMeters property: Length In Meters property.

Integer getLiveTrafficIncidentsTravelTimeInSeconds()

Get the liveTrafficIncidentsTravelTimeInSeconds property: Estimated travel time calculated using real-time speed data.

Integer getNoTrafficTravelTimeInSeconds()

Get the noTrafficTravelTimeInSeconds property: Estimated travel time calculated as if there are no delays on the route due to traffic conditions (e.g.

Integer getTrafficDelayInSeconds()

Get the trafficDelayInSeconds property: Estimated delay in seconds caused by the real-time incident(s) according to traffic information.

Integer getTravelTimeInSeconds()

Get the travelTimeInSeconds property: Estimated travel time in seconds property that includes the delay due to real-time traffic.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Constructor Details

RouteLegSummary

public RouteLegSummary()

Creates an instance of RouteLegSummary class.

Method Details

fromJson

public static RouteLegSummary fromJson(JsonReader jsonReader)

Reads an instance of RouteLegSummary from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of RouteLegSummary if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the RouteLegSummary.

getArrivalTime

public OffsetDateTime getArrivalTime()

Get the arrivalTime property: The estimated arrival time for the route or leg. Time is in UTC.

Returns:

the arrivalTime value.

getBatteryConsumptionInKwH

public Double getBatteryConsumptionInKwH()

Get the batteryConsumptionInKwH property: Estimated electric energy consumption in kilowatt hours (kWh) using the Electric Consumption Model. Included if vehicleEngineType is set to electric and constantSpeedConsumptionInkWhPerHundredkm is specified. The value of batteryConsumptionInkWh includes the recuperated electric energy and can therefore be negative (which indicates gaining energy). If both maxChargeInkWh and currentChargeInkWh are specified, recuperation will be capped to ensure that the battery charge level never exceeds maxChargeInkWh. If neither maxChargeInkWh nor currentChargeInkWh are specified, unconstrained recuperation is assumed in the consumption calculation.

Returns:

the batteryConsumptionInKwH value.

getDepartureTime

public OffsetDateTime getDepartureTime()

Get the departureTime property: The estimated departure time for the route or leg. Time is in UTC.

Returns:

the departureTime value.

getFuelConsumptionInLiters

public Double getFuelConsumptionInLiters()

Get the fuelConsumptionInLiters property: Estimated fuel consumption in liters using the Combustion Consumption Model. Included if vehicleEngineType is set to _combustion_ and constantSpeedConsumptionInLitersPerHundredkm is specified. The value will be non-negative.

Returns:

the fuelConsumptionInLiters value.

getHistoricTrafficTravelTimeInSeconds

public Integer getHistoricTrafficTravelTimeInSeconds()

Get the historicTrafficTravelTimeInSeconds property: Estimated travel time calculated using time-dependent historic traffic data. Included only if computeTravelTimeFor = all is used in the query.

Returns:

the historicTrafficTravelTimeInSeconds value.

getLengthInMeters

public Integer getLengthInMeters()

Get the lengthInMeters property: Length In Meters property.

Returns:

the lengthInMeters value.

getLiveTrafficIncidentsTravelTimeInSeconds

public Integer getLiveTrafficIncidentsTravelTimeInSeconds()

Get the liveTrafficIncidentsTravelTimeInSeconds property: Estimated travel time calculated using real-time speed data. Included only if computeTravelTimeFor = all is used in the query.

Returns:

the liveTrafficIncidentsTravelTimeInSeconds value.

getNoTrafficTravelTimeInSeconds

public Integer getNoTrafficTravelTimeInSeconds()

Get the noTrafficTravelTimeInSeconds property: Estimated travel time calculated as if there are no delays on the route due to traffic conditions (e.g. congestion). Included only if computeTravelTimeFor = all is used in the query.

Returns:

the noTrafficTravelTimeInSeconds value.

getTrafficDelayInSeconds

public Integer getTrafficDelayInSeconds()

Get the trafficDelayInSeconds property: Estimated delay in seconds caused by the real-time incident(s) according to traffic information. For routes planned with departure time in the future, delays is always 0. To return additional travel times using different types of traffic information, parameter computeTravelTimeFor=all needs to be added.

Returns:

the trafficDelayInSeconds value.

getTravelTimeInSeconds

public Integer getTravelTimeInSeconds()

Get the travelTimeInSeconds property: Estimated travel time in seconds property that includes the delay due to real-time traffic. Note that even when traffic=false travelTimeInSeconds still includes the delay due to traffic. If DepartAt is in the future, travel time is calculated using time-dependent historic traffic data.

Returns:

the travelTimeInSeconds value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to

Azure SDK for Java

Preview