sdk-routing / com.tomtom.online.sdk.data.reachablerange / ReachableRangeQueryBuilder

ReachableRangeQueryBuilder

@DeprecatedSince("2020.06", "com.tomtom.online.sdk.routing.reachablerange.ReachableRangeSpecification.Builder") class ReachableRangeQueryBuilder : IReachableRangeQuery
Deprecated: Replaced by the ReachableRangeSpecification

The default builder for {@link ReachableRangeQuery} objects.

Constructors

<init>

ReachableRangeQueryBuilder(origin: LatLng)

The default builder for {@link ReachableRangeQuery} objects.

Properties

accelerationEfficiency

var accelerationEfficiency: Double?

adrTunnelRestrictionCode

var adrTunnelRestrictionCode: AdrTunnelRestrictionCode?

auxiliaryPowerInKW

var auxiliaryPowerInKW: Double?

auxiliaryPowerInLitersPerHour

var auxiliaryPowerInLitersPerHour: Double?

avoidList

var avoidList: List<Avoid>?

avoidType

var avoidType: Avoid?

considerTraffic

var considerTraffic: Boolean?

constantSpeedConsumptionInKWhPerHundredKm

var constantSpeedConsumptionInKWhPerHundredKm: SpeedToConsumptionMap?

constantSpeedConsumptionInLitersPerHundredKm

var constantSpeedConsumptionInLitersPerHundredKm: SpeedToConsumptionMap?

currentChargeInKWh

var currentChargeInKWh: Double?

currentFuelInLiters

var currentFuelInLiters: Double?

decelerationEfficiency

var decelerationEfficiency: Double?

departAt

var departAt: Date?

distanceBudgetInMeters

var distanceBudgetInMeters: Double?

downhillEfficiency

var downhillEfficiency: Double?

energyBudgetInKWh

var energyBudgetInKWh: Double?

fuelBudgetInLiters

var fuelBudgetInLiters: Double?

fuelEnergyDensityInMJoulesPerLiter

var fuelEnergyDensityInMJoulesPerLiter: Double?

hilliness

var hilliness: Hilliness?

maxChargeInKWh

var maxChargeInKWh: Double?

origin

var origin: LatLng

routeType

var routeType: RouteType?

timeBudgetInSeconds

var timeBudgetInSeconds: Double?

travelMode

var travelMode: TravelMode?

uphillEfficiency

var uphillEfficiency: Double?

vehicleAxleWeightInKg

var vehicleAxleWeightInKg: Int?

vehicleCommercial

var vehicleCommercial: Boolean?

vehicleEngineType

var vehicleEngineType: VehicleEngineType?

vehicleHeightInMeters

var vehicleHeightInMeters: Double?

vehicleLengthInMeters

var vehicleLengthInMeters: Double?

vehicleLoadType

var vehicleLoadType: VehicleLoadType?

vehicleMaxSpeedInKph

var vehicleMaxSpeedInKph: Int?

vehicleWeightInKg

var vehicleWeightInKg: Int?

vehicleWidthInMeters

var vehicleWidthInMeters: Double?

windingness

var windingness: Windingness?

Functions

build

fun build(): ReachableRangeQuery

Creates a new instance of ReachableRangeQuery.

withAccelerationEfficiency

fun withAccelerationEfficiency(accelerationEfficiency: Double): ReachableRangeQueryBuilder

Specifies the efficiency of converting chemical energy stored in fuel to kinetic energy when the vehicle accelerates (i.e., KineticEnergyGained/ChemicalEnergyConsumed). ChemicalEnergyConsumed is obtained by converting consumed fuel to chemical energy using fuelEnergyDensityInMJoulesPerLiter.

withAdrTunnelRestrictionCode

fun withAdrTunnelRestrictionCode(adrTunnelRestrictionCode: AdrTunnelRestrictionCode): ReachableRangeQueryBuilder

If vehicleAdrTunnelRestrictionCode is specified, the vehicle is subject to ADR tunnel restrictions.

withAuxiliaryPowerInKW

fun withAuxiliaryPowerInKW(auxiliaryPowerInKW: Double): ReachableRangeQueryBuilder

Specifies the amount of power consumed for sustaining auxiliary systems, in kilowatts (kW). It can be used to specify consumption due to devices and systems such as AC systems, radio, heating, etc. Applicable only for electric engines.

withAuxiliaryPowerInLitersPerHour

fun withAuxiliaryPowerInLitersPerHour(auxiliaryPowerInLitersPerHour: Double): ReachableRangeQueryBuilder

Specifies the amount of fuel consumed for sustaining auxiliary systems of the vehicle, in liters per hour. It can be used to specify consumption due to devices and systems such as AC systems, radio, heating, etc. Applicable only for combustion engines.

withAvoidList

fun withAvoidList(avoidList: List<Avoid>): ReachableRangeQueryBuilder

Specifies what the route calculation should try to avoid when determining the route.

withAvoidType

fun withAvoidType(avoidType: Avoid): ReachableRangeQueryBuilder

Specifies what the route calculation should try to avoid when determining the route.

withConsiderTraffic

fun withConsiderTraffic(considerTraffic: Boolean): ReachableRangeQueryBuilder

Specifies if all available traffic information should be considered during routing.

withConstantSpeedConsumptionInKWhPerHundredKm

fun withConstantSpeedConsumptionInKWhPerHundredKm(constantSpeedConsumptionInKWhPerHundredKm: SpeedToConsumptionMap): ReachableRangeQueryBuilder

Specifies the speed-dependent component of consumption. Provided as an unordered list of speed/consumption-rate in kWh pairs. Applicable only for electric engines.

withConstantSpeedConsumptionInLitersPerHundredKm

fun withConstantSpeedConsumptionInLitersPerHundredKm(constantSpeedConsumptionInLitersPerHundredKm: SpeedToConsumptionMap): ReachableRangeQueryBuilder

Specifies the speed-dependent component of consumption. Provided as an unordered list of speed/consumption-rate in liters-per-100km pairs. Applicable only for combustion engines.

withCurrentChargeInKWh

fun withCurrentChargeInKWh(currentChargeInKWh: Double): ReachableRangeQueryBuilder

Specifies the current electric energy supply in kilowatt hours (kWh). Applicable only for electric engines. If used at all, must be used in conjunction with .withMaxChargeInKWh.

withCurrentFuelInLiters

fun withCurrentFuelInLiters(currentFuelInLiters: Double): ReachableRangeQueryBuilder

Specifies the current supply of fuel in liters. Applicable only for combustion engines.

withDecelerationEfficiency

fun withDecelerationEfficiency(decelerationEfficiency: Double): ReachableRangeQueryBuilder

Specifies the efficiency of converting kinetic energy to saved (not consumed) fuel when the vehicle decelerates (i.e., ChemicalEnergySaved/KineticEnergyLost). ChemicalEnergySaved is obtained by converting saved (not consumed) fuel to energy using fuelEnergyDensityInMJoulesPerLiter.

withDepartAt

fun withDepartAt(departAt: Date): ReachableRangeQueryBuilder

Specifies the departure time.

withDistanceBudgetInMeters

fun withDistanceBudgetInMeters(distanceBudgetInMeters: Double): ReachableRangeQueryBuilder

The distance budget in meters that determines the maximum range which can be traveled. The Consumption Model will only affect the range when the routeType is eco.

withDownhillEfficiency

fun withDownhillEfficiency(downhillEfficiency: Double): ReachableRangeQueryBuilder

Specifies the efficiency of converting potential energy to saved (not consumed) fuel when the vehicle loses elevation (i.e. ChemicalEnergySaved/PotentialEnergyLost). ChemicalEnergySaved is obtained by converting saved (not consumed) fuel to energy using fuelEnergyDensityInMJoulesPerLiter. Applicable only for combustion engines. If used at all, must be used in conjunction with .withUphillEfficiency. If used, .withVehicleWeightInKg has to be used as well.

withEnergyBudgetInKWh

fun withEnergyBudgetInKWh(energyBudgetInKWh: Double): ReachableRangeQueryBuilder

Electric energy budget in kilowatt hours (kWh) that determines the maximum range that can be traveled using the specified Electric Consumption Model.

withFuelBudgetInLiters

fun withFuelBudgetInLiters(fuelBudgetInLiters: Double): ReachableRangeQueryBuilder

Fuel budget in liters that determines the maximum range that can be travelled using the specified Combustion Consumption Model.

withFuelEnergyDensityInMJoulesPerLiter

fun withFuelEnergyDensityInMJoulesPerLiter(fuelEnergyDensityInMJoulesPerLiter: Double): ReachableRangeQueryBuilder

Specifies the amount of chemical energy stored in one liter of fuel in megajoules (MJ). It is used in conjunction with the *Efficiency parameters for conversions between saved or consumed energy and fuel. For example, energy density is 34.2 MJ/l for gasoline, and 35.8 MJ/l for Diesel fuel. Applicable only for combustion engines.

withHilliness

fun withHilliness(hilliness: Hilliness): ReachableRangeQueryBuilder

Specifies the hilliness type for route calculation.

withMaxChargeInKWh

fun withMaxChargeInKWh(maxChargeInKWh: Double): ReachableRangeQueryBuilder

Specifies the capacity of the vehicle's battery in kilowatt hours (kWh). Applicable only for electric engines. If used at all, must be used in conjunction with .withCurrentChargeInKWh.

withRouteType

fun withRouteType(routeType: RouteType): ReachableRangeQueryBuilder

Specifies the route type.

withTimeBudgetInSeconds

fun withTimeBudgetInSeconds(timeBudgetInSeconds: Double): ReachableRangeQueryBuilder

Time budget in seconds that determines the maximum range that can be traveled within a given time. The consumption parameters will only affect eco-routes and thereby indirectly affect the driving time.

withTravelMode

fun withTravelMode(travelMode: TravelMode): ReachableRangeQueryBuilder

Specifies the travel mode for route calculation.

withUphillEfficiency

fun withUphillEfficiency(uphillEfficiency: Double): ReachableRangeQueryBuilder

Specifies the efficiency of converting chemical energy stored in fuel to potential energy when the vehicle gains elevation (i.e. PotentialEnergyGained/ChemicalEnergyConsumed). ChemicalEnergyConsumed is obtained by converting consumed fuel to chemical energy using fuelEnergyDensityInMJoulesPerLiter. Applicable only for combustion engines. If used at all, must be used in conjunction with .withDownhillEfficiency. If used, .withVehicleWeightInKg has to be used as well.

withVehicleAxleWeightInKg

fun withVehicleAxleWeightInKg(vehicleAxleWeightInKg: Int): ReachableRangeQueryBuilder

Specifies the vehicle axle weight for route calculation.

withVehicleCommercial

fun withVehicleCommercial(vehicleCommercial: Boolean): ReachableRangeQueryBuilder

Specifies if the vehicle is used for commercial to calculate route.

withVehicleEngineType

fun withVehicleEngineType(vehicleEngineType: VehicleEngineType): ReachableRangeQueryBuilder

Specifies the vehicle engine type for route query.

withVehicleHeightInMeters

fun withVehicleHeightInMeters(vehicleHeightInMeters: Double): ReachableRangeQueryBuilder

Specifies the vehicle height for route calculation.

withVehicleLengthInMeters

fun withVehicleLengthInMeters(vehicleLengthInMeters: Double): ReachableRangeQueryBuilder

Specifies the vehicle length for route calculation.

withVehicleLoadType

fun withVehicleLoadType(vehicleLoadType: VehicleLoadType): ReachableRangeQueryBuilder

Specifies the vehicle load type for route calculation.

withVehicleMaxSpeedInKph

fun withVehicleMaxSpeedInKph(vehicleMaxSpeedInKph: Int): ReachableRangeQueryBuilder

Specifies the vehicle max speed for route calculation.

withVehicleWeightInKg

fun withVehicleWeightInKg(vehicleWeightInKg: Int): ReachableRangeQueryBuilder

Specifies the vehicle weight in kilograms for route calculation.

withVehicleWidthInMeters

fun withVehicleWidthInMeters(vehicleWidthInMeters: Double): ReachableRangeQueryBuilder

Specifies the vehicle width for route calculation.

withWindingness

fun withWindingness(windingness: Windingness): ReachableRangeQueryBuilder

Specifies the windingness type for route calculation.

Companion Object Functions

create

fun create(origin: LatLng): ReachableRangeQueryBuilder

Creates an instance of ReachableRangeQueryBuilder with given origin.