Structure
Location
@dynamicMemberLookup
public struct Location
A value type wrapper for CLLocation
. This type is necessary so that we can do equality checks
and write tests against its values.
Relationships
Conforms To
Codable
Hashable
Initializers
init(altitude:coordinate:course:horizontalAccuracy:speed:timestamp:verticalAccuracy:)
public init(
altitude: CLLocationDistance = 0,
coordinate: CLLocationCoordinate2D = CLLocationCoordinate2D(latitude: 0, longitude: 0),
course: CLLocationDirection = 0,
horizontalAccuracy: CLLocationAccuracy = 0,
speed: CLLocationSpeed = 0,
timestamp: Date = Date(),
verticalAccuracy: CLLocationAccuracy = 0
)
init(rawValue:)
public init(rawValue: CLLocation)
init(altitude:coordinate:course:courseAccuracy:horizontalAccuracy:speed:speedAccuracy:timestamp:verticalAccuracy:)
public init(
altitude: CLLocationDistance = 0,
coordinate: CLLocationCoordinate2D = CLLocationCoordinate2D(latitude: 0, longitude: 0),
course: CLLocationDirection = 0,
courseAccuracy: Double = 0,
horizontalAccuracy: CLLocationAccuracy = 0,
speed: CLLocationSpeed = 0,
speedAccuracy: Double = 0,
timestamp: Date = Date(),
verticalAccuracy: CLLocationAccuracy = 0
)
init(from:)
public init(from decoder: Decoder) throws
Properties
rawValue
public let rawValue: CLLocation
Methods
hash(into:)
public func hash(into hasher: inout Hasher)
encode(to:)
public func encode(to encoder: Encoder) throws
Operators
==
public static func == (lhs: Self, rhs: Self) -> Bool