EnterCarpoolLaneGuidanceInstruction
public struct EnterCarpoolLaneGuidanceInstruction : GuidanceInstruction
Guidance Instruction indicating entering a carpool lane by changing lanes.
Important
This is a Public Preview API. It may be changed or removed at any time.-
init(id:
routeOffset: travelTime: maneuverPoint: drivingSide: combinedWithNext: previousSignificantRoad: nextSignificantRoad: routePath: intersectionName: signpost: carpoolLaneDirection: ) Initializes the guidance instruction, specifying values for its fields.
Declaration
Swift
public init( id: UUID = UUID(), routeOffset: Measurement<UnitLength>, travelTime: Measurement<UnitDuration>, maneuverPoint: CLLocationCoordinate2D, drivingSide: DrivingSide, combinedWithNext: Bool, previousSignificantRoad: RoadInformation?, nextSignificantRoad: RoadInformation?, routePath: [RouteCoordinate], intersectionName: String, signpost: Signpost?, carpoolLaneDirection: CarpoolLaneDirection )
Parameters
uuid
The ID of the instruction.
routeOffset
The distance from the start of the route to the instruction point.
travelTime
Estimated travel time to the point at routeOffset.
maneuverPoint
Location of the maneuver expressed as
CLLocationCoordinate2D
.drivingSide
Indicates left-hand vs. right-hand side driving at the point of the maneuver.
combinedWithNext
Indicates whether the instruction should be combined with the next one. This can be used to build messages like “Turn left and then turn right”.
previousSignificantRoad
Information about the road the driver will be on immediately before starting the maneuver, if available for this instruction.
nextSignificantRoad
Information about the road the driver will be on immediately after completing the maneuver.
routePath
A list of
RouteCoordinate
s that represents a route path.intersectionName
Name of the intersection at the maneuver point, if present for this instruction.
signpost
Signpost information, if present for this instruction.
carpoolLaneDirection
direction of the maneuver to enter the carpool lane.
-
Creates a guidance instruction initialized relative to the route instruction.
Throws an error if converting to guidance types fails.
Declaration
Swift
public init(instruction: EnterCarpoolLaneInstruction) throws
-
The ID of the instruction.
Declaration
Swift
public let id: UUID
-
The distance from the start of the route to the instruction point.
Declaration
Swift
public let routeOffset: Measurement<UnitLength>
-
The estimated travel time to the point at
routeOffset
.Declaration
Swift
public let travelTime: Measurement<UnitDuration>
-
Location of the maneuver expressed as a
CLLocationCoordinate2D
.Declaration
Swift
public let maneuverPoint: CLLocationCoordinate2D
-
Indicates left-hand vs. right-hand side driving at the point of the maneuver.
Declaration
Swift
public let drivingSide: DrivingSide
-
Indicates if the instruction should be combined with the next one. This can be used to build messages like “Turn left and then turn right”.
Declaration
Swift
public let combinedWithNext: Bool
-
Information about the road the driver will be on immediately before starting the maneuver, if available for this instruction.
Declaration
Swift
public let previousSignificantRoad: RoadInformation?
-
Information about the road the driver will be on immediately after completing the maneuver, if available for this instruction.
Declaration
Swift
public let nextSignificantRoad: RoadInformation?
-
An array of
RouteCoordinate
‘s that represents a route path.Declaration
Swift
public let routePath: [RouteCoordinate]
-
Name of the intersection at the maneuver point, if present for this instruction.
Declaration
Swift
public let intersectionName: String
-
Signpost information, if present for this instruction.
Declaration
Swift
public let signpost: Signpost?
-
Direction of the maneuver to enter the carpool lane.
Declaration
Swift
public let carpoolLaneDirection: CarpoolLaneDirection