You have to create an account at Here website and create a new app in order to obtain your app_id
and app_code
at your app's page.
In order to execute the application, you must add the required HERE SDK resources as follows:
-
From the directory where you downloaded the
HERE SDK
, copy the contents of theHERE-sdk/libs/
folder, to your project'sapp/app/libs/
folder (the same folder as the src). -
copy the contents of the
HERE-sdk/libs/armeabi-v7a
folder to your project'sapp/src/main/jniLibs/armeabi
folder. You will need to create the jniLibs and armeabi subfolders. -
download the JTS Topology Suite (version 1.13 or later) from http://sourceforge.net/projects/jts-topo-suite/, extract its contents, and add the
jts-.jar
library into thelibs/
folder of yourEclipse
project.Directory structure should be something like that:
├───libs │ gson-2.3.1.jar │ HERE-sdk.jar │ HERE-sdk.jar.properties │ jts-1.13.jar └───src └───main ├───java │ └───com │ └───here │ └───android │ └───tutorial │ └───basicmap ├───jniLibs │ └───armeabi │ libc++_shared.so │ libCertResourcesPkg.so │ libcrypto.so │ libLohitIndicFontPkg.so │ libMapsEngineResourcePkg.so │ libMAPSJNI.so │ libNanumGothicFontPkg.so │ libPureArabicFontPkg.so │ libPureChineseFontPkg.so │ libPureIndicSouthFontPkg.so │ libPureThaiFontPkg.so │ libSdkResourcePkg.so │ libssl.so │ └───res ├───drawable-mdpi ├───layout ├───menu └───values
Result: Your project will be able to make use of APIs from the HERE SDK
.
In order to automatically include your libs dependencies, you should put the following code into your build.gradle:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
}