From 03a4a1deec6a1b8848f435215c0084e8a0a49ea3 Mon Sep 17 00:00:00 2001 From: Thomas Rasch Date: Sat, 16 Sep 2023 19:05:47 +0200 Subject: [PATCH] Convert CLLocationCoordinate2D to Coordinate3D --- Sources/GISTools/GeoJson/Coordinate3D.swift | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Sources/GISTools/GeoJson/Coordinate3D.swift b/Sources/GISTools/GeoJson/Coordinate3D.swift index d130e9b..4d70381 100644 --- a/Sources/GISTools/GeoJson/Coordinate3D.swift +++ b/Sources/GISTools/GeoJson/Coordinate3D.swift @@ -470,4 +470,12 @@ extension CLLocation { } +extension CLLocationCoordinate2D { + + /// The receiver as a ``Coordinate3D``. + public var coordinate3D: Coordinate3D { + Coordinate3D(self) + } + +} #endif