UI components
The ArcGIS Runtime SDK for iOS offers an open source toolkit that contains components to help simplify your iOS app development. Check out the examples project to see these components in action or read through the documentation to learn more about them.
To use toolkit in your project:
- Install with CocoaPods - Add
pod 'ArcGIS-Runtime-Toolkit-iOS'
to your podfile. - Install with Carthage - Add
github "esri/arcgis-runtime-toolkit-ios"
to your cartfile. - Build manually - Build and include manually if you'd like to customize or extend the toolkit.
Toolkit Components
- Augmented reality (AR) - Integrates the scene view with ARKit to enable augmented reality (AR).
- Bookmarks - Shows bookmarks, from a map, scene, or a list.
- Compass - Shows a compass direction when the map is rotated. Auto-hides when the map points north up.
- JobManager - Suspends and resumes ArcGIS Runtime tasks when the app is background, terminated, and relaunched.
- LegendViewController - Displays a legend for all the layers in a map or scene contained in an
AGSGeoView
. - MeasureToolbar - Allows measurement of distances and areas on the map view.
- PopupController - Display details and media, edit attributes, geometry and related records, and manage the attachments of features and graphics (pop-ups are defined in the
popup
property of features and graphics). - Scalebar - Displays current scale reference.
- TemplatePickerViewController - Allows a user to choose a template from a list of
AGSFeatureTemplate
when creating new features. - TimeSlider - Allows interactively defining a temporal range (i.e. time extent) and animating time moving forward or backward. Can be used to manipulate the time extent in a
MapView
orSceneView
.
Requirements
- ArcGIS Runtime SDK for iOS 100.9.0 (or higher)
- Xcode 11.0 (or higher)
The ArcGIS Runtime Toolkit for iOS has a Target SDK version of 12.0, meaning that it can run on devices with iOS 12.0 or newer.
Toolkit installation
Cocoapods
- Add
pod 'ArcGIS-Runtime-Toolkit-iOS'
to your podfile - Run
pod install
. This will download the toolkit and the ArcGIS Runtime SDK for iOS which the toolkit depends upon and then configure your project to reference them both. - Add
import ArcGISToolkit
in your source code and start using the toolkit components
New to cocoapods? Visit cocoapods.org
Carthage
Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.
- Add
github "esri/arcgis-runtime-toolkit-ios"
to your Cartfile - Run
carthage update
- Drag the
ArcGISToolkit.framework
from theCarthage/Build
folder to the "TARGETS" settings for your application and drop it in the "Embedded Binaries" section in the "General" tab - Add
import ArcGISToolkit
in your source code and start using the toolkit components
New to Carthage? Visit the Carthage GitHub page.
Note that you must have the ArcGIS Runtime SDK for iOS installed and your project set up. See Install and set up.
Manual
- Ensure you have downloaded and installed ArcGIS Runtime SDK for iOS. See Install and set up.
- Clone or download the toolkit repository.
- Drag and Drop the
Toolkit/ArcGISToolkit.xcodeproj
file into your project through the XCode Project Navigator pane. - Drag the
ArcGISToolkit.framework
from theArcGISToolkit.xcodeproj/ArcGISToolkit/Products
folder to the "TARGETS" settings for your application and drop it in the "Embedded Binaries" section in the "General" tab - Add
import ArcGISToolkit
in your source code and start using the toolkit components
SwiftLint
Both the toolkit and examples app support SwiftLint. You can install SwiftLint from here. It is not necessary to have it installed in order to build, but you will get a warning without it. The specific rules the linter uses can be found in the swiftlint.yml
files in the Toolkit
and Examples
directories.