This plugin simplifies the development of Gradle projects that use the ArcGIS Maps SDK for Java, by automating the necessary dependencies.
Open the project you want to apply the plugin to. In your build.gradle
, add the plugin to the plugins
block:
plugins {
id 'com.esri.arcgis-java-plugin' version '0.1.0'
}
Add an arcgis
block to build.gradle
, specifying the version of the ArcGIS Maps SDK for Java you want to use, for
example:
arcgis {
version = '200.3.0'
}
If you added the ArcGIS Maps SDK for Java to your project before this plugin was available, you can now delete the
following things that you previously added manually to build.gradle
:
- The
copyNatives
task, and thedependsOn copyNatives
line in therun
block:
task copyNatives(type: Copy) {
description = "Copies the arcgis native libraries into the .arcgis directory for development."
group = "build"
configurations.natives.asFileTree.each {
from(zipTree(it))
}
into "${System.properties.getProperty("user.home")}/.arcgis/$arcgisVersion"
}
run {
dependsOn copyNatives
}
- The
natives
configuration:
configurations {
natives
}
- The
ext
block (its functionality is provided by thearcgis
block mentioned above):
ext {
arcgisVersion = '200.1.0'
}
- These
arcgis-java
dependencies from thedependencies
block:
implementation "com.esri.arcgisruntime:arcgis-java:$arcgisVersion"
natives "com.esri.arcgisruntime:arcgis-java-jnilibs:$arcgisVersion"
natives "com.esri.arcgisruntime:arcgis-java-resources:$arcgisVersion"
See System Requirements for ArcGIS Maps SDK for Java.
Find a bug in this Plugin or want to request a new feature? Please let us know by submitting an issue in this repository.
Esri welcomes contributions from anyone and everyone. Please see our guidelines for contributing.
Copyright 2024 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
http://www.apache.org/licenses/LICENSE-2.0
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.txt file.