AlternativeRoutesOptions
public struct AlternativeRoutesOptions
Specifies options related to alternative routes.
Note
Supporting points which are used for reconstructing a route and for calculating zero or more alternative routes to this reference route is part ofRouteLegOptions
-
Creates an
AlternativeRoutesOptionsinstance.Throws
RoutingOptionsErrorif invalid routing options provided.Declaration
Swift
public init ( maxAlternatives: Int, alternativeType: AlternativeType? = nil, minDeviationDistance: Measurement<UnitLength>? = nil, minDeviationTime: Measurement<UnitDuration>? = nil ) throwsParameters
maxAlternativesMaximum number of alternative routes to generate in addition to the primary route.
alternativeTypeWhether to find only better routes or any alternative to a given reference route. Can only be used with route reconstructions.
minDeviationDistanceFollow the reference route for at least this distance before deviating. Can only be used with route reconstructions.
minDeviationTimeFollow the reference route for at least this travel time before deviating. Can only be used with route reconstructions.
-
Maximum number of alternative routes to generate in addition to the primary route.
Declaration
Swift
public let maxAlternatives: Int -
Whether to find only better routes or any alternative to a given reference route. Can only be used with route reconstructions.
Declaration
Swift
public let alternativeType: AlternativeType? -
Follow the reference route for at least this distance before deviating. Can only be used with route reconstructions.
Declaration
Swift
public let minDeviationDistance: Measurement<UnitLength>? -
Follow the reference route for at least this travel time before deviating. Can only be used with route reconstructions.
Declaration
Swift
public let minDeviationTime: Measurement<UnitDuration>?
TomTom SDK for iOS (0.53.1)
AlternativeRoutesOptions