diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml deleted file mode 100644 index ce06f18..0000000 --- a/.github/workflows/build-test.yml +++ /dev/null @@ -1,21 +0,0 @@ -name: Build & Test - -on: - push: - branches: - - master - pull_request: - -jobs: - - build: - - runs-on: macOS-latest - - steps: - - name: Checkout Repository - uses: actions/checkout@v3 - - name: Install - run: pod install - - name: Build & Test - run: xcodebuild test -workspace grid-ios.xcworkspace -scheme grid-ios -destination 'platform=iOS Simulator,OS=latest,name=iPhone 14' diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a2b0b01..ac6375a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -13,8 +13,18 @@ jobs: steps: - name: Checkout Repository - uses: actions/checkout@v3 - - name: Install - run: pod install + uses: actions/checkout@v4 - name: Build - run: xcodebuild build-for-testing -workspace grid-ios.xcworkspace -scheme grid-ios -destination 'platform=iOS Simulator,OS=latest,name=iPhone 14' + run: | + iphone_names=$(xcrun simctl list devices available --json | jq -r '.devices | to_entries[] | .value[] | select(.name | test("^iPhone [0-9]+")) | .name') + latest_iphone=$(echo "$iphone_names" | sort | tail -n 1) + echo "latest_iphone: $latest_iphone" + xcodebuild build -scheme Grid -destination "platform=iOS Simulator,OS=latest,name=$latest_iphone" + + - name: Test + run: | + iphone_names=$(xcrun simctl list devices available --json | jq -r '.devices | to_entries[] | .value[] | select(.name | test("^iPhone [0-9]+")) | .name') + latest_iphone=$(echo "$iphone_names" | sort | tail -n 1) + echo "latest_iphone: $latest_iphone" + xcodebuild test -scheme Grid -destination "platform=iOS Simulator,OS=latest,name=$latest_iphone" + \ No newline at end of file diff --git a/.gitignore b/.gitignore index 50867b6..76c7045 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ xcuserdata/ *.swp Carthage/ build/ +.build/ \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a8e1d8..36039c2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,9 +4,11 @@ Adheres to [Semantic Versioning](http://semver.org/). --- -# 1.0.8 (TBD) +# 2.0.0 -* TBD +* SimpleFeatures (sf-ios) 5.0.0 (Breaking change for NS_ENUM symbol exposure to Swift) +* Updated to Swift Package Manager (SPM) since Cocoapods is deprecated. +* Updated Unit to GridUnit to prevent collision Grid class (GARS and MGRS could not resolve the symbol) ## [1.0.7](https://github.com/ngageoint/grid-ios/releases/tag/1.0.7) (04-08-2024) diff --git a/Package.resolved b/Package.resolved new file mode 100644 index 0000000..3899eb7 --- /dev/null +++ b/Package.resolved @@ -0,0 +1,24 @@ +{ + "originHash" : "0a2343e561738888d0c374606b530f6803217a627a8961bb5e186cf7135f809a", + "pins" : [ + { + "identity" : "color-ios", + "kind" : "remoteSourceControl", + "location" : "https://github.com/ngageoint/color-ios", + "state" : { + "branch" : "psolt/package", + "revision" : "37e9f7f9cea14ec1759f36c3981effee063a31f6" + } + }, + { + "identity" : "simple-features-ios", + "kind" : "remoteSourceControl", + "location" : "https://github.com/ngageoint/simple-features-ios", + "state" : { + "branch" : "psolt/v5-NS_ENUM_Package", + "revision" : "0050585703585a94bca5c8530a6c45de10c0293c" + } + } + ], + "version" : 3 +} diff --git a/Package.swift b/Package.swift new file mode 100644 index 0000000..6c8e5e9 --- /dev/null +++ b/Package.swift @@ -0,0 +1,34 @@ +// swift-tools-version: 5.10 + +import PackageDescription + +let package = Package( + name: "Grid", + platforms: [.macOS(.v11), .iOS(.v13)], + products: [ + .library( + name: "Grid", + targets: ["Grid"]) + ], + dependencies: [ + .package(url: "https://github.com/ngageoint/simple-features-ios", branch: "psolt/v5-NS_ENUM_Package"), // FIXME: Update to published release (5.0.0 version) + .package(url: "https://github.com/ngageoint/color-ios", branch: "psolt/package") + ], + targets: [ + .target( + name: "Grid", + dependencies: [ + .product(name: "SimpleFeatures", package: "simple-features-ios"), + .product(name: "Color", package: "color-ios") + ], + path: "grid-ios" + ), + .testTarget( + name: "GridTests", + dependencies: [ + "Grid" + ], + path: "grid-iosTests" + ) + ] +) diff --git a/Podfile b/Podfile deleted file mode 100644 index 917f004..0000000 --- a/Podfile +++ /dev/null @@ -1,12 +0,0 @@ -source 'https://github.com/CocoaPods/Specs.git' -platform :ios, '12.0' -use_frameworks! - -target 'grid-ios' do - pod 'color-ios', '~> 1.0.2' - pod 'sf-ios', '~> 4.1.4' - - target 'grid-iosTests' do - inherit! :complete - end -end diff --git a/README.md b/README.md index c1b1b88..ca6118f 100644 --- a/README.md +++ b/README.md @@ -29,42 +29,47 @@ View the latest [Appledoc](http://ngageoint.github.io/grid-ios/docs/api/) ```swift -import grid_ios +import Grid ``` ### Build ### -[![Build & Test](https://github.com/ngageoint/grid-ios/workflows/Build%20&%20Test/badge.svg)](https://github.com/ngageoint/grid-ios/actions/workflows/build-test.yml) +[![Build](https://github.com/ngageoint/grid-ios/workflows/Build/badge.svg)](https://github.com/ngageoint/grid-ios/actions/workflows/build.yml) -Build this repository using Xcode and/or CocoaPods: +Build and Test (Uses UIKit, so we build with xcodebuild instead of SPM). - pod install - -Open grid-ios.xcworkspace in Xcode or build from command line: - - xcodebuild -workspace 'grid-ios.xcworkspace' -scheme grid-ios build - -Run tests from Xcode or from command line: - - xcodebuild test -workspace 'grid-ios.xcworkspace' -scheme grid-ios -destination 'platform=iOS Simulator,name=iPhone 15' + ./build.sh + +You can build and test if you open the Package.swift in Xcode. ### Include Library ### Include this repository by specifying it in a Podfile using a supported option. -Pull from [CocoaPods](https://cocoapods.org/pods/grid-ios): - pod 'grid-ios', '~> 1.0.7' +### Include Library ### + +Use this library via SPM in your Package.swift: -Pull from GitHub: + dependencies: [ + .package(url: "https://github.com/ngageoint/grid-ios.git", branch: "release/2.0.0"), + ] + +Or as a tagged release: - pod 'grid-ios', :git => 'https://github.com/ngageoint/grid-ios.git', :branch => 'master' - pod 'grid-ios', :git => 'https://github.com/ngageoint/grid-ios.git', :tag => '1.0.7' + dependencies: [ + .package(url: "https://github.com/ngageoint/grid-ios.git", from: "2.0.0"), + ] -Include as local project: +Reference it in your Package.swift target: - pod 'grid-ios', :path => '../grid-ios' + .target( + name: "MyApp", + dependencies: [ + .product(name: "Grid", package: "grid-ios"), + ], + ), ### Remote Dependencies ### diff --git a/build.sh b/build.sh new file mode 100755 index 0000000..e4bcc5f --- /dev/null +++ b/build.sh @@ -0,0 +1,16 @@ +#!/bin/bash + +set -e + +# Find iPhone Simulator +iphone_names=$(xcrun simctl list devices available --json | jq -r '.devices | to_entries[] | .value[] | select(.name | test("^iPhone [0-9]+")) | .name') +if [ -z "$iphone_names" ]; then echo "Error: No iPhone simulators found."; exit 1; fi + +latest_iphone=$(echo "$iphone_names" | sort | tail -n 1) +echo "latest_iphone: $latest_iphone" + +# Build +xcodebuild build -scheme Grid -destination "platform=iOS Simulator,OS=latest,name=$latest_iphone" + +# Test +xcodebuild test -scheme Grid -destination "platform=iOS Simulator,OS=latest,name=$latest_iphone" \ No newline at end of file diff --git a/grid-ios.podspec b/grid-ios.podspec deleted file mode 100644 index f09acef..0000000 --- a/grid-ios.podspec +++ /dev/null @@ -1,22 +0,0 @@ -Pod::Spec.new do |s| - s.name = 'grid-ios' - s.version = '1.0.8' - s.license = {:type => 'MIT', :file => 'LICENSE' } - s.summary = 'iOS SDK for Grids' - s.homepage = 'https://github.com/ngageoint/grid-ios' - s.authors = { 'NGA' => '', 'BIT Systems' => '', 'Brian Osborn' => 'bosborn@caci.com' } - s.social_media_url = 'https://twitter.com/NGA_GEOINT' - s.source = { :git => 'https://github.com/ngageoint/grid-ios.git', :tag => s.version } - s.requires_arc = true - s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES' } - - s.platform = :ios, '12.0' - s.ios.deployment_target = '12.0' - - s.source_files = 'grid-ios/**/*.swift' - - s.frameworks = 'Foundation' - - s.dependency 'color-ios', '~> 1.0.2' - s.dependency 'sf-ios', '~> 4.1.4' -end diff --git a/grid-ios.xcodeproj/project.pbxproj b/grid-ios.xcodeproj/project.pbxproj deleted file mode 100644 index bdcbde2..0000000 --- a/grid-ios.xcodeproj/project.pbxproj +++ /dev/null @@ -1,684 +0,0 @@ -// !$*UTF8*$! -{ - archiveVersion = 1; - classes = { - }; - objectVersion = 55; - objects = { - -/* Begin PBXBuildFile section */ - 04281FF62899BD7F00026382 /* grid_ios.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 04281FED2899BD7F00026382 /* grid_ios.framework */; }; - 04281FFC2899BD7F00026382 /* grid_ios.h in Headers */ = {isa = PBXBuildFile; fileRef = 04281FF02899BD7F00026382 /* grid_ios.h */; settings = {ATTRIBUTES = (Public, ); }; }; - 0428200A289A9B8200026382 /* GridPoint.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282009289A9B8200026382 /* GridPoint.swift */; }; - 0428200D289AA16B00026382 /* Unit.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428200C289AA16B00026382 /* Unit.swift */; }; - 04282011289AC47400026382 /* Pixel.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282010289AC47400026382 /* Pixel.swift */; }; - 04282013289AC5CF00026382 /* PixelRange.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282012289AC5CF00026382 /* PixelRange.swift */; }; - 04282015289AC85A00026382 /* GridTile.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282014289AC85A00026382 /* GridTile.swift */; }; - 04282017289ACA3B00026382 /* Bounds.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282016289ACA3B00026382 /* Bounds.swift */; }; - 04282019289BF4CE00026382 /* Line.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282018289BF4CE00026382 /* Line.swift */; }; - 0428201B289C0E6100026382 /* GridUtils.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428201A289C0E6100026382 /* GridUtils.swift */; }; - 0428201D289C44AF00026382 /* GridConstants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428201C289C44AF00026382 /* GridConstants.swift */; }; - 04282020289C651A00026382 /* PointTestCase.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428201F289C651A00026382 /* PointTestCase.swift */; }; - 04282022289D481500026382 /* PropertyConstants.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282021289D481500026382 /* PropertyConstants.swift */; }; - 04282024289D4B2C00026382 /* GridProperties.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282023289D4B2C00026382 /* GridProperties.swift */; }; - 04282026289D970700026382 /* Hemisphere.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282025289D970700026382 /* Hemisphere.swift */; }; - 04282028289D9AFC00026382 /* Label.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282027289D9AFC00026382 /* Label.swift */; }; - 0428202A289DA41700026382 /* GridStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04282029289DA41700026382 /* GridStyle.swift */; }; - 0428202C289DB5DE00026382 /* Labeler.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428202B289DB5DE00026382 /* Labeler.swift */; }; - 0428202E28A1242B00026382 /* BaseGrid.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428202D28A1242B00026382 /* BaseGrid.swift */; }; - 0428203028A1454D00026382 /* BaseZoomGrids.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428202F28A1454D00026382 /* BaseZoomGrids.swift */; }; - 0428203228A155C900026382 /* BaseGrids.swift in Sources */ = {isa = PBXBuildFile; fileRef = 0428203128A155C900026382 /* BaseGrids.swift */; }; - 04F5211928AD646A004C6D8C /* TileDraw.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F5211828AD646A004C6D8C /* TileDraw.swift */; }; - 04F5211B28AD69D5004C6D8C /* TileUtils.swift in Sources */ = {isa = PBXBuildFile; fileRef = 04F5211A28AD69D5004C6D8C /* TileUtils.swift */; }; - 7B8F91BDECC4D386AEEBDD6D /* Pods_grid_ios.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6298E09A9ED0C174E8F1C242 /* Pods_grid_ios.framework */; }; - EA202A114D6AB4C28FB13973 /* Pods_grid_ios_grid_iosTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 63109E2CA5CCF3CD56103440 /* Pods_grid_ios_grid_iosTests.framework */; }; -/* End PBXBuildFile section */ - -/* Begin PBXContainerItemProxy section */ - 04281FF72899BD7F00026382 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = 04281FE42899BD7F00026382 /* Project object */; - proxyType = 1; - remoteGlobalIDString = 04281FEC2899BD7F00026382; - remoteInfo = "grid-ios"; - }; -/* End PBXContainerItemProxy section */ - -/* Begin PBXFileReference section */ - 04281FED2899BD7F00026382 /* grid_ios.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = grid_ios.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - 04281FF02899BD7F00026382 /* grid_ios.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = grid_ios.h; sourceTree = ""; }; - 04281FF52899BD7F00026382 /* grid-iosTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "grid-iosTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; - 04282009289A9B8200026382 /* GridPoint.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridPoint.swift; sourceTree = ""; }; - 0428200C289AA16B00026382 /* Unit.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Unit.swift; sourceTree = ""; }; - 04282010289AC47400026382 /* Pixel.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pixel.swift; sourceTree = ""; }; - 04282012289AC5CF00026382 /* PixelRange.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PixelRange.swift; sourceTree = ""; }; - 04282014289AC85A00026382 /* GridTile.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridTile.swift; sourceTree = ""; }; - 04282016289ACA3B00026382 /* Bounds.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Bounds.swift; sourceTree = ""; }; - 04282018289BF4CE00026382 /* Line.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Line.swift; sourceTree = ""; }; - 0428201A289C0E6100026382 /* GridUtils.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridUtils.swift; sourceTree = ""; }; - 0428201C289C44AF00026382 /* GridConstants.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridConstants.swift; sourceTree = ""; }; - 0428201F289C651A00026382 /* PointTestCase.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PointTestCase.swift; sourceTree = ""; }; - 04282021289D481500026382 /* PropertyConstants.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PropertyConstants.swift; sourceTree = ""; }; - 04282023289D4B2C00026382 /* GridProperties.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridProperties.swift; sourceTree = ""; }; - 04282025289D970700026382 /* Hemisphere.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Hemisphere.swift; sourceTree = ""; }; - 04282027289D9AFC00026382 /* Label.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Label.swift; sourceTree = ""; }; - 04282029289DA41700026382 /* GridStyle.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GridStyle.swift; sourceTree = ""; }; - 0428202B289DB5DE00026382 /* Labeler.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Labeler.swift; sourceTree = ""; }; - 0428202D28A1242B00026382 /* BaseGrid.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseGrid.swift; sourceTree = ""; }; - 0428202F28A1454D00026382 /* BaseZoomGrids.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseZoomGrids.swift; sourceTree = ""; }; - 0428203128A155C900026382 /* BaseGrids.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BaseGrids.swift; sourceTree = ""; }; - 04F5211828AD646A004C6D8C /* TileDraw.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TileDraw.swift; sourceTree = ""; }; - 04F5211A28AD69D5004C6D8C /* TileUtils.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TileUtils.swift; sourceTree = ""; }; - 3295100FC695C71079321C28 /* Pods-grid-ios.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-ios.release.xcconfig"; path = "Target Support Files/Pods-grid-ios/Pods-grid-ios.release.xcconfig"; sourceTree = ""; }; - 43F6D866DB2D2299E81BE1D4 /* Pods-grid-ios-grid-iosTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-ios-grid-iosTests.debug.xcconfig"; path = "Target Support Files/Pods-grid-ios-grid-iosTests/Pods-grid-ios-grid-iosTests.debug.xcconfig"; sourceTree = ""; }; - 449E8DB981E6CC3061EE3115 /* Pods-grid-iosTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-iosTests.release.xcconfig"; path = "Target Support Files/Pods-grid-iosTests/Pods-grid-iosTests.release.xcconfig"; sourceTree = ""; }; - 4E9E5249E3C73D594F06BCAF /* Pods-grid-ios-grid-iosTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-ios-grid-iosTests.release.xcconfig"; path = "Target Support Files/Pods-grid-ios-grid-iosTests/Pods-grid-ios-grid-iosTests.release.xcconfig"; sourceTree = ""; }; - 6298E09A9ED0C174E8F1C242 /* Pods_grid_ios.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_grid_ios.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - 63109E2CA5CCF3CD56103440 /* Pods_grid_ios_grid_iosTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_grid_ios_grid_iosTests.framework; sourceTree = BUILT_PRODUCTS_DIR; }; - 92880B6C95E606EF80A8E4FC /* Pods-grid-iosTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-iosTests.debug.xcconfig"; path = "Target Support Files/Pods-grid-iosTests/Pods-grid-iosTests.debug.xcconfig"; sourceTree = ""; }; - E851D60405F0F6192D5968E0 /* Pods-grid-ios.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-grid-ios.debug.xcconfig"; path = "Target Support Files/Pods-grid-ios/Pods-grid-ios.debug.xcconfig"; sourceTree = ""; }; -/* End PBXFileReference section */ - -/* Begin PBXFrameworksBuildPhase section */ - 04281FEA2899BD7F00026382 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - 7B8F91BDECC4D386AEEBDD6D /* Pods_grid_ios.framework in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; - 04281FF22899BD7F00026382 /* Frameworks */ = { - isa = PBXFrameworksBuildPhase; - buildActionMask = 2147483647; - files = ( - 04281FF62899BD7F00026382 /* grid_ios.framework in Frameworks */, - EA202A114D6AB4C28FB13973 /* Pods_grid_ios_grid_iosTests.framework in Frameworks */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXFrameworksBuildPhase section */ - -/* Begin PBXGroup section */ - 04281FE32899BD7F00026382 = { - isa = PBXGroup; - children = ( - 04281FEF2899BD7F00026382 /* grid-ios */, - 04281FF92899BD7F00026382 /* grid-iosTests */, - 04281FEE2899BD7F00026382 /* Products */, - 893E1AC857AF11139CB60595 /* Pods */, - 6F74DC420EB3232760614D11 /* Frameworks */, - ); - sourceTree = ""; - }; - 04281FEE2899BD7F00026382 /* Products */ = { - isa = PBXGroup; - children = ( - 04281FED2899BD7F00026382 /* grid_ios.framework */, - 04281FF52899BD7F00026382 /* grid-iosTests.xctest */, - ); - name = Products; - sourceTree = ""; - }; - 04281FEF2899BD7F00026382 /* grid-ios */ = { - isa = PBXGroup; - children = ( - 04281FF02899BD7F00026382 /* grid_ios.h */, - 0428202D28A1242B00026382 /* BaseGrid.swift */, - 0428203128A155C900026382 /* BaseGrids.swift */, - 0428202F28A1454D00026382 /* BaseZoomGrids.swift */, - 0428201C289C44AF00026382 /* GridConstants.swift */, - 04282029289DA41700026382 /* GridStyle.swift */, - 0428201A289C0E6100026382 /* GridUtils.swift */, - 04282025289D970700026382 /* Hemisphere.swift */, - 04282027289D9AFC00026382 /* Label.swift */, - 0428202B289DB5DE00026382 /* Labeler.swift */, - 04282007289A9A8400026382 /* features */, - 04282006289A9A7900026382 /* property */, - 04282005289A9A6B00026382 /* tile */, - ); - path = "grid-ios"; - sourceTree = ""; - }; - 04281FF92899BD7F00026382 /* grid-iosTests */ = { - isa = PBXGroup; - children = ( - 0428201E289C64A500026382 /* features */, - ); - path = "grid-iosTests"; - sourceTree = ""; - }; - 04282005289A9A6B00026382 /* tile */ = { - isa = PBXGroup; - children = ( - 04282014289AC85A00026382 /* GridTile.swift */, - 04282010289AC47400026382 /* Pixel.swift */, - 04282012289AC5CF00026382 /* PixelRange.swift */, - 04F5211828AD646A004C6D8C /* TileDraw.swift */, - 04F5211A28AD69D5004C6D8C /* TileUtils.swift */, - ); - path = tile; - sourceTree = ""; - }; - 04282006289A9A7900026382 /* property */ = { - isa = PBXGroup; - children = ( - 04282023289D4B2C00026382 /* GridProperties.swift */, - 04282021289D481500026382 /* PropertyConstants.swift */, - ); - path = property; - sourceTree = ""; - }; - 04282007289A9A8400026382 /* features */ = { - isa = PBXGroup; - children = ( - 04282016289ACA3B00026382 /* Bounds.swift */, - 04282018289BF4CE00026382 /* Line.swift */, - 04282009289A9B8200026382 /* GridPoint.swift */, - 0428200C289AA16B00026382 /* Unit.swift */, - ); - path = features; - sourceTree = ""; - }; - 0428201E289C64A500026382 /* features */ = { - isa = PBXGroup; - children = ( - 0428201F289C651A00026382 /* PointTestCase.swift */, - ); - path = features; - sourceTree = ""; - }; - 6F74DC420EB3232760614D11 /* Frameworks */ = { - isa = PBXGroup; - children = ( - 6298E09A9ED0C174E8F1C242 /* Pods_grid_ios.framework */, - 63109E2CA5CCF3CD56103440 /* Pods_grid_ios_grid_iosTests.framework */, - ); - name = Frameworks; - sourceTree = ""; - }; - 893E1AC857AF11139CB60595 /* Pods */ = { - isa = PBXGroup; - children = ( - E851D60405F0F6192D5968E0 /* Pods-grid-ios.debug.xcconfig */, - 3295100FC695C71079321C28 /* Pods-grid-ios.release.xcconfig */, - 43F6D866DB2D2299E81BE1D4 /* Pods-grid-ios-grid-iosTests.debug.xcconfig */, - 4E9E5249E3C73D594F06BCAF /* Pods-grid-ios-grid-iosTests.release.xcconfig */, - 92880B6C95E606EF80A8E4FC /* Pods-grid-iosTests.debug.xcconfig */, - 449E8DB981E6CC3061EE3115 /* Pods-grid-iosTests.release.xcconfig */, - ); - path = Pods; - sourceTree = ""; - }; -/* End PBXGroup section */ - -/* Begin PBXHeadersBuildPhase section */ - 04281FE82899BD7F00026382 /* Headers */ = { - isa = PBXHeadersBuildPhase; - buildActionMask = 2147483647; - files = ( - 04281FFC2899BD7F00026382 /* grid_ios.h in Headers */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXHeadersBuildPhase section */ - -/* Begin PBXNativeTarget section */ - 04281FEC2899BD7F00026382 /* grid-ios */ = { - isa = PBXNativeTarget; - buildConfigurationList = 04281FFF2899BD7F00026382 /* Build configuration list for PBXNativeTarget "grid-ios" */; - buildPhases = ( - B993E02F2C99A4D637D2A1D2 /* [CP] Check Pods Manifest.lock */, - 04281FE82899BD7F00026382 /* Headers */, - 04281FE92899BD7F00026382 /* Sources */, - 04281FEA2899BD7F00026382 /* Frameworks */, - 04281FEB2899BD7F00026382 /* Resources */, - ); - buildRules = ( - ); - dependencies = ( - ); - name = "grid-ios"; - productName = "grid-ios"; - productReference = 04281FED2899BD7F00026382 /* grid_ios.framework */; - productType = "com.apple.product-type.framework"; - }; - 04281FF42899BD7F00026382 /* grid-iosTests */ = { - isa = PBXNativeTarget; - buildConfigurationList = 042820022899BD7F00026382 /* Build configuration list for PBXNativeTarget "grid-iosTests" */; - buildPhases = ( - 321F54B66A477D58A760C00E /* [CP] Check Pods Manifest.lock */, - 04281FF12899BD7F00026382 /* Sources */, - 04281FF22899BD7F00026382 /* Frameworks */, - 04281FF32899BD7F00026382 /* Resources */, - 435BB7D55A42213CDE8B473C /* [CP] Embed Pods Frameworks */, - ); - buildRules = ( - ); - dependencies = ( - 04281FF82899BD7F00026382 /* PBXTargetDependency */, - ); - name = "grid-iosTests"; - productName = "grid-iosTests"; - productReference = 04281FF52899BD7F00026382 /* grid-iosTests.xctest */; - productType = "com.apple.product-type.bundle.unit-test"; - }; -/* End PBXNativeTarget section */ - -/* Begin PBXProject section */ - 04281FE42899BD7F00026382 /* Project object */ = { - isa = PBXProject; - attributes = { - BuildIndependentTargetsInParallel = 1; - LastSwiftUpdateCheck = 1340; - LastUpgradeCheck = 1340; - TargetAttributes = { - 04281FEC2899BD7F00026382 = { - CreatedOnToolsVersion = 13.4.1; - LastSwiftMigration = 1340; - }; - 04281FF42899BD7F00026382 = { - CreatedOnToolsVersion = 13.4.1; - }; - }; - }; - buildConfigurationList = 04281FE72899BD7F00026382 /* Build configuration list for PBXProject "grid-ios" */; - compatibilityVersion = "Xcode 13.0"; - developmentRegion = en; - hasScannedForEncodings = 0; - knownRegions = ( - en, - Base, - ); - mainGroup = 04281FE32899BD7F00026382; - productRefGroup = 04281FEE2899BD7F00026382 /* Products */; - projectDirPath = ""; - projectRoot = ""; - targets = ( - 04281FEC2899BD7F00026382 /* grid-ios */, - 04281FF42899BD7F00026382 /* grid-iosTests */, - ); - }; -/* End PBXProject section */ - -/* Begin PBXResourcesBuildPhase section */ - 04281FEB2899BD7F00026382 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; - 04281FF32899BD7F00026382 /* Resources */ = { - isa = PBXResourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXResourcesBuildPhase section */ - -/* Begin PBXShellScriptBuildPhase section */ - 321F54B66A477D58A760C00E /* [CP] Check Pods Manifest.lock */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; - outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-grid-ios-grid-iosTests-checkManifestLockResult.txt", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; - showEnvVarsInLog = 0; - }; - 435BB7D55A42213CDE8B473C /* [CP] Embed Pods Frameworks */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-grid-ios-grid-iosTests/Pods-grid-ios-grid-iosTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", - ); - name = "[CP] Embed Pods Frameworks"; - outputFileListPaths = ( - "${PODS_ROOT}/Target Support Files/Pods-grid-ios-grid-iosTests/Pods-grid-ios-grid-iosTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-grid-ios-grid-iosTests/Pods-grid-ios-grid-iosTests-frameworks.sh\"\n"; - showEnvVarsInLog = 0; - }; - B993E02F2C99A4D637D2A1D2 /* [CP] Check Pods Manifest.lock */ = { - isa = PBXShellScriptBuildPhase; - buildActionMask = 2147483647; - files = ( - ); - inputFileListPaths = ( - ); - inputPaths = ( - "${PODS_PODFILE_DIR_PATH}/Podfile.lock", - "${PODS_ROOT}/Manifest.lock", - ); - name = "[CP] Check Pods Manifest.lock"; - outputFileListPaths = ( - ); - outputPaths = ( - "$(DERIVED_FILE_DIR)/Pods-grid-ios-checkManifestLockResult.txt", - ); - runOnlyForDeploymentPostprocessing = 0; - shellPath = /bin/sh; - shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; - showEnvVarsInLog = 0; - }; -/* End PBXShellScriptBuildPhase section */ - -/* Begin PBXSourcesBuildPhase section */ - 04281FE92899BD7F00026382 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 04282022289D481500026382 /* PropertyConstants.swift in Sources */, - 04282011289AC47400026382 /* Pixel.swift in Sources */, - 04282017289ACA3B00026382 /* Bounds.swift in Sources */, - 04282015289AC85A00026382 /* GridTile.swift in Sources */, - 0428201D289C44AF00026382 /* GridConstants.swift in Sources */, - 04F5211B28AD69D5004C6D8C /* TileUtils.swift in Sources */, - 04282026289D970700026382 /* Hemisphere.swift in Sources */, - 04282024289D4B2C00026382 /* GridProperties.swift in Sources */, - 0428200A289A9B8200026382 /* GridPoint.swift in Sources */, - 04F5211928AD646A004C6D8C /* TileDraw.swift in Sources */, - 0428203028A1454D00026382 /* BaseZoomGrids.swift in Sources */, - 0428202E28A1242B00026382 /* BaseGrid.swift in Sources */, - 04282019289BF4CE00026382 /* Line.swift in Sources */, - 0428200D289AA16B00026382 /* Unit.swift in Sources */, - 0428201B289C0E6100026382 /* GridUtils.swift in Sources */, - 04282028289D9AFC00026382 /* Label.swift in Sources */, - 04282013289AC5CF00026382 /* PixelRange.swift in Sources */, - 0428202A289DA41700026382 /* GridStyle.swift in Sources */, - 0428202C289DB5DE00026382 /* Labeler.swift in Sources */, - 0428203228A155C900026382 /* BaseGrids.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; - 04281FF12899BD7F00026382 /* Sources */ = { - isa = PBXSourcesBuildPhase; - buildActionMask = 2147483647; - files = ( - 04282020289C651A00026382 /* PointTestCase.swift in Sources */, - ); - runOnlyForDeploymentPostprocessing = 0; - }; -/* End PBXSourcesBuildPhase section */ - -/* Begin PBXTargetDependency section */ - 04281FF82899BD7F00026382 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - target = 04281FEC2899BD7F00026382 /* grid-ios */; - targetProxy = 04281FF72899BD7F00026382 /* PBXContainerItemProxy */; - }; -/* End PBXTargetDependency section */ - -/* Begin XCBuildConfiguration section */ - 04281FFD2899BD7F00026382 /* Debug */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = dwarf; - ENABLE_STRICT_OBJC_MSGSEND = YES; - ENABLE_TESTABILITY = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_DYNAMIC_NO_PIC = NO; - GCC_NO_COMMON_BLOCKS = YES; - GCC_OPTIMIZATION_LEVEL = 0; - GCC_PREPROCESSOR_DEFINITIONS = ( - "DEBUG=1", - "$(inherited)", - ); - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 12.0; - MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; - MTL_FAST_MATH = YES; - ONLY_ACTIVE_ARCH = YES; - SDKROOT = iphoneos; - SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Debug; - }; - 04281FFE2899BD7F00026382 /* Release */ = { - isa = XCBuildConfiguration; - buildSettings = { - ALWAYS_SEARCH_USER_PATHS = NO; - CLANG_ANALYZER_NONNULL = YES; - CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; - CLANG_CXX_LANGUAGE_STANDARD = "gnu++17"; - CLANG_ENABLE_MODULES = YES; - CLANG_ENABLE_OBJC_ARC = YES; - CLANG_ENABLE_OBJC_WEAK = YES; - CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; - CLANG_WARN_BOOL_CONVERSION = YES; - CLANG_WARN_COMMA = YES; - CLANG_WARN_CONSTANT_CONVERSION = YES; - CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; - CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; - CLANG_WARN_DOCUMENTATION_COMMENTS = YES; - CLANG_WARN_EMPTY_BODY = YES; - CLANG_WARN_ENUM_CONVERSION = YES; - CLANG_WARN_INFINITE_RECURSION = YES; - CLANG_WARN_INT_CONVERSION = YES; - CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; - CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; - CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; - CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; - CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; - CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; - CLANG_WARN_STRICT_PROTOTYPES = YES; - CLANG_WARN_SUSPICIOUS_MOVE = YES; - CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; - CLANG_WARN_UNREACHABLE_CODE = YES; - CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; - COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 1; - DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; - ENABLE_NS_ASSERTIONS = NO; - ENABLE_STRICT_OBJC_MSGSEND = YES; - GCC_C_LANGUAGE_STANDARD = gnu11; - GCC_NO_COMMON_BLOCKS = YES; - GCC_WARN_64_TO_32_BIT_CONVERSION = YES; - GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; - GCC_WARN_UNDECLARED_SELECTOR = YES; - GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; - GCC_WARN_UNUSED_FUNCTION = YES; - GCC_WARN_UNUSED_VARIABLE = YES; - IPHONEOS_DEPLOYMENT_TARGET = 12.0; - MTL_ENABLE_DEBUG_INFO = NO; - MTL_FAST_MATH = YES; - SDKROOT = iphoneos; - SWIFT_COMPILATION_MODE = wholemodule; - SWIFT_OPTIMIZATION_LEVEL = "-O"; - VALIDATE_PRODUCT = YES; - VERSIONING_SYSTEM = "apple-generic"; - VERSION_INFO_PREFIX = ""; - }; - name = Release; - }; - 042820002899BD7F00026382 /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = E851D60405F0F6192D5968E0 /* Pods-grid-ios.debug.xcconfig */; - buildSettings = { - CLANG_ENABLE_MODULES = YES; - CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 1; - DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_KEY_NSHumanReadableCopyright = ""; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - "@loader_path/Frameworks", - ); - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = mil.nga.grid; - PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)"; - PROVISIONING_PROFILE_SPECIFIER = ""; - "PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = ""; - SKIP_INSTALL = YES; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_OPTIMIZATION_LEVEL = "-Onone"; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 042820012899BD7F00026382 /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 3295100FC695C71079321C28 /* Pods-grid-ios.release.xcconfig */; - buildSettings = { - CLANG_ENABLE_MODULES = YES; - CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 1; - DEFINES_MODULE = YES; - DEVELOPMENT_TEAM = ""; - DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 1; - DYLIB_INSTALL_NAME_BASE = "@rpath"; - GENERATE_INFOPLIST_FILE = YES; - INFOPLIST_KEY_NSHumanReadableCopyright = ""; - INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; - LD_RUNPATH_SEARCH_PATHS = ( - "$(inherited)", - "@executable_path/Frameworks", - "@loader_path/Frameworks", - ); - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = mil.nga.grid; - PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)"; - PROVISIONING_PROFILE_SPECIFIER = ""; - "PROVISIONING_PROFILE_SPECIFIER[sdk=macosx*]" = ""; - SKIP_INSTALL = YES; - SWIFT_EMIT_LOC_STRINGS = YES; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; - 042820032899BD7F00026382 /* Debug */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 43F6D866DB2D2299E81BE1D4 /* Pods-grid-ios-grid-iosTests.debug.xcconfig */; - buildSettings = { - ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - GENERATE_INFOPLIST_FILE = YES; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = "mil.nga.grid-iosTests"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_EMIT_LOC_STRINGS = NO; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Debug; - }; - 042820042899BD7F00026382 /* Release */ = { - isa = XCBuildConfiguration; - baseConfigurationReference = 4E9E5249E3C73D594F06BCAF /* Pods-grid-ios-grid-iosTests.release.xcconfig */; - buildSettings = { - ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; - CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 1; - GENERATE_INFOPLIST_FILE = YES; - MARKETING_VERSION = 1.0; - PRODUCT_BUNDLE_IDENTIFIER = "mil.nga.grid-iosTests"; - PRODUCT_NAME = "$(TARGET_NAME)"; - SWIFT_EMIT_LOC_STRINGS = NO; - SWIFT_VERSION = 5.0; - TARGETED_DEVICE_FAMILY = "1,2"; - }; - name = Release; - }; -/* End XCBuildConfiguration section */ - -/* Begin XCConfigurationList section */ - 04281FE72899BD7F00026382 /* Build configuration list for PBXProject "grid-ios" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 04281FFD2899BD7F00026382 /* Debug */, - 04281FFE2899BD7F00026382 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 04281FFF2899BD7F00026382 /* Build configuration list for PBXNativeTarget "grid-ios" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 042820002899BD7F00026382 /* Debug */, - 042820012899BD7F00026382 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; - 042820022899BD7F00026382 /* Build configuration list for PBXNativeTarget "grid-iosTests" */ = { - isa = XCConfigurationList; - buildConfigurations = ( - 042820032899BD7F00026382 /* Debug */, - 042820042899BD7F00026382 /* Release */, - ); - defaultConfigurationIsVisible = 0; - defaultConfigurationName = Release; - }; -/* End XCConfigurationList section */ - }; - rootObject = 04281FE42899BD7F00026382 /* Project object */; -} diff --git a/grid-ios.xcodeproj/xcshareddata/xcschemes/grid-ios.xcscheme b/grid-ios.xcodeproj/xcshareddata/xcschemes/grid-ios.xcscheme deleted file mode 100644 index 331bf28..0000000 --- a/grid-ios.xcodeproj/xcshareddata/xcschemes/grid-ios.xcscheme +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/grid-ios/BaseGrid.swift b/grid-ios/BaseGrid.swift index 6a51666..ca2f0ab 100644 --- a/grid-ios/BaseGrid.swift +++ b/grid-ios/BaseGrid.swift @@ -6,7 +6,7 @@ // import Foundation -import color_ios +import Color /** * Base Grid diff --git a/grid-ios/BaseGrids.swift b/grid-ios/BaseGrids.swift index 8456756..5dc5317 100644 --- a/grid-ios/BaseGrids.swift +++ b/grid-ios/BaseGrids.swift @@ -6,7 +6,7 @@ // import Foundation -import color_ios +import Color /** * Grids diff --git a/grid-ios/GridConstants.swift b/grid-ios/GridConstants.swift index 7e2d0f6..433ef76 100644 --- a/grid-ios/GridConstants.swift +++ b/grid-ios/GridConstants.swift @@ -6,7 +6,7 @@ // import Foundation -import sf_ios +import SimpleFeatures /** * Grid Constants diff --git a/grid-ios/GridStyle.swift b/grid-ios/GridStyle.swift index 177f9a2..ede7d30 100644 --- a/grid-ios/GridStyle.swift +++ b/grid-ios/GridStyle.swift @@ -6,7 +6,7 @@ // import Foundation -import color_ios +import Color /** * Grid Line Style diff --git a/grid-ios/GridUtils.swift b/grid-ios/GridUtils.swift index 064742b..d303f2a 100644 --- a/grid-ios/GridUtils.swift +++ b/grid-ios/GridUtils.swift @@ -6,7 +6,7 @@ // import Foundation -import sf_ios +import SimpleFeatures /** * Grid utilities @@ -155,7 +155,7 @@ public class GridUtils { * desired unit * @return point in unit */ - public static func toUnit(_ fromUnit: Unit, _ longitude: Double, _ latitude: Double, _ toUnit: Unit) -> GridPoint { + public static func toUnit(_ fromUnit: GridUnit, _ longitude: Double, _ latitude: Double, _ toUnit: GridUnit) -> GridPoint { var point: GridPoint if fromUnit == toUnit { point = GridPoint(longitude, latitude, toUnit) @@ -178,7 +178,7 @@ public class GridUtils { * @return point in unit */ public static func toUnit(_ longitude: Double, _ latitude: Double, - _ unit: Unit) -> GridPoint { + _ unit: GridUnit) -> GridPoint { var point: SFPoint switch unit { case .DEGREE: @@ -267,7 +267,7 @@ public class GridUtils { let point: SFPoint? = SFGeometryUtils.intersectionBetweenLine1Point1(line1Point1.toMeters(), andLine1Point2: line1Point2.toMeters(), andLine2Point1: line2Point1.toMeters(), andLine2Point2: line2Point2.toMeters()) if point != nil { - intersection = GridPoint(point!, Unit.METER).toUnit(line1Point1.unit) + intersection = GridPoint(point!, GridUnit.METER).toUnit(line1Point1.unit) } return intersection diff --git a/grid-ios/Labeler.swift b/grid-ios/Labeler.swift index fbd2cff..7725c58 100644 --- a/grid-ios/Labeler.swift +++ b/grid-ios/Labeler.swift @@ -6,7 +6,7 @@ // import Foundation -import color_ios +import Color /** * Grid Labeler diff --git a/grid-ios/features/Bounds.swift b/grid-ios/features/Bounds.swift index 0bc6937..f411da8 100644 --- a/grid-ios/features/Bounds.swift +++ b/grid-ios/features/Bounds.swift @@ -6,7 +6,7 @@ // import Foundation -import sf_ios +import SimpleFeatures /** * Grid Bounds @@ -27,7 +27,7 @@ public class Bounds: SFGeometryEnvelope { * @return bounds */ public static func degrees(_ minLongitude: Double, _ minLatitude: Double, _ maxLongitude: Double, _ maxLatitude: Double) -> Bounds { - return Bounds(minLongitude, minLatitude, maxLongitude, maxLatitude, Unit.DEGREE) + return Bounds(minLongitude, minLatitude, maxLongitude, maxLatitude, GridUnit.DEGREE) } /** @@ -44,13 +44,13 @@ public class Bounds: SFGeometryEnvelope { * @return bounds */ public static func meters(_ minLongitude: Double, _ minLatitude: Double, _ maxLongitude: Double, _ maxLatitude: Double) -> Bounds { - return Bounds(minLongitude, minLatitude, maxLongitude, maxLatitude, Unit.METER) + return Bounds(minLongitude, minLatitude, maxLongitude, maxLatitude, GridUnit.METER) } /** - * Unit + * GridUnit */ - public var unit: Unit + public var unit: GridUnit /** * The min longitude @@ -231,7 +231,7 @@ public class Bounds: SFGeometryEnvelope { * max latitude */ public convenience init(_ minLongitude: Double, _ minLatitude: Double, _ maxLongitude: Double, _ maxLatitude: Double) { - self.init(minLongitude, minLatitude, maxLongitude, maxLatitude, Unit.DEGREE) + self.init(minLongitude, minLatitude, maxLongitude, maxLatitude, GridUnit.DEGREE) } /** @@ -248,7 +248,7 @@ public class Bounds: SFGeometryEnvelope { * @param unit * unit */ - public init(_ minLongitude: Double, _ minLatitude: Double, _ maxLongitude: Double, _ maxLatitude: Double, _ unit: Unit) { + public init(_ minLongitude: Double, _ minLatitude: Double, _ maxLongitude: Double, _ maxLatitude: Double, _ unit: GridUnit) { self.unit = unit super.init(minX: NSDecimalNumber.init(value: minLongitude), andMinY: NSDecimalNumber.init(value: minLatitude), andMinZ: nil, andMinM: nil, andMaxX: NSDecimalNumber.init(value: maxLongitude), andMaxY: NSDecimalNumber.init(value: maxLatitude), andMaxZ: nil, andMaxM: nil) } @@ -287,7 +287,7 @@ public class Bounds: SFGeometryEnvelope { * @param unit * unit */ - public init(_ envelope: SFGeometryEnvelope, _ unit: Unit) { + public init(_ envelope: SFGeometryEnvelope, _ unit: GridUnit) { self.unit = unit super.init(minX: envelope.minX, andMinY: envelope.minY, andMinZ: envelope.minZ, andMinM: envelope.minM, andMaxX: envelope.maxX, andMaxY: envelope.maxY, andMaxZ: envelope.maxZ, andMaxM: envelope.maxM) } @@ -299,7 +299,7 @@ public class Bounds: SFGeometryEnvelope { * unit * @return true if in the unit */ - public func isUnit(_ unit: Unit) -> Bool { + public func isUnit(_ unit: GridUnit) -> Bool { return self.unit == unit } @@ -309,7 +309,7 @@ public class Bounds: SFGeometryEnvelope { * @return true if degrees */ public func isDegrees() -> Bool { - return isUnit(Unit.DEGREE) + return isUnit(GridUnit.DEGREE) } /** @@ -318,7 +318,7 @@ public class Bounds: SFGeometryEnvelope { * @return true if meters */ public func isMeters() -> Bool { - return isUnit(Unit.METER) + return isUnit(GridUnit.METER) } /** @@ -328,7 +328,7 @@ public class Bounds: SFGeometryEnvelope { * unit * @return bounds in units, same bounds if equal units */ - public func toUnit(_ unit: Unit) -> Bounds { + public func toUnit(_ unit: GridUnit) -> Bounds { var bounds: Bounds if isUnit(unit) { bounds = self @@ -346,7 +346,7 @@ public class Bounds: SFGeometryEnvelope { * @return bounds in degrees, same bounds if already in degrees */ public func toDegrees() -> Bounds { - return toUnit(Unit.DEGREE) + return toUnit(GridUnit.DEGREE) } /** @@ -355,7 +355,7 @@ public class Bounds: SFGeometryEnvelope { * @return bounds in meters, same bounds if already in meters */ public func toMeters() -> Bounds { - return toUnit(Unit.METER) + return toUnit(GridUnit.METER) } /** @@ -374,7 +374,7 @@ public class Bounds: SFGeometryEnvelope { */ public func centroidLatitude() -> Double { var centerLatitude: Double - if unit == Unit.DEGREE { + if unit == GridUnit.DEGREE { centerLatitude = centroid().latitude } else { centerLatitude = midY() @@ -384,7 +384,7 @@ public class Bounds: SFGeometryEnvelope { public override func centroid() -> GridPoint { var point: GridPoint - if unit == Unit.DEGREE { + if unit == GridUnit.DEGREE { point = toMeters().centroid().toDegrees() } else { point = GridPoint(super.centroid(), unit) @@ -437,7 +437,7 @@ public class Bounds: SFGeometryEnvelope { * @return west line */ public func westLine() -> Line { - return grid_ios.Line(northwest, southwest) + return Line(northwest, southwest) } /** @@ -446,7 +446,7 @@ public class Bounds: SFGeometryEnvelope { * @return south line */ public func southLine() -> Line { - return grid_ios.Line(southwest, southeast) + return Line(southwest, southeast) } /** @@ -455,7 +455,7 @@ public class Bounds: SFGeometryEnvelope { * @return east line */ public func eastLine() -> Line { - return grid_ios.Line(southeast, northeast) + return Line(southeast, northeast) } /** @@ -464,7 +464,7 @@ public class Bounds: SFGeometryEnvelope { * @return north line */ public func northLine() -> Line { - return grid_ios.Line(northeast, northwest) + return Line(northeast, northwest) } /** @@ -547,7 +547,7 @@ public class Bounds: SFGeometryEnvelope { } public required init?(coder: NSCoder) { - unit = Unit.init(rawValue: coder.decodeInteger(forKey: "unit"))! + unit = GridUnit.init(rawValue: coder.decodeInteger(forKey: "unit"))! super.init(coder: coder) } diff --git a/grid-ios/features/GridPoint.swift b/grid-ios/features/GridPoint.swift index 4715827..a9c3d9f 100644 --- a/grid-ios/features/GridPoint.swift +++ b/grid-ios/features/GridPoint.swift @@ -6,7 +6,7 @@ // import Foundation -import sf_ios +import SimpleFeatures import MapKit /** @@ -24,7 +24,7 @@ public class GridPoint: SFPoint { * @return point in degrees */ public static func degrees(_ longitude: Double, _ latitude: Double) -> GridPoint { - return GridPoint(longitude, latitude, Unit.DEGREE) + return GridPoint(longitude, latitude, GridUnit.DEGREE) } /** @@ -37,7 +37,7 @@ public class GridPoint: SFPoint { * @return point in meters */ public static func meters(_ longitude: Double, _ latitude: Double) -> GridPoint { - return GridPoint(longitude, latitude, Unit.METER) + return GridPoint(longitude, latitude, GridUnit.METER) } /** @@ -53,7 +53,7 @@ public class GridPoint: SFPoint { * desired unit * @return point in unit */ - public static func toUnit(_ fromUnit: Unit, _ longitude: Double, _ latitude: Double, _ toUnit: Unit) -> GridPoint { + public static func toUnit(_ fromUnit: GridUnit, _ longitude: Double, _ latitude: Double, _ toUnit: GridUnit) -> GridPoint { return GridUtils.toUnit(fromUnit, longitude, latitude, toUnit) } @@ -68,7 +68,7 @@ public class GridPoint: SFPoint { * desired unit * @return point in unit */ - public static func toUnit(_ longitude: Double, _ latitude: Double, _ unit: Unit) -> GridPoint { + public static func toUnit(_ longitude: Double, _ latitude: Double, _ unit: GridUnit) -> GridPoint { return GridUtils.toUnit(longitude, latitude, unit) } @@ -82,7 +82,7 @@ public class GridPoint: SFPoint { * @return point in meters */ public static func degreesToMeters(_ longitude: Double, _ latitude: Double) -> GridPoint { - return toUnit(Unit.DEGREE, longitude, latitude, Unit.METER) + return toUnit(GridUnit.DEGREE, longitude, latitude, GridUnit.METER) } /** @@ -95,13 +95,13 @@ public class GridPoint: SFPoint { * @return point in degrees */ public static func metersToDegrees(_ longitude: Double, _ latitude: Double) -> GridPoint { - return toUnit(Unit.METER, longitude, latitude, Unit.DEGREE) + return toUnit(GridUnit.METER, longitude, latitude, GridUnit.DEGREE) } /** - * Unit + * GridUnit */ - public var unit: Unit + public var unit: GridUnit /** * The longitude @@ -136,7 +136,7 @@ public class GridPoint: SFPoint { * latitude */ public convenience init(_ longitude: Double, _ latitude: Double) { - self.init(longitude, latitude, Unit.DEGREE) + self.init(longitude, latitude, GridUnit.DEGREE) } /** @@ -149,7 +149,7 @@ public class GridPoint: SFPoint { * @param unit * unit */ - public init(_ longitude: Double, _ latitude: Double, _ unit: Unit) { + public init(_ longitude: Double, _ latitude: Double, _ unit: GridUnit) { self.unit = unit super.init(hasZ: false, andHasM: false, andX: NSDecimalNumber.init(value: longitude), andY: NSDecimalNumber.init(value: latitude)) } @@ -172,7 +172,7 @@ public class GridPoint: SFPoint { * @param unit * unit */ - public init(_ point: SFPoint, _ unit: Unit) { + public init(_ point: SFPoint, _ unit: GridUnit) { self.unit = unit super.init(hasZ: point.hasZ, andHasM: point.hasM, andX: point.x, andY: point.y) z = point.z @@ -186,7 +186,7 @@ public class GridPoint: SFPoint { * unit * @return true if in the unit */ - public func isUnit(_ unit: Unit) -> Bool { + public func isUnit(_ unit: GridUnit) -> Bool { return self.unit == unit } @@ -196,7 +196,7 @@ public class GridPoint: SFPoint { * @return true if degrees */ public func isDegrees() -> Bool { - return isUnit(Unit.DEGREE) + return isUnit(GridUnit.DEGREE) } /** @@ -205,7 +205,7 @@ public class GridPoint: SFPoint { * @return true if meters */ public func isMeters() -> Bool { - return isUnit(Unit.METER) + return isUnit(GridUnit.METER) } /** @@ -215,7 +215,7 @@ public class GridPoint: SFPoint { * unit * @return point in units, same point if equal units */ - public func toUnit(_ unit: Unit) -> GridPoint { + public func toUnit(_ unit: GridUnit) -> GridPoint { var point: GridPoint if isUnit(unit) { point = self @@ -231,7 +231,7 @@ public class GridPoint: SFPoint { * @return point in degrees, same point if already in degrees */ public func toDegrees() -> GridPoint { - return toUnit(Unit.DEGREE) + return toUnit(GridUnit.DEGREE) } /** @@ -240,7 +240,7 @@ public class GridPoint: SFPoint { * @return point in meters, same point if already in meters */ public func toMeters() -> GridPoint { - return toUnit(Unit.METER) + return toUnit(GridUnit.METER) } /** @@ -288,7 +288,7 @@ public class GridPoint: SFPoint { } public required init?(coder: NSCoder) { - unit = Unit.init(rawValue: coder.decodeInteger(forKey: "unit"))! + unit = GridUnit.init(rawValue: coder.decodeInteger(forKey: "unit"))! super.init(coder: coder) } diff --git a/grid-ios/features/Unit.swift b/grid-ios/features/GridUnit.swift similarity index 82% rename from grid-ios/features/Unit.swift rename to grid-ios/features/GridUnit.swift index 594f4a9..e63555f 100644 --- a/grid-ios/features/Unit.swift +++ b/grid-ios/features/GridUnit.swift @@ -1,5 +1,5 @@ // -// Unit.swift +// GridUnit.swift // grid-ios // // Created by Brian Osborn on 8/3/22. @@ -8,9 +8,9 @@ import Foundation /** - * Unit + * GridUnit */ -public enum Unit: Int { +public enum GridUnit: Int { /** * Degrees diff --git a/grid-ios/features/Line.swift b/grid-ios/features/Line.swift index e007bcc..13c5cc9 100644 --- a/grid-ios/features/Line.swift +++ b/grid-ios/features/Line.swift @@ -6,7 +6,7 @@ // import Foundation -import sf_ios +import SimpleFeatures /** * Line between two points @@ -40,7 +40,7 @@ open class Line: SFLine { /** * The unit */ - public var unit: Unit { + public var unit: GridUnit { get { return point1.unit } @@ -55,7 +55,7 @@ open class Line: SFLine { * second point */ public init(_ point1: GridPoint, _ point2: GridPoint) { - super.init(type:SF_LINESTRING, andHasZ: false, andHasM: false) + super.init(type:.LINESTRING, andHasZ: false, andHasM: false) setPoints(point1, point2) } @@ -66,7 +66,7 @@ open class Line: SFLine { * line to copy */ public init(_ line: Line) { - super.init(type:SF_LINESTRING, andHasZ: line.hasZ, andHasM: line.hasM) + super.init(type:.LINESTRING, andHasZ: line.hasZ, andHasM: line.hasM) setPoints(line.point1, line.point2) } @@ -93,7 +93,7 @@ open class Line: SFLine { * unit * @return true if in the unit */ - public func isUnit(_ unit: Unit) -> Bool { + public func isUnit(_ unit: GridUnit) -> Bool { return point1.isUnit(unit) } @@ -122,7 +122,7 @@ open class Line: SFLine { * unit * @return line in units, same line if equal units */ - public func toUnit(_ unit: Unit) -> Line { + public func toUnit(_ unit: GridUnit) -> Line { var line: Line if isUnit(unit) { line = self @@ -139,7 +139,7 @@ open class Line: SFLine { * @return line in degrees, same line if already in degrees */ public func toDegrees() -> Line { - return toUnit(Unit.DEGREE) + return toUnit(GridUnit.DEGREE) } /** @@ -148,7 +148,7 @@ open class Line: SFLine { * @return line in meters, same line if already in meters */ public func toMeters() -> Line { - return toUnit(Unit.METER) + return toUnit(GridUnit.METER) } /** diff --git a/grid-ios/property/GridProperties.swift b/grid-ios/property/GridProperties.swift index c11caef..bc09089 100644 --- a/grid-ios/property/GridProperties.swift +++ b/grid-ios/property/GridProperties.swift @@ -36,6 +36,18 @@ open class GridProperties { properties = dict! } + public init(_ propertiesData: Data) { +// let dict: [String: Any]? +// properties = [:] +// let propertiesPath = GridProperties.propertyListURL(resourceClass, bundle, name) + do { +// let propertiesData = try Data(contentsOf: propertiesPath) + properties = try PropertyListSerialization.propertyList(from: propertiesData, options: [], format: nil) as? [String: Any] ?? [:] + } catch { + fatalError("Failed to load properties data") + } + } + /** * Combine the base property with the property to create a single combined property * @@ -317,10 +329,17 @@ open class GridProperties { public static func propertyListURL(_ resourceClass: AnyClass, _ bundle: String, _ name: String) -> URL { return resourceURL(resourceClass, bundle, name, PropertyConstants.PROPERTY_LIST_TYPE) } + +// public static func propertyListURL(_ name: String) -> URL { +// return resourceURL(resourceClass, bundle, name, PropertyConstants.PROPERTY_LIST_TYPE) +// } + public static func resourceURL(_ resourceClass: AnyClass, _ bundle: String, _ name: String, _ ext: String) -> URL { let resource = "\(bundle)/\(name)" + + var resourceURL = Bundle.main.url(forResource: resource, withExtension: ext) if resourceURL == nil { resourceURL = Bundle(for: resourceClass).url(forResource: resource, withExtension: ext) diff --git a/grid-ios/tile/GridTile.swift b/grid-ios/tile/GridTile.swift index e799d78..6d106c1 100644 --- a/grid-ios/tile/GridTile.swift +++ b/grid-ios/tile/GridTile.swift @@ -113,7 +113,7 @@ public class GridTile { * units * @return bounds in units */ - public func bounds(_ unit: Unit) -> Bounds { + public func bounds(_ unit: GridUnit) -> Bounds { return bounds.toUnit(unit) } @@ -123,7 +123,7 @@ public class GridTile { * @return bounds in degrees */ public func boundsDegrees() -> Bounds { - return bounds(Unit.DEGREE) + return bounds(GridUnit.DEGREE) } /** @@ -132,7 +132,7 @@ public class GridTile { * @return bounds in meters */ public func boundsMeters() -> Bounds { - return bounds(Unit.METER) + return bounds(GridUnit.METER) } /** diff --git a/grid-ios/tile/TileUtils.swift b/grid-ios/tile/TileUtils.swift index 517ad12..df207db 100644 --- a/grid-ios/tile/TileUtils.swift +++ b/grid-ios/tile/TileUtils.swift @@ -6,7 +6,7 @@ // import MapKit -import sf_ios +import SimpleFeatures /** * Tile Utils diff --git a/grid-iosTests/features/PointTestCase.swift b/grid-iosTests/PointTestCase.swift similarity index 82% rename from grid-iosTests/features/PointTestCase.swift rename to grid-iosTests/PointTestCase.swift index 5e8f887..b3e6d59 100644 --- a/grid-iosTests/features/PointTestCase.swift +++ b/grid-iosTests/PointTestCase.swift @@ -6,24 +6,24 @@ // import XCTest -@testable import grid_ios +@testable import Grid class PointTestCase: XCTestCase { func testExample() { let point = GridPoint.degrees(-112.500003, 21.943049) - XCTAssertEqual(Unit.DEGREE, point.unit) + XCTAssertEqual(GridUnit.DEGREE, point.unit) XCTAssertEqual(-112.500003, point.longitude, accuracy: 0.0000000000001) XCTAssertEqual(21.943049, point.latitude, accuracy: 0.0000000000001) let point2 = point.toMeters() - XCTAssertEqual(Unit.METER, point2.unit) + XCTAssertEqual(GridUnit.METER, point2.unit) XCTAssertEqual(-12523443.048201751, point2.longitude, accuracy: 0.00000001) XCTAssertEqual(2504688.958883909, point2.latitude, accuracy: 0.00000001) let point3 = point.toDegrees() - XCTAssertEqual(Unit.DEGREE, point3.unit) + XCTAssertEqual(GridUnit.DEGREE, point3.unit) XCTAssertEqual(-112.500003, point3.longitude, accuracy: 0.0000000000001) XCTAssertEqual(21.943049, point3.latitude, accuracy: 0.0000000000001)