This repository contains Swift sample code demonstrating the capabilities of ArcGIS Runtime SDK for iOS and how to use them in your own app. The project can be opened in Xcode and run on a simulator or a device. Or you can download the app from the App Store on your iOS device.
main branch of this repository contains samples configured for the latest available version of ArcGIS Runtime SDK for iOS. For samples configured for older versions of the SDK, look under the
Releases tab for a specific version.
The ArcGIS Runtime SDK Samples app has a Target SDK version of 13.0, meaning that it can run on devices with iOS 13.0 or newer.
The project has been configured to use the
arcgis-runtime-toolkit-iospackage, which provides the
ArcGISToolkitframework as well as the
pod installcommand in the folder where you cloned this repository
arcgis-ios-sdk-samplesproject node, go to the
Swift Packagestab, and delete the
arcgis-runtime-toolkit-iospackage. This Swift package conflicts with CocoaPods and is only required when using the Swift Package Manager as described in the previous section.
Some sample data is too large to store in the repository, so it is automatically downloaded at build time. The first time the app is built, a build script downloads the necessary data to
Portal Data. The script only downloads data files that do not already exist, so subsequent builds will take significantly less time.
As a best-practices principle, the project conceals app secrets from source code by generating and compiling an
AppSecrets.swift source code file at build time using a custom build rule.
This build rule looks for a secrets file stored in the project's root directory,
Note: Without licensing or licensing with invalid keys do not throw an exception, but simply fail to license the app, falling back to Developer Mode (which will display a watermark on the map and scene views).
echo ARCGIS_LICENSE_KEY=your-license-key >> .secrets echo ARCGIS_EXTENSION_LICENSE_KEY=your-extension-license-key >> .secrets echo ARCGIS_API_KEY=your-api-key >> .secrets
Replace 'your-license-key', 'your-extension-license-key' and 'your-api-key' with your keys.
AppDelegate.application(_:didFinishLaunchingWithOptions:), and choose the appropriate licensing method for your keys.
To learn more about
masquerade, consult the documentation of Esri's Data Collection app.
Find a bug or want to request a new feature? Please let us know by submitting an issue.
Esri welcomes contributions from anyone and everyone. Please see our guidelines for contributing.
Copyright 2021 Esri
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
A copy of the license is available in the repository's LICENSE file.