Builder

class Builder

Builder used to create an instance of VehicleRestrictions. Once constructed, the user cannot change the field values.

Important: This is a Public Preview API. It may be changed or removed at any time.

Constructors

Link copied to clipboard
fun Builder()

Functions

Link copied to clipboard
fun build(): VehicleRestrictions

Creates a new instance of the VehicleRestrictions.

Link copied to clipboard
fun isVehicleCommercial(isVehicleCommercial: Boolean): VehicleRestrictions.Builder

Specifies whether the vehicle is used for commercial purposes and thus may not be allowed to drive on some roads.

Link copied to clipboard
fun vehicleAdrTunnelRestrictionCode(vehicleAdrTunnelRestrictionCode: VehicleAdrTunnelRestrictionCode): VehicleRestrictions.Builder

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

Link copied to clipboard
fun vehicleLoadType(vehicleLoadType: VehicleLoadType): VehicleRestrictions.Builder

Specifies the vehicle load type for route calculation.

Link copied to clipboard
fun vehicleMaxSpeedInKph(vehicleMaxSpeedInKph: Int): VehicleRestrictions.Builder

Specifies maximum speed of the vehicle in km/hour.