Waypoint
public struct Waypoint : Hashable, Sendable
Value type describing a single Waypoint defined within a GPXTrack
. A Waypoint
has a location consisting of latitude, longitude and some metadata,
e.g. name and description.
-
The
Coordinate
(latitude, longitude and elevation in meters)Declaration
Swift
public var coordinate: Coordinate
-
Optional date for a given point.
Declaration
Swift
public var date: Date?
-
Optional name of the waypoint
Declaration
Swift
public var name: String?
-
Optional comment for the waypoint
Declaration
Swift
public var comment: String?
-
Optional description of the waypoint
Declaration
Swift
public var description: String?
-
Initializer You don’t need to construct this value by yourself, as it is done by GXPKits track parsing logic.
Declaration
Swift
public init(coordinate: Coordinate, date: Date? = nil, name: String? = nil, comment: String? = nil, description: String? = nil)
Parameters
coordinate
Coordinate
of the waypoint, requireddate
Optional date
name
Name of the waypoint
comment
A short comment
description
A longer description