MaxSpeedOnSegment
public struct MaxSpeedOnSegment : Hashable
New base speed for a segment. Affects route calculation and the ETA. Cannot increase base speed on segment.
Note: This option can only be used with the RoutingEngine. The OfflineRoutingEngine is not supported and the option will be ignored. Note that the OfflineRoutingEngine is only available for the Navigate license.
-
A segment for which the new base speed is specified. Only the
segmendIdandtravelDirectionparameters are used, other parameters are ignored. Setting asegmendIdis mandatory.Note: The
SegmentReferenceis not directly accessible from the map via the HERE SDK. Although, after route calculation you can retrieve the related segments for eachSpan. The segment IDs are the same that are also used by, for example, the Routing REST API. These IDs are mostly stable and only change when the underlying map data changes due to a new road or similar changes in the real world.Declaration
Swift
public var segment: SegmentReference -
New maximum value in m/s of baseSpeed on segment. The provided value must be in the range [1.0, 70.0]. Cannot increase base speed on segment. If the value is greater than the default base speed, then such penalty will have no effect.
Declaration
Swift
public var baseSpeedInMetersPerSecond: Double -
Creates a new instance.
Parameters
- segment: A segment for which the new base speed is specified. Only the
segmendIdandtravelDirectionparameters are used, other parameters are ignored. Setting asegmendIdis mandatory.
Note: The
SegmentReferenceis not directly accessible from the map via the HERE SDK. Although, after route calculation you can retrieve the related segments for eachSpan. The segment IDs are the same that are also used by, for example, the Routing REST API. These IDs are mostly stable and only change when the underlying map data changes due to a new road or similar changes in the real world.- baseSpeedInMetersPerSecond: New maximum value in m/s of baseSpeed on segment. The provided value must be in the range [1.0, 70.0]. Cannot increase base speed on segment. If the value is greater than the default base speed, then such penalty will have no effect.
- segment: A segment for which the new base speed is specified. Only the
Declaration
Swift
public init(segment: SegmentReference, baseSpeedInMetersPerSecond: Double)