HERE Android SDK Premium Edition V3.6 Developer's Guide

User Manual: Pdf

Open the PDF directly: View PDF PDF.
Page Count: 2351 [warning: Documents this large are best viewed by clicking the View PDF Link!]

HERE Android SDK
Developer's Guide
Premium Edition Version 3.6
HERE Android SDK Developer's Guide
Notices
2
Important Information 
Notices
Topics:
Legal Notices
Document Information
Service Support
This section contains document notices.
HERE Android SDK Developer's Guide
Notices
3
Legal Notices
© 2017 HERE Global B.V. and its Affiliate(s). All rights reserved.
This material, including documentation and any related computer programs, is protected by copyright
controlled by HERE. All rights are reserved. Copying, including reproducing, storing, adapting or translating,
any or all of this material requires the prior written consent of HERE. This material also contains confidential
information, which may not be disclosed to others without the prior written consent of HERE.
Trademark Acknowledgements
HERE is trademark or registered trademark of HERE Global B.V.
Other product and company names mentioned herein may be trademarks or trade names of their respective
owners.
Disclaimer
This content is provided "as-is" and without warranties of any kind, either express or implied, including, but
not limited to, the implied warranties of merchantability, fitness for a particular purpose, satisfactory quality
and non-infringement. HERE does not warrant that the content is error free and HERE does not warrant or
make any representations regarding the quality, correctness, accuracy, or reliability of the content. You
should therefore verify any information contained in the content before acting on it.
To the furthest extent permitted by law, under no circumstances, including without limitation the negligence
of HERE, shall HERE be liable for any damages, including, without limitation, direct, special, indirect, punitive,
consequential, exemplary and/ or incidental damages that result from the use or application of this content,
even if HERE or an authorized representative has been advised of the possibility of such damages.
HERE Android SDK Developer's Guide
Notices
4
Document Information
Product
Name: HERE Android SDK
Version: Premium Edition Version 3.6
 
Document
Name: HERE Android SDK Developer's Guide
ID: 063f807-1513029408-3db914db
Status: FINAL
Date: 2017-Dec-11, 22:11 (GMT)
 
Service Support
If you need assistance with this or any other HERE product, select one of the following options.
If you have a HERE representative, contact them when you have questions/issues.
If you manage your applications and accounts through developer.here.com, log into your account
and check the pages on the SLA report or API Health. If this does not clarify the issue, then check
stackoverflow.com/questions/tagged/here-api.
If you have an evaluation plan, check stackoverflow.com/questions/tagged/here-api.
If you have questions about billing or your account, Contact Us.
If you have purchased your plan/product from a HERE reseller, contact your reseller.
HERE Android SDK Developer's Guide
Contents
5
Contents
Chapter1:Overview............................................................................................................................................................................8
What is the HERE Android SDK?.................................................................................................................................................................9
Feature List.............................................................................................................................................................................................................9
Legal Requirements..........................................................................................................................................................................................11
Chapter2:Quick Start.................................................................................................................................................................. 12
Run the Sample Application.......................................................................................................................................................................13
Chapter3:User Guide...................................................................................................................................................................16
System Requirements..................................................................................................................................................................................... 17
Authenticating Applications.........................................................................................................................................................................17
Examples on GitHub........................................................................................................................................................................................18
HERE Map Data...................................................................................................................................................................................................19
Embedding the Map Service.......................................................................................................................................................................20
Maps.........................................................................................................................................................................................................................22
Gestures..............................................................................................................................................................................................................27
Map Schemes.................................................................................................................................................................................................. 30
MapEngine Class............................................................................................................................................................................................33
Objects and Interaction.............................................................................................................................................................................34
Marker Clustering..........................................................................................................................................................................................46
Traffic Information.......................................................................................................................................................................................49
Offline Maps (MapLoader)........................................................................................................................................................................52
Shared Map Resources.............................................................................................................................................................................. 54
Traffic History................................................................................................................................................................................................. 54
3D Landmarks................................................................................................................................................................................................. 56
Extruded Buildings........................................................................................................................................................................................57
Custom Raster Tiles.................................................................................................................................................................................... 60
Mobile Asset Management.......................................................................................................................................................................63
Fleet Connectivity.........................................................................................................................................................................................66
Transit................................................................................................................................................................................................................. 68
Map Customization.......................................................................................................................................................................................78
Positioning............................................................................................................................................................................................................81
HERE Android SDK Developer's Guide
Contents
6
Basic Positioning........................................................................................................................................................................................... 81
Advanced Positioning by HERE............................................................................................................................................................. 85
Map Matching..................................................................................................................................................................................................93
Directions.............................................................................................................................................................................................................. 95
Car and Pedestrian Routing....................................................................................................................................................................95
Bicycle Routing...............................................................................................................................................................................................99
Truck Routing................................................................................................................................................................................................100
Transit Routing.............................................................................................................................................................................................101
Urban Mobility Routing........................................................................................................................................................................... 103
Indoor Venue Routing.............................................................................................................................................................................. 107
Offline Routing............................................................................................................................................................................................. 107
Route Consumption................................................................................................................................................................................... 107
Route Serialization.....................................................................................................................................................................................109
Places.....................................................................................................................................................................................................................110
Geocoding and Reverse Geocoding...................................................................................................................................................111
Search and Discovery................................................................................................................................................................................113
Offline Search............................................................................................................................................................................................... 120
Custom Locations and Geometries....................................................................................................................................................... 121
Custom Location Extension 2............................................................................................................................................................... 121
Using CLE2 Offline...................................................................................................................................................................................... 126
Toll Cost Extension........................................................................................................................................................................................ 132
Street-Level........................................................................................................................................................................................................135
Street-Level Imagery................................................................................................................................................................................. 135
Street-Level Objects.................................................................................................................................................................................. 141
Turn-by-Turn Navigation.............................................................................................................................................................................145
Navigation Events.......................................................................................................................................................................................149
Voice Instructions....................................................................................................................................................................................... 152
Traffic-Aware Navigation.........................................................................................................................................................................155
Audio Management........................................................................................................................................................................................156
Urban Mobility.................................................................................................................................................................................................. 157
Coverage Search..........................................................................................................................................................................................158
Transit Station Search............................................................................................................................................................................. 160
Next Nearby Departures..........................................................................................................................................................................162
3D Venues...........................................................................................................................................................................................................164
Venue Zoom................................................................................................................................................................................................... 172
Private Venues..............................................................................................................................................................................................174
Venue Routing...............................................................................................................................................................................................175
LiveSight............................................................................................................................................................................................................ 180
HERE Android SDK Developer's Guide
Contents
7
Starting and Stopping LiveSight.........................................................................................................................................................182
Adding and Interacting with LiveSight Content......................................................................................................................... 183
Customizing LiveSight.............................................................................................................................................................................. 188
Platform Data Extension.............................................................................................................................................................................192
Natural Language Processing (NLP)..................................................................................................................................................... 199
Chapter4:Supplemental Information................................................................................................................203
Creating a Simple Application................................................................................................................................................................ 204
Requesting Android Permissions...........................................................................................................................................................210
Android Emulator Support.........................................................................................................................................................................212
Adding a MapFragment at Runtime......................................................................................................................................................212
3D Venues FAQ................................................................................................................................................................................................. 213
Size Management............................................................................................................................................................................................218
Map Rendering Order...................................................................................................................................................................................219
Development Tips...........................................................................................................................................................................................221
Signpost Parsing............................................................................................................................................................................................. 224
Chapter5:Coverage Information...............................................................................................................................227
Downloadable Maps by Country/Region...........................................................................................................................................228
Map Label Languages...................................................................................................................................................................................232
Navigation Voices...........................................................................................................................................................................................234
Safety Camera Coverage.............................................................................................................................................................................236
Chapter6:API Reference......................................................................................................................................................239
HERE Android SDK Developer's Guide
Overview
8
Chapter 1
Overview
Topics:
What is the HERE Android S...
Feature List
Legal Requirements
The articles that follow introduce the HERE Android SDK, explain
essential concepts and describe the common use cases it supports.
HERE Android SDK Developer's Guide
Overview
9
What is the HERE Android SDK?
The HERE Android SDK provides a set of programming interfaces that enable developers to build an
immersive, geographically-aware Android applications by leveraging a powerful and flexible mapping
platform. Through this SDK, developers can add rich location features such as routing, interactive maps,
and global place search to their applications. The powerful client-side HERE Android SDK also includes
a sophisticated engine for rendering map data and calculated routes. In addition to dynamic map data
downloads, the SDK also supports offline maps using previously cached map data or downloaded map
packages.
Feature List
The main features offered by the HERE Android SDK are listed below.
Not all features are enabled by default. The features available to you are determined based on your business
plan.
Note: The HERE Android SDK is designed for standalone Android APK development. Using the HERE
SDK for platform-embedded app development (apps that ship with the device ROM) is not supported.
Mapping:
Dynamically download vector maps for more than 190 countries in over 60 languages
Preload maps for offline usage
Map styles: normal street map, satellite map, transit map, and more
Textured 3D landmarks
Street-level imagery
Touch gestures (including rotate, tilt, pan, flick, and pinch zoom)
Overlay objects on the map such as polylines, polygons, icons, and routes
Map marker clusters
Overlay 3D map objects
Overlay custom raster tiles on the map (for example, to display heat maps)
Ability to render raster tiles and map objects interleaved within different map layers
3D venue (indoor) maps
Show real-time traffic flow and incidents
3D Extruded Buildings
Transit object interaction
Search:
Search through a broad set of geographical content across the globe, (including streets, address points,
and categorized places)
Search for a specific place or explore by categories
Access rich details for a Point of Interest from third-party content sources (including images, ratings,
reviews, and editorials)
HERE Android SDK Developer's Guide
Overview
10
Perform geocoding and reverse geocoding lookups
Offline Places search, Geocoding, Reverse Geocoding
Directions:
Online Car, Public Transit, Bicylce, Truck, and Pedestrian Route Directions
Routing options (Highways, Tolls, Fastest etc.)
Specify preferred route type (fastest or shortest) and route options (such as avoiding toll roads,
motorways, and parks)
Alternate routes
Saving a route as a file
Offline route calculation
Driving directions with traffic taken into account
Public Transit directions using online timetables
Indoor routing
Turn-by-turn Navigation:
Online turn-by-turn navigation for pedestrian, car, and truck routes
Offline turn-by-turn navigation for pedestrian and car routes
Natural-sounding guidance instructions, such as "turn left at the gas station" and "at the next light, turn
right"
Recorded audio and speech synthesis voices in a variety of languages. For a list of the available
languages, see the Developer's Guide.
Approximate user coordinates to the nearest road or navigation route
Approximate user tunnel position, even when there is no GPS signal
Dynamic information including signposts, the driver's current street lane, and speed
Realistic previews of certain junctions and lanes
HERE Positioning:
Wi-Fi, Cellular, and BT network-based positioning, including:
Online Outdoor positioning
Online-Offline Hybrid Outdoor positioning
Indoor positioning
Private Indoor positioning
LiveSight:
Track the position of a device in space and animate view accordingly
Seamless transitions from Map to LiveSight and back again
Gesture support allows the user to interact with content, custom gestures can also be defined
Content transitions and interaction are animated using hardware acceleration
"Radar" UI support, which provides the user with more context regarding their position relative to
content
Highly configurable LiveSight engine allows the user experience to be customized
Other Features:
Custom location and custom location geometry search
HERE Android SDK Developer's Guide
Overview
11
Support for fleet dispatching and connectivity
Urban Mobility: transit station and departure information search
Map information for fleet vehicles and trucks
Congestion toll zones and the typical traffic patterns for a given time of the week
Ability to retrieve the toll cost of a route
Natural language interface (English only) beta
Legal Requirements
In addition to the applicable terms and conditions under which you have licensed the SDK, the following
shall apply.
Components of the HERE SDK collect certain information from your application. Such information includes
access credentials ( licenseKey, App_Id and App_Code – see also Authenticating Applications on page
17) and the types of features utilized by your application when used by end users. The information does
not identify an individual end user. However, your application's privacy policy must disclose to the end users
that you have licensed products and services from HERE and that such information is collected from your
application as it is being used by end users and that HERE collects and processes such information from the
application.
HERE Android SDK Developer's Guide
Quick Start
12
Chapter 2
Quick Start
Topics:
Run the Sample Application
The example in this section provide information to help you start
using the HERE Android SDK.
HERE Android SDK Developer's Guide
Quick Start
13
Run the Sample Application
This tutorial contains instructions on how to run the basic sample application to render a map on an
Android device. This tutorial assumes that you are using the Android Studio development environment and a
supported Android device. For more details, see System Requirements on page 17.
Development tasks for this basic application include:
Check HERE Credentials.
Open the sample project in Android Studio.
Import the necessary resources into the project.
Note: HERE Android SDK is now distributed as an .AAR instead of a .JAR, and the basic sample app is
also updated. If you are upgrading your existing project from an older version of the HERE SDK, be
sure to modify the project by following the instructions in Development Tips on page 221.
Check Credentials
This sample application is already configured with a set of HERE SDK credentials for evaluation
purposes. You can check these credentials by opening the BasicMapSolution/app/src/main/
AndroidManifest.xml file and inspecting the following <meta-data> tags:
<meta-data android:name="com.here.android.maps.appid"
android:value="{SAMPLE_APP_ID}"/>
<meta-data android:name="com.here.android.maps.apptoken"
android:value="{SAMPLE_APP_CODE}"/>
<meta-data android:name="com.here.android.maps.license.key"
android:value="{SAMPLE_LICENSE}"/>"/>
Important: Typically, before developing a new HERE SDK application, you need to acquire a set of
credentials by registering your application on http://developer.here.com. Each application requires a
unique set of credentials. When you register your app, the registered bundle identifier must match the
package name in your project.
Open the Sample Project in Android Studio
The next task before running the sample HERE SDK project is to locate the project folder and open it in
Android Studio as follows:
1. In the Welcome to Android Studio dialogue box, select Open an existing Android Studio project.
2. In the Open File or Project dialogue box, select the BasicMapSolution folder from your file system and
click OK. The main Android Studio project window should appear with an error "Error: Failed to
resolve: :HERE-sdk:" in the Messages pane.
Import the HERE SDK Android Archive
The HERE Android SDK library is shipped as an Android Archive (.AAR) file. You can import this library by
doing the following:
1. On the View menu, click Tool Windows> Project.
HERE Android SDK Developer's Guide
Quick Start
14
2. A few tabs are available in this tool window. Select the Project tab to show a file system view of the
application structure.
3. Right-click on the app folder and select New> Directory to create a new folder. Use libs as the new
folder name.
4. In your operating system's file system, navigate to the extracted HERE SDK directory. Copy the HERE-
sdk.aar file and paste it into the newly created libs directory.
5. Open the build.gradle file under the app folder and ensure the following entries are present:
repositories {
flatDir {
dirs 'libs'
}
}
dependencies {
compile(name:'HERE-sdk', ext:'aar')
// Depending on your specific project configuration, you may have other entries here.
}
6. Optional: To enable quick Javadoc reference within your Android Studio environment, scroll down to the
External Libraries section, right-click on HERE-sdk, and then select Library Properties. Click the + button
and locate HERE-sdk-javadoc.jar from the HERE SDK package.
Note: You can also import HERE-sdk.aar by using the menu, selecting File> Project Structure... and
clicking the "+" button. If you use this method, ensure that HERE-sdk is listed properly under the app
Module Dependencies.
Figure 1: Location of the .AAR file
HERE Android SDK Developer's Guide
Quick Start
15
Run the Project
You can run your simple application by pressing the key combination Shift + F10 (or Ctrl + R on macOS) from
within Android Studio. The application renders a map retrieved from the HERE servers. When you are running
your application on a device, make sure a dataconnection is enabled.
Note: For detailed instructions on how to create a new HERE SDK app, see Create a Simple App Using
the HERE SDK on page 204
HERE Android SDK Developer's Guide
User Guide
16
Chapter 3
User Guide
Topics:
System Requirements
Authenticating Application...
Examples on GitHub
HERE Map Data
Embedding the Map Service
Maps
Positioning
Directions
Places
Custom Locations and Geome...
Toll Cost Extension
Street-Level
Turn-by-Turn Navigation fo...
Audio Management
Urban Mobility
3D Venues
LiveSight
Platform Data Extension
Natural Language Processin...
The articles in this section provide a guide to using the HERE
Android SDK.
HERE Android SDK Developer's Guide
User Guide
17
System Requirements
HERE Android SDK is designed and tested with Android phones and tablets in mind. SDK performance will
vary between devices, since it is primarily determined by CPU, GPU, and display resolution. Currently, Nexus 5
is a suitable reference for a device which delivers acceptable SDK performance. If your target device is not a
phone or tablet, contact us to discuss performance requirements.
Android 4.1.x "Jelly Bean" (API Level 16) or higher as the application Minimum API Level
(android:minSdkVersion).
Apps should be developed using Android Studio 2.3.2 or above
For apps that implement basic use cases such as map rendering, search, and routing, a minimum of
60MB of memory (RAM) is recommended to be available. More complex use cases, such as turn-by-turn
navigation, require more memory.
A minimum of 25MB per application should be made available for the storage of the HERE SDK libraries
A minimum of 50MB should be made available for the storage of map data
Data connectivity (WiFi or Cellular) is required to download map data and ensure map data is updated
when new versions are made available.
Note: HERE Android SDK does not support x86 Android devices.
Authenticating Applications
Developers using the HERE SDK with their app are required to register for a set of HERE credentials and to
specify these credentials (App_Id, App_Code, and licenseKey) in their app's Android manifest XML file.
Failure to do so results in blocked access to certain features and degradation in the quality of other services.
To obtain these credentials, visit the developer portal at https://developer.here.com/?create=Evaluation and
register for a free Evaluation license. Once your project is created, you can generate these credentials on
your Project Details page. If you already have a commercial (public or business) plan, you can also retrieve
these credentials from your Project Details page.
Note: Credentials are unique to your application's package namespace. Do not reuse credentials
across multiple applications.
Important: When switching from an Evaluation plan to a commercial plan, new HERE credentials must
be taken into use. Applications must not be commercially released (such as submitted to a store)
using a license key obtained as part of an Evaluation plan. Once you have upgraded to a commerical
license, you need to obtain your new license key on the Project Details page, add it to your app, and
re-deploy your app. Please contact HERE for further information.
Adding Credentials to the Manifest
You can add your HERE credentials as <meta-data/> attributes to the AndroidManifest.xml file as
follows:
1. In your development environment, double-click your project's AndroidManifest.xml file and ensure
that you are viewing the file in text editor mode.
HERE Android SDK Developer's Guide
User Guide
18
2. Within the <application></application> block of tags, add the following markup directly beneath
the <activity></activity> tag:
<meta-data android:name="com.here.android.maps.appid"
android:value="{YOUR_APP_ID}"/>
<meta-data android:name="com.here.android.maps.apptoken"
android:value="{YOUR_APP_CODE}"/>
<meta-data android:name="com.here.android.maps.license.key"
android:value="{YOUR_LICENSE_KEY}"/>
3. Replace {YOUR_APP_ID}, {YOUR_APP_CODE} and {YOUR_LICENSE_KEY} with the appropriate
credentials for your application.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.mapstutorial.livesightradar"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk
android:minSdkVersion="14"
android:targetSdkVersion="16" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<!-- Additional permission for LiveSight -->
<uses-permission android:name="android.permission.ACCESS_MOCK_LOCATION" />
<uses-permission android:name="android.permission.CAMERA" />
<application
android:icon="@drawable/icon"
android:label="@string/app_name" >
<activity
android:name="com.mapstutorial.livesightradar.LiveSightRadarActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<meta-data
android:name="com.here.android.maps.appid"
android:value="{YOUR_APP_ID}" />
<meta-data
android:name="com.here.android.maps.apptoken"
android:value="{YOUR_APP_CODE}" />
<meta-data
android:name="com.here.android.maps.license.key"
android:value="YOUR_LICENSE_KEY" />
</application>
</manifest>
Examples on GitHub
You can find more HERE SDK sample projects on GitHub: https://www.github.com/heremaps
HERE Android SDK Developer's Guide
User Guide
19
HERE Map Data
Much of the functionality offered through the HERE SDK depends on HERE Map Data being downloaded and
cached on the device. This section describes different approaches that you can take to manage map data
download.
Passive Approach
The passive approach is where you allow the SDK to download map data as needed. A typical example is
where a user is panning the map, and this triggers on-demand download of the needed map data to render
the map.
Map data downloaded in this way is cached permanently and may be used for offline operation, in cases
where a network connection is not available or not desired, such as when the device is in roaming mode.
However, there is no way for you to know if sufficient data has been downloaded to enable all offline
operations, such as offline search or routing.
Active Approach
The active approach is where you explicitly preload map data. You do this by selecting from a list of
map packages. A map package may be a state (such as California), region, or a country (such as England).
Preloading map data guarantees that offline operations are possible in cases where a network connection is
not available or not desired.
Note: If map data is needed but not available in one of the preloaded map packages (for example,
if a user panned the map to a new country), the SDK dynamically downloads the needed data. This
means that the map data cache on the device contains a mixture of preloaded map packages and on-
demand downloaded map data.
Keep Data Up-to-Date
Irrespective of which approach your app supports, it is important that you are aware of your responsibility
to ensure that your app is using the latest map data release. HERE releases quarterly (every three months)
updates to the map data. You must use SDK APIs to check for map data updates, and if updates are available,
trigger the update. It is recommended that your app perform such a check every time it starts. For more
information on how to check for map data updates, see the API Reference for the MapLoader class.
Important: Some SDK features may return errors if the map data is more than six months old.
Note: Incremental or patch updates are supported when upgrading from one version to the next
version, helping to reduce the amount of data downloaded. Skipping versions may result in a full
update and a large amount of data downloaded.
HERE Android SDK Developer's Guide
User Guide
20
Embedding the Map Service
Map Service is an Android service that facilitates the use of a shared disk cache among applications that use
the HERE SDK. This service must be embedded and deployed with your HERE-enabled application; otherwise,
the MISSING_SERVICE error code is returned via the onEngineInitializationCompleted() callback.
To embed Map Service, add the following lines inside the <application></application> section in your
AndroidManifest.xml file:
<service
android:name="com.here.android.mpa.service.MapService"
android:label="HereMapService"
android:process="global.Here.Map.Service.v3"
android:exported="true" >
<intent-filter>
<action android:name="com.here.android.mpa.service.MapService.v3" >
</action>
</intent-filter>
</service>
Incompatibility with Older Versions
Starting in v3.4, the HERE SDK is no longer compatible with pre-3.4 versions of the HERE SDK disk cache. Map
data downloaded on pre-3.4 versions of the HERE SDK cannot be used on v3.4 or later.
If your app uses the shared disk cache settings as described above, be aware of the following:
The required <service>...</service> snippet, as described in the previous section, has changed.
When your users update their pre-3.4 HERE SDK apps to a newer version, their previously-downloaded
data will be unavailable. This occurs whether the app was automatically or manually updated.
In the case where a user has multiple HERE SDK apps on their system, pre-3.4 apps share one cache,
while post-3.4 apps share another.
If your app uses the isolated disk cache setting as described in the next section, be aware of the following:
When your users update their pre-3.4 HERE SDK apps to a newer version, their previously-downloaded
data will be unavailable. This occurs whether the app was automatically or manually updated.
You can avoid this issue by upgrading the pre-3.4 cache using the
DiskCacheUtility.migrate(String sourcePath, String destPath) method. This method
takes the same path value as setIsolatedDiskCacheRootPath(String, String), and it must be
run before MapEngine is initialized for the first time.
Note: migrate(String, String) is marked as deprecated because it is offered temporarily to
assist with the transition. It will be removed in a future release.
Using an Isolated Map Disk Cache with the Map Service
The HERE SDK supports an isolated disk cache. This allows you to set the disk cache to another location, such
as an SD Card.
Note:
HERE Android SDK Developer's Guide
User Guide
21
Migrating the disk cache contents from one location to another is not supported.
If you are using an SD card, ensure the SD card is always present to avoid any unexpected
behavior.
You should only delete the map data cache when the app is in its early start-up stages, before
any HERE SDK calls. Otherwise, map data corruption and unexpected app errors can occur.
If you plan to support changing the storage location, such as switching between internal storage
and an SD card, be aware that this requires an app restart, as the storage location switch must
be done before initializing MapEngine or MapFragment. Also, your manifest entry for the
MapService must not contain the process attribute, so that the MapService runs in the same
process as your app. Doing so ensures it that the service is shut down properly when the app
restarts (for example, using System.exit()), and that the disk cache location change can take
effect.
The first step to use an isolated disk cache is to edit the AndroidManifest.xml with the following,
providing the service label and intent name with your custom values.
<service
android:name="com.here.android.mpa.service.MapService"
android:label="{YOUR_LABEL_NAME}"
android:exported="false" >
<intent-filter>
<action android:name="{YOUR_INTENT_NAME}" >
</action>
</intent-filter>
</service>
Note: Always provide custom values for {YOUR_LABEL_NAME} and {YOUR_INTENT_NAME} when you
are using an isolated disk cache. Do not reuse the HERE SDK defaults.
After editing AndroidManifest.xml, add a call to
MapSettings.setIsolatedDiskCacheRootPath(String path, String intent) with the desired
cache location and the custom intent name. This call should occur before MapEngine initialization. For
example, if you are modifying the application from the sample tutorial app, you can add the call in the
BasicMapActivity.java file before mapFragment.init().
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Search for the map fragment to finish setup by calling init().
mapFragment = (MapFragment) getFragmentManager().findFragmentById(R.id.mapfragment);
boolean success = com.here.android.mpa.common.MapSettings.setIsolatedDiskCacheRootPath(
"/sdcard/foo/myservice", "{YOUR_INTENT_NAME}");
if (!success) {
// Setting the isolated disk cache was not successful, please check if the path is valid and
// ensure that it does not match the default location
// (getExternalStorageDirectory()/.here-maps).
// Also, ensure the provided intent name does not match the default intent name.
} else {
mapFragment.init(new OnEngineInitListener() {
...
}
HERE Android SDK Developer's Guide
User Guide
22
Maps
The core feature of the HERE Android SDK is Maps. The key concepts covered in this section include adding
a map to an Android application, changing the location displayed by the map and its various properties.
The classes covered include MapFragment and Map. MapFragment and Map are parts of a Model-View-
Controller (MVC) pattern where the Model is the Map, and the View is the MapFragment. The MapFragment
is a standard Android Fragment derived component. You can create a controller class to coordinate all
interactions using custom logic.
The first step to integrate a map into an application is to insert a MapFragment to the view layout of the
application. This is accomplished by adding com.here.android.mpa.mapping.MapFragment to the
Android XML layout file as follows.
<!-- Example fragment. This can be integrated and annotated
like any other android Fragment or View widget -->
<fragment
class="com.here.android.mpa.mapping.MapFragment"
android:id="@+id/mapfragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent"/>
The MapFragment class handles all user interactions such as panning, tapping or pinching, as well as other
standard HERE SDK touch gestures documented in MapGestures.
Initializing MapFragment
After adding the MapFragment to the layout, the fragment must be initialized. The
MapFragment initialization is processed asynchronously. During initialization, the MapEngine
is initialized to create an instance of Map that is associated with the MapFragment. The
MapFragment.init(OnEngineInitListener) method takes in an OnEngineInitListener input
parameter to signal the caller when initialization is completed and if it was successful. The MapFragment
also initializes a MapEngine instance and creates a Map object associated with the MapFragment. The
following code illustrates the basic initialization flow when an Activity is created.
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Search for the Map Fragment
final MapFragment mapFragment = (MapFragment)
getFragmentManager().findFragmentById(R.id.mapfragment);
// initialize the Map Fragment and
// retrieve the map that is associated to the fragment
mapFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(
OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// now the map is ready to be used
Map map = mapFragment.getMap();
// ...
HERE Android SDK Developer's Guide
User Guide
23
} else {
System.out.println("ERROR: Cannot initialize MapFragment");
}
}
});
}
Note: For performance reasons, com.here.android.mpa.mapping.MapFragment has set
Fragment.setRetainInstance(boolean) to true, and therefore onCreate(Bundle) is not
called again when Activity is re-created (for example, after a zoom-level change).
Note: The MapFragment class provides an asynchronous method,
getScreenCapture(OnScreenCaptureListener), for creating map snapshots of
the currently visible MapFragment area. When a snapshot has been created, an event
callback to OnScreenCaptureListener occurs, and the screenshot is provided as an
android.graphics.Bitmap object. This method of screen capture only works if the view is in
the foreground and it is rendering. If a background or viewless screen capture is required, use
MapOffscreenRenderer.
Working with Map
Once the MapFragment is initialized, you get the Map associated with the MapFragment through
MapFragment.getMap(). The Map class represents the virtual model of the world in a digital format. Key
attributes of the Map include the center GeoCoordinate, zoom level, orientation, and tilt. For example, the
following code snippet illustrates how to use Map.setCenter(GeoCoordinate, Map.Animation) to
render the Map at Vancouver, Canada.
// map fragment has been successfully initialized
...
// now the map is ready to be used
Map map = mapFragment.getMap();
// Set the map center to Vancouver, Canada.
map.setCenter(new GeoCoordinate(49.196261,
-123.004773), Map.Animation.NONE);
...
In the preceding code:
The GeoCoordinate for the map center is created by a call to the new GeoCoordinate(double,
double) constructor.
When setting the center of a map, there is an option either to animate the change or to suppress
animation by passing the constant Map.Animation.NONE as the relevant parameter.
Map Center , Tilt, Orientation, and Zoom
Here are examples of setting and getting Map attributes:
Map Center
The center of the Map is a GeoCoordinate location that your Map is focused on. You can move a Map by
redefining its center GeoCoordinate:
// Move the map to London.
map.setCenter(new GeoCoordinate(51.51,-0.11),
Map.Animation.NONE );
HERE Android SDK Developer's Guide
User Guide
24
// Get the current center of the Map
GeoCoordinate coordinate = map.getCenter();
Zoom Level
The size of the geographical area displayed by Map can be controlled by changing the zoom level. The zoom
level ranges from getMinZoomLevel() to getMaxZoomLevel(), with the minimum value displaying the
entire world. The following code sets the zoom level to the median zoom level.
// Get the maximum,minimum zoom level.
double maxZoom = map.getMaxZoomLevel();
double minZoom = map.getMinZoomLevel();
// Set the zoom level to the median (10).
map.setZoomLevel((maxZoom + minZoom)/2);
// Get the zoom level back
double zoom = map.getZoomLevel();
Orientation
The map can be orientated in any direction. By default, the orientation is in a true North position. The
following code changes the orientation to South-up.
// Rotate 180 degrees.
map.setOrientation(180);
// Get the orientation, should be 180.
float orientation = map.getOrientation();
Tilt
The map can be tilted and rendered in a three-dimensional perspective. By default, the tilt is completely
flat. You can retrieve the minimum and maximum possible tilt values by calling getMinTilt() and
getMaxTilt()
// Set the tilt to 45 degrees
map.setTilt(45);
// Get the tilt
float tilt = map.getTilt();
Animations
The map supports three types of animations when changing attributes:
Map.Animation.NONE
Map.Animation.LINEAR
Map.Animation.BOW
// Move to Vancouver using bow animation
map.setCenter(new GeoCoordinate(49.0,-123.0),
Map.Animation.LINEAR);
Note: If the map changes size or the app comes to the foreground while Map.Animation.LINEAR or
Map.Animation.BOW is being used in a Map attribute setter method, then the animation aborts, and
the transition appears to fail. To avoid this behavior, use the Map.Animation.NONE animation type
or wait until the map is stable before performing the transition operation.
HERE Android SDK Developer's Guide
User Guide
25
Setting Multiple Attributes
Map.setCenter(GeoCoordinate point, Animation animation, double level, float
orientation, float tilt) is an extended API provided for changing one or more attributes
at the same time. The zoom level, tilt and perspective can be preserved and unchanged using
Map.MOVE_PRESERVE_ZOOM_LEVEL, Map.MOVE_PRESERVE_ORIENTATION, Map.MOVE_PRESERVE_TILT
respectively.
// Move to Vancouver using a bow animation, zoom level 17, 180
//degree orientation and 45 degree tilt.
map.setCenter(new GeoCoordinate(49.0,-123.0),
Map.Animation.BOW, 17.0d, 180, 45);
Map Projection Mode
By default, the map is set to a globe projection mode. You can change it to use Mercator projection by calling
setProjectionMode(Projection). For example:
map.setProjectionMode(Map.Projection.MERCATOR);
It may be useful to set the projection modes when you need to predictably display certain types of map
information, such as custom raster tiles.
Figure 2: Globe Projection Figure 3: Mercator Projection
MapState and Listening for Map Transform Events
MapState is an object that is a composite of the tilt, orientation, zoom level and center map attributes. Your
application can listen for updates to the MapState by using an OnTransformListener.
Map transform events are triggered by any operation that causes the MapState to change. These operations
include user interaction (for example, map gestures) as well as programmatic calls to the Map (for example,
map.setCenter(GeoCoordinate, MapAnimation)). The onMapTransformStart() method is called
before MapState begins to change, while the onMapTransformEnd(MapState) method is called after the
MapState returns to a steady value. Because of this, there can be a significant amount of time between the
two callbacks in cases such as animated map movement events and continuous user interaction.
The following code is an example of registering an OnTransformListener to listen for map transform
events:
map.addTransformListener(new OnTransformListener() {
HERE Android SDK Developer's Guide
User Guide
26
@Override
public void onMapTransformStart() {
// map transform is about to start
}
@Override
public void onMapTransformEnd(MapState mapState) {
// map transform has come to an end
}
});
If you need to update UI widgets as the MapState changes between these two callbacks, the recommended
approach is to trigger a Runnable when onMapTransformStart() is called, which periodically checks (at
no more than 30 frames per second) the current map state via map.getMapState() and updates the UI
widgets accordingly. This Runnable can then be canceled upon a call to onMapTransformEnd(MapState).
An Android Handler can be used to trigger these Runnable objects.
Note: Do not update UI widgets in MapRenderListener.onPostDraw(boolean, long), as this
method is frequently called.
Pedestrian Features
By default, icons that indicate pedestrian access features (such as stairs or escalators)
are not displayed on the map. To display a pedestrian feature on the map view, call the
Map.setPedestrianFeaturesVisible(EnumSet) method with the desired set of PedestrianFeature.
To find out whether a feature type is enabled, call the Map.getPedestrianFeaturesVisible() method.
Figure 4: Pedestrian Feature Icons
Safety Spots
Speed cameras and traffic-light cameras are also known as safety spots in the HERE SDK. Similar to
pedestrian features, icons that indicate safety spots are not displayed on the map by default. To display
safety spots, set the Map.setSafetySpotsVisible(boolean) to true. To find out whether safety spots
are enabled, call the areSafetySpotsVisible() method.
Individual safety spots icons can be selected on the map by using SafetySpotObject, which is a subclass
of MapProxyObject. Each SafetySpotObject contains a reference to a corresponding SafetySpotInfo
HERE Android SDK Developer's Guide
User Guide
27
object that contains the location and other properties about the camera. For more information on selecting
map proxy objects, refer to Objects and Interaction on page 34.
Map Gestures
The MapGesture interface encapsulates all user interactions and touch gestures supported by the
HERE Android SDK. The MapGesture associated with a particular fragment can be retrieved from
MapFragment.getMapGesture(). The default behavior of the map for each gesture type may be used as-
is, supplemented, or replaced entirely. The following table is a summary of the available gestures and their
default behavior.
To zoom the map in a fixed amount, tap the screen twice with one finger
To zoom out a fixed amount, tap the screen with two fingers
To move the map, press and hold one finger to the screen, and move it in any direction.
To tilt the map, press and hold two fingers to the screen, and move them in a vertical direction. No behavior is
predefined for other directions.
To pan the map with momentum, press and swipe one finger on the screen. The map continues to move in the
same direction, and gradually slows to a stop.
To zoom in or out continuously, press and hold two fingers to the screen, and increase or decrease the
distance between them
HERE Android SDK Developer's Guide
User Guide
28
To rotate the map, press and hold two fingers to the screen, and rotate them together in a circle
Tap the screen with one finger. This gesture does not have a predefined map action.
Press and hold one finger to the screen. This gesture does not have a predefined map action.
The OnGestureListener Interface
The OnGestureListener interface represents a listener to provide notification upon completion of a Map
gesture event such as a single tap on a map.
For example, you can create a new OnGestureListener(), as illustrated below.
// Map gesture listener
private class MyOnGestureListener implements OnGestureListener {
@Override
public void onPanStart() {
}
@Override
public void onPanEnd() {
}
@Override
public void onMultiFingerManipulationStart() {
}
@Override
public void onMultiFingerManipulationEnd() {
}
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
return false;
}
@Override
public boolean onTapEvent(PointF p) {
return false;
}
@Override
public boolean onDoubleTapEvent(PointF p) {
return false;
HERE Android SDK Developer's Guide
User Guide
29
}
@Override
public void onPinchLocked() {
}
@Override
public boolean onPinchZoomEvent(float scaleFactor, PointF p) {
return false;
}
@Override
public void onRotateLocked() {
}
@Override
public boolean onRotateEvent(float rotateAngle) {
return false;
}
@Override
public boolean onTiltEvent(float angle) {
return false;
}
@Override
public boolean onLongPressEvent(PointF p) {
return false;
}
@Override
public void onLongPressRelease() {
}
@Override
public boolean onTwoFingerTapEvent(PointF p) {
return false;
}
}
Note: The OnGestureListener methods that mention "rotate" and "tilt", such as
onRotateEvent(float), are not supported. They are only defined here to maintain compatibility
with the Premium Edition of the HERE SDK.
To add the listener to your map, include a call to addOnGestureListener(OnGestureListener) after
the map fragment has been successfully initialized as follows:
...
mapFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// map fragment has been successfully initialized
mapFragment.getMapGesture().addOnGestureListener(new MyOnGestureListener());
}
}
});
...
Note: After you add an OnGestureListener to an application, remember to call
removeOnGestureListener(OnGestureListener) when you no longer need to listen for map
events to free up application resources.
The default implementation of a OnGestureListener does not affect any of the standard HERE SDK touch
gestures. Each method within the MyOnGestureListener class returns a value of false, which stipulates
HERE Android SDK Developer's Guide
User Guide
30
that the application should not override the underlying action that a device performs upon detecting a
particular gesture.
If you want to customize an action that your application performs upon detection of a particular gesture,
you must include appropriate commands within a relevant method of the MyOnGestureListener
class and return a value of true to override the default action, as illustrated below with revisions to the
onTwoFingerTapEvent(PointF) method.
@Override
public boolean onTwoFingerTapEvent(PointF p) {
// Reset the map view
double level = map.getMinZoomLevel() + map.getMaxZoomLevel() / 2;
map.setCenter(new GeoCoordinate(49.196261, -123.004773),
Map.Animation.NONE);
map.setZoomLevel(level);
return true;
}
Note: Since the onTapEvent(PointF) event is always triggered before the
onMapObjectsSelected(List<ViewObject>) event, you can leverage this behavior to implement
your own object selection logic. While implementing object selection, it is recommended that you
use both Map.getSelectedObject(PointF) and Map.getSelectedObject(ViewRect) and
combine the results, so that the user's tap input is interpreted over a larger area, rather than only a
single point.
After the revision, the basic application responds to each two-finger tap gesture by returning to its initial
view (the view displayed upon application launch). Other touch gestures continue to trigger standard HERE
SDK actions.
Map Schemes
The HERE Android SDK provides a variety of map appearances for your application to choose from, these
appearances are otherwise known as map schemes.
Map.Scheme defines visualization types that the HERE map service supports. There is a variety of map
schemes available that can be used, based on the specific use case:
Explore - Normal, Terrain, Pedestrian
Overlays - Grey, Transit, Reduced, Traffic
Navigation - Car Navigation, Car Navigation with Traffic, Maneuver
You can set a desired scheme by making a call to the Map.setMapScheme(String) method.
HERE Android SDK Developer's Guide
User Guide
31
Examples of Map Scheme
All available schemes are defined as constant strings in the Map.Scheme class. The following are examples
of string values that you can use to set the map scheme in your application:
Figure 5: Scheme.NORMAL_DAY Figure 6: Scheme.SATELLITE_DAY
Figure 7: Scheme.HYBRID_DAY Figure 8: Scheme.TERRAIN_DAY
Note: Your application also needs to switch to one of the following schemes if you enable traffic
information with Map.setTrafficInfoVisible(true). These map schemes are otherwise
identical to their non-traffic counterparts.
Scheme.HYBRID_TRAFFIC_DAY
Scheme.HYBRID_TRAFFIC_NIGHT
Scheme.NORMAL_TRAFFIC_DAY
Scheme.NORMAL_TRAFFIC_NIGHT
HERE Android SDK Developer's Guide
User Guide
32
Note: In addition to the preceding schemes, Scheme.SATELLITE_NIGHT is also available. It is
similar to Scheme.SATELLITE_DAY, but the color of the sky is different when the map is tilted.
Figure 9: Scheme.HYBRID_DAY_TRANSIT Figure 10: Scheme.NORMAL_NIGHT_TRANSIT
Figure 11: Scheme.NORMAL_NIGHT Figure 12: Scheme.NORMAL_DAY_TRANSIT
Navigation Schemes
The HERE SDK also offers the following schemes to be used with navigation:
Scheme.CARNAV_DAY
Scheme.CARNAV_NIGHT
Scheme.CARNAV_HYBRID_DAY
Scheme.CARNAV_HYBRID_NIGHT
Scheme.CARNAV_TRAFFIC_DAY
Scheme.CARNAV_TRAFFIC_NIGHT
Scheme.CARNAV_TRAFFIC_HYBRID_DAY
Scheme.CARNAV_TRAFFIC_HYBRID_NIGHT
HERE Android SDK Developer's Guide
User Guide
33
Scheme.CARNAV_DAY_GREY
Scheme.CARNAV_NIGHT_GREY
Scheme.PEDESTRIAN_DAY
Scheme.PEDESTRIAN_NIGHT
Scheme.PEDESTRIAN_DAY_HYBRID
Scheme.PEDESTRIAN_NIGHT_HYBRID
Scheme.TRUCKNAV_DAY
Scheme.TRUCKNAV_NIGHT
Scheme.TRUCKNAV_HYBRID_DAY
Scheme.TRUCKNAV_HYBRID_NIGHT
If you are using a pedestrian navigation scheme, it is recommended that you also enable the pedestrian
features using the Map class. See Maps on page 22 for more details.
Note: The HERE SDK does not automatically switch map schemes during navigation mode. Before
starting car or pedestrian navigation, be sure to save the current map scheme and switch to the
appropriate navigation map scheme. When navigation has completed, your application code should
switch back to the previously saved scheme.
For more information on how to perform navigation operations, see Turn-by-Turn Navigation for Walking and
Driving on page 145.
Setting a Map Scheme
The following example demonstrates how to retrieve available map schemes and change the current map
scheme:
// Array containing string values of all available map schemes
List<String> schemes = map.getMapSchemes();
// Assume to select the 2nd map scheme in the available list
map.setMapScheme(schemes.get(1));
Listening for MapScheme Change Events
Applications can listen for map scheme change events by way of the Map.OnSchemeChangedListener:
map.addSchemeChangedListener(new OnSchemeChangedListener() {
@Override
public void onMapSchemeChanged(String mapScheme) {
// react to map scheme change here
}
});
For information on the fleet map scheme, see Mobile Asset Management on page 63.
MapEngine Class
MapEngine is a singleton class used to manage active mapping resources for use in applications developed
with the HERE SDK. MapEngine must be initialized before Map and map-related objects, such as MapMarker
and Places, can be instantiated and retrieved from the API. A runtime exception occurs if MapEngine is not
properly initialized before map-related objects are used.
HERE Android SDK Developer's Guide
User Guide
34
Initialization
MapEngine must be initialized before it can be used. MapEngine is automatically initialized for your
application by using MapFragment. MapFragment is a fragment class that applications can use as an UI
module in an activity for map display. However, if your application does not use MapFragment classes, then
the application should initialize the MapEngine directly before using any HERE APIs. You can do this by
calling MapEngine.init(ApplicationContext, OnEngineInitListener) as shown below:
MapEngine mapEngine = MapEngine.getInstance();
ApplicationContext appContext = new ApplicationContext(context);
mapEngine.init(appContext, new OnEngineInitListener() {
@Override
public void onEngineInitializatonCompleted(Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// Post initialization code goes here
} else {
// handle factory initialization failure
}
}
});
If map engine initialization is in progress or has failed, calling any other HERE SDK APIs fails because invalid
objects cannot be created. To avoid this problem, check for MapEngine.isInitialized() in your app
lifecycle callbacks. For example, the following example avoids problems with using the PositionManager
before an instance can be properly created:
public void onDestroy()
{
//Set initComplete using MapEngine.isInitialized()
if (initComplete) {
PositioningManager.getInstance().removeListener(this);
}
super.onDestroy();
}
For examples of typical scenarios using the MapFragment that automatically initializes the MapEngine, see
Maps on page 22.
Objects and Interaction
You can select ViewObject objects by using a single tap gesture. To enable
this in your code, create an OnGestureListener object and pass it to
MapFragment.getMapGesture().addOnGestureListener(OnGestureListener). When a single tap
occurs, the listener receives the onTapEvent(PointF) callback, and if that event is not handled, then the
listener receives the onMapObjectsSelected(List<ViewObject>) callback. The application can then
define what to do with the selected ViewObject.
Types of ViewObject objects that are selectable are defined within the ViewObject.Type enumeration,
which includes:
USER_OBJECT - an object that the application adds to a map with a MapObject base class
(MapPolygon for example).
PROXY_OBJECT - an object that is added automatically to a map with a MapProxyObject base class.
A proxy object may contain special information about the object, depending on the type (for example,
HERE Android SDK Developer's Guide
User Guide
35
TransitStopObject may provide transit stop-related information), but it cannot be created or
modified.
UNKNOWN_OBJECT - a selectable map object that is not a USER_OBJECT nor a PROXY_OBJECT
The ViewObject Abstract Class
The ViewObject abstract class represents the base implementation for all objects that are selectable on a
MapView or MapFragment. The MapFragment features user-selectable objects.
Sub-classes of the ViewObject class include MapObject and MapProxyObject .
MapObject and Geo Objects
MapObject represents an abstract class for all map-related objects that can be added on a Map. The
subclasses of this abstract class include:
MapContainer
MapCircle
MapPolyline
MapPolygon
MapRoute
MapMarker
MapLocalModel
MapGeoModel
MapLabeledMarker
MapScreenMarker
These objects can be created by calling the appropriate constructor methods. In some cases, a geo object
is required in the constructor. Geo objects (for example, GeoPolyline and GeoPolygon) are geographical
data representations that act as models to MapObjects, which act as views. Unlike map objects, geo objects
cannot be added directly to a Map. For more information on geo objects and creating map objects, see the
API Reference.
The following code snippet demonstrates how to create a MapPolyline and a GeoPolyline object:
List<GeoCoordinate> testPoints = new ArrayList<GeoCoordinate>();
testPoints.add(new GeoCoordinate(49.163, -123.137766, 10));
testPoints.add(new GeoCoordinate(59.163, -123.137766, 10));
testPoints.add(new GeoCoordinate(60.163, -123.137766, 10));
GeoPolyline polyline = new GeoPolyline(testPoints);
MapPolyline mapPolyline = new MapPolyline(polyline);
To add a MapObject to the map, use Map.addMapObject(MapObject) or
Map.addMapObjects(List<MapObject>). You can use the setOverlayType(MapOverlayType)
method to set the display layer for the map object. By default, map objects are assigned to the foreground.
Note: For use cases where a map object needs to be viewable in 3D space, use MapLocalModel or
MapGeoModel. Other map objects are not guaranteed to support 3D.
HERE Android SDK Developer's Guide
User Guide
36
MapContainer
You can use MapContainer as a container for other MapObject instances. Map containers
determine the stacking order of objects displayed on a map. To add a map object, call the
MapContainer.addMapObject(MapObject) method.
Note: MapRoute and MapContainer cannot be added to a MapContainer.
Note: If a map object is a part of a MapContainer, it has the same MapOverlayType as the map
container.
MapCircle
A MapCircle represents a type of MapObject in the shape of a circle, with an assigned radius distance
and a GeoCoordinate center. It can be created by calling the constructor MapCircle(double radius,
GeoCoordinate center).
Figure 13: A MapCircle object
MapPolyline
A MapPolyline is a MapObject in the shape of a polyline with anchor points at any number of
GeoCoordinate points. It can be created via a GeoPolyline object, which can be created by calling the
GeoPolyline(List<GeoCoordinate> points) constructor.
HERE Android SDK Developer's Guide
User Guide
37
Note: A MapPolyline or MapPolygon can only contain up to 65536 vertices.
Figure 14: A MapPolyline object
MapPolygon
A MapPolygon is a MapObject in the shape of a polygon. In contrast with a MapPolyline, it is assumed
that the last coordinate in the line's path is connected to the first coordinate, thereby constructing an
enclosed geometry. A MapPolygon may define separate border and fill colors. To create a MapPolygon,
use the constructor MapPolygon(GeoPolygon polygon). A GeoPolygon can be created by calling
GeoPolygon(List<GeoCoordinate> points).
Figure 15: A MapPolygon object
MapRoute
A MapRoute is a MapObject that displays a calculated route on a map. For more information on MapRoute,
see Routing .
HERE Android SDK Developer's Guide
User Guide
38
MapMarker
A MapMarker is a MapObject that displays an icon at a geographical position on a map. You can create a
MapMarker with your own custom icon by calling MapMarker(GeoCoordinate, Image).
Figure 16: A MapMarker object
MapMarker instances are always placed on top of other map objects. Refer to the diagram below for more
information about z-index ordering for multiple map markers.
Figure 17: MapMarker order
You can set MapMarker to be draggable by using the MapMarker.setDraggable(true) method. To listen
for drag events, such as marker position changes, use MapMarker.OnDragListener.
MapLabeledMarker
A MapLabeledMarker is a different type of marker object that avoids overlapping with other icons and text
on the map. By default, the visual appearance of a MapLabeledMarker is similar to a point of interest. You
HERE Android SDK Developer's Guide
User Guide
39
can choose a preset category icon (for example, IconCategory.ZOO) or set your own Image as the marker
icon.
Figure 18: A MapLabeledMarker object
Unlike MapMarker, setting the label text to a MapLabeledMarker does not require enabling an
info bubble. You can set the marker label text by providing a language and a localized string to the
MapLabeledMarker.setLabelText(String, String) method. The localized text in the language that
matches the current Map.getMapDisplayLanguage(), if available, is displayed. Otherwise, the first-added
localized text is displayed.
Note: Although a MapLabeledMarker is visually similar to a point of interest, its overlay type is set
to FOREGROUND_OVERLAY by default.
MapLocalModel
A MapLocalModel is an arbitrary 3D map object that is drawn using a local coordinate (as opposed to a
geocoordinate) mesh. You can create a custom MapLocalModel by calling MapLocalModel(), and setting
the model mesh, texture, orientation, and geographical location before adding it to the map. For example:
FloatBuffer buff = FloatBuffer.allocate(12); // Two triangles
buff.put(0- delta);
buff.put(0- delta);
buff.put(1.f);
buff.put(0 + delta);
buff.put(0 - delta);
buff.put(1.f);
buff.put(0 - delta);
buff.put(0 + delta);
buff.put(1.f);
buff.put(0 + delta);
buff.put(0 + delta);
buff.put(1.f);
// Two triangles to generate the rectangle. Both front and back face
IntBuffer vertIndicieBuffer = IntBuffer.allocate(12);
vertIndicieBuffer.put(0);
vertIndicieBuffer.put(2);
vertIndicieBuffer.put(1);
vertIndicieBuffer.put(2);
vertIndicieBuffer.put(3);
HERE Android SDK Developer's Guide
User Guide
40
vertIndicieBuffer.put(1);
vertIndicieBuffer.put(0);
vertIndicieBuffer.put(1);
vertIndicieBuffer.put(2);
vertIndicieBuffer.put(1);
vertIndicieBuffer.put(3);
vertIndicieBuffer.put(2);
// Texture coordinates
FloatBuffer textCoordBuffer = FloatBuffer.allocate(8);
textCoordBuffer.put(0.f);
textCoordBuffer.put(0.f);
textCoordBuffer.put(1.f);
textCoordBuffer.put(0.f);
textCoordBuffer.put(0.f);
textCoordBuffer.put(1.f);
textCoordBuffer.put(1.f);
textCoordBuffer.put(1.f);
LocalMesh myMesh = new LocalMesh();
myMesh.setVertices(buff);
myMesh.setVertexIndices(vertIndicieBuffer);
myMesh.setTextureCoordinates(textCoordBuffer);
MapLocalModel myObject = new MapLocalModel();
myObject.setMesh(myMesh); //a LocalMesh object
myObject.setTexture(myImage); //an Image object
myObject.setAnchor(myLocation); //a GeoCoordinate object
myObject.setScale(20.0f);
myObject.setDynamicScalingEnabled(true);
myObject.setYaw(45.0f);
map.addMapObject(myObject);
While translating the 3D model mesh to the map, a unit of 1.0f represents 1 meter in the real world. For
example, a Vector3f(100,200,300) represents an offset of +100 meters in the x-axis (East), +200 meters
in the y-axis (North), and +300 meters in the z-axis direction (Up). You can further control the size of the 3D
model mesh by setting a scaling factor with the setScale() method.
Figure 19: A MapLocalModel object
HERE Android SDK Developer's Guide
User Guide
41
Aside from setting a texture, a MapLocalModel can also be customized by setting its material and lighting
using the Phong reflection model. For example, the following code sets the ambient color, diffuse color, and
light source to the MapLocalModel.
// This light shines from above in the Z axis
DirectionalLight light = new DirectionalLight(new Vector3f(0, 0.5f, 1));
m_model.addLight(light);
// Give this a default color
PhongMaterial mat = new PhongMaterial();
mat.setAmbientColor(0xffffffff);
mat.setDiffuseColor(0x00000000);
m_model.setMaterial(mat);
Note:
As 3D objects consume large amounts of memory, avoid using MapLocalModel and
MapGeoModel to replace 2D map markers. Two examples of recommended uses of these classes
are adding a few 3D structures to the map, or showing a realistic car model during guidance.
If you use MapLocalModel to create a two-dimensional object, and if you use an anchor with an
undefined or zero altitude value, there is a known rendering issue with OpenGL where parts of
the object may conflict with the map layer, causing the object to flicker. To get around this issue,
use a z-coordinate offset that is greater than 0. For example, you can use a small floating point
number such as, 0.001, so that the user is unable to distinguish between the object's altitude
and the map.
MapGeoModel
A MapGeoModel is an arbitrary 3D map object that is drawn using geocoordinate vertices. You can create
a MapGeoModel by calling its constructor and setting a list of geocoordinates, a list indicating the vertex
order, a list of UV coordinates, and a texture Image. For example:
List<GeoCoordinate> myLocations = Arrays.asList(
new GeoCoordinate(37.783409, -122.439473),
new GeoCoordinate(37.785444, -122.424667),
new GeoCoordinate(37.774149, -122.429345));
// vertices must be specified in a counter-clockwise manner
IntBuffer vertIndicieBuffer = IntBuffer.allocate(3);
vertIndicieBuffer.put(0);
vertIndicieBuffer.put(2);
vertIndicieBuffer.put(1);
FloatBuffer textCoordBuffer = FloatBuffer.allocate(6);
textCoordBuffer.put(0.5f);
textCoordBuffer.put(0.5f);
textCoordBuffer.put(0.5f);
textCoordBuffer.put(0.5f);
textCoordBuffer.put(0.5f);
textCoordBuffer.put(0.5f);
GeoMesh meshy = new GeoMesh();
meshy.setVertices(myLocations);
meshy.setVertexIndices(vertIndicieBuffer);
meshy.setTextureCoordinates(textCoordBuffer);
MapGeoModel myGeoModel = new MapGeoModel();
myGeoModel.setMesh(meshy);
myGeoModel.setTexture(myTexture);
HERE Android SDK Developer's Guide
User Guide
42
As with MapLocalModel, you can also set the lighting and color properties for a MapGeoModel using the
addLight(DirectionalLight) and setMaterial(PhongMaterial) methods.
Figure 20: A MapGeoModel object
MapCartoMarker
Points of interest are represented by instances of the MapCartoMarker proxy object class.
Figure 21: Examples of Points of Interest
In the above screenshot, there are four points of interests: two shops, one restaurant, and one car
dealership. Each of these points of interest may be selected by either tapping on the map.
HERE Android SDK Developer's Guide
User Guide
43
The following is an example of how to retrieve point of interest information from a MapCartoMarker:
switch (proxyObj.getType()) {
case MAP_CARTO_MARKER:
MapCartoMarker mapCartoMarker =
(MapCartoMarker) proxyObj;
Location location = mapCartoMarker.getLocation();
String placeName =
location.getInfo().getField(Field.PLACE_NAME);
String placeCategory =
location.getInfo().getField(Field.PLACE_CATEGORY);
String placePhone =
location.getInfo().getField(Field.PLACE_PHONE_NUMBER);
//...
break;
//...
default:
Log.d(TAG, "ProxyObject.getType() unknown");
}
You can extract further Point of Interest (POI) information from a cartographic marker by using the Places
feature in the HERE SDK, since cartographic markers contain identifying data that can be passed to a Place
search request. For example:
if (mapCartoMarker.getLocation() != null &&
mapCartoMarker.getLocation().getInfo() != null)
{
LocationInfo info = mapCartoMarker.getLocation().getInfo();
String foreignSource = info.getField(Field.FOREIGN_ID_SOURCE);
String foreignId = info.getField(Field.FOREIGN_ID);
PlaceRequest request = new PlaceRequest(foreignSource, foreignId);
request.execute(new ResultListener<Place>() {
@Override
public void onCompleted(Place data, ErrorCode error) {
if (error == ErrorCode.NONE) {
//extract Place data
}
}
});
}
For more information about this feature, see the External References section.
User Interactions with MapObject
This section provides an example on handling MapObject tap events. In the following code:
addMapObject() adds the object on the Map.
List<ViewObject> holds the objects that have been selected in this tap event. By looping through this
list of objects, your code can find the MapObject that should respond to this tap event.
Note: The onMapObjectsSelected(List) callback is triggered after the onTapEvent(PointF)
callback. For more information on this, refer to Map Gestures on page 27
// Create a custom marker image
com.here.android.mpa.common.Image myImage =
new com.here.android.mpa.common.Image();
try {
HERE Android SDK Developer's Guide
User Guide
44
myImage.setImageResource(R.drawable.my_png);
} catch (IOException e) {
finish();
}
// Create the MapMarker
MapMarker myMapMarker =
new MapMarker(new GeoCoordinate(LAT, LNG), myImage);
map.addMapObject(myMapMarker);
...
// Create a gesture listener and add it to the MapFragment
MapGesture.OnGestureListener listener =
new MapGesture.OnGestureListener.OnGestureListenerAdapter() {
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject viewObj : objects) {
if (viewObj.getBaseType() == ViewObject.Type.USER_OBJECT) {
if (((MapObject)viewObj).getType() == MapObject.Type.MARKER) {
// At this point we have the originally added
// map marker, so we can do something with it
// (like change the visibility, or more
// marker-specific actions)
((MapObject)viewObj).setVisible(false);
}
}
}
// return false to allow the map to handle this callback also
return false;
}
...
};
The MapOverlay Class
The MapOverlay class represents a special type of map object that does not inherit from the MapObject
base class. Instead, it provides a way for any Android View to be displayed at a fixed geographical location on
the map.
You can add content to a map overlay by using the MapOverlay(View, GeoCoordinate) constructor.
If complex view contents are required, such as a view with subviews of its own, the content should be fully
initialized before adding it to the map overlay.
Due to the extra performance cost of Android views, it is recommended that the MapOverlay only be used
in situations where the additional functionality provided by a View, such as a button, is needed. If the map
object only needs to display a static image, use MapMarker.
Note: MapOverlay does not inherit from MapObject, but overlays are returned as a MapMarker
from a a tap gesture callback by default. To avoid this behavior and these substitute markers, the
appropriate gesture handling must be implemented either in a MapOverlay subclass, or in a custom
view that is added as a subview to a standard MapOverlay.
The following code shows how to use a simple button in a MapOverlay.
private Button button;
private void onMapFragmentInitializationCompleted() {
// retrieve a reference of the map from the map fragment
map = mapFragment.getMap();
// Set the map center coordinate to the Vancouver region (no animation)
HERE Android SDK Developer's Guide
User Guide
45
map.setCenter(new GeoCoordinate(49.196261, -123.004773, 0.0),
Map.Animation.NONE);
// Set the map zoom level to the average between min and max (no
// animation)
map.setZoomLevel((map.getMaxZoomLevel() + map.getMinZoomLevel()) / 2);
// create the button
button = new Button(this);
button.setText("TEST");
// create overlay and add it to the map
map.addMapOverlay(
new MapOverlay(button,
new GeoCoordinate(37.77493, -122.419416, 0.0)));
}
Handling MapProxyObject objects
The following code demonstrates how to handle tap events on a MapProxyObject:
The onMapObjectsSelected event of the OnGestureListener listens to object selected. For more
information on OnGestureListener, refer to Map Gestures on page 27.
If the selected object is a PROXY_OBJECT then you can safely cast the ViewObject into a
MapProxyObject.
If the selected object is a USER_OBJECT then you need to find the object using the hash map; refer to
the preceding example.
private MapGesture.OnGestureListener listener =
new MapGesture.OnGestureListener.OnGestureListenerAdapter() {
...
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject obj : objects) {
switch (obj.getBaseType()) {
case PROXY_OBJECT:
MapProxyObject proxyObj = (MapProxyObject) obj;
switch (proxyObj.getType()) {
case TRANSIT_ACCESS:
TransitAccessObject transitAccessObj =
(TransitAccessObject) proxyObj;
Log.d(TAG, "Found a TransitAccessObject");
break;
case TRANSIT_LINE:
TransitLineObject transitLineObj =
(TransitLineObject) proxyObj;
Log.d(TAG, "Found a TransitLineObject");
break;
case TRANSIT_STOP:
TransitStopObject transitStopObj =
(TransitStopObject) proxyObj;
Log.d(TAG, "Found a TransitStopObject");
break;
default:
Log.d(TAG, "ProxyObject.getType() unknown");
}
break;
// User objects are more likely to be handled
// as in the previous example
case USER_OBJECT:
default:
Log.d(TAG,
"ViewObject.getBaseType() is USER_OBJECT or unknown");
break;
}
HERE Android SDK Developer's Guide
User Guide
46
}
return true;
}
...
};
Marker Clustering
You can use marker clustering to reduce the visual overload caused by too much markers being displayed on
the map at once. With this feature, markers that are close together are automatically replaced by numbered
cluster markers to indicate that multiple map markers are represented.
Figure 22: Cluster Markers
Showing Cluster Markers
You can enable cluster markers on a map by using a ClusterLayer and adding map markers to it. All
markers that are on a layer are automatically clustered based on a grid-based clustering algorithm that
depends on the map zoom level.
The following steps demonstrates how to use the ClusterLayer class:
1. Create map markers as normal:
MapMarker mm = new MapMarker();
mm.setIcon(myImage);
mm.setCoordinate(new GeoCoordinate(52.53,13.23));
2. Create a ClusterLayer object.
ClusterLayer cl = new ClusterLayer();
HERE Android SDK Developer's Guide
User Guide
47
3. Add markers to the cluster layer, instead of the map directly. You can also add a Collection of
MapMarker instead of setting just adding a single marker.
cl.addMarker(mm);
4. Add the cluster layer to the map.
mMap.addClusterLayer(cl);
Note: The order of these two steps is not important. You can also add the cluster layer to the
map first and add markers to the cluster layer afterwards.
5. To remove a marker or collection or markers from the cluster layer again, call:
cl.removeMarker(mm);
You can also retrieve all markers on a cluster layer with the ClusterLayer.getMarkers()
method. This is useful in the case where you would like to remove all markers by using the
removeMarkers(Collection<MapMarker>) method.
Theming
You can customize clusters by assigning a ClusterTheme object to the ClusterLayer. Every theme
consists of several styles, where a cluster style defines the look of marker cluster objects at a particular
density. Cluster density is the amount of markers that is being represented by a cluster.
Figure 23: Marker Cluster with Density of 7
There are three available cluster styles that you can use with a ClusterTheme:
Default cluster style - the predefined markers behavior. This is the default style that is used if you do not
set a theme. It is also used for ranges that are not covered by your own theme.
BasicClusterStyle - similar to the default style, but you can change the fill color, text color, and
stroke color for the markers.
ImageClusterStyle - use your own bitmap image as a marker.
To set a style, use the setStyleForDensityRange(int, int, ClusterStyle) or
setStyleForDensityRange(ClusterDensityRange, ClusterStyle) methods in ClusterTheme. For
example, if you want red for all clusters between density 10 to 19, and green for 20 to 49, and the default
blue for all other cases, you can use BasicClusterStyle as follows:
HERE Android SDK Developer's Guide
User Guide
48
1. Create a style with a red circle and a style with a green one:
BasicClusterStyle redStyle = new BasicClusterStyle();
redStyle.setFillColor(Color.RED);
BasicClusterStyle greenStyle = new BasicClusterStyle();
greenStyle.setFillColor(Color.GREEN);
2. Create a new theme and add those styles to the theme with defining the density ranges they should be
used for:
ClusterTheme theme = new ClusterTheme();
theme.setStyleForDensityRange(10, 19, redStyle);
theme.setStyleForDensityRange(20, 49, greenStyle);
Instead of setting the integer values directly, you can also make use of the ClusterDensityRange
class.
Note: Do not overlap density ranges. Overlapping ranges causes InvalidArgumentException.
3. Finally, add this theme to the cluster layer you use:
cl.setTheme(theme);
To use your own image as a cluster icon, set an Image to an ImageClusterStyle instance before setting
the style to the cluster theme. For example:
Image img = new Image();
try {
img.setImageResource(R.drawable.banner);
} catch (IOException e) {
e.printStackTrace();
}
ImageClusterStyle imageCluster = new ImageClusterStyle(img);
ClusterTheme theme = new ClusterTheme();
theme.setStyleForDensityRange(2, 9, imageCluster);
cl.setTheme(theme);
Although you can only set one theme per layer, you can mix styles for different densities in a single theme.
For example, you can set a BasicClusterStyle from density of 10 to 19 and an ImageClusterStyle
from 20 to 30. The default theme applies for all other densities that are not covered by the custom themes.
Cluster Marker Events
Cluster markers are similar to normal markers on the map. You can also use map object gesture listeners in a
similar manner as normal map markers. For example:
1. Add a gesture listener to the map via:
mMapFragment.getMapGesture().addOnGestureListener(mMyGestureHandler);
2. Next, listen for
public boolean onMapObjectsSelected(List<ViewObject> viewObjects)
to get the map click event.
3. Iterate over the ViewObjects and check for type PROXY_OBJECT and sub-type CLUSTER_MARKER.
Alternatively, you can also use the instanceof keyword.
@Override
public boolean onMapObjectsSelected(List<ViewObject> viewObjects) {
HERE Android SDK Developer's Guide
User Guide
49
for (ViewObject obj : viewObjects){
if (obj.getBaseType() == ViewObject.Type.PROXY_OBJECT){
if (proxyObj.getType() == MapProxyObject.Type.CLUSTER_MARKER) {
ClusterViewObject cv = (ClusterViewObject) proxyObj;
Log.i(TAG, "Cluster clicked: markers#"+cv.getMarkers().size());
return true;
}
}
return false;
}
Working with Clusters
The HERE SDK also provides a few other ways for you to interact with marker clusters. You can get all markers
inside one specific cluster by using the ClusterViewObject, which is a proxy object representing a cluster.
For example:
Collection<MapMarker> ClusterViewObject.getMarkers()
You can also retrieve the bounding box around all markers that are in a cluster marker by calling the
following:
BoundingBox ClusterViewObject.getBoundingBox();
Traffic Information
Traffic information can be displayed on the Map, depending on traffic data availability, by using
Map.setTrafficInfoVisible(true) and setting the map to a traffic-enabled map scheme. Traffic
visualization requires a network data connection to download real time traffic information. However, traffic
information may continue to be displayed thereafter without a connection until the traffic events expire or
the visibility is toggled.
The current traffic-enabled map schemes are:
Map.Scheme.HYBRID_TRAFFIC_DAY
Map.Scheme.HYBRID_TRAFFIC_NIGHT
Map.Scheme.NORMAL_TRAFFIC_DAY
Map.Scheme.NORMAL_TRAFFIC_NIGHT
Map.Scheme.CARNAV_TRAFFIC_DAY
Map.Scheme.CARNAV_TRAFFIC_NIGHT
Map.Scheme.CARNAV_TRAFFIC_HYBRID_DAY
Map.Scheme.CARNAV_TRAFFIC_HYBRID_NIGHT
HERE Android SDK Developer's Guide
User Guide
50
The following figure shows a sample traffic visualization.
Figure 24: Traffic information with color-coded lines
Traffic flow lines are color coded as follows:
Green Normal
Amber High
Red Very High
Black Blocking
Controlling Traffic Display
You can further control traffic display by calling Map.getMapTrafficLayer() and using the
MapTrafficLayer object.
With MapTrafficLayer, you can individually disable Traffic Flow, Traffic Incidents, or On-Route Traffic, as
well as filter traffic that is displayed according to the minimal severity level.
For example, you can set the map to only display traffic flow lines that are "very high" (red) or
"blocking" (black) by performing the following:
MapTrafficLayer traffic = map.getMapTrafficLayer();
//set the minimum displayed traffic level
traffic.setDisplayFilter(TrafficEvent.Severity.VERY_HIGH);
Controlling Traffic Updates
By default, traffic events are automatically loaded inside the viewport when traffic is
enabled. You can also explicitly fetch traffic around a given set of geocoordinates by using
TrafficUpdater.request(GeoCoordinate, int, Listener).
HERE Android SDK Developer's Guide
User Guide
51
To completely customize the traffic-updating implementation in your app, first turn off automatic traffic
updates via the Map.disableTrafficAutoUpdate() method, then use the above mentioned method to
fetch traffic only where it is required.
Note: Since downloading and decoding traffic data can be computationally costly, do not fetch
traffic for the same area too frequently. For example, if you are fetching traffic only around the user
position, do not fetch more frequently than once a minute. For lower end devices, fetch data in even
less frequent intervals, such as once every five minutes.
Selecting Traffic Objects and Events
Traffic events are selectable through map gestures and
OnGestureListener.onMapObjectsSelected(List<ViewObject>). A user selectable
TrafficEventObject contains live traffic event information and is presented on the map in different
forms. The following figures illustrate three examples:
Figure 25: TrafficEventObject example:
Roadwork
Figure 26: TrafficEventObject example:
Accident
Figure 27: TrafficEventObject example:
Road Closed
To acquire information about a tapped TrafficEventObject (see MapObjects), use
onMapObjectsSelected(List<ViewObject>) as in the following:
private MapGesture.OnGestureListener listener = new MapGesture.OnGestureListener() {
...
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject obj : objects) {
if (obj.getBaseType() == ViewObject.Type.PROXY_OBJECT) {
MapProxyObject proxyObj = (MapProxyObject) obj;
if (proxyObj.getType() == MapProxyObject.Type.TRAFFIC_EVENT) {
TrafficEventObject trafficEventObj =
(TrafficEventObject) proxyObj;
TrafficEvent trafficEvent =
trafficEventObj.getTrafficEvent();
Toast.makeText(getApplicationContext(), trafficEvent.getEventText(),
Toast.LENGTH_LONG).show();
}
}
}
return true;
};
HERE Android SDK Developer's Guide
User Guide
52
Offline Maps (MapLoader)
Even without an active data connection, applications developed with the HERE Android SDK let you
browse, search and interact with maps. Classes involved with providing Offline Maps functionality include
MapLoader, MapLoader.Listener, MapLoader.ResultCode and MapPackage.
An application can use MapLoader while it is performing another map operation. For example, an app can
download map data while a user is panning a map.
Offline map functionality is invoked automatically, or you can also disable connectivity for the entire HERE
SDK by using MapEngine.setOnline(false). Note that you can only set MapEngine.setOnline(true)
when the device is online. If not, then the request is ignored.
MapLoader and MapLoader.Listener
Offline maps capabilities are enabled through the use of MapLoader and its associated objects. The
MapLoader class provides a set of APIs that allow manipulation of the map data stored on the device.
Operations include:
getMapPackages() - To retrieve the state of the map data on the device
installMapPackages(List<Integer> packageIdList) - To download and install new country or
region data
uninstallMapPackages(List<Integer> packageIdList) - To uninstall and delete country or
region data that is no longer desired
checkForMapDataUpdate() - To check whether a new map data version is available
performMapDataUpdate() - To perform a map data version update, if available
cancelCurrentOperation() - To cancel the running MapLoader operation
To use MapLoader, you must call MapLoader.getInstance() to retrieve a MapLoader object instance.
Note that com.here.android.mpa.mapping.MapEngine must be successfully initialized before this
method can be used.
MapLoader operations are performed asynchronously. Results of the various operations are returned by way
of a MapLoader.Listener implementation that must be set to listen for notifications from the MapLoader
as in the code snippet below:
MapLoader.Listener mapLoaderListener = new MapLoader.Listener() {
public void onUninstallMapPackagesComplete(MapPackage rootMapPackage,
MapLoader.ResultCode mapLoaderResultCode) {
}
public void onProgress(int progressPercentage) {
}
public void onPerformMapDataUpdateComplete(MapPackage rootMapPackage,
MapLoader.ResultCode mapLoaderResultCode) {
}
public void onInstallationSize(long diskSize, long networkSize) {
}
public void onInstallMapPackagesComplete(MapPackage rootMapPackage,
MapLoader.ResultCode mapLoaderResultCode) {
}
public void onGetMapPackagesComplete(MapPackage rootMapPackage,
MapLoader.ResultCode mapLoaderResultCode) {
}
public void onCheckForUpdateComplete(boolean updateAvailable,
HERE Android SDK Developer's Guide
User Guide
53
String currentMapVersion,String newestMapVersion,
MapLoader.ResultCode mapLoaderResultCode) {
}
};
MapLoader mapLoader = MapLoader.getInstance();
mapLoader.addListener(mapLoaderListener);
Also, all operations of the MapLoader are mutually exclusive. For example, if method XYZ is called before
the callback method ABC has returned a result, method XYZ returns false to indicate that the MapLoader is
busy with another operation.
The MapPackage Class
The map data packages available for download are represented as a tree structure with the root map
package representing the world map. The MapPackage class represents the model through which this tree
structure is accessed. As shown in the preceding code snippet, many of the MapLoader.Listener callbacks
returns the root MapPackage. The other MapPackage instances are accessed by recursing through the tree
structure from the root.
The MapPackage state of a particular instance is not updated dynamically to reflect changes to map data
on disk. Therefore if you retrieve MapPackage instance A, and then perform an installation operation (which
returns MapPackage instance B through onInstallMapPackagesComplete()), MapPackage instance A
does not reflect the updated map data state, but MapPackage instance B does. Therefore, always use the
new MapPackage object returned by a given operation and update the representation in your application
accordingly.
Note: The getSize() method returns the maximum install size of the map package, in kilobytes.
If this is the first MapPackage to be installed, then the package takes up the same amount of
memory storage as returned by this method. However, if other packages have already been installed,
then the required disk space for this map package is considerably less than the value returned by
getSize(), because common data between map packages does not need to be installed again. To
get an accurate representation of the disk space that is used for a given installation operation, use
the MapLoader.Listener.onInstallationSize(long, long) callback method.
Note: Map data packages may need to be reinstalled if the application crashes or is forced closed
during MapLoader installation or uninstallation.
Incremental Map Data Updates
MapLoader exposes the ability to update the map data version to provide the user with the freshest map
data available. The map data version applies not only to map data pre-installed using the MapLoader, but
also to data that is retrieved dynamically by browing new areas.
Map data version is consistent for all map data across the entire system, whether the map data is
downloaded or not. It is not possible to have some data from one map version and other data from another
map version concurrent in the disk cache. Therefore, it is important to keep the map version of the system
up to date. However, map version updating does not require re-downloading everything. Instead, only
incremental changes need to be downloaded, making typical updates small and quick. Map version updating
is exposed through the checkForMapDataUpdate() and performMapDataUpdate() methods.
HERE Android SDK Developer's Guide
User Guide
54
Data Groups
Map packages are made up of several groups, each of which contains a different type of map
data. Some of these groups may be selected or deselected before map packages are downloaded
for offline use, depending on the needs of the application. The optional data groups are given
in the SelectableDataGroup enum. To select or deselect a data group for download, pass the
appropriate enum value to the NMAMapLoader.selectDataGroup(SelectableDataGroup) or
deselectDataGroup(SelectableDataGroup) method.
Note: This feature can only be used with an isolated disk cache. For more information, see Embedding
the Map Service on page 20.
The selected data groups of the map loader are used for all future installation operations. However, changes
to the data group selection do not affect previously installed packages. To update these packages, call
performMapDataUpdate() after changing the data group selection.
The default data group selection may not be optimal for some applications. To minimize disk space
usage, it's recommended that any applications which allow offline map downloads ensure they are only
downloading the required data groups.
Shared Map Resources
The HERE SDK utilizes a shared disk cache on external device memory where it keeps map resources. This
disk cache is shared between all applications and components that use the HERE SDK. The disk cache can be
accessed by multiple applications concurrently, even while map data is being loaded. (For more information,
see Offline Maps (MapLoader) on page 52)
Usage of map resources must be properly handled on an application level. When an application is in active
use, it must hold a reference to map resources for HERE SDK functionality to work. When an application is
not being used (for example, it has been sent to the background), it should release its reference to map
resources.
For MapFragment users, map resource usage is handled automatically, so explicit handling of map resource
references is not required.
Reference handling can be performed manually. This is useful if an application wishes to support a use
case that is outside the scope of classes that provide automatic reference handling. Some examples of this
include performing route calculations in a background service or directly using a MapView component.
onPause() - Decrements the reference count of map resource usage.
onResume() - Increments the reference count of map resource usage.
getResourceReferenceCount() - Get the current reference count of map resource usage for your
application
For more info on these methods and their usage, consult the API reference.
Traffic History
Traffic History allows the user to obtain map tiles that show the typical traffic pattern for
a specific time point during the week. To display Traffic History tiles, create an instance of
HERE Android SDK Developer's Guide
User Guide
55
HistoricalTrafficRasterTileSource by specifying a day of the week and a time. For example, to show
the traffic tiles for Wednesdays at 5:40pm, add the following:
HistoricalTrafficRasterTileSource tileSource =
new HistoricalTrafficRasterTileSource(DaysOfTheWeek.WEDNESDAY, 17, 40);
map.addRasterTileSource(tileSource);
Figure 28: Traffic History in San Francisco
HERE Android SDK Developer's Guide
User Guide
56
3D Landmarks
Figure 29: A Landmark on a Map of San Francisco
Another related feature in the Map class is 3D landmarks. By calling setLandmarksVisible(true), you
can make certain landmark structures visible. These structures are presented with textures and more details
in their 3D geometry, as seen in the screenshot above. Landmarks are not visible when the map is set to a
Hybrid or Satellite map scheme.
HERE Android SDK Developer's Guide
User Guide
57
Extruded Buildings
Figure 30: Extruded Buildings on a Map of San Francisco
HERE Android SDK supports 3D representations of buildings and structures. This feature is called extruded
buildings, and you can display them by using the setExtrudedBuildingsVisible() method in
com.here.android.mpa.mapping.Map. Extruded buildings are available for most metropolitan areas in
North America and Europe.
The MapBuildingLayer Class
The main entry point for extruded buildings is the MapBuildingLayer class, which can be retrieved by
calling getMapBuildingLayer() from a Map. MapBuildingLayer provides methods for working with
building groups and individual buildings such as:
getBuilding()
createNewBuildingGroup()
releaseBuildingGroup()
getDefaultBuildingGroup()
These APIs provide a way for the developer to create groups of buildings (for example, to highlight them in a
blue color), or to retrieve a default group containing all possible extruded buildings on-screen.
Note: The extruded building methods are available even when buildings are invisible. For example,
calling getDefaultBuildingGroup() returns the default group, even if you have called
setExtrudedBuildingsShown(false) or if the current zoom level does not allow visible extruded
buildings.
The MapBuildingGroup Class
The MapBuildingGroup class represents a group of buildings. There are two types of groups:
New building groups - Created by calling createNewBuildingGroup(). No building is attached to this
group when it is created. An application can have a maximum of six new building groups at a time.
Default building groups - Retrieved by calling getDefaultBuildingGroup(). The default building
group is a generic group that represents all possible buildings in the entire world. There are two distinct
HERE Android SDK Developer's Guide
User Guide
58
types of default building groups— IMPORTANT_BUILDINGS, which are textured landmark buildings, and
NORMAL_BUILDINGS, which include all other buildings.
Each MapBuildingGroup holds an EnumSet of building faces, a color, as well as a building height scaling
factor. To control the appearance of extruded buildings, you can set these attributes and add buildings to
the group. For example, to highlight a building's roof, create a new building group, set the group's roof color
as Color.RED, and then add a building to this group, as in the following code:
// retrieve a reference of the map from the map fragment
map = mapFragment.getMap();
// Create a custom building group
buildingGroup = map.getMapBuildingLayer().createNewBuildingGroup();
// Set the buildingGroup's roof color to "red"
buildingGroup.setColor(Color.RED, EnumSet.of(MapBuildingGroup.BuildingFace.ROOF));
// Set the buildingGroup's height
buildingGroup.setVerticalScale(0.90f);
buildingGroup.addBuilding(myBuildingIdentifier);
Note: Remember to call releaseBuildingGroup() to release any unused building groups.
Otherwise, users may receive a null pointer exception after the device has been rotated a few times.
Figure 31: Highlighting a Building
Note: By default, a new MapBuildingGroup has the color
MapBuildingLayer.DefaultBuildingColor.SELECTED on all building faces.
The following images show the values that can be used to highlight building faces:
HERE Android SDK Developer's Guide
User Guide
59
MapBuildingGroup.BuildingFace.ROOF
MapBuildingGroup.BuildingFace.OUTLINE
MapBuildingGroup.BuildingFace.WALLBOTTOM
MapBuildingGroup.BuildingFace.WALLTOP
HERE Android SDK Developer's Guide
User Guide
60
MapBuildingGroup.BuildingFace.LANDMARKS - Note that this value is
only applicable for landmarks. When this value is used, the entire landmark is
shaded.
The MapBuildingObject Class
The MapBuildingObject class represents a single building, with the following attributes:
a name
a geocoordinate position
the building height, in meters
a unique map building identifier
To detect whether a user has tapped on an extruded building, use MapGesture.OnGestureListener and
look for the selected MapBuildingObject:
private MapGesture.OnGestureListener gestureListener =
new MapGesture.OnGestureListener.OnGestureListenerAdapter() {
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject vo : objects) {
if (vo instanceof MapBuildingObject) {
// Remove currently selected building
buildingGroup.removeAllBuildings();
// Add this building to the group.
MapBuildingObject building = (MapBuildingObject) vo;
buildingGroup.addBuilding(building.getIdentifier());
}
}
return false;
}
};
Custom Raster Tiles
You can use the HERE Android SDK to enhance maps with custom raster tiles. Custom raster tiles are tile
images that you can add to a map to customize it with enhanced information. For example, you may wish
to use this feature to add heat maps over a map of New York City. You can store custom raster tile images
locally or on a remote server for users to access when they navigate in a map. If the application is set to
display custom raster tiles, then tiles are displayed when users view a designated geographical area at a
specified zoom level or range of zoom levels.
HERE Android SDK Developer's Guide
User Guide
61
Dividing a Map and Tile Lookup
To use your own custom raster tile images, you need to have a scheme for dividing your map according to
the zoom level and map coordinates, and then provide map tiles according to this scheme. Your application
must then use this scheme in the implementation of one of the following classes:
MapRasterTileSource - Implement this class if you plan to fetch local tile images, create dynamic
images, or if you would like to provide your own method of retrieving images from a remote server.
UrlMapRasterTileSourceBase - This is a convenience child class of MapRasterTileSource.
Implement this if you plan to fetch tile images from a remote server using a URL over HTTP.
Note: Raster tiles can be one of the following supported image types:
• PNG
• JPEG
• BMP
Once a tile source has been implemented, you can toggle its display by adding or
removing it to the map using Map.addRasterTileSource(MapRasterTileSource) or
Map.removeRasterTileSource(MapRasterTileSource).
The MapRasterTileSource Abstract Class
MapRasterTileSource is the common way for you to define your raster tile source. If your application
uses local tile images or remote images that require custom server authentication, then you should
implement this class by defining the hasTile() and getTileWithError() methods. For example:
public class MyTileSource extends MapRasterTileSource {
@Override
public boolean hasTile(int x, int y, int zoomLevel) {
return true;
}
@Override
public TileResult getTileWithError(int x, int y, int zoomLevel) {
byte[] myImageData = null;
// perform tile retrieval logic such as server authentication
// also translate the x, y, and zoomlevel to address an image
TileResult result = new TileResult(Error.NONE, myImageData);
return result;
}
}
Note: Ensure that getTileWithError() returns within a reasonable amount of time. If your
operation takes a longer period of time, launch an asynchronous operation and return the
TileResult.Error.NOT_READY error code while the operation is in progress.
The UrlMapRasterTileSourceBase Abstract Class
UrlMapRasterTileSourceBase is a child abstract class of MapRasterTileSource that you
can use if you plan to fetch tile images from a remote server using image URLs. The following
is a sample implementation of UrlMapRasterTileSourceBase. In this example, we use the
MapRasterTileSource.MapTileSystemHelper.tileXYToQuadKey() method to address our map tiles.
HERE Android SDK Developer's Guide
User Guide
62
This helper method assumes that we are using a quadtree/quadkey scheme, where the map is divided into a
quadtree (a tree data structure where each node has exactly four children) with 20 levels. Each level of this
map quadtree has (2 x )2 tiles, where x represents the floor function value of the current zoom level. So for
level 0, there is 1 x 1 = 1 tile, level 1 has 2 x 2 = 4 tiles, level 2 has 4 x 4 = 16 tiles, and level 3.7 has 8 x 8 = 64
tiles—since the floor value of 3.7 is 3.
For more information about the quadkey/quadtree division scheme, see the tileXYToQuadKey() API
reference.
public class LiveMapRasterTileSource extends UrlMapRasterTileSourceBase {
private final static String URL_FORMAT =
"http://1.communitymaptiles.example.org/tilehub/live/map/png/%s";
public LiveMapRasterTileSource() {
// We want the tiles placed over everything else
setOverlayType(MapOverlayType.FOREGROUND_OVERLAY);
// We don't want the map visible beneath the tiles
setTransparency(Transparency.OFF);
// We don't want the tiles visible between these zoom levels
hideAtZoomRange(12, 20);
// Do not cache tiles
setCachingEnabled(false);
}
// Implementation of UrlMapRasterTileSourceBase
public String getUrl(int x, int y, int zoomLevel) {
String url = null;
// Utility to map the x, y coordinates easily into an equivalent
// quadkey at a specified zoomLevel
String quadKey =
MapTileSystemHelper.tileXYToQuadKey(x, y, zoomLevel);
try {
// Append the quadkey to the URL template to get a real URL
url = String.format(URL_FORMAT, quadKey);
} catch (Exception ex) {
ex.printStackTrace();
}
return url;
}
}
The example above generates a quadkey from the x, y coordinates and the zoom level and appends it to the
URL. However, this is server-specific and the method of converting x, y and zoom level to a URL can be done
in many ways. Also, it is worth noting that tiles can be cached with setCachingEnabled(true).
Changing the Overlay Rendering Order
You can choose to customize the order that raster tiles are rendered by calling
MapRasterTileSource.setOverlayType(MapOverlayType). For example
MapOverlayType.BACKGROUND_OVERLAY and MapOverlayType.BACKGROUND_REPLACEMENT are similar
to rendering raster tiles with streets rendered on top. MapOverlayType.FOREGROUND_OVERLAY renders
tiles on top of everything on the map.
HERE Android SDK Developer's Guide
User Guide
63
Caching Tiles
Tiles can be cached to the disk by calling the following:
// Give the tile source a custom prefix so it can be cached on the disk
MapRasterTileSource.setCachePrefix(String cache)
// Give each raster tile file an expiration time in seconds.
MapRasterTileSource.setCacheExpiration( int seconds )
If no expiration time is set, then the raster tiles remains on the device. We recommend that both a cache
prefix and an expiration time be set.
Mobile Asset Management
The Mobile Asset Management (MAM) features provide useful information for logistics
companies to manage their fleet vehicles. You can enable features one at a time,
or multiple at the same time, using setFleetFeaturesVisible(EnumSet).
setFleetFeaturesVisible(EnumSet.noneOf(Map.FleetFeature.class)) disables all fleet
features.
Fleet Vehicle Map
The fleet vehicle map scheme is a scheme optimized for fleet management. These schemes can be used to
show road networks, as well as truck toll and highway exits.
To display fleet maps, pick one of the following truck map schemes:
TRUCK_DAY
TRUCK_NIGHT
TRUCK_HYBRID_DAY
TRUCK_HYBRID_NIGHT
For example:
map.setMapScheme(Map.Scheme.TRUCK_DAY);
HERE Android SDK Developer's Guide
User Guide
64
The screenshot below shows highways with truck toll highlighted in purple and highway exit signs in Berlin.
Figure 32: Fleet Map of Berlin
For information about other map schemes, see Map Schemes on page 30.
Truck Restrictions
This fleet feature contains information about heavy vehicle route restrictions, such as height, weight, or
environmental restrictions. For example, trucks carrying flammable materials may not travel on certain
roads.
To display truck restrictions, add TRUCK_RESTRICTIONS to your fleet features as follows:
map.setFleetFeaturesVisible(EnumSet.of(Map.FleetFeature.TRUCK_RESTRICTIONS));
HERE Android SDK Developer's Guide
User Guide
65
The screenshot below shows truck restrictions in London.
Figure 33: Truck Restrictions in London
Congestion and Environmental Zones
This fleet feature highlights congestion and environmental zones. Congestion zones are areas where certain
classes of vehicles must pay a toll to enter. Environmental Zones areas only admit certain kinds of vehicles
depending on their emissions class.
To display congestion and environmental zones, add CONGESTION_ZONES and ENVIRONMENTAL_ZONES to
your fleet features:
EnumSet<Map.FleetFeature> features = map.getFleetFeaturesVisible();
features.add(Map.FleetFeature.CONGESTION_ZONES);
features.add(Map.FleetFeature.ENVIRONMENTAL_ZONES);
map.setFleetFeaturesVisible(features);
The screenshots below show congestion and environmental zones in London.
HERE Android SDK Developer's Guide
User Guide
66
Figure 34: London Congestion Zones Figure 35: London Environmental
Zones
Figure 36: London Congestion and
Environmental Zones (with Truck
Restrictions)
Fleet Connectivity
The Fleet Connectivity features allows applications that use the HERE Android SDK to receive job dispatches
from a fleet dispatcher. Each job dispatch contains custom information, such as a geocoordinate to a
destination, that can be used by your application for navigation or other purposes.
Your application, which is known as an asset in a fleet connectivity context, can also use this feature to
indicate its job status to the dispatcher. These job statuses include whether it is available to receive a job,
whether the job was accepted, and whether the job is finished.
Note: The HERE Android SDK contains APIs for you to implement a fleet connectivity client. For
instructions on how to use the fleet dispatcher features, see the Fleet Connectivity Extension
Developer's Guide at developer.here.com.
FleetConnectivityService
This singleton class holds information such as this fleet asset ID, the fleet dispatcher to connect to, the
running job, and job event polling interval.
Note: At a minimum, you must set the fleet asset and dispatcher IDs before starting the fleet
connectivity service.
FleetConnectivityEvent and FleetConnectivityService.Listener
You can set a FleetConnectivityService.Listener to the service to listen for dispatcher events.
Dispatcher events are highly customizable, with the only mandatory information being a Job ID. Otherwise,
you can define any type of information in its content payload, such as a set of geocoordinates, a Place ID,
or an address string.
There are two methods that need to be implemented in Listener:
HERE Android SDK Developer's Guide
User Guide
67
onMessageReceived(FleetConnectivityMessage)
onEventAcknowledged(FleetConnectivityEvent, FleetConnectivityError)
Using the Fleet Connectivity Feature
The basic flow of how to use the Fleet Connectivity feature is as follows:
1. Start the fleet connectivity service and begin listening for fleet connectivity events.
FleetConnectivityService service = FleetConnectivityService.getInstance();
service.setDispatcherId("Driver-321");
service.setAssetId("Truck-987");
if (service.start()) {
// service has started
} else {
// service has failed to start
}
2. Implement Listener. Once a message is received, check if it is a dispatch job.
public void onMessageReceived(FleetConnectivityMessage message) {
if (message.getMessage() != null) {
// Display the optional message content
}
if (message instanceof FleetConnectivityJobMessage) {
// This message represents a job
FleetConnectivityJobMessage newDestinationMessage =
(FleetConnectivityJobMessage) message;
// Get job ID from newDestinationMessage.getJobId()
// Get location (in your preferred format) from
// newDestinationMessage.getMessage()
// Get threshold from newDestinationMessage.getEtaThreshold()
// (this threshold controls when ETA updates are sent back to dispatcher)
} else if (message instanceof FleetConnectivityCustomMessage) {
// This message does not represent a job
FleetConnectivityCustomMessage customMessage =
(FleetConnectivityCustomMessage) message;
// Get job ID from customMessage.getJobId()
// Get message from customMessage.getContent()
}
}
3. Send an event to the dispatcher that the job has been accepted.
FleetConnectivityJobStartedEvent event =
new FleetConnectivityJobStartedEvent();
// populate event.setJobId(String)
// populate event.setEtaThreshold(long)
if (FleetConnectivityService.getInstance().sendEvent(event)) {
// job is running
// for example, your application can begin navigating to the job destination
} else {
// job has failed to start
}
Alternatively, you can also reject the the job by sending a rejection event.
FleetConnectivityJobRejectedEvent event =
new FleetConnectivityJobRejectedEvent();
// populate event.setJobId(String)
HERE Android SDK Developer's Guide
User Guide
68
if (!FleetConnectivityService.getInstance().sendEvent(event)) {
// failed to reject job
}
4. While a job is in the accepted state, you can tell the dispatcher that the job is canceled.
FleetConnectivityJobCancelledEvent event = new FleetConnectivityJobCancelledEvent();
if (!FleetConnectivityService.getInstance().sendEvent(event)) {
// failed to cancel job
}
5. Upon job completion, notify the server that the job is finished. For example, you can choose to send this
event when your application has successfully finished the navigation session.
FleetConnectivityJobFinishedEvent event = new FleetConnectivityJobFinishedEvent();
if (!FleetConnectivityService.getInstance().sendEvent(event)) {
// failed to mark job as finished
}
6. In the previous steps, after sending each event, your application receives an acknowledgment
from the dispatching server through the onEventAcknowledged(FleetConnectivityEvent,
FleetConnectivityError) callback.
public void onEventAcknowledged(FleetConnectivityEvent event, FleetConnectivityError error)
{
if (event instanceof FleetConnectivityJobStartedEvent) {
// the job start event is acknowledged
} else if (event instanceof FleetConnectivityJobRejectedEvent) {
// the job rejection event is acknowledged
} else if (event instanceof FleetConnectivityJobFinishedEvent) {
// the job completion event is acknowledged
} else if (event instanceof FleetConnectivityJobCancelledEvent) {
// the job cancellation event is acknowledged
} else if (event instanceof FleetConnectivityCustomEvent) {
// the custom event is acknowledged
}
}
7. Stop the service by calling FleetConnectivityService.getInstance().stop().
Transit Information
Your application can use API calls from the HERE Android SDK to display transit information for users.
Note: The transit map schemes (NORMAL_DAY_TRANSIT, NORMAL_NIGHT_TRANSIT, and
HYBRID_DAY_TRANSIT) are specifically designed for displaying transit information. You can opt to
use one of these schemes when your app displays transit information.
MapTransitLayer
MapTransitLayer is a layer that displays the available transit data for a map area. To customize the transit
layer, call Map.getMapTransitLayer() to access the methods available through the MapTransitLayer
class. For example, to show all transit information available:
// Assumes map is instantiated
map.getMapTransitLayer().setMode(MapTransitLayer.Mode.EVERYTHING);
HERE Android SDK Developer's Guide
User Guide
69
Note: MapTransitLayer settings may be affected when you change map schemes. For example,
changing the map scheme to NORMAL_DAY_TRANSIT enables the "everything" mode. It is
recommended that map scheme changes occur before changes in the MapTransitLayer.
Figure 37: MapTransitLayer set to show everything
To show only transit stops and accesses call:
// Assumes map is instantiated
map.getMapTransitLayer().setMode(MapTransitLayer.Mode.STOPS_AND_ACCESSES);
Figure 38: MapTransitLayer set to show only transit stops and accesses
To hide all transit information call:
// Assumes map is instantiated
map.getMapTransitLayer().setMode(MapTransitLayer.Mode.NOTHING);
Highlighting Transit Objects
The following four types of transit data objects are available:
HERE Android SDK Developer's Guide
User Guide
70
Transit Stop data - represented by TransitStopObject
Transit Line data - represented by TransitLineObject
Transit Access data - represented by TransitAccessObject
Transit Line Segment data - represented by TransitLineSegmentObject
Transit objects can be selected through tap gestures. For example, to highlight one or more
TransitLineObject, you need to know the unique identifier of the line objects. Depending on the use
case, there are several ways of getting a single or a list of Identifier objects:
Call TransitLineObject.getLineId() when a user has selected a TransitLineObject by tapping
on it. It returns an Identifier of the selected transit line.
Call TransitStopObject.getTransitStopInfo().getLines() when a user has selected a
TransitStopObject via tapping. getLines() returns a list of Identifier of the lines connected to
the selected transit stop.
For details of handling tappable MapProxyObjects, see Handling MapProxyObject objects on page 45.
With a single or a list of Identifier objects, you call the following API to highlight the lines:
// Assumes map is instantiated and identifierList is
// filled with a list of Identifiers
map.getMapTransitLayer().highlightTransitLines(identifierList);
Figure 39: MapTransitLayer highlighting transit lines connected to the selected transit stop
HERE Android SDK Developer's Guide
User Guide
71
TransitStopObject
A TransitStopObject is a type of MapProxyObject that contains information about a transit stop. The
following figures show the different types of transit stops:
Figure 40: TransitStopObject: A metro station Figure 41: TransitStopObject: A ferry station
To acquire information about a tapped TransitStopObject (see Handling MapProxyObject objects on page
45 ) use onMapObjectsSelected(List<ViewObject>) as follows:
private MapGesture.OnGestureListener listener = new MapGesture.OnGestureListener() {
...
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject obj : objects) {
if (obj.getBaseType() == ViewObject.Type.PROXY_OBJECT) {
MapProxyObject proxyObj = (MapProxyObject) obj;
if (proxyObj.getType() == MapProxyObject.Type.TRANSIT_STOP) {
TransitStopObject transitStopObj
= (TransitStopObject) proxyObj;
Log.d(TAG, "Found a TransitStopObject");
Log.d(TAG, "position is "
+ transitStopObj.getCoordinate().toString());
TransitStopInfo transitStopInfo
= transitStopObj.getTransitStopInfo();
...
}
}
return true;
}
The TransitStopObject provides two methods for getting information about the transit stop:
getCoordinate() gets the location coordinates of the transit stop.
getTransitStopInfo() gets further information about the transit stop.
HERE Android SDK Developer's Guide
User Guide
72
TransitStopInfo
The TransitStopInfo class contains transit stop information that is accessed by calling one or more of the
following methods
getOfficialName() gets the official name of the transit stop
getInformalName() gets the informal name of the transit stop
getId() gets the Identifier of the transit stop
getTransitTypes() gets the transit types this transit stop belongs to; there can be more than one.
getLines() gets a list of Identifier objects for transit lines connected to this transit stop
Each Identifier is submitted to the TransitDatabase to get further information. For more details, see
TransitDatabase. Also they can be submitted to the MapTransitLayer to get highlighted on the map. (See
MapTransitLayer on page 68)
An example of getting information about the first transit line connected to the transit stop is provided
below. A TransitDatabase.OnGetTransitInfoListener needs to be implemented to receive the
TransitLineInfo. (See TransitLineInfo on page 74)
An asynchronous request is submitted to the TransitDatabase along with the
OnGetTransitInfoListener.
TransitDatabase.OnGetTransitInfoListener listener
= new TransitDatabase.OnGetTransitInfoListener() {
......
@Override
public void onTransitLineInfo(TransitLineInfo info) {
......
}
// transitStopInfo is a TransitStopInfo object
......
mTransitDatabase.getLineInfo(transitStopInfo.getLines().get(0), listener);
HERE Android SDK Developer's Guide
User Guide
73
TransitLineObject
A TransitLineObject is a type of MapProxyObject that contains information about a transit line. The
following figure shows examples of different types of transit lines:
Figure 42: Three types of transit lines: Metro, Train and Water
To acquire information about a tapped TransitLineObject (see Handling MapProxyObject objects on page
45 ) use onMapObjectsSelected(List<ViewObject>) as illustrated in the following code:
private MapGesture.OnGestureListener listener = new MapGesture.OnGestureListener() {
...
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject obj : objects) {
if (obj.getBaseType() == ViewObject.Type.PROXY_OBJECT) {
MapProxyObject proxyObj = (MapProxyObject) obj;
if (proxyObj.getType() == MapProxyObject.Type.TRANSIT_LINE) {
TransitLineObject transitLineObj
= (TransitLineObject) proxyObj;
Log.d(TAG, "Found a TransitLineObject");
Log.d(TAG, "Id is "
+ transitLineObj.getLineId().toString());
mTransitDatabase.getLineInfo(m_lineIdList.get(0),
mOnGetTransitInfoListener);
}
}
}
return true;
}
The TransitLineObject provides a single method for getting the Identifier of the transit line.
This Identifier can be submitted to the MapTransitLayer to get highlighted on the map. (For more
information, refer to MaptransitLayer)
As shown in the example above, the Identifier can also be submitted to the TransitDatabase (see
TransitDatabase) along with the OnGetTransitInfoListener to get more information about the transit
HERE Android SDK Developer's Guide
User Guide
74
line. mOnGetTransitInfoListener is implemented to receive the TransitLineInfo object from the
TransitDatabase.
TransitDatabase.OnGetTransitInfoListener mOnGetTransitInfoListener
= new TransitDatabase.OnGetTransitInfoListener() {
...
@Override
public void onTransitLineInfo(TransitLineInfo info) {
...
}
}
TransitLineInfo
The TransitLineInfo class contains transit line information that is accessed by calling one or more of the
following methods:
getOfficialName() gets the official name of the transit line
getInformalName() gets the informal name of the transit line
getShortName() gets the short name of the transit line
getTransitType() gets the transit types this transit line belongs to.
TransitAccessObject
A TransitAccessObject is a type of MapProxyObject that contains information about a transit access. A
transit access is an entrance/exit to a transit stop. There can be multiple transit accesses to a transit stop.
Transit access is presented as a smaller transit stop with a downward triangle attached to the bottom and is
visible only in higher zoom levels. The icons presenting the transit stops and access vary between different
countries and companies. The following figures show two examples:
Figure 43: Transit Stop and Access: Metro Station with Single Access Figure 44: Transit Stop and Access: Metro Station with Mutiple
Accesses
HERE Android SDK Developer's Guide
User Guide
75
To acquire information about a tapped TransitAccessObject (see Handling MapProxyObject objects on
page 45) use onMapObjectsSelected(List<ViewObject>) as in the following code:
private MapGesture.OnGestureListener listener = new MapGesture.OnGestureListener() {
...
@Override
public boolean onMapObjectsSelected(List<ViewObject> objects) {
for (ViewObject obj : objects) {
if (obj.getBaseType() == ViewObject.Type.PROXY_OBJECT) {
MapProxyObject proxyObj = (MapProxyObject) obj;
if (proxyObj.getType() == MapProxyObject.Type.TRANSIT_ACCESS) {
TransitAccessObject transitAccessObj
= (TransitAccessObject) proxyObj;
Log.d(TAG, "position is " +
transitAccessObj.getCoordinate().toString());
TransitAccessInfo transitAccessInfo
= transitAccessObj.getTransitAccessInfo();
...
break;
}
}
}
return true;
}
The TransitAccessObject provides two methods for getting information about the transit access:
getCoordinate() gets the location coordinates of the transit access.
getTransitAccessInfo() gets further information about the transit access.
TransitAccessInfo
The TransitAccessInfo class contains transit access information that can be accessed by calling one or
more of the following methods
getTransitTypes() gets the transit types this transit access belongs to; there can be more than one.
getStopId() gets a unique Identifier of the transit stop that this transit access leads to.
In the next example, the unique identifier of the transit stop is submitted to the TransitDatabase to get
further information. For more details, see TransitDatabase.
// transitAccessInfo is a TransitAccessInfo object
Log.d(TAG, "transit type is " +
transitAccessInfo.getTransitTypes().toString());
Log.d(TAG, "Stop Id is " +
transitAccessInfo.getStopId().toString());
mTransitDatabase.getStopInfo(transitAccessInfo
.getStopId(), mOnGetTransitInfoListener);
An example of getting information about the destination transit stop of a transit access is provided below.
An OnGetTransitInfoListener needs to be implemented to receive the TransitStopInfo object. An
asynchronous request is submitted to the TransitDatabase along the OnGetTransitInfoListener. For
more information, see TransitStopInfo.
TransitDatabase.OnGetTransitInfoListener mOnGetTransitInfoListener
= new TransitDatabase.OnGetTransitInfoListener(){
......
HERE Android SDK Developer's Guide
User Guide
76
@Override
public void onTransitStopInfo(TransitStopInfo info) {
......
}
}
// transitAccessInfo is a TransitAccessInfo object
......
mTransitDatabase.getStopInfo(transitAccessInfo.getStopId(),
mOnGetTransitInfoListener);
TransitSystemInfo
The TransitSystemInfo class contains information about a public transit system that can be accessed by
calling one or more of the following methods:
getSystemOfficialName() - gets the official name of the transit system
getSystemWebsitUrl() - gets the website URL of the transit system
getCompanyOfficialName() - gets the official transit system company name
getCompanyWebsiteUrl() - gets the website URL of the transit system company
getCompanyRoutePlannerUrl() - gets the route planner URL of the transit system company
getCompanyScheduleUrl() - gets the schedule url of the transit system company
getCompanyPhone() - gets the phone number for the transit system company
getBicycleHours() - gets the tranit system's bicycle parking hours
getSystemLogo() - gets the system logo (if present)
getCompanyLogo() - gets the companyLogo (if presents)
An example of retrieving transit system information is provided below. In this example, an
OnGetTransitInfoListener is implemented to receive the TransitSystemInfo object. For more
information, see the TransitDatabase section.
TransitDatabase.OnGetTransitInfoListener mOnGetTransitInfoListener =
new TransitDatabase.OnGetTransitInfoListener() {
...
@Override
public void onTransitSystemInfo(TransitSystemInfo systemInfo) {
String officialName = systemInfo.getSystemOfficialName();
}
...
}
// transitLineInfo is a TransitLineInfo object
mTransitDatabase.getSystemInfo(transitLineInfo.getSystemId(),
mOnGetTransitInfoListener);
TransitDatabase
The TransitDatabase class is responsible for querying transit information of various types using a unique
Identifier , with a OnGetTransitInfoListener for monitoring query results and triggering appropriate
callback methods upon completion. Applications can call the TransitDatabase constructor to activate a
TransitDatabase for querying transit information.
HERE Android SDK Developer's Guide
User Guide
77
The OnGetTransitInfoListener interface can be used to monitor query results of the
TransitDatabase. It must be implemented within the application and submitted as part of the
asynchronous query request.
TransitDatabase.OnGetTransitInfoListener mOnGetTransitInfoListener
= new TransitDatabase.OnGetTransitInfoListener() {
@Override
public void onTransitLineInfo(TransitLineInfo info) {
//...
}
@Override
public void onTransitStopInfo(TransitStopInfo info) {
//...
}
@Override
public void onTransitAccessInfo(TransitAccessInfo info) {
//...
}
@Override
public void onTransitSystemInfo(TransitSystemInfo info) {
//...
}
@Override
public void onEnd(TransitDatabase.Error error) {
//...
}
};
The OnGetTransitInfoListener class provides five callbacks:
onTransitLineInfo provides a TransitLineInfo object. (See TransitLineInfo on page 74)
onTransitStopInfo provides a TransitStopInfo object. (See TransitStopInfo on page 72)
onTransitAccessInfo provides a TransitAccessInfo object. (See TransitAccessInfo on page 75)
onTransitSystemInfo provides a TransitSystemInfo object. (See TransitSystemInfo on page 76)
onEnd is a callback that signifies the asynchronous query request has completed.
Note: TransitDatabase rejects all subsequent requests unless it has completed the current
request. If the TransitDatabase is busy, INVALID_OPERATION is returned.
An asynchronous request is submitted to the TransitDatabase along with the
OnGetTransitInfoListener. Note that the TransitDatabase instance is created by calling the
TransitDatabase constructor.
The following lists the main use cases of the TransitDatabase:
getLineInfo() - Pass in TransitLineObject.getLineId() when a user has selected a
TransitLineObject by tapping on it. This method returns an Identifier of a selected transit line.
// transitLineObject is a TransitLineObject object
......
mTransitDatabase.getLineInfo(transitLineObject
.getLineId(), mOnGetTransitInfoListener);
HERE Android SDK Developer's Guide
User Guide
78
getLineInfo() - Pass in TransitStopObject.getTransitStopInfo().getLines() when a user
has selected a TransitStopObject by tapping on it. This method returns a list of Identifiers for
the lines connected to the selected transit stop.
// transitStopInfo is a TransitStopInfo object
......
// Requesting transit line info of the first identifier on the list.
mTransitDatabase.getLineInfo(transitStopInfo
.getLines().get(0), mOnGetTransitInfoListener);
getStopInfo() - Pass in TransitAccessInfo.getStopId() when a user has selected a
TransitAccessObject by tapping on it. This method returns an Identifier of the stop that the
transit access leads to.
// transitAccessInfo is a TransitAccessInfo object
......
mTransitDatabase.getStopInfo(transitAccessInfo
.getStopId(), mOnGetTransitInfoListener);
Transit-related enumerations
The TransitType enum - represents values describing different transit types, such as BUS_PUBLIC,
RAIL_METRO or TRAIN_REGIONAL.
The TransitDatabase.Error enum - represents values describing possible transit database errors,
such as NONE or INVALID_PARAMETERS
Map Customization
Whether you want to optimize your map for a certain display size, use case, branding, or highlight objects
which are important to your users, the HERE SDK map customization feature allows a high degree of
customization freedom so that you can achieve fine control of your map view's rendering characteristics.
This section presents the components and concepts which you need to create your own map look-and-feel.
Map Schemes
Map customization starts by using one of the predefined schemes (such as "Normal Day" and "Normal Night")
to serve as a staring point. These predefined schemes are not customizable themselves, but provide the
initial values that a custom scheme derives from.
The following screenshots show examples of pre-defined schemes available in HERE SDK.
Figure 45: Normal Day scheme Figure 46: Normal Night scheme
HERE Android SDK Developer's Guide
User Guide
79
To customize the map, the first step is to obtain a Customizable Scheme object from the map view. With this
object, you can then set properties to modify the map. You can change color, icon size, width, length, and
other properties of almost all map objects such as buildings, land features, and roads. Whether property
changes are visible depends on if the map you are customizing is currently at the affected zoom level, and
the map scheme is active.
Note: A custom scheme is not permanently saved, but it lives as long as the map view object is in
memory.
Creating Your First Map Scheme Customization
After you decide on which scheme to base on, create a Customizable Scheme object with the map view
method:
CustomizableScheme scheme = map.createCustomizableScheme("newCustomScheme", Map.Scheme.NORMAL_DAY);
After creating the customizable scheme, you can retrieve it again with the following method, as long as the
map view object was not destroyed. Customizable Schemes are created and valid only to the specific Map
View from which was obtained:
CustomizableScheme scheme = map.getCustomizableScheme("newCustomScheme");
You can then get map attributes for a particular zoom level. To set attributes, specify a zoom range. A helper
ZoomRange class is provided, which takes a minimum and maximum zoom level value.
ZoomRange range = new ZoomRange (0, 20);
The HERE SDK has a class called CustomizableVariables which list all the attributes that the HERE SDK
supports for customization.
Note that in the CustomizableVariables class, map attributes are wrapped in their respective
types to identify their type. For example, CustomizableVariables.CountryBoundary.WIDTH is of
SchemeFloatProperty type which means that it is holding float value. The same applies for the others.
The SDK provides following helper classes to handle the different types of properties:
CustomizableColorProperty - specify color type (In Android, Color is represented as ARGB integer
color value)
SchemeFloatProperty - specify float type
CustomizableIntegerProperty - specify int type
To change map attributes for color, float, and integer types, perform the following:
// change 0M water color
CustomizableScheme.ErrorCode errorCode =
scheme.setVariableValue(CustomizableVariables.Water.COLOR_0M, Color.RED, range);
// get water color for zoom level 10
int waterColor0M = scheme.getVariableValue(CustomizableVariables.Water.COLOR_0M, 10.0f);
// change 3d landmark
CustomizableScheme.ErrorCode errorCode =
scheme.setVariableValue(CustomizableVariables.Landmark3d.ALPHA, 1, range);
// get 3d landmark for zoom level 10
int waterColor0M = scheme.getVariableValue(CustomizableVariables.Landmark3d.ALPHA, 10.0f);
// change CountryBoundary WIDTH
HERE Android SDK Developer's Guide
User Guide
80
CustomizableScheme.ErrorCode errorCode =
scheme.setVariableValue(CustomizableVariables.CountryBoundary.WIDTH, 2.0f, range);
// get CountryBoundary WIDTH for zoom level 10
float countryBoundaryWidth = scheme.getVariableValue(CustomizableVariables.CountryBoundary.WIDTH,
10.0f);
After customizing, you should activate your scheme by calling one of following methods:
Map.setMapScheme(CustomizableScheme customizableScheme);
or
Map.setMapScheme(String scheme)
Note: You can customize the current activated custom scheme, but changes are not automatically
applied. Remember to call one of the above methods to refresh the map scheme.
The following is a more complete example:
// create a new scheme
CustomizableScheme scheme = map.createCustomizableScheme("newCustomScheme", Map.Scheme.NORMAL_DAY);
// change water color 0m
int lightYellow = Color.argb(0, 255,255,224);
CustomizableScheme.ErrorCode err = scheme.setVariableValue(CustomizableVariables.Water.COLOR_0M,
lightYellow , range);
Log.i(TAG, "Error: " + err);
// change water color 3000m
err = scheme.setVariableValue(CustomizableVariables.Water.COLOR_3000M, Color.YELLOW, range);
Log.i(TAG, "Error: " + err);
// activate scheme
HERE Android SDK Developer's Guide
User Guide
81
map.setMapScheme(scheme);
Figure 47: Example Output
Positioning
HERE Android SDK positioning interface allows applications to choose from two different location
information sources:
Basic Positioning is described in Basic Positioning on page 81 and provides a simple interface to the
location information provided by the Android platform. This location source is always at the developer's
disposal regardless of the HERE Android SDK license.
Advanded Positioning by HERE is described in Advanced Positioning by HERE on page 85. Advanced
positioning is accessed via the same interface as the Basic Positioning, but the underlying location
source is HERE Positioning that provides developers, amongst other things, advanced offline network
positioning as well as indoor positioning.
Note: To use HERE Positioning, one or more HERE Positioning features needs to be enabled in the
HERE Android SDK license.
Basic Positioning
The HERE Android SDK provides the following interfaces for users to retrieve location updates and to display
their current location on a map:
PositioningManager
OnPositionChangedListener
HERE Android SDK Developer's Guide
User Guide
82
PositionIndicator
Note: The Android permission android.permission.ACCESS_FINE_LOCATION is required when
your app calls PositioningManager.start(LocationMethod). Otherwise, the method returns
false. In addition, to ensure that the app receives location updates, the user needs to have the
Location permission enabled (toggled to "on") during runtime.
PositioningManager Class
A PositioningManager class provides information related to the device's geographical location, like the
current position and the average speed. Applications can register to receive position updates using one of
the positioning mechanisms described in the LocationMethod:
GPS - positioning using the real GPS available on the device.
GPS_NETWORK - positioning is provided using a wireless network or the real GPS available on the device
NETWORK - positioning using a wireless network.
Note: See Advanced Positioning by HERE on page 85 for more information about additional
Location Method types.
The current status of a particular location method is represented by the LocationStatus value returned
from the PositioningManager.getLocationStatus(LocationMethod) method.
PositioningManager can be accessed by calling PositioningManager.getInstance().
An application can start receiving real time positioning updates by calling
PositioningManager.start(LocationMethod) with one of the location methods listed above
and can stop the positioning updates by calling PositioningManager.stop(). While position
updates are being received, an application can retrieve the current position of the client device via the
PositioningManager.getPosition() method.
OnPositionChangedListener Interface
In addition to the PositioningManager's getPosition() method, applications can
subscribe to position update notifications from the PositioningManager through the
PositioningManager.OnPositionChangedListener interface. To add or remove
OnPositionChangedListener, applications can use the following methods:
PositioningManager.addListener(WeakReference<OnPositionChangedListener>)
PositioningManager.removeListener(OnPositionChangedListener)
The positioning manager enhances your application with the current position of the user's device. The
registration of the positioning listener should be performed after the MapFragment, MapView, or
MapEngine is initialized as described in the following code snippet.
// Define positioning listener
private OnPositionChangedListener positionListener = new
OnPositionChangedListener() {
public void onPositionUpdated(LocationMethod method,
GeoPosition position, boolean isMapMatched) {
// set the center only when the app is in the foreground
// to reduce CPU consumption
if (!paused) {
map.setCenter(position.getCoordinate(),
Map.Animation.NONE);
HERE Android SDK Developer's Guide
User Guide
83
}
}
public void onPositionFixChanged(LocationMethod method,
LocationStatus status) {
}
};
// Register positioning listener
PositioningManager.getInstance().addListener(
new WeakReference<OnPositionChangedListener>(positionListener));
...
In order to avoid unnecessary position updates while the activity is in the background, you need to start or
stop the PositioningManager within your activity's onResume() and onPause() methods.
// Set this to PositioningManager.getInstance() upon Engine Initialization
private PositioningManager posManager;
...
// Resume positioning listener on wake up
public void onResume() {
super.onResume();
paused = false;
if (posManager != null) {
posManager.start(
PositioningManager.LocationMethod.GPS_NETWORK);
}
}
// To pause positioning listener
public void onPause() {
if (posManager != null) {
posManager.stop();
}
super.onPause();
paused = true;
}
// To remove the positioning listener
public void onDestroy() {
if (posManager != null) {
// Cleanup
posManager.removeListener(
positionListener);
}
map = null;
super.onDestroy();
}
PositionIndicator Class
PositionIndicator is a special map marker object that allows the current client device position to be
shown on a map. Every HERE SDK Map object has an integrated position indicator, set to invisible, by default.
The indicator can be retrieved and set to visible by calling MapFragments.getPositionIndicator() and
PositionIndicator.setVisible(), as follows:
// Display position indicator
mapFragment.getPositionIndicator().setVisible(true);
HERE Android SDK Developer's Guide
User Guide
84
By default, the position indicator is rendered as a marker surrounded by a circle, the diameter
of which illustrates the accuracy of the indicated position. You can change this marker by calling
PositionIndicator.setMarker(Image).
Figure 48: A PositionIndicator
Note: For the position indicator to stay in the center of the map and illustrate real-time updates of
the device's position, it is necessary to update the map's center whenever a new location update is
received.
Note: PositionIndicator only works if the application has started the PositioningManager.
Position Simulation and Creating Position Logs
You can use PositionSimulator to simulate device position by injecting locations
into the Android LocationManager. Locations are read from GPX log files. After calling
PositionSimulator.startPlayback(String), the positions in the log file are processed until the end
of the log is reached or stopPlayback() is called.
You can also use the HERE SDK to create the GPX logs that can be replayed by PositionSimulator.
To do this, call setLogType(EnumSet<LogType>) in PositioningManager to include
LogType.DATA_SOURCE. GPX logs are written to a "gpx" sub-directory of your appication's data directory —
for example, "/sdcard/Android/data/com.companyName.appName/files/gpx/". To disable logging,
call setLogType(EnumSet.noneOf(LogType.class)).
Note: This feature is only intended for debugging purposes. Do not use Position Logging in a
production application.
Note: PositionSimulator does not support indoor positioning.
HERE Android SDK Developer's Guide
User Guide
85
Advanced Positioning by HERE
In addition to the basic platform positioning, HERE Android SDK provides advanced HERE Positioning with the
following key features:
Cellular network positioning in GSM, CDMA, WCDMA, TD-SCDMA and LTE networks
Wifi network positioning
High accuracy indoor positioning with building and floor detection using wifi and Bluetooth radios
Automatic, on-demand download of radio positioning data for positioning without network connection
(offline)
Note: Offline functionality is not supported for CDMA positioning.
Automatic positioning method switching between satellite-based (GNSS), wifi, Bluetooth, and cellular
network positioning, providing the best possible position information using the available methods.
HERE Indoor Positioning supports both private and public data. You can have a private venue that is
mapped through HERE Private Venues on page 174 or your own custom indoor map, with the indoor
location information being only available for your applications. In contrast, indoor location information
for public venues is available for all HERE SDK users with an appropriate license.
Global positioning coverage and data hosting infrastructure for the optimal availability, reliability, and
user experience.
HERE Positioning Feature Groups
HERE Positioning is split into features groups. Depending on your business plan, you may have access to one
or more of the following:
Online Positioning
This feature group provides online positioning by sending anonymous network measurements
(cellular and wifi) to the HERE Positioning servers to resolve the device location based on the provided
measurements. Online positioning offers limited offline positioning capabilities through caching:
measurements and resolved positions are stored into a local cache from which they can be later used
without network connection.
Offline Positioning
This feature group provides offline network positioning (cellular and wifi) by utilizing downloaded
positioning assistance data, i.e. radiomaps, for the position estimation within the device. In this context
offline means that network connectivity is only required for the radiomap download after which no
connectivity is needed unless further radiomap tiles are needed. This may happen due to the device
movement or radiomap expiration.
Radiomap download is handled by the on-demand downloader, which automatically downloads
radiomap tiles in the vicinity of the device. The downloader also handles the maintenance of the
radiomaps in the device by updating the radiomap tiles at regular intervals as needed, and by removing
the oldest radiomap tiles in case the storage consumed by the radiomap tiles exceed the quota. This
quota is defined per technology and is configured as speficied in the table below. The table also defines,
how often the HERE Android SDK attempts to update the radiomaps.
HERE Android SDK Developer's Guide
User Guide
86
Public Indoor
This feature group provides high accuracy indoor positioning for public venues from which indoor radio
data (wifi or Bluetooth) has been collected using the HERE Indoor Radio Mapper tool. The feature uses
HERE Indoor Positioning community radiomaps that are accessible by all HERE Android SDK users having
access to this feature. Further details can be found in the HERE Indoor Positioning Installation Guide.
Similarly to Offline Positioning, HERE Public Indoor Positioning works in offline mode. The storage quota
and the radiomap tile update interval is specified in the table below.
Private Indoor
This feature group provides high accuracy indoor positioning for private venues from which indoor
radio data (wifi or Bluetooth) has been collected using the HERE Indoor Radio Mapper tool. In contrast
to the Public Indoor feature, the Private Indoor feature provides indoor positioning capability that
is accessible only by the owner of the radiomap. Further details can be found in the HERE Indoor
Positioning Installation Guide.
Similarly to the Offline Positioning, also HERE Private Indoor Positioning works in the offline mode. The
storage quota and the radiomap tile update interval is specified in the table below.
Table 1: Maximum Storage Consumption and Update Interval Per Technology
Technology Quota Update interval Description
Offline cellular 32MB 23 days Radiomaps for cellular network positioning (all network technologies).
Offline wifi 32MB 23 days Radiomaps for wifi network positioning.
Indoor wifi and
Bluetooth
32MB 7 days Radiomaps (private and community) for high accuracy indoor wifi and
Bluetooth positioning.
Using HERE Positioning
To start using HERE Positioning in the Android applications, complete the following steps:
1. Embed the HERE Positioning service in your application
2. Add the required Android permissions to your application
3. Set the positioning data source to HERE Positioning and start the Positioning Manager
4. Receive and handle location updates
In detail, the following actions need to be taken:
1) Embedding the HERE Positioning service
To embed the HERE Positioning service, add the following lines to the <application></application>
section in AndroidManifest.xml:
<!-- HERE Positioning Service definition. -->
<service
android:name="com.here.services.internal.LocationService"
android:enabled="true"
android:exported="false"
android:process=":remote">
</service>
2) Add the Android permissions to your application
HERE Android SDK Developer's Guide
User Guide
87
Add the following permissions to AndroidManifest.xml:
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.BLUETOOTH" />
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN"/>
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
<uses-permission android:name="android.permission.CHANGE_WIFI_STATE" />
<uses-permission android:name="android.permission.READ_PHONE_STATE" android:maxSdkVersion="22" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
Note: If your application uses Android target SDK version level 23 or above, you must add code to
request permissions at runtime. For more detailed instructions and example code, see Requesting
Android Permissions on page 210.
3) Change the positioning data source and start PositioningManager
After completing the previous configuration steps, change the Positioning Manager data source to HERE
Positioning and start the Positioning Manager with the suitable location method to start receiving HERE
Positioning location updates:
m_hereDataSource = LocationDataSourceHERE.getInstance();
if (m_hereDataSource != null) {
PositioningManager pm = PositioningManager.getInstance();
pm.setDataSource(m_hereDataSource);
pm.addListener(new WeakReference<PositioningManager.OnPositionChangedListener>(this));
if (pm.start(PositioningManager.LocationMethod.GPS_NETWORK_INDOOR)) {
// Position updates started successfully.
}
}
For detailed description of the location methods available for the HERE Positioning location data source,
please see the section Location Methods on page 88.
Note:
LocationDataSourceHERE.getInstance() cannot be instantiated if no HERE Positioning
features are enabled in the SDK license.
You cannot start PositioningManager with a location method containing indoor positioning
without first setting location data source to HERE
You can only start PositioningManager with a location method that is enabled by your
business plan.
When using a location method containing indoor positioning, the indoor positioning mode can
be controlled. Please see the section Indoor Positioning Mode on page 89 below for further
information.
4) Receive and handle location updates
The location updates are handled by onPositionUpdated() (when the device location
changes) and onPositionFixChanged() (when location method changes) methods from
OnPositionChangedListener:
@Override public void onPositionUpdated(final PositioningManager.LocationMethod locationMethod,
final GeoPosition geoPosition, final boolean mapMatched) {
// new position update received
}
@Override public void onPositionFixChanged(PositioningManager.LocationMethod locationMethod,
PositioningManager.LocationStatus locationStatus) {
// positioning method changed
HERE Android SDK Developer's Guide
User Guide
88
}
Note:
PositioningManager.OnPositionChangedListener represents an interface for the
position update listeners.
GeoPosition carries GeoCoordinate that contains the device WGS84 Latitude/Longitude
coordinates and altitude with double precision. In addition, GeoPosition carries location
uncertainty estimate as well as speed and heading information.
For indoor positioning, GeoPosition carries building information (building name and building
ID) as well as floor level information.
Location Methods
The Location methods refers to the set of technologies used in the location determination. HERE Positioning
supports a plethora of location methods. The following table introduces the location methods that the
PositioningManager can be started with, when the location data source is LocationDataSourceHERE.
Table 2: Supported Location Methods
Method Description
GPS Uses the satellite-based positioning (GNSS) as provided by the Android platform.
NETWORK Uses the online or offline wifi or cellular network positioning methods, depending upon the device
capabilities, always selecting the best radio technology for location estimation.
INDOOR Uses either wifi or Bluetooth radio to provide indoor location estimates, with building and floor information,
always selecting the best radio technology in case both are available.
GPS_NETWORK Uses satellite-based positioning and network positioning, always selecting the best technology for optimal
location estimation.
GPS_NETWORK_INDOOR Uses satellite-based positioning, network positioning and indoor positioning, always selecting the best
technology for optimal location estimation.
Pre-downloading radiomaps to the device
The RadioMapLoader interface provides a mechanism to pre-download radiomaps surrounding a specified
center point to the device. Having pre-downloaded radiomaps to the device, the device can be located
without data connectivity. In addition to the center point, the interface needs to be provided with the type of
the radiomap to be downloaded. The available types are:
Table 3: Radiomap types available for pre-download
Mode Description
SPARSE Configures the download of the cellular radiomaps for coarse positioning (accuracy hundreds of meters) within
15 kilometers from the center point.
COARSE Configures the download of the cellular radiomaps and the highly compressed wifi radiomaps to balance data
consumption and positioning accuracy. Radiomaps are downloaded within 5 km from the center point.
DETAILED Configures the download of the cellular radiomaps and the less compressed wifi radiomaps to favor accuracy
over data consumption. Radiomaps are downloaded within one km from the center point.
INDOOR Configures the download of the radiomaps necessary for indoor positioning. Radiomaps are downloaded within
500 m from the center point.
HERE Android SDK Developer's Guide
User Guide
89
Instead of defining the center point and the radiomap type to the interface, it is also possible to provide the
Venue Map information as com.here.android.mpa.venues3d.Venue to the interface. In this case the job
downloads the radiomaps necessary for indoor positioning at that particular venue.
The interface also provides a mechanism to delete all the downloaded radiomaps as well as to observe the
status and the progress of the download job.
Indoor Positioning Mode
The indoor positioning mode refers to the set of radiomaps used by the indoor positioning engine. For
detailed discussion on the different radiomaps, please refer to HERE Indoor Positioning Installation Guide.
Indoor positioning can be configured to run in four different modes, which are defined by
the LocationDataSourceHERE.IndoorPositioningMode enumeration. Use the method
setIndoorPositioningMode() from the LocationDataSourceHERE class to change the indoor
positioning mode. Use the method getIndoorPositioningMode() from the same class to check the
current mode.
The following table introduces the four indoor positioning modes.
Table 4: Indoor Positioning Modes Supported by the HERE Positioning
Mode Description
AUTOMATIC HERE Positioning automatically chooses which mode to apply. Requires that the SDK license has both public
and private indoor positioning features enabled. If both features are enabled in the SDK license, then this
positioning mode is set as the default.
COMMUNITY Community indoor radiomap is used by the indoor positioning engine. Requires that the SDK license has the
public indoor positioning feature enabled. If only the public indoor positioning feature is enabled in the SDK
license, then this indoor positioning mode is set as the default.
PRIVATE The customer's private indoor radiomap is used by the indoor positioning engine. Requires that the SDK license
has private indoor positioning feature enabled. If only the private indoor positioning feature is enabled in the
SDK license, then this indoor positioning mode is set as the default.
DRAFT Mode used for testing the draft indoor radiomap before publishing the draft to production servers. Requires
that either public or private indoor feature is enabled in the SDK license. Please see the Using the Draft Indoor
Positioning Mode on page 89 section below for further details.
Using the Draft Indoor Positioning Mode
A Draft Radiomap is a sandbox for the system operators and developers to test and try out positioning
without affecting the applications using HERE Indoor Positioning. When radio data is collected and tested in
the HERE Indoor Radio Mapper, the tool always uses a Draft Radiomap. Once the Draft Radiomap shows good
performance, the radio data is published to the production radiomap (private or public one, depending upon
the venue type) for the use by HERE Android SDK.
In the production configuration, HERE Android SDK fetches positioning data from the production radiomaps.
However, for R&D purposes, HERE Android SDK can be configured to use a draft radiomap. The DRAFT
indoor positioning mode allows testing the unpublished draft indoor radiomap in the actual application
(as opposed to testing only in the HERE Indoor Radio Mapper) before publishing the Draft Radiomap to
production. However, since this is an R&D feature, this mode is limited to a maximum of ten devices that
have to be defined before compiling the application.
HERE Android SDK Developer's Guide
User Guide
90
For detailed discussion on the radiomaps and data flows, please refer to HERE Indoor Positioning Installation
Guide.
To enable the DRAFT indoor positioning mode for a specific device, do the following:
1. Find out the Android ID of the device that you want to enable the DRAFT indoor positioning mode for.
a. Run command adb shell getprop | grep net.hostname via the Android debug bridge
b. Inspect the command output. For example:
[net.hostname]: [android-1234567812345678]
The Android ID is what appears after the string "android-".
c. Please note that the Android ID may change when the device factory settings are returned or when
switching the user profile in a device with multi-user support
2. Add a new XML resource to your project using the Android Studio and name it, for example, as
draft_enabled_devices.xml
3. Add the Android ID to the string-array within resources as follows in
draft_enabled_devices.xml:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string-array name="draft_enabled_devices">
<!—My Android device -->
<item>1234567812345678</item>
</string-array>
</resources>
Note: Up to ten Android IDs can be defined in the string-array. If more than ten Android IDs
are defined, none of them will work.
4. Add a new metadata element defining the draft-enabled devices to your AndroidManifest.xml:
<meta-data android:name="com.here.location.indoor_draft_access"
android:resource="@array/draft_enabled_devices" />
Note: This field must be added at the same level with the HERE Application ID, Application Code
and the SDK License.
Note: The resource name must match to the string-array name created in the step 3.
Indoor Positioning-specific Methods
HERE Positioning has three indoor positioning-specific methods, which are methods of geoPosition class:
String getBuildingName()
Returns the BuildingName, if known. If the BuildingName is not present, null is returned.
For HERE Venue Maps the BuildingName is assigned by HERE, when creating the Venue Map. This
method returns that name.
For custom indoor maps, the BuildingName is the one given when the indoor map was imported using
HERE Indoor Radio Mapper. However, illegal characters are removed from the name.
String getBuildingId()
Returns the BuildingID, if known. If the BuildingID is not present, null is returned.
HERE Android SDK Developer's Guide
User Guide
91
For HERE Venue Maps, the BuildingID is the globally unique ID assigned by HERE, when creating the
Venue Map. An example of a HERE Venue Map BuildingID is DM_8213.
For custom indoor maps, the BuildingID is the customer-defined BuildingName, prefixed with BM_.
If the position estimate is outdoors, but indoor positioning is used for producing the location estimate,
the string OUTDOOR is returned.
Integer getFloorId()
Returns the floor level. If the FloorId is not present, null is returned.
For HERE Venue Maps, the floor levels are returned as defined for the particular the HERE Venue Map.
For custom indoor maps, the FloodId follows the customer-defined floor levels specified in HERE
Indoor Radio Mapper, when the indoor maps were imported.
Receiving Detailed Status Reports and Diagnostics
Status Listener
StatusListener provides information on the few most typical issues that prevent the usage of HERE
Indoor Positioning. An instance of StatusListener is given as an input parameter, when creating an
instance of HERE Positioning: LocationDataSourceHERE.getInstance(StatusListener).
The following table details the return codes as defined in StatusListener.PositioningError.
Table 5: Status messages provided by StatusListener
Status message Description
INJECT ERROR Coarse location could not be resolved. HERE Indoor Positioning requires coarse location to retrieve the correct
positioning data from the HERE positioning servers.
NO COVERAGE No radiomaps were found in the vicinity of the resolved coarse location. Please ensure you have created indoor
positioning coverage with HERE Indoor Radio Mapper and that the data has been published for use.
NOT FOUND HERE Indoor Positioning coverage exists for the area, but resolving position failed. Please make sure that your
latest data has been published in HERE Indoor Radio Mapper.
Diagnostics Listener
DiagnosticsListener provides more detailed information on the most typical issues preventing
the usage of HERE Indoor Positioning. The diagnostics listener can be set up via the method
setDiagnosticsListener.
The following table lists the events that can be received through the DiagnosticsListener.
Table 6: Diagnostics messages provided by DiagnosticsListener
Diagnostics message Category Description
List of the enabled positioning
methods
info Lists the positioning methods at your disposal.
List of the requested and
enabled positioning methods
info Lists the requested positioning methods in addition to the allowed positioning
methods. In case you are missing a method you would like to use, please contact
your HERE representative.
HERE Android SDK Developer's Guide
User Guide
92
Diagnostics message Category Description
No license to use any of the
requested positioning methods
error In case none of the requested methods is enabled in your license, positioning
cannot be performed. Please use a method allowed by your license.
Dynamic permissions are not
set for the application and
service cannot be started
error Please set the permissions as instructed in Using HERE Positioning on page 86
No reference position error The same as INJECT ERROR above.
No coverage error The same as NO COVERAGE above.
Not found error The same as NOT FOUND above.
Device Settings
The device settings may have a major impact on positioning accuracy and may even prevent HERE
Positioning from functioning altogether—for example, disabling GPS/GNSS, network location support, or
radio technologies prevent HERE Positioning from functioning normally. As a developer you should detect
these situations, let the application user know about the situation, and inform the user about the possible
corrective action. The following table lists the situations that may impact positioning, and the corrective
action for each case.
Table 7: Device Settings and Corrective Actions
Situation Impact Corrective Action
Device Only Location mode is selected from
the device location settings.
HERE Positioning is not allowed to perform
network or indoor positioning.
Notify the user about the situation and
inform the user to switch the Location
mode to High accuracy.
Battery Saving Location mode is selected
from the device location settings.
HERE Positioning is not able to use
satellite-based positioning.
Notify the user about the situation and
inform the user to switch the Location
mode to High accuracy.
Airplane mode is enabled. By default, the airplane mode shuts down
device radios preventing either all the
network measurements or only cellular
measurements, depending on how the user
has modified device settings after enabling
the airplane mode.
Notify the user about the situation. Do not
inform the user to turn off the airplane
mode without warning, because there
might be a valid reason why airplane mode
is enabled.
wifi is disabled. Disabling wifi scans prevents wifi-based
outdoor and indoor positioning.
Notify the user about the situation and
inform the user to switch the wifi radio on,
or to turn on Scanning always available
option from the wifi advanced settings or
from the location settings.
Bluetooth is disabled. Disabling Bluetooth prevents Bluetooth-
based indoor positioning.
Notify the user about the situation and
inform the user to switch the Bluetooth
radio on, or to turn on Scanning always
available option from the Bluetooth
advanced setting or from the location
settings.
HERE Android SDK Developer's Guide
User Guide
93
Power Consumption Considerations
HERE Positioning power consumption depends heavily on the used LocationMethod. As a rule of thumb,
network (wifi or cellular) positioning consumes less power than GNSS and indoor positioning. If your
application does not require the highest possible accuracy, you should consider using network positioning to
save energy.
Online network positioning consumes more energy than offline network positioning. In a typical setting
offline positioning uses up to 80-90% less energy than online positioning. The difference is mainly because
of the network connection usage in online network positioning.
In order to save energy, you should also consider pausing position updates when your application is moved
to the background, unless your application is dependent on frequent location updates even when the
application is in the background.
Troubleshooting HERE Positioning
If your application does not receive any position updates while using HERE Positioning, try the following:
Check that the Android permissions are set as defined in this document
Check that the positioning service is correctly defined in the application manifest
Make sure that the relevant network settings are enabled:
Go to System settings and check that Wifi, Cellular and Bluetooth (if the indoor feature is used) are
enabled.
Make sure that the device has network connection
Check that the high accuracy location settings is enabled:
Device-only location setting prevents network and indoor positioning
battery-saving location setting prevents GNSS positioning
Make sure the indoor positioning mode is correctly set
Log events from StatusListener and DiagnosticsListener
If your application receives inaccurate position estimates while using HERE Positioning, try the following:
Make sure that you have wifi and Bluetooth (for indoor positioning) network measurements enabled
Use the best-suited LocationMethod for your applications when requesting location updates
Check that the high accuracy location settings is enabled
If you are trying to use indoor positioning, make sure that the location estimates really originate
from the indoor positioning engine by checking the position source through GetPositionSource
on GeoPosition. Moreover, please check that the positioning technology is as expected through
GetPositionTechnology.
Force the download of the latest indoor positioning data by deleting the folder sdcard/Android/
data/{your_package_name}/files/rmb and restarting the application.
Map Matching
The HERE Android SDK performs Map Matching automatically when it needs to match a raw position to the
road network, such as during drive guidance, where there may be inaccuracies in the road rendering or GPS
data. Map matching also supports instances where the GPS signal is lost while entering a road tunnel. The
position is extrapolated and updated based on the driver’s speed and knowledge of the tunnel layout.
HERE Android SDK Developer's Guide
User Guide
94
Automotive Map Matching
The HERE Android SDK supports high-accuracy map matching through the
LocationDataSourceAutomotive class. As a requirement to use this class, you must have positioning
data input from a GNSS module that supports dead reckoning. This ensures a continuous and reliable stream
of position updates even in cases where the GPS becomes unavailable (for example, when the user is driving
in a tunnel). It is strongly recommended that position updates are provided, at a constant rate of 10 Hz,
together with standard deviations of the following:
Horizontal radial error (large component)
Horizontal radial error (small component)
• Course
• Speed
• Elevation
Note:
Automotive Map Matching is currently offered as a beta feature. APIs may change without notice.
Automotive Map Matching does not support tunnel extrapolation.
Custom Data Sources
In general, you can use any custom positioning data by implementing the LocationDataSource class and
set it by calling PositioningManager.setDataSource(LocationDataSource) before starting the
positioning manager.
Note: While LocationDataSource.start(LocationMethod) requires a
LocationMethod parameter, it is not necessary for your data source to support all
PositioningManager.LocationMethod types.
You can support tunnel extrapolation while using a Custom Data Source by following these steps:
1. When the data source location data is unavailable, check to see if the device is currently in a tunnel:
RoadElement roadElement = getPositioningManager().getRoadElement();
if (roadElement != null
&& roadElement.getAttributes().contains(RoadElement.Attribute.TUNNEL)) {
return true;
}
return false;
2. If the device is in a tunnel, submit a null location through
LocationDataSource.onLocationUpdated(LocationMethod, Location) at an interval of once
per second. The HERE SDK then provides an extrapolated position in the tunnel.
3. Continue to periodically send null positions to the positioning manager while the device is in a tunnel.
You can implement a timer so that onLocationUpdated(LocationMethod, Location) calls stop
after a period of time (after one minute, for example), and re-enable updates when location data is
available again.
HERE Android SDK Developer's Guide
User Guide
95
Directions
This section provides an overview of the Directions feature in the HERE SDK. The Directions feature allows
developers to define and display routes between a start and a destination point within their application. It
supports many navigation options such as toll road preference and transport type.
Car and Pedestrian Routing
The HERE Android SDK supports route calculation with multiple waypoints, optimized for walking or driving. A
route describes a path between at least two waypoints, the starting point and the destination, with optional
intermediate waypoints in between. Applications can provide route information to users in two ways:
A line rendered on a map that displays a connecting path between all waypoints
Turn-by-turn directions in text format
Route Calculation Classes
This section introduces the following classes that are used for route calculations:
CoreRouter
RoutePlan
RouteWaypoint
RouteOptions
The CoreRouter class is responsible for calculating car, pedestrian, and truck routes. An application
can initiate a route calculation by calling the CoreRouter.calculateRoute(RoutePlan,
CoreRouter.Listener) method, providing options and waypoints through RoutePlan, and receive
progress events through the Router.Listener instance.
Note: The CoreRouter can also calculate routes with traffic taken into account by using
Route.TrafficPenaltyMode and setDynamicPenalty(DynamicPenalty) before calling
calculateRoute(). For more information on the DynamicPenalty class, see Dynamic Routing
Penalty on page 98.
RoutePlan is a waypoint container that is used for route calculation. A RoutePlan object is comprised of
a list of waypoint objects and an optional RouteOptions. If RouteOptions is not specified, default values
are used.
You can use RouteWaypoint to add more waypoint details to a route calculation. These details include
whether a waypoint is a deliberate stopover or a via point that the route must pass through. This affects
routing, as routes containing stopovers or via waypoints may be different. For example, a calculated route
may suggest a U-turn maneuver after a stopover, while a route containing the same location as a via
waypoint suggests continuing on the same street. The via waypoint type is only supported in car routes, and
it is not supported in other route types.
The RouteOptions class is a model of the parameters required to calculate one route. It encapsulates
"building block" parameters for a route such as:
The desired number of routes
HERE Android SDK Developer's Guide
User Guide
96
The direction of travel that the route should start in
The routing type, such as fastest travel time or shortest distance
The departure time
The allowed types of route segments, such as dirt roads or highways
The HERE SDK supports alternate routes between two waypoints. The alternate route feature allows more
than one route to be returned after a route calculation. You can use the RouteOptions class to set the
desired number of routes, and the HERE SDK then returns different routes according to this limit. Note that
the first element of the returned list of RouteResult is the main route, and the rest of the returned routes
are not listed in any specific order.
Note: Do not set more than three desired routes in offline mode, as these route calculations take
significantly more time to complete.
Note: In some cases, specifying a higher route count than a previous working query can result in
a GRAPH_DISCONNECTED error. This is due to a limit on the complexity and size of the calculated
routes that can be processed. The higher the route count and the more complex a route is, the more
likely that this limit is exceeded.
RouteResult and Route
The RouteResult class represents a route calculation result. Applications can retrieve a Route
object and the corresponding set of violated routing conditions. Violated routing options are the
conditions that a routing result was unable to adhere to. For example, after specifying a route calculation
that avoids tolls and ferries, you may get a RouteResult that contains a Route object along with
RouteResult.ViolatedOption.AVOID_TOLL_ROADS. This indicates that although a route was found, this
route goes through at least one toll road—violating a condition of your route request.
The Route class is a distinct calculated path connecting two or more waypoints, consisting of
a list of maneuvers and route links. By using CoreRouter.calculateRoute(RoutePlan,
CoreRouter.Listener) to trigger a route calculation, your application can use the
CoreRouter.Listener to monitor the calculation and trigger callback methods. These callback methods
have parameters that include a list of the calculated RouteResult objects. Using these RouteResult
objects, you can call getRoute() to retrieve the routes.
The MapRoute map object
The MapRoute class is a type of MapObject that displays a calculated route on a map. Typically, an
application creates a MapRoute after a route calculation, passing the relevant Route object as a
parameter to the MapRoute(Route) constructor before adding the MapRoute to the map by calling
Map.addMapObject(MapRoute).
Note: MapRoute.setRenderType(RenderType) must be called after the MapRoute is added to a
Map.
HERE Android SDK Developer's Guide
User Guide
97
For example, if you want to render a route that connects two waypoints (start and destination), you can add
the following application logic:
Figure 49: Calculate Route
1. Declare a CoreRouter instance.
// Declare the variable (the CoreRouter)
CoreRouter router = new CoreRouter();
2. Create a RoutePlan and add two GeoCoordinate waypoints.
// Create the RoutePlan and add two waypoints
RoutePlan routePlan = new RoutePlan();
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.1966286, -123.0053635)));
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.1947289, -123.1762924)));
3. Create a new RouteOptions object, set its Type and TransportMode values by calling appropriate
RouteOptions methods, and then add it to RoutePlan.
// Create the RouteOptions and set its transport mode & routing type
RouteOptions routeOptions = new RouteOptions();
routeOptions.setTransportMode(RouteOptions.TransportMode.CAR);
routeOptions.setRouteType(RouteOptions.Type.FASTEST);
routePlan.setRouteOptions(routeOptions);
4. To make sure route calculation can handle returning a Route object that in turn can be used
to create a MapRoute instance for rendering on the map, add an inner class by implementing
CoreRouter.Listener in the appropriate activity class.
private class RouteListener implements CoreRouter.Listener {
HERE Android SDK Developer's Guide
User Guide
98
// Method defined in Listener
public void onProgress(int percentage) {
// Display a message indicating calculation progress
}
// Method defined in Listener
public void onCalculateRouteFinished(List<RouteResult> routeResult, RoutingError error) {
// If the route was calculated successfully
if (error == RoutingError.NONE) {
// Render the route on the map
mapRoute = new MapRoute(routeResult.get(0).getRoute());
map.addMapObject(mapRoute);
}
else {
// Display a message indicating route calculation failure
}
}
}
5. After adding the inner listener class (named RouteListener for this example), calculate the route
by calling CoreRouter.calculateRoute(RoutePlan, CoreRouter.Listener). Note that
CoreRouter.Listener extends Router.Listener<List<RouteResult>, RoutingError>.
// Calculate the route
router.calculateRoute(routePlan, new RouteListener());
Dynamic Routing Penalty
You can use DynamicPenalty to create a policy of roads and area restriction factors that are applied during
routing calculations. For example, you can use this class to indicate that the travel speed in an area is 50
percent slower than usual. The DynamicPenalty class also allows you to set the mode used for handling
traffic events in a route calculation through the setTrafficPenaltyMode(TrafficPenaltyMode)
method.
You can change the active policy by calling CoreRouter.setDynamicPenalty(DynamicPenalty). The
policy must be set before a route calculation for the restrictions to be taken into account.
Retrieving Traffic Event Objects
You can use the TrafficUpdater class to retrieve traffic events such as road closures or congestions.
Before using the traffic updater, it must be be enabled via TrafficUpdater.enableUpdate(boolean
update) for the traffic requests to take effect.
Using the TrafficUpdater is a two-step process. First, create a TrafficUpdater.Listener and use it
with one of the following methods:
request(GeoCoordinate center, Listener listener) - request traffic with given center
coordinates and the default radius
request(GeoCoordinate center, int radius, Listener listener) - request traffic with
given center coordinates and radius
request(Route route, Listener listener) - request traffic for the given route and default
radius around each waypoint
request(Route route, int radius, Listener listener) - request traffic for given route and
radius around each waypoint
HERE Android SDK Developer's Guide
User Guide
99
request(RouteElements elements, Listener listener) - request traffic for a route element
(RouteElement) object
Upon the successful callback from TrafficUpdater.Listener (with the state
TrafficUpdater.RequestState.DONE), you should retrieve a list of traffic events that affect the given
route or route element by using one of the following methods:
getEvents(Route route, GetEventsListener listener)
getEvents(RouteElement element, GetEventsListener listener)
getEvents(List<RouteElement> elements, GetEventsListener listener)
getEvents(RouteElements elements, GetEventsListener listener)
TrafficUpdater.GetEventsListener contains one callback method,
onComplete(List<TrafficEvent> events, Error error), which provides a newly updated list of
traffic events.
Routing-related Enumerations
Route calculations make use of HERE SDK enumerations that include:
The Route.TrafficPenaltyMode enum - represents values describing how the CoreRouter should
handle traffic events in a route calculation, such as DISABLED, AVOID_LONG_TERM_CLOSURES, or
OPTIMAL.
The RouteOptions.Type enum - represents values describing different routing types, such as
FASTEST or SHORTEST
The RouteOptions.TransportMode enum - represents values describing different transport modes,
such as CAR, TRUCK, TRACK (which connects waypoints using straight lines), or PEDESTRIAN
The RoutingError enum - represents values describing possible route calculation errors, such as NONE
or VIOLATES_OPTIONS
The RouteResult.ViolatedOption enum - represents values describing possible route option
violations, such as AVOID_HIGHWAYS or AVOID_FERRIES
Bicycle Routing
The bicycle routing feature provides route calculation using car and pedestrian roads with bicycle-specific
speed estimations. This type of routing can be performed online or offline, with elevation data being
available in an online request.
Note:
Bicycle routing is currently offered as a beta feature. APIs may change without notice. Do not use
this feature in a commercial application.
Bike-specific roadways are not yet supported.
Bicycle routing includes pedestrian-only roads and road segments that require traversing a one-way road
opposite the allowed direction of travel. When a road is not open for driving in the travel direction, the
routing algorithm assumes that the user must walk the bicycle, and therefore it uses the pedestrian walking
speed for such segments. As a special exception to this rule, pedestrian segments located in parks are
assumed to be open for bicycles, so full bicycle speed is used there. Generally, such walk-only segments
are used in bicycle routing only when they provide a big shortcut, or when a waypoint is located on such a
segment.
HERE Android SDK Developer's Guide
User Guide
100
Performing a Bicycle Routing Request
You can perform bicycle routing by using the CoreRouter class and
RouteOptions.TransportMode.BICYCLE, as shown in the following example:
CoreRouter router = new CoreRouter();
// Create the RoutePlan and add two waypoints
RoutePlan routePlan = new RoutePlan();
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.276271, -123.113224)));
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.1947289, -123.1762924)));
RouteOptions routeOptions = new RouteOptions();
routeOptions.setTransportMode(RouteOptions.TransportMode.BICYCLE);
routeOptions.setRouteType(RouteOptions.Type.FASTEST);
routePlan.setRouteOptions(routeOptions);
// Calculate the route, assuming that you have already implemented RouteListener.
// See the Car Routing section for more details.
router.calculateRoute(routePlan, new RouteListener());
Route Elevation
In an online bicycle routing session, the HERE SDK considers elevation changes when determining what
speed should be used on the given road. When going uphill, speed decreases, possibly down to the
pedestrian speed. When going downhill, speed increases.
Note: Elevation-based speed estimations may change in the future.
You can also create an elevation profile of a route, similar to the following screenshot, by using altitude data
of the points on a calculated route.
Figure 50: Plotted Chart of Elevations
To retrieve this elevation data, call the Route.getRouteGeometryWithElevationData() method and
inspect the altitude on each returned GeoCoordinate object. If the altitude is not known at that location,
calling GeoCoordinate.getAltitude() returns the GeoCoordinate.UNKNOWN_ALTITUDE value.
Note: Route altitude data is available in online calculated routes for cars, pedestrians, trucks, and
bicycles.
Truck Routing
The Truck Routing feature in the HERE SDK allows users to calculate routes that can be specifically traveled
by trucks and commercial vehicles. Commercial vehicles typically have different regulations for their
transportation routes. For example, a government may have laws that restrict trucks carrying flammable
materials from traveling in a residential area. By using the Truck Routing feature, you can launch a route
calculation that specifically adheres to these restrictions.
HERE Android SDK Developer's Guide
User Guide
101
Truck Routing and the RouteOptions Class
The RouteOptions class contains a number of truck-specific methods and enums that you should use
before performing a route calculation. To perform a truck route calculation, use the TransportMode.TRUCK
enum with the setTransportMode(TransportMode) method to specify the route transportation type. You
can also set the following truck-specific route options before performing the route calculation:
The number of truck trailers
The truck height
The truck length
The truck width
The maximum allowed truck weight
Hazardous goods that are transported by the truck
The category of tunnels that the truck can travel on
The truck's weight per axle
Difficult turns
Note: Truck routing only supports the RouteOptions.Type.FASTEST routing type. Other routing
types are not supported.
A Route Calculation Example
1. As with the previous routing example, retrieve the CoreRouter, create a RoutePlan and set its
waypoints.
2. Create a new RouteOptions object. The TransportMode should be set to TRUCK.
// Create the RouteOptions and set its transport mode & routing type
RouteOptions routeOptions = new RouteOptions();
routeOptions.setTransportMode(RouteOptions.TransportMode.TRUCK);
routeOptions.setRouteType(RouteOptions.Type.FASTEST);
3. Set other truck routing options.
routeOptions.setTruckTunnelCategory(TunnelCategory.E)
.setTruckLength(25.25f)
.setTruckHeight(2.6f)
.setTruckTrailersCount(1);
4. Set the RouteOptions to the RoutePlan.
routePlan.setRouteOptions(routeOptions);
5. Create a CoreRouter.Listener and then calculate the route by calling
CoreRouter.calculateRoute(RoutePlan, Listener).
Transit Routing
Transit Routes are routes calculated by using CoreRouter with the the RouteOptions transport mode set
to PUBLIC_TRANSPORT. With the transit routing feature, you can calculate transit routes by using known
online timetable information.
HERE Android SDK Developer's Guide
User Guide
102
Note:
RouteOptions.TransportMode.PUBLIC_TRANSPORT is no longer deprecated as of HERE SDK
v3.4.
To use this feature, your application must include the Gson library (release 2.2.4 or a compatible
version) on its class path.
Before displaying transit routing, you should set the map scheme to include transit so that the MapRoute
shows the color of the transit lines.
// sets the map scheme to include transit.
map.setMapScheme(Map.Scheme.NORMAL_DAY_TRANSIT);
The following is an example of a transit route using CoreRouter:
...
CoreRouter router = new CoreRouter();
// Select routing options
RoutePlan routePlan = new RoutePlan();
RouteOptions routeOptions = new RouteOptions();
routeOptions.setTransportMode(RouteOptions.TransportMode.PUBLIC_TRANSPORT);
routeOptions.setRouteType(RouteOptions.Type.FASTEST);
routePlan.setRouteOptions(routeOptions);
// Select Waypoints for your routes
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.1966286, -123.0053635)));
routePlan.addWaypoint(new RouteWaypoint(new GeoCoordinate(49.1947289, -123.1762924)));
router.calculateRoute(routePlan, new RouterListener());
...
private final class RouterListener implements CoreRouter.Listener {
// Method defined in Listener
public void onProgress(int percentage) {
// Display a message indicating calculation progress
}
// Method defined in Listener
public void onCalculateRouteFinished(List<RouteResult> routeResult, RoutingError error) {
// If the route was calculated successfully
if (error == RoutingError.NONE) {
// Render the route on the map
mapRoute = new MapRoute(routeResult.get(0).getRoute());
map.addMapObject(mapRoute);
// Get the bounding box containing the route and zoom in (no animation)
GeoBoundingBox gbb = routeResult.get(0).getRoute().getBoundingBox();
map.zoomTo(gbb, Map.Animation.NONE, Map.MOVE_PRESERVE_ORIENTATION);
}
else {
// Display a message indicating route calculation failure
}
}
HERE Android SDK Developer's Guide
User Guide
103
}
Figure 51: Transit Route
The TransitRouteElement Class
Transit route elements, which are route element objects specific to public transit, can be retrieved from the
getTransitElement() method in the RouteElement class.
Urban Mobility Routing
With the Urban Mobility Routing feature, you can calculate transit routes and fare costs by using real time
online timetable information.
To perform this type of transit routing, use UMRouter in a similar manner to CoreRouter, while specifying
options through the UMRouteOptions class.
Notes and Disclaimers
Before using the Transit Routing feature, be aware of the following:
Transit routing is currently offered as a beta feature. APIs may change without notice.
Access to the Transit Routing feature is restricted. Contact a HERE representative (https://
developer.here.com/contact-us?interest=mobile-sdk#contact-sales) for more information and to request
for access.
To use this feature, your application must include the Gson library (release 2.2.4 or a compatible version)
on its class path.
HERE Android SDK Developer's Guide
User Guide
104
Urban Mobility routing is now offered as an additional feature outside of the evaluation package.
Urban Mobility Routing Example
The following is an example of how to calculate a public transit route that connects two waypoints (start and
destination):
1. Declare a UMRouter instance.
// Declare the variable (the UMRouter)
UMRouter router = new UMRouter();
2. Create a RoutePlan and add two GeoCoordinate waypoints.
// Create the RoutePlan and add two waypoints
RoutePlan plan = new RoutePlan();
// add start point to route plan
plan.addWaypoint(new RouteWaypoint(new GeoCoordinate(40.750488, -73.993546)));
// add end point to route plan
plan.addWaypoint(new RouteWaypoint(new GeoCoordinate(40.749877, -73.845853)));
Note: Destinations that are too close to the starting waypoint are not supported. Use a
pedestrian route calculation instead.
3. Create a new UMRouteOptions object and set the desired options. Add the route options to
RoutePlan.
// Create the UMRouteOptions and set its options
UMRouteOptions options = new UMRouteOptions();
// setup walk parameters
options.setTransitWalkMaxDistance(1000);
options.setTransitWalkTimeMultiplier(0.75f);
plan.setRouteOptions(options);
4. Create a UMRouter.Listener instance by implementing the
onCalculateRouteFinished(UMCalculateResult, ErrorCode) and onProgress(int)
methods. Note that the returned object, UMCalculateResult, may contain multiple route results
(UMRouteResult), each of which contains a single UMRoute.
UMRoute can be used to create a MapRoute instance for rendering purposes.
UMRouter.Listener listener = new UMRouter.Listener() {
@Override
public void onCalculateRouteFinished(UMCalculateResult response, ErrorCode error) {
if (error == ErrorCode.NONE) {
for (UMRouteResult result: response.getResults()) {
int changesCount = result.getUMRoute().getChangesCount();
List<Tariff> tariffs =
result.getUMRoute().getTariffs();
for (RouteSection section: result.getUMRoute().getSections()) {
Departure departure = section.getDeparture();
Collection<Alert> alerts = section.getAlerts();
}
// ...
MapRoute mapRoute = new MapRoute(result.getUMRoute());
// show mapRoute on the map
}
if (response.isSubsequentRouteSupported()) {
// UMRouter.calculateSubsequentRoute() can be used to calculate later routes
}
} else {
HERE Android SDK Developer's Guide
User Guide
105
String errorMessage = response.getErrorMessage();
// display error
}
}
@Override
public void onProgress(int percentage) {
// update progress
}
};
5. To perform subsequent route calculations, check if the returned UMCalculateResult object
supports subsequent routes, and call calculateSubsequentRoute(UMCalculateResult,
SubsequentRouteType, int, UMRouter.Listener) as needed. For more information on
subsequent routes, see the Subsequent Routes section in this chapter.
6. After adding the listener class (named listener for this example), calculate the route by calling
UMRouter.calculateRoute(RoutePlan, UMRouter.Listener). Note that UMRouter.Listener
extends Router.Listener<List<RouteResult>, RoutingError>.
// Calculate the route
router.calculateRoute(routePlan, listener);
7. You are required to display the source attribution, retrieved through the
Route.getTransitRouteSourceAttribution() method somewhere near the route results.
8. Geometry, line color, and other types of display information can be retrieved through
TransitRouteElement objects, available through the UMRoute. You can retrieve and display ticket
fare information by using the Ticket objects inside UMRoute.
Subsequent Routes
The UMRouter class supports subsequent route calculations based on an initial set of route results.
For example, you can use UMRouter to launch a route calculation, and then use the returned
UMCalculateResult to launch a subsequent route calculation for three routes that have the same
waypoints, but have an earlier departing time.
You do not need to specify a timestamp for the subsequent calculation. The HERE SDK will automatically
return your desired number of results based on whether you specified earlier or later. In other words, you
can "slide" the window of interested route results by specifying SubsequentRouteType.EARLIER or
(SubsequentRouteType.LATER) and the desired number of results.
The method to perform this calculation is
UMRouter.calculateSubsequentRoute(UMCalculateResult, SubsequentRouteType, int,
UMRouter.Listener).
Displaying Transit Routes
Before displaying transit routing, you should set the map scheme to include transit so that the MapRoute
shows the color of the transit lines.
// sets the map scheme to include transit.
HERE Android SDK Developer's Guide
User Guide
106
map.setMapScheme(Map.Scheme.NORMAL_DAY_TRANSIT);
Figure 52: Transit Route
The TransitRouteElement Class
Transit route elements, which are route element objects specific to public transit, can be retrieved from the
getTransitElement() method in the RouteElement class.
Online Timetables and Fallback Scenarios
Wherever possible, the HERE SDK performs route calculations using the latest online timetable data from
municipalities. This is performed automatically when you launch a transit routing request, but the following
conditions must be fulfilled:
Your application must have an active data connection. If there is no data connection, an estimated
routing is performed instead.
The route must be between two endpoints—an origin and a destination. Multiple endpoints are not
supported.
This type of calculation only returns a maximum of ten route results, even if the limit set in the
RouteOptions.setRouteCount(int) exceeds it.
Note: The following route options are ignored in this route calculation mode:
setTransitMinimumChangeTime(int)
setTransitWalkTimeMultiplier(int)
In addition, the setTransitMaximumChanges(int) option is supported in the primary route result,
but the maximum number of changes is capped at ten.
HERE Android SDK Developer's Guide
User Guide
107
Note: Contractual limitations exist for Online Timetable coverage in Paris, France and Germany.
Contact your HERE SDK Sales, Marketing, or Product representative for additional details.
Indoor Venue Routing
For more information on 3D venues and indoor routing, see 3D Venues on page 164 and Venue Routing on
page 175.
Offline Routing
Even without an active data connection, the applications developed with the HERE Android SDK are able to
request routing information to assist travelling from one location to another.
Your application's users do not need to maintain active, data connections to calculate routes and render
them on a map. It is possible to pre-download updated maps and database information for initiating routing
requests while offline. For example, if a user has downloaded offline maps of California and Oregon, a route
from San Diego to Portland can be created without any data connection.
For more information about downloading offline maps, refer to Offline Maps (MapLoader) on page 52.
Force Online or Offline
You can launch online or offline routing without changing the device or the HERE SDK connectivity by using
the setConnectivity(Connectivity) method on a CoreRouter instance. Connectivity has three
possible values:
If you launch a request using the DEFAULT connectivity mode, the request is performed according to
the MapEngine connectivity setting. If the device is offline while MapEngine is set to online mode, the
request fails.
If you launch a request using the ONLINE connectivity mode, an online request is performed, regardless
of the MapEngine connectivity setting.
If you launch a request using the OFFLINE connectivity mode, an offline request is performed using
cached data, regardless of the MapEngine connectivity setting.
In all cases, if the request fails, no fallback action is automatically performed.
To ensure that the connectivity mode is applied, call setConnectivity(Connectivity) before launching
a CoreRouter calculation request. If a Connectivity.ONLINE route calculation request fails due to
connection issues, the HERE SDK returns the RoutingError.NETWORK_COMMUNICATION error code. If a
Connectivity.OFFLINE route calculation request fails due to not enough cached data, the HERE SDK
returns the RoutingError.GRAPH_DISCONNECTED error code.
Note: This feature is only applicable to car, bicycle, truck, and pedestrian routing through the
CoreRouter class.
Route Consumption
Route consumption calculation is a beta feature which allows the consumption of fuel resources, such as
gasoline or electricity, to be calculated for a given, already calculated route.
HERE Android SDK Developer's Guide
User Guide
108
Vehicles have a limited range depending on the amount of fuel remaining and how much fuel the vehicle
consumes per kilometre under different driving conditions. This is especially important for electric vehicles,
which can typically travel less distance on a full charge than a gasoline powered vehicle could travel on a full
tank.
In order to ensure that a vehicle is able to complete a calculated route, the HERE Android SDK can calculate
the consumption for each element in that route given certain consumption parameters. This allows the
developer to, firstly, determine how much fuel the vehicle will have left at the end of the route and, secondly,
check where vehicle would run out of fuel in the case that the final destination is not reachable.
Since different vehicles consume different types of fuel (such as gasoline and electricity) and also have
different rates of consumption, the consumption calculation must be configured with consumption
parameters for a given vehicle before the calculation is performed.
An important concept for consumption calculation is the capacity unit. The capacity unit is how fuel is
measured for a given vehicle. Because consumption calculation is general, the unit is effectively defined
by the developer. For an electric vehicle the capacity unit is generally kilowatt hours (kWh), for a gasoline
powered vehicle it could be liters of gasoline.
A vehicle will have a maximum capacity and current capacity, which indicates how much fuel it can hold in
total and the current amount respectively.
In the following description, we will assume that we are calculating consumption for an electric vehicle, since
this is the most common use case. The capacity unit used will be kilowatt hours (kWh).
The consumption parameters are grouped onto the ConsumptionParameters class. The API
documentation provides descriptions of each of the individual values that can be modified. Here we will
describe the more complex and important values. To being, we'll create an empty consumption parameters
object
ConsumptionParameters consumptionParams = new ConsumptionParameters();
The speed consumption table is the basis for much of the consumption calculation, this is stored as a table,
represented as list of ConsumptionForSpeed objects. The table represents the consumption of the vehicle
per meter in kilowatt hours (the capacity unit) for ranges of speeds.
Consider a very simple example with three ranges of speeds and a consumption for each.
Table 8:
Speed range (km/h) Consumption per meter (kWh)
0 - 30 38.82
31 - 90 18.20
> 90 27.41
From this table, we see that our vehicle consumes 38.82 kWh of capacity per metre when traveling between
0 and 30 km/h, 18.20 kWh of capacity per metre when traveling between 31 and 90 km/h and 27.41 kWh of
capacity per metre when traveling at 90 km/h or faster. Of course this example is very simple, a real world
speed consumption table would have finer grained values.
HERE Android SDK Developer's Guide
User Guide
109
To use this table in our consumption parameters, call the
setSpeedParameters(List<ConsumptionForSpeed>) method, with the upper bound of each range as
the key and the consumption per metre as the value. The final key (for > 90 km/h) should use the key 250.
List<ConsumptionForSpeed> consumptionSpeed = new ArrayList<ConsumptionForSpeed>();
consumptionSpeed.add(new ConsumptionForSpeed(30, 38.82));
consumptionSpeed.add(new ConsumptionForSpeed(90, 18.20));
consumptionSpeed.add(new ConsumptionForSpeed(250, 27.41));
consumptionParams.setSpeedParameters(consumptionSpeed);
The speed consumption table is enough to calculate simplistic consumption for a route. Assuming that we
already have a Route object called route, which contains a calculated route, calculate the consumption for
this route.
RouteConsumption consumption =
route.getConsumption(consumptionParameters, null);
Once we have the route consumption we can determine the last reachable position on the same route given
current capacity of our vehicle. In this example we'll suppose that our vehicle has 100,000 kWh of remaining
capacity at the beginning of the route.
GeoCoordinates lastPosition =
route.getLastReachablePosition(consumption, 100000);
The variable lastPosition will now contain the last point that our vehicle will be able to reach before the
capacity reaches zero. In the case that the final destination of the route is reachable, lastPosition will be
nil.
We can also use the route consumption to obtain the consumption for each route element that comprise the
route itself. The following code snippet prints out the starting and ending geo-coordinates for each route
element as well as the consumption for that route element.
List<RouteElement> routeElements = route.getRouteElements().getElements();
for (int i = 0; i < routeElements.size(); i++) {
RouteElement element = routeElements.get(i);
List<GeoCoordinate> geometry = element.getGeometry();
double startLat = geometry.get(0).getLatitude();
double startLong = geometry.get(0).getLongitude();
double endLat = geometry.get(geometry.size() - 1).getLatitude();
double endLong = geometry.get(geometry.size() - 1).getLongitude();
Log.d(TAG, String.format("Route element (%.4f, %.4f) ---> (%.4f, %.4f) consumption %d",
startLat, startLong, endLat, endLong, consumption.getConsumption(i)));
}
As mentioned above, setting only the consumptionSpeed property is sufficient for basic consumption
calculation. There are more specialised values which can be set to more closely model the consumption of a
real vehicle across different road and traffic conditions. For more details on these properties, please see the
API documentation.
Route Serialization
Route serialization is a feature that allows users to use the Route methods to serialize a route into binary
data, which can then be saved as a file. You can also use Route class to generate a route from a previously
HERE Android SDK Developer's Guide
User Guide
110
serialized route without going through the route calculation process. This is useful when a user wants to
recover from a crash during navigation or when a user wants to transfer a route from another device.
Note: Route serialization is currently offered as a beta feature. APIs may change without notice.
Route serialization currently only supports car, bike, truck, and pedestrian routes. Public Transit, Indoor
Venue, and Urban Mobility routes cannot be serialized. Route serialization also does not work when the
map version from which a route is serialized does not match the current map version. Route serialization
also fails if the binary data containing the serialized route is tempered with or corrupted. In these cases, a
specific SerializerError error code is returned.
Both asynchronous and synchronous operations are supported. To asynchronously serialize a route, perform
the following:
Route route;
//assume that route calculation was already performed
Route.SerializtionCallback sCallback = new SerializationCallback() {
@Override
public void onSerializationComplete(Route.SerializationResult result) {
//do something with data
byte[] data = result.data;
}
};
Route.serializeAsync(route, sCallback);
To asynchronously deserialize a route:
byte[] data;
//assume 'data' is a previously-serialized route
Route.DeserializationCallback dCallback = new DeserializationCallback() {
@Override
public void onDeserializationComplete(Route.Deserialization result){
//do something with the route
Route route = result.route;
}
};
Route.deserializeAsync(data, dCallback);
Places
This section provides an overview of the Places feature in the HERE SDK. The Places feature enables
developers to build rich, location-aware applications by adding point of interest search, discovery,
interaction, and information retrieval.
For example, when an application submits a place discovery request using this API, the application receives
a response that contains a list of links to places resources (among other information). By accessing one of
the linked Place resources, the application can get detailed information about that place, including ratings,
images, reviews, editorials, and owner content. This detailed place response also contains references to
other related places, allowing the application's users to discover other places relevant or related to their
original search.
HERE Android SDK Developer's Guide
User Guide
111
Note: To use this feature, your application must include the Gson library (release 2.2.4 or a
compatible version) on its class path.
Geocoding and Reverse Geocoding
Geocoding and reverse geocoding APIs from the HERE Android SDK allow application developers to offer
search functionality for requesting location information and structured addresses. Geocoding APIs resolve
to a GeoCoordinate from a text query, while reverse geocoding APIs resolve to a geographic data, such as
Address, from a GeoCoordinate. Address provides textual address information, which includes house
number, street name, city, country, and district. It encompasses everything about an address or a point on
the map. Location represents a physical point on the map where additional attributes can be retrieved.
These additional attributes include a unique identifier, label, Address, GeoCoordinate positions, and
GeoBoundingBox for the Location.
The GeocodeRequest Class
GeocodeRequest represents an extended Request. GeocodeRequest can be created using a one-box
(free-formatted text) search using a combination of a text query string and geographical area arguments. The
following shows the method used to create a one-box request:
GeocodeRequest request = new GeocodeRequest(String).setSearchArea(GeoCoordinate, int)
The preceding method returns a GeocodeRequest object. To begin the search, call
GeocodeRequest.execute(). This method requires a ResultListener as an argument. When the search
is completed, the ResultListener.onCompleted() method is called with a result status and a list of
found locations.
After a request is invoked, it can be canceled using the GeocodeRequest.cancel() method, which returns
true if the request was cancelled successfully. For GeocodeRequest, a list of Location objects are
expected at the completion of the request.
The following code example demonstrates how to perform a GeocodeRequest:
// Implementation of ResultListener
class GeocodeListener implements ResultListener<List<Location>> {
@Override
public void onCompleted(List<Location> data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
...
} else {
// Process result data
...
}
}
}
// Instantiate a GeoCoordinate object
GeoCoordinate vancouver = new GeoCoordinate( 49.2849,- 123.1252);
// Example code for creating a OneBox Request
ResultListener<List<Location>> listener = new GeocodeListener();
GeocodeRequest request = new GeocodeRequest("Granville").setSearchArea(vancouver, 5000);
if (request.execute(listener) != ErrorCode.NONE) {
// Handle request error
...
HERE Android SDK Developer's Guide
User Guide
112
}
The ReverseGeocodeRequest2 Class
The ReverseGeocodeRequest2 class represents an extended Request used to retrieve Location data.
The request is created using a GeoCoordinate as shown below:
new ReverseGeocodeRequest2(GeoCoordinate)
The above method returns a ReverseGeocodeRequest2 object. To invoke the request, you can then call
the execute() method of the returned ReverseGeocodeRequest2 object and pass in a ResultListener
to retrieve the information about the completion of the request. Once a request is invoked, the request can
be canceled via the ReverseGeocodeRequest2.cancel() method. cancel() returns true if the request
was cancelled successfully. For ReverseGeocodeRequest2, a structured Location is expected at the
completion of the request.
The following is an example of creating ReverseGeocodeRequest2 using new
ReverseGeocodeRequest2(GeoCoordinate):
// Implementation of ResultListener
class ReverseGeocodeListener implements ResultListener<Location> {
@Override
public void onCompleted(Location data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
...
} else {
// Process result data
...
}
}
}
// Instantiate a GeoCoordinate object
GeoCoordinate vancouver = new GeoCoordinate( 49.2849,- 123.1252);
// Example code for creating ReverseGeocodeRequest2
ResultListener<Location> listener = new ReverseGeocodeListener();
ReverseGeocodeRequest2 request = new ReverseGeocodeRequest2(vancouver);
if (request.execute(listener) != ErrorCode.NONE) {
// Handle request error
...
}
By default, the reverse geocode request above searches for the closest street address. Alternatively, you can
also create a reverse geocoding request in one of the following modes (ReverseGeocodeMode):
RETRIEVE_ADDRESSES - Search for the closest street address or addresses (same as above)
RETRIEVE_AREAS - Retrieve the administrative area information for the position provided in the
request
RETRIEVE_LANDMARKS - Search for landmarks like parks and lakes in the proximity provided in the
request
RETRIEVE_ALL - Search for streets, administrative areas and landmarks. This mode aggregates the
results of the previous three modes in one call
TRACK_POSITION - Retrieve street and address information based on a position and bearing
HERE Android SDK Developer's Guide
User Guide
113
See the following for an example of how to use this type of request. Note that the bearing parameter is
only used when you use TRACK_POSITION.
ResultListener<Location> listener = new ReverseGeocodeListener();
ReverseGeocodeRequest2 request = new ReverseGeocodeRequest2(geoCoord, null, RETRIEVE_ADDRESSES,
bearing);
if (request.execute(listener) != ErrorCode.NONE)
{
// Handle request error ...
}
Offline Geocoding
Applications developed with the HERE Android SDK can perform offline geocoding, which allows geocode
and reverse geocode requests to be performed without an active data connection. This is performed
automatically when an active data connection is not available and when the map and database information
have already been downloaded and cached.
Search and Discovery
The HERE Android SDK provides application developers the Places API, which allows places discovery and
information retrieval.
Steps for performing a search
1. Implement the ResultListener interface to handle the completion of the search
2. Create a request and apply request options
3. Invoke the request by calling Request.execute(ResultListener)
4. The ResultListener.onCompleted() callback is triggered when the request is finished
Note: Applications that use the Places API must honor the following prescribed workflow:
1. Search
2. Request for Details
3. Perform Actions
Do not preload results linked from a response to improve performance, as doing so violates HERE's
guidelines. For more information about usage restrictions, consult the API Implementation Check List
in the REST HERE Places API documentation.
The Place Class
The Place class represents a detailed set of data about a physical place, acting as a container for various
attributes, collections of media about a place, and key-value pairs of related places. A Place object can
belong to a specific Category, and has attributes such as:
A unique identifier (ID)
A name
A Location object representing the physical location of the place, including access locations
A List of Category objects that link to the categories assigned to the place
A URL to the icon that best represents the place
Optional information, such as related places, user ratings, reviews, and other editorial media.
HERE Android SDK Developer's Guide
User Guide
114
For more information, please see the API Reference.
Discovery Requests
The HERE Places Search API supports the following discovery requests:
Request HERE SDK class Purpose
Search SearchRequest Finds places that match user-provided search terms.
Explore ExploreRequest Finds interesting places nearby, or in the map viewport, sorted by popularity.
Use this type of request if you are trying to answer the question "What are the
interesting places near here?" The results may be optionally restricted to a given
set of categories, which acts as a filter in terms of what places get returned.
Here HereRequest Helps users identify places at the given location by finding places of interest
near a given point, sorted by distance. Use this type of request if you are trying
to answer the question "What is near this location?" or "Where am I?" You can
use this endpoint to implement features like "check-in" (by identifying places at
the user's current position) or "tap to get more information about this place of
interest".
Note: Normally, the closest known places are returned with the Here
Discovery request, but if the uncertainty in the given position is high,
then some nearer places are excluded from the result in favor of more
popular places in the area of uncertainty.
Around AroundRequest Allows users to request places near a given point, based on a location precision
parameter. The places around that point are returned in order of proximity.
This type of request is intended for applications that employ features such as
augmented reality, where places around the user's location are displayed on a
device. It is intended to provide places that are likely to be visible to the user as
well as important places that are farther away. The Around request is considered
experimental, and its behavior and functionality are still evolving. Check future
documentation for updates to this feature.
The following code example demonstrates how to perform a search discovery request:
// Example Search request listener
class SearchRequestListener implements ResultListener<DiscoveryResultPage> {
@Override
public void onCompleted(DiscoveryResultPage data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
...
} else {
// Process result data
...
}
}
}
// Create a request to search for restaurants in Seattle
try {
GeoCoordinate seattle
= new GeoCoordinate(47.592229, -122.315147);
DiscoveryRequest request =
new SearchRequest("restaurant").setSearchCenter(seattle);
HERE Android SDK Developer's Guide
User Guide
115
// limit number of items in each result page to 10
request.setCollectionSize(10);
ErrorCode error = request.execute(new SearchRequestListener());
if( error != ErrorCode.NONE ) {
// Handle request error
...
}
} catch (IllegalArgumentException ex) {
// Handle invalid create search request parameters
...
}
The result of a discovery request is a DiscoveryResultPage. The DiscoveryResultPage represents a
paginated collection of items from which the following can be retrieved:
Next page and previous page requests - discovery requests used to retrieve additional pages of search
items
Items for the current page - a List of DiscoveryResult
When additional pages of search results are needed, retrieve and invoke the DiscoveryRequest returned
by DiscoveryResultPage.getNextPageRequest(). If the next page request is null, no additional
results are available.
The following is an example:
DiscoveryResultPage mResultPage = null;
// Example Search request listener
class SearchRequestListener implements ResultListener<DiscoveryResultPage> {
@Override
public void onCompleted(DiscoveryResultPage data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
...
} else {
// Store the last DiscoveryResultPage for later processing
mResultPage = data;
...
}
}
}
...
// When the next page of results is needed...
DiscoveryRequest nextPageRequest = mResultPage.getNextPageRequest();
if (nextPageRequest != null) {
// More data is available if the nextPageRequest is not null
ErrorCode error = nextPageRequest.execute(new SearchRequestListener());
if( error != ErrorCode.NONE ) {
// Handle request error
...
}
}
Calling DiscoveryResultPage.getItems(), returns a List containing one of the following types of
objects, which are DiscoveryResult instances. DiscoveryResult is a collection of Link subtypes.
PlaceLink - Represents discovery information about a Place. The PlaceLink contains a brief
summary about a place. Details about a place are available from the Place that the PlaceLink
references.
HERE Android SDK Developer's Guide
User Guide
116
DiscoveryLink - Represents a discovery-related API link used to retrieve additional
DiscoveryResultPage. This type of Link can be a result item in an Explore or Here type of search.
The DiscoveryLink references refined discovery requests resulting in more specific results. For
example, the DiscoveryLink may link to a discovery request to search for 'Eat & Drink', 'Going Out',
'Accommodation', and so on.
Since there may be new types of Link items in the future, it is recommended that each type of
DiscoveryResult be checked before it is used (as shown in the following code snippet). In the following
example, it is shown how a Place is retrieved through a PlaceLink:
// Implement a search result listener
ResultListener<DiscoveryResultPage> searchListener = new ResultListener<DiscoveryResultPage>() {
@Override
public void onCompleted(DiscoveryResultPage results, ErrorCode error) {
if (error == ErrorCode.NONE) {
// The results is a DiscoveryResultPage which represents a
// paginated collection of items.
List<DiscoveryResult> items = results.getItems();
// Iterate through the found place items.
for (DiscoveryResult item : items) {
// A Item can either be a PlaceLink (meta information
// about a Place) or a DiscoveryLink (which is a reference
// to another refined search that is related to the
// original search; for example, a search for
// "Leisure & Outdoor").
if (item.getResultType() == ResultType.PLACE) {
PlaceLink placeLink = (PlaceLink) item;
// PlaceLink should be presented to the user, so the link can be
// selected in order to retrieve additional details about a place
// of interest.
...
} else if (item.getResultType() == ResultType.DISCOVERY) {
DiscoveryLink discoveryLink = (DiscoveryLink) item;
// DiscoveryLink can also be presented to the user.
// When a DiscoveryLink is selected, another search request should be
// performed to retrieve results for a specific category.
...
}
}
} else {
// Handle search request error.
}
}
};
...
// Implement a Place listener for handling user interaction with a displayed PlaceLink
class PlaceListener implements ResultListener<Place> {
@Override
public void onCompleted(Place data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
...
} else {
// Present the place details to the user.
String placeName = data.getName();
List<Category> placeCategories = data.getCategories();
...
HERE Android SDK Developer's Guide
User Guide
117
}
}
}
// Retrieve the place details when the user selects a displayed PlaceLink.
private void onPlaceLinkSelected(PlaceLink placeLink) {
PlaceRequest placeRequest = placeLink.getDetailsRequest();
if( placeRequest.execute(new PlaceListener()) == ErrorCode.NONE ) {
// Request successful. Additional work can be done here, however, place details will
// be returned in PlaceListener.onCompleted().
...
} else {
// Handle the error
...
}
}
Text AutoSuggestion Requests
The HERE Places Search API also supports text autosuggestion requests. This type of request is used for
retrieveing a list of instant results (AutoSuggestPlace) and refined search links (AutoSuggestSearch)
that are related to a specified location context and a partial search term. For example, if you make a request
with the String "rest" in Berlin, the results contain search terms such as "Restaurant", "Rest area", and
"Restorf, Höhbeck, Germany".
Note: Text AutoSuggestion is currently offered as a beta feature. APIs may change without notice.
Offline requests are not supported.
To use text suggestions, implement a listener to handle a list of AutoSuggest objects and call new
TextAutoSuggestionRequest(String) as follows:
// Example request listener
class AutoSuggestionQueryListener implements ResultListener<List<AutoSuggest>> {
@Override
public void onCompleted(List<AutoSuggest> data, ErrorCode error) {
for (AutoSuggest r : data) {
try {
String term = "rest";
TextAutoSuggestionRequest request = null;
request = new TextAutoSuggestionRequest(term).setSearchCenter(myMap.getCenter());
if (request.execute(new AutoSuggestionQueryListener()) !=
ErrorCode.NONE ) {
//Handle request error
//...
}
} catch (IllegalArgumentException ex) {
//Handle invalid create search request parameters
}
}
}
}
You can retrieve the results of a TextAutoSuggestionRequest by first checking the autosuggest object
type, as shown in the following example. Note that it is possible for AutoSuggestSearch to contain
additional paginated results through the DiscoveryRequest object. If the object is AutoSuggestPlace,
you can request for more details through its PlaceRequest object.
//assume autoSuggestList contains the list of results
try {
AutoSuggest autoSuggest = autoSuggestList.get(index);
HERE Android SDK Developer's Guide
User Guide
118
// set title
String title = autoSuggest.getTitle();
// get highlightedTitle
String highlightedTitle = Html.fromHtml(autoSuggest.getHighlightedTitle()).toString();
if (autoSuggest instanceof AutoSuggestPlace) {
AutoSuggestPlace autoSuggestPlace = (AutoSuggestPlace)autoSuggest;
// vicinity
if (autoSuggestPlace.getVicinity() != null) {
String vicinity = autoSuggestPlace.getVicinity();
}
// set category
if (autoSuggestPlace.getCategory() != null) {
String category = autoSuggestPlace.getCategory();
}
// set position
if (autoSuggestPlace.getPosition() != null) {
String position = autoSuggestPlace.getPosition().toString();
}
// set boundaryBox
if (((AutoSuggestPlace)autoSuggest).getBoundingBox() != null) {
String boundingBox = ((AutoSuggestPlace)autoSuggest).getBoundingBox().toString();
}
} else if (autoSuggest instanceof AutoSuggestSearch) {
AutoSuggestSearch autoSuggestSearch = (AutoSuggestSearch)autoSuggest;
// set category
if (autoSuggestSearch.getCategory() != null) {
String category = autoSuggestSearch.getCategory();
}
// set position
if (autoSuggestSearch.getPosition() != null) {
String position = autoSuggestSearch.getPosition().toString();
}
// set boundaryBox
if (autoSuggestSearch.getBoundingBox() != null) {
String boundingBox = autoSuggestSearch.getBoundingBox().toString();
}
DiscoveryRequest myDiscoveryRequest = autoSuggestSearch.getSuggestedSearchRequest();
myDiscoveryRequest.execute(myDiscoveryResultPagelistener);
} catch (Exception e) {
Log.e("ERROR: ", e.getMessage());
}
External References
A place of interest can contain a reference to a foreign system outside of the HERE SDK. For example, a
Place representing a restaurant contains an external reference to an entry in a restaurant reviews website.
Each external reference is tied to a single reference source. However, each reference can have one or
multiple identifiers.
The following external reference sources are supported in PlaceRequest and DiscoveryRequest:
HERE Android SDK Developer's Guide
User Guide
119
Request.PVID_ID_REFERENCE_NAME - Source for HERE Core Maps POI data
"yelp" - Source for Yelp IDs
An external reference is returned in the form of one or multiple String identifiers in Place, PlaceLink, or
Location. To retrieve a reference, add a source to the PlaceRequest or DiscoveryRequest, as shown in
the following example:
// Create a request to search for restaurants in Vancouver
GeoCoordinate vancouver =
new GeoCoordinate(48.263392, -123.12203);
DiscoveryRequest request =
new SearchRequest("restaurant").setSearchCenter(vancouver);
// We also want to retrieve the Yelp ID external reference
request.addReference("yelp");
request.setCollectionSize(10);
ErrorCode error = request.execute(new SearchRequestListener());
After the request execution is complete, you can retrieve the results by using the getReference(String)
method. If an external reference returns multiple results, such as the case where a single Place is
associated with multiple identifiers, use the getAlternativeReferenceIds(String) method in Place
or PlaceLink to retrieve the remaining result items.
//...
class SearchRequestListener implements ResultListener<DiscoveryResultPage> {
@Override
public void onCompleted(DiscoveryResultPage data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
//...
} else {
//...
mResultPage = data;
for (PlaceLink link : mResultPage.getPlaceLinks())
{
String yelpReferenceID = link.getReference("yelp");
}
//...
}
}
}
//...
Additional external reference sources are supported through details requests, as shown in the next example.
For example, you can use getDetailsRequest() from a PlaceLink object and retrieve reference IDs by
executing the details request.
Note: The following external references can be retrieved through a details request:
Request.PVID_ID_REFERENCE_NAME - Source for HERE Core Maps POI data
Request.VENUES_VENUE_ID_REFERENCE_NAME - Source for HERE Venue IDs
Request.VENUES_CONTENT_ID_REFERENCE_NAME - Source for HERE Venue Content IDs
Request.VENUES_DESTINATION_ID_REFERENCE_NAME - Source for HERE Venue Destination
IDs
Request.BUILDING_ID_REFERENCE_NAME - Source for HERE Building IDs
HERE Android SDK Developer's Guide
User Guide
120
"tripadvisor" - Source for TripAdvisor IDs, to be used with TripAdvisor Content API. [*]
"facebook" - Source for Facebook unique page IDs, to be used with Facebook Graph API. [*]
"yelp" - Source for Yelp IDs, to be used with Yelp Business API. [*]
"opentable" - Source for OpenTable restaurant unique IDs, to be used with OpenTable
reservation widget. [*]
//...
class SearchRequestListener implements ResultListener<DiscoveryResultPage> {
@Override
public void onCompleted(DiscoveryResultPage data, ErrorCode error) {
if (error != ErrorCode.NONE) {
// Handle error
//...
} else {
//...
mResultPage = data;
for (PlaceLink link : mResultPage.getPlaceLinks())
{
PlaceRequest detailsRequest = link.getDetailsRequest();
detailsRequest.addReference("tripadvisor");
//assuming you have created DetailsListener()
if( placeRequest.execute(new DetailsListener()) == ErrorCode.NONE ) {
// Request successful.
// Check the returned Place objects in DetailsListener.onCompleted().
...
} else {
// Handle the error
...
}
}
//...
}
}
}
//...
Note: Sources marked with [*] cannot be used with the PlaceRequest(String, String)
constructor.
You can also use an external reference in the reverse scenario to retrieve a particular Place by using a
PlaceRequest created using the PlaceRequest(String, String) constructor. For example:
PlaceRequest placeRequest =
new PlaceRequest(Request.BUILDING_ID_REFERENCE_NAME, "12345");
Offline Search
When internet connectivity is unavailable, the HERE Places supports offline search by providing results using
available cached map data. The search results in this offline mode may be limited.
The main differences compared to online search results are:
Fewer POIs (Point of Interests) are available
No detailed POI's information is available (for example: ratings, reviews, editorials, images, and so on)
HERE Android SDK Developer's Guide
User Guide
121
Force Online or Offline
You can launch online or offline searches without changing the device or HERE SDK connectivity by using
the setConnectivity(Connectivity) method on a Request instance. This property is applicable to all
Request subclasses, except TextAutoSuggestionRequest, which can only be used online.
Connectivity has three possible values:
If you launch a request using the DEFAULT connectivity mode, the request is performed according to
the MapEngine connectivity setting. If the device is offline while MapEngine is set to online mode, the
request fails.
If you launch a request using the ONLINE connectivity mode, an online request is performed, regardless
of the MapEngine connectivity setting.
If you launch a request using the OFFLINE connectivity mode, an offline request is performed,
regardless of the MapEngine connectivity setting.
In all cases, if the request fails, no fallback action is automatically performed.
To ensure that the connectivity mode is applied, setConnectivity(Connectivity) before executing a
Request.
If a Connectivity.ONLINE search request fails due to connection issues, HERE SDK returns the
ErrorCode.UNKNOWN error code.
If a Connectivity.ONLINE Geocoding or Reverse Geocoding request fails due to connection issues,
HERE SDK returns the ErrorCode.NETWORK_COMMUNICATION error code.
If a Connectivity.OFFLINE search request fails due to not enough cached data, HERE SDK returns
with zero results.
If you attempt to execute a TextAutoSuggestionRequest with the Connectivity.OFFLINE
connectivity mode, HERE SDK returns the ErrorCode.SERVICE_UNAVAILABLE error code, since auto
suggestions are only supported online.
Custom Locations and Geometries
This section describes the Custom Locations feature. This feature allow user-defined locations and
geometries to be retrieved through different search requests.
You can find more information about using Custom Locations, including how to import locations and how
to manage location layers, by using the Custom Locations API Developer's Guide and the Custom Location
Extension User Guide on http://developer.here.com.
Note: To use this feature, your application must include the Gson library (release 2.2.4 or a
compatible version) on its class path.
Custom Location Extension 2
Custom Location Extension 2 (CLE2) allows you to easily distribute custom geospatial information in your
mobile applications. Through CLE2, you can programatically insert spatial content to the local database and
upload them to the server for data-sharing purposes. You can also also perform online or offline searches.
These features effectively turns the HERE Android SDK into a lightweight spatial storage solution that enables
insertion and query for geospatial information using optimized algorithms.
HERE Android SDK Developer's Guide
User Guide
122
The classes that support this feature are located under com.here.android.mpa.customlocation2.
Instead of having specific interfaces for location and geometry requests, CLE2 unifies all use cases
in one flexible approach: the returned value always contains one of the geometry types (such as
CLE2PointGeometry), along with a set of 0 to N user-defined attributes that can represent any information.
There is no implied structure in these attributes. These attributes are made available as a Map of keys and
attribute values.
Some examples of how you can use these CLE2 features include:
Show all users' custom Points of Interest (POIs) within a 2km radius.
Online or offline search for all customer offices within Germany using an area defined by a polygon, then
display the office's reception phone numbers, employee counts, and other details.
Edit geometry shapes in real time in offline mode and perform queries against it to get notifications
when such shapes intersect with other existing fixed shapes and other basic Geofencing solutions. For
example, this can be a ‘moving platform’, such as ships near ship docks, where locations are relative to
GPS movements.
Sharing Points of Interest that are not officially available as a part of HERE map data, such as a city's
facilities and outdoor basketball courts.
Persist GPS data that is tied to arbitrary data, such as hiking trails with speed, even during offline mode.
Search for specific types of objects that are near a given route.
Layers and Filtering
All data is organized in the form of layers. When uploading, storing or search for information, a layer name
string is specified and can be used to better filter relevant information.
A further filtering is possible by checking the geometry's attributes. These attributes are user-defined fields
that are linked to a geometry, such as CLE2PointGeometry, and can be text or number fields.
Note: CLE2 search is restricted per layer by app credentials. To manage the access restriction of a
Custom Location layer, contact your Custom Location administrator. If you do not have one, contact
your HERE representative.
Inserting and Uploading Data
To upload data to the CLE2 servers, you can use the web interface or REST APIs. Refer to the following User
Guide for more details: https://developer.here.com/documentation/versions#custom-location.
It is also possible to insert data locally and to the server via HERE Android SDK. The HERE SDK makes
it straightforward to generate any location-referenced data, even when storing it locally offline, and
sequentially sharing that information to other devices when a connection is established.
Performing Spatial Searches
To perform a search, choose one of the search types as shown below. A common input parameters to all
requests is the searched layer's name.
Table 9: Search Classes
Search Type Description Class Name
Proximity Retrieve geometries that are within a given radius from
a center.
CLE2ProximityRequest
HERE Android SDK Developer's Guide
User Guide
123
Search Type Description Class Name
Corridor Retrieve geometries along a route specified by a
sequence of coordinates.
CLE2CorridorRequest
Bounding box Retrieve geometries within a specified rectangular
geographic area.
CLE2BoundingBoxRequest
Quadkey Retrieve geometries that falls within a specified
QuadKey.
CLE2QuadkeyRequest
Attribute Retrieve all geometries that matches with a specified
query. This type of search is only available online.
CLE2AttributeRequest
Each of the search request types supports some common parameters, as listed below.
Table 10: Common CLE2Request Members
Setter Method Description Example Values
setGeometry(CLE2GeometryType) Specifies the geometry type to be given in the result
(online only), see details below on "Understanding the
search results"
CLE2GeometryType.FULL
CLE2GeometryType.LOCAL
CLE2GeometryType.NONE
setCachingEnabled(boolean) Default is false. If enabled, geometries received from
such online search request will be stored locally.
setQuery(String) Currently available for online requests only. This
variable allows a query filter to be specified on the
user's geometry attributes so that only geometries that
passes the filter are returned. Free form text with simple
equality and comparison operators.
Once you have a search request object created and set up according to your needs, call its
execute(CLE2ResultListener) method. The result of the search will be delivered to the provided
listener. You can get the geometries that matched search criteria from a CLE2Result object by calling
getGeometries(). This list of geometry results may contain objects of the following types:
Table 11: Geometry Return Types
Class Geometry Description Relevant Getter Methods
CLE2Geometry Base class for all other geometry return values,
containing user-defined attributes.
Map<String, String>
getAttributes()
CLE2PointGeometry Represents a point in coordinates. Relates to a Point in
WKT.
GeoCoordinate getPoint()
CLE2MultiPointGeometry Represents a multi-point as a coordinates array. Relates
to a MultiPoint in WKT.
List<GeoCoordinate>
getMultiPoint()
CLE2PolylineGeometry Represents a polyline as an GeoPolyline. Relates to a
WKT LineString object.
GeoPolyline getPolyline()
CLE2MultiPolylineGeometry Represents a multi-polyline as an array of
GeoPolyline. Relates to a WKT MultiLineString
object.
List<GeoPolyline>
getPolylines()
HERE Android SDK Developer's Guide
User Guide
124
Class Geometry Description Relevant Getter Methods
CLE2PolygonGeometry Represents a polygon with a GeoPolygon for the outer
ring, and an array of GeoPolygon for inner holes.
Relates to a WKT polygon object containing all rings of
this geometry.
GeoPolygon getOuterRing(),
List<GeoPolygon>
getInnerRings()
CLE2MultiPolygonGeometry Represents a multi-polygon as an array of
CLE2GeometryPolygon. Relates to a MultiPolygon
object in WKT.
List<CLE2PolygonGeometry>
getPolygons()
In the OpenGIS (the implementation standard for Geographic Information) and WKT representation formats,
the concept of a polygon is defined by one outer ring polygon plus zero or more inner hole polygons. This is
the reason that the class CLE2PolygonGeometry contains a GeoPolygon and a secondary GeoPolygon
array.
Understanding Local and Full Search Results
While processing user-uploaded data, CLE2 creates a look-up index where geometries are divided by an
internal fixed grid. If a geometry spans across several grid tiles, then the search index may contain smaller
slices of this uploaded geometry. This behavior allows for better search performance, as well as optimized
return values, since it is possible to only return the relevant part of the originally submitted geometry, and
thus reducing the response size and processing time.
Before executing a search, you can specify if you are only interested in the part of the geometry that falls
within the tiles around the search area (in other words, the tiled "local" geometry), or if you would like to
receive the full geometry as originally uploaded.
Note: By default, HERE SDK returns full geometries.
Figure 53: Local and Full Geometry
You can use the following three options to define whether you are requesting for full or local results. These
options are available for all search types:
CLE2GeometryType value Meaning
FULL The result contains the original geometry (as uploaded).
LOCAL The result contains the processed geometries that falls within the search area for the tiles in reach.
NONE No geometry is returned at all, only the properties/attributes of the geometries that match the given
search are returned.
HERE Android SDK Developer's Guide
User Guide
125
Proximity Search Request Example
To perform a custom location search, you need to create a CLE2ProximityRequest using the
CLE2ProximityRequest(String layerId, GeoCoordinate center, int radius) or
CLE2ProximityRequest(List<String> layerIds, GeoCoordinate center, int radius)
constructor methods.
A proximity search returns a list of custom locations that fall within a specified radius of a GeoCoordinate
location. For example, the following code shows how to perform a search for all locations in the previously-
mentioned stores layer that exists within a 0.5 kilometer radius of Frankfurt Central Station:
String layerId = "HERE_SITES";
int radius = 8000; // 8 km
GeoCoordinate location = new GeoCoordinate(49.196261, -123.004773);
CLE2ProximityRequest req = new CLE2ProximityRequest(layerId, location, radius);
req.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error)
{
//if CLE2Error.NONE.equals(error) is true, the request was successful
if (error.equals(CLE2Error.NONE)) {
List<CLE2Geometry> gemetry = result.getGeometries();
for (CLE2Geometry geo : gemetry) {
java.util.Map<String, String> attributeMap = geo.getAttributes();
String name = attributeMap.get("NAME1");
double distance = geo.getDistance();
}
}
}
});
The layerId parameter represents a set of custom locations. For example, layerID="HERE_SITES"
represents an example layer that contains HERE locations in Germany. You can also perform a proximity
search on different layers at the same time:
List<String> layerIds = new ArrayList<String>():
layerIds.add("LAYER_1");
layerIds.add("LAYER_2");
int radius = 500; // 500 meters
GeoCoordinate location = new GeoCoordinate(50.113905,8.677608);
CLE2ProximityRequest req = new CLE2ProximityRequest(layerIds, location, radius);
req.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error)
{
//if CLE2Error.NONE.equals(error) is true, the request was successful
if (error.equals(CLE2Error.NONE)) {
List<CLE2Geometry> gemetry = result.getGeometries();
for (CLE2Geometry geo : gemetry) {
java.util.Map<String, String> attributeMap = geo.getAttributes();
String name = attributeMap.get("NAME1");
double distance = geo.getDistance();
}
}
}
});
After creating a request object, you can call the execute(ResultListener) method to launch the search
request and listen for search results.
HERE Android SDK Developer's Guide
User Guide
126
You can also add a filter to the request. A filter is a JavaScript-like expression that is evaluated for each
location-matching search query. When specified, only locations where the expression evaluates to true are
returned. For example, if you want to filter for location results that have the custom location parameter of
rating that is greater than 3 and the name "MyPlace23", perform the following:
String layerId = "HERE_SITES";
int radius = 8000; // 8 km
GeoCoordinate location = new GeoCoordinate(49.196261, -123.004773);
CLE2ProximityRequest req = new CLE2ProximityRequest(layerId, location, radius);
String filter = "CITY == 'Burnaby' && NAME1 != 'MyPlace'";
req.setQuery(filter);
req.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error)
{
//if CLE2Error.NONE.equals(error) is true, the request was successful
if (error.equals(CLE2Error.NONE)) {
List<CLE2Geometry> gemetry = result.getGeometries();
for (CLE2Geometry geo : gemetry) {
java.util.Map<String, String> attributeMap = geo.getAttributes();
String name = attributeMap.get("NAME1");
double distance = geo.getDistance();
}
}
}
});
Iterating Over Results
The CLE2Result object contains a list of geometries that are a result of the search and make them available
with getGeometries() method. Since different types of geometry can be returned, it is recommended to
test for the type before using it. For example, you can use CLE2ResultListener in a similar manner as the
following example:
CLE2ResultListener resultListener = new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error) {
if (!error.equals(CLE2Request.CLE2Error.NONE)) {
// process search results
for (CLE2Geometry geometry : result.getGeometries()) {
if (geometry instanceof CLE2PointGeometry) {
CLE2PointGeometry point = (CLE2PointGeometry) geometry;
// work with point geometry data
}
}
} else {
// handle error
}
}
};
Using CLE2 Offline
You can perform search requests online to the server or offline to the local device. To enable offline
searches against local data, the HERE SDK provides different ways for you to pre-fetch data.
Use offline mode as much as possible, since it provides the following advantages:
HERE Android SDK Developer's Guide
User Guide
127
Resilience to network instability.
More efficient use of network bandwidth. Instead of sending one request per object, you can aggregate
requests locally and transmit data in batches.
Savings in network bandwidth. Your app can cache and update data that is only near the user's current
location or pre-download a layer only when a WiFi network becomes available.
Potentially making the application more responsive and improving the user experience and interface
interactions, since the data is already available locally on the device.
Create or modify geometries with the HERE SDK, and then store them locally, effectively using the HERE
SDK as a data source and a storage of information.
The offline CLE2 feature is designed to be simple to use. Since all database synchronization and geospatial-
related complexities are handled by the SDK, you can focus on other parts of app development.
Querying the Local Storage
To search using locally stored data, set the connectivity mode to OFFLINE for a desired CLE2Request and
perform the request:
CLE2ProximityRequest proximitySearch =
new CLE2ProximityRequest("HERE_TEST", map.getCenter(), 1000);
proximitySearch.setConnectivityMode(CLE2Request.CLE2ConnectivityMode.OFFLINE);
proximitySearch.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error) {
if (!error.equals(CLE2Request.CLE2Error.NONE)) {
// process search results
} else {
// handle error
}
}
});
You can configure the search request to hybrid or automatic mode, indicating that if during an
online request the connection drops or there is a network error, then the request automatically
falls back to an offline operation. You can see whether the search was performed online or offline
by checking the connectivity mode that was used to perform the search. This can be done by calling
getConnectivityModeUsed() on the CLE2Result object.
CLE2ProximityRequest proximitySearch
= new CLE2ProximityRequest("HERE_TEST", map.getCenter(), 1000);
proximitySearch.setConnectivityMode(CLE2Request.CLE2ConnectivityMode.AUTO);
proximitySearch.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error) {
if (!error.equals(CLE2Request.CLE2Error.NONE)) {
// check if data came from online or offline search
boolean isDataFromServer = result.getConnectivityModeUsed() ==
CLE2Request.CLE2ConnectivityMode.ONLINE;
} else {
// handle error
}
}
});
HERE Android SDK Developer's Guide
User Guide
128
Ways to Populate the Local Storage
By default, the offline feature is disabled and the local storage contains no data. There are three ways to add
geometries to make them available for offline searches:
1. Caching search results after performing one or more requests, such as CLE2ProximityRequest. Note
that you cannot cache attribute requests.
2. Download one or more layers.
3. Direct insertion of data into the local database.
After populating the database, you can query for the data in offline mode as usual by switching the
connectivity mode of the respective request to CLE2ConnectivityMode.OFFLINE.
CLE2DataManager and CLE2Task
The CLE2DataManager object is the central interaction point with the local storage. With it, it is possible to:
Download all geometries of a specific layer
Check how many geometries are currently stored in total, or in a specific layer
Delete geometries belonging to a specific layer
Purge the local storage by deleting all items
Create, update, or delete a local or remote geometry
All the operations relating to data management that CLE2DataManager exposes make use of a CLE2Task
that represent a unit of work. Since all of the data management operations involve database access,
network communication or both, CLE2Task runs asynchronously. You can obtain a CLE2Task object from
CLE2DataManager.
With CLE2Task, you can:
Pass it to other parts of your code. CLE2Task is a self-contained unit of work.
Subscribe for results of the operation. Multiple subscribers are supported and they are called on the
main thread.
Start execution of the task. Tasks are reusable. You can run them repeatedly multiple times, which makes
retrying a failed operation very easy.
Cancel a running task.
Check if the task is started.
Check if the task has finished.
Wait for the task to finish.
Retrieve the status of a finished operation directly from the task (check for errors).
Retrieve the result of a successfully finished operation directly from the task.
Storing Data by Caching Search Results
When caching is enabled in a CLE2Request, any returned geometries are automatically stored locally. To
activate it, call setCachingEnabled(true) before performing the request:
// set query
String query = "CITY=='Berlin'";
request.setQuery(query);
// set Geometry type
request.setGeometry(CLE2GeometryType.LOCAL);
HERE Android SDK Developer's Guide
User Guide
129
// to cache response
request.setCachingEnabled(true);
request.execute(new CLE2Request.CLE2ResultListener() {
@Override
public void onCompleted(CLE2Result result, String error) {
if (!error.equals(CLE2Request.CLE2Error.NONE)) {
// request succeeded, which means that the results are now stored locally
} else {
// handle error
}
}
});
//Now some geometries are in local storage.
//At a later point in time if you'd like to make an offline search,
//switch the connectivity mode to offline
Storing Data by Downloading Layers
The second option is to use CLE2DataManager to insert data to the local storage using the
newDownloadLayerTask() method.
The following is an example of how to download a whole layer from the CLE2 server:
CLE2DataManager.getInstance().newDownloadLayerTask("MYLAYER").start(
new CLE2Task.Callback<CLE2OperationResult>() {
@Override
public void onTaskFinished(CLE2OperationResult result, CLE2Error error) {
if (error.getErrorCode() == CLE2ErrorCode.NONE) {
// download succeeded
} else {
// handle download error
}
}
});
It is also possible to delete individual layers from local storage or completely wiping out all data stored
locally:
// fire and forget method of running tasks (no callback)
CLE2DataManager.getInstance().newDeleteLayersTask(Arrays.asList(new String[]{"MYLAYER"}),
StorageType.LOCAL).start();
// by specifying StorageType.REMOTE, it is possible to delete the layers from CLE2 server, so be
careful
// wipe out all local data
CLE2DataManager.getInstance().newPurgeLocalStorageTask().start(new
CLE2Task.Callback<CLE2OperationResult>() {
@Override
public void onTaskFinished(CLE2OperationResult result, CLE2Error error) {
if (error.getErrorCode() == CLE2ErrorCode.NONE) {
// notify user that all his data is gone
}
}
});
HERE Android SDK Developer's Guide
User Guide
130
Storing Data by Inserting Geometries
You can generate location-based data and persist it locally, remotely, or both, by using the method
newGeometryTask() from the CLE2DataManager class. This factory method returns a CLE2Task object
that can be used to start, cancel, or to fetch results of operations at any given time.
public CLE2Task<CLE2OperationResult> newGeometryTask(
OperationType operationType,
String layerId,
List<CLE2Geometry> geometryData,
StorageType storageType)
The first parameter in this method describes the operation type, which can be one of the following:
OperationType.CREATE
OperationType.UPDATE
OperationType.DELETE
Note that querying for geometries is accomplished through the respective CLE2Request specialized
classes, so there is no "read" opreation here.
The second parameter is the layer the operation should be applied to.
The third parameter is a list with the geometries themselves.
The last parameter defines whether to operate on local storage (StorageType.LOCAL), or remote
storage (StorageType.REMOTE) using the HERE CLE2 server.
Note: While this section covers usage of this method for the local option, all operations (create,
update, delete) can also be used to change remote layers.
The following is an example on how to create a geometry and store it locally:
final int geometryCount = 100;
Random rand = new Random();
List<CLE2Geometry> geometries = new ArrayList<>(geometryCount);
// generate random point across the globe
for (int i = 0; i < geometryCount; i++) {
GeoCoordinate newPoint = new GeoCoordinate(
(rand.nextFloat()) * 180 - 90,
(rand.nextFloat()) * 360 - 180);
CLE2PointGeometry point = new CLE2PointGeometry(newPoint);
point.setAttribute("i", Integer.toString(i));
point.setAttribute("COLOR", rand.nextInt() % 2 == 0 ? "BLUE" : "RED");
geometries.add(point);
}
// create task for storing new geometries locally
// if the layer does not exist already, it is created,
// otherwise the geometries is added to existing layer
CLE2Task<CLE2OperationResult> createLocal = CLE2DataManager.getInstance().newGeometryTask(
OperationType.CREATE, "RED_VS_BLUE", geometries, StorageType.LOCAL);
createLocal.start(new CLE2Task.Callback<CLE2OperationResult>() {
@Override
public void onTaskFinished(CLE2OperationResult result, CLE2Error error) {
if (error.getErrorCode() == CLE2ErrorCode.NONE) {
// success
}
}
});
HERE Android SDK Developer's Guide
User Guide
131
Uploading a Local Layer
It is possible to upload a locally-stored layer to the server. Since this requires two operations (fetch from
local storage and upload), it's a good candidate to run individual tasks in synchronous manner to avoid
callback hell creeping in. Of course, this needs to be done on it's own thread, for example using AsyncTask.
AsyncTask<String, Void, Boolean> localToRemoteAsyncTask = new AsyncTask<String, Void, Boolean>() {
@Override
protected Boolean doInBackground(String... strings) {
CLE2DataManager dataManager = CLE2DataManager.getInstance();
boolean success = false;
for (String layerId : strings) {
// grab data from local storage
CLE2Task<List<CLE2Geometry>> fetchLocalTask = dataManager
.newFetchLocalLayersTask(Arrays.asList(new String[] {layerId}))
.start()
.waitForResult(5, TimeUnit.SECONDS);
success = fetchLocalTask.isFinished()
&& fetchLocalTask.getError().getErrorCode() == CLE2ErrorCode.NONE;
if (!success) {
break;
}
// upload the data to the server, creating a new layer or replacing existing one
CLE2Task<CLE2OperationResult> uploadTask = dataManager
.newUploadLayerTask(layerId, fetchLocalTask.getResult())
.start()
.waitForResult(15, TimeUnit.SECONDS);
success = uploadTask.isFinished()
&& uploadTask.getError().getErrorCode() == CLE2ErrorCode.NONE;
if (!success) {
break;
}
}
return success;
}
};
Data Management Considerations
The following are a few tips to help with data management when using CLE2 in an offline context.
Local-only Geometries
All CLE2Geometry objects have the following properties:
1. Geometry ID, accessible with getGeometryId()
2. Locality flag, accessible with isLocal()
The geometry ID is unique to a layer. If a geometry object has just been created, its geometry ID is null and
the locality flag is false.
The locality flag tells whether this geometry belongs to a local context only, meaning it was not retrieved
or passed through the CLE2 server. A geometry with a true locality flag has a locally generated unique
geometry ID. Otherwise, it contains a server-provided ID. This server-provided ID is not related to the locally
generated IDs of geometries stored directly in the database created via newGeometryTask().
HERE Android SDK Developer's Guide
User Guide
132
Note: The functionality of locally storing geometries without passing through the server is provided
so that you do not need to manage data persistence on these objects when a connection is not
available.
For simplicity, when saving geometries directly to the local database, keep them using a separate
layer name. If at a later desired point in time these geometries should be shared with the server, fetch
all local geometries using newFetchLocalLayersTask() method of CLE2DataManager and then
upload them either using newUploadLayerTask() or newGeometryTask() with a create operation
(OperationType.CREATE). This avoids the requirement to check for the isLocal() property.
By using these concepts, you can move geometries to different layers, contexts, and use these tools to
organize data.
Data Consistency
Use of newUploadLayer() should be primarily restricted to administrative users, because this method
deletes all existing geometries in the server and recreate the layer with the provided ones. If the user does
not have the latest information for this layer, data loss may occur, as it can overwrite another user's upload.
Therefore, for a scenario with continuous or concurrent geometry upload, use the newGeometryTask()
method with OperationType.CREATE or OperationType.UPDATE. Operating in a "append only"
manner or only updating the existing geometries avoids data loss, even if users are uploading geometries
concurrently to the server.
Current Limitations
Currently, individualized user account management for the CLE2 server is not available. For security reasons,
care must be taken that your app credentials are kept well hidden. Please contact HERE if your application
requires a user account access feature.
Note: Since geospatial queries are the focus of CLE2, HERE SDK does not support attribute searches in
offline mode. You can filter the data using one of the geospatial queries (such as proximity) to narrow
down the results to a small enough number that most applications do not suffer performance impact
by iterating the geometry’s attributes key-value dictionary to filter results further.
Toll Cost Extension
Toll Cost Extension provides you the possibility to easily access Toll Cost Extension API from the HERE SDK.
The HERE Toll Cost Extension (TCE) allows you to determine the toll costs for a specified route for a defined
vehicle profile.
TCE Classes
Class Description
TollCostOptions Specify all input parameters of TollCostRequest which includes
vehicle profile currency and departure date.
TollCostRequest Allows you to determine the toll costs for a specified route for a
defined vehicle profile.
TollCostResult Represents a result from a TCE request.
HERE Android SDK Developer's Guide
User Guide
133
Class Description
TollCostVehicleProfile Specify different vehicle parameters and optional input
parameters.
Requesting the Toll Cost Data
To use Toll Cost Extension, you need to first have a route calculated in online mode, as the Toll Cost
Extension requires permanent directed link IDs. After having a route from the core router, you can then
retrieve the toll cost of the route.
// Create the core router
CoreRouter router = new CoreRouter();
// We need link IDs, Route.getPermanentLinkIds(), so we force online routing
router.setConnectivity(Connectivity.ONLINE);
You can provide options for the toll cost request through an instance of TollCostOptions. If the
vehicle needs non-default settings, such as if this toll request is for a specific type of vehicle, create an
TollCostVehicleProfile object.
Note: It is your responsibility to provide a compatible route and toll cost options. When setting the
toll cost options, make sure that they match the route options. For example, if the toll cost option
vehicle type is set as truck, but the route is created for a car, they are incompatible. In this case, the
toll cost result may not be valid.
HERE Android SDK Developer's Guide
User Guide
134
Next, create a TollCostRequest request object. If the request object is valid and the route contains
permanent directed linkids, then you can execute the toll cost request via a result listener. When the result is
received, first it is checked for any error. If there is no error, its toll cost contents are retrieved.
Figure 54: A Toll Cost Example
// Step 1: Provide input and calculate toll cost.
Route route = null; // Required
Date departureTime = null; // Optional
// Step 2: Wrap all input.
// Vehicle profile -> Type Bus, EmissionType EURO_IV, TrailerType NONE. Optional.
TollCostVehicleProfile vehicleProfile = new TollCostVehicleProfile();
HERE Android SDK Developer's Guide
User Guide
135
vehicleProfile.setVehicleType(TollCostVehicleProfile.VehicleType.BUS);
vehicleProfile.setEmissionType(TollCostVehicleProfile.EmissionType.EURO_IV);
vehicleProfile.setTrailerType(TollCostVehicleProfile.TrailerType.NONE);
TollCostOptions options = new TollCostOptions();
parameter.setDeparture(departureTime);
parameter.setVehicleProfile(vehicleProfile);
// Step 3: Create request
TollCostRequest request = new TollCostRequest(route, parameter); // request created, can not be
modify.
// Step 4: Execute with result listener
request.execute(new TollCostRequest.Listener<TollCostResult>() {
@Override
public void onComplete(TollCostResult result, TollCostError error) {
// Step 5: process result
if(error.getErrorCode() != TollCostError.ErrorCode.SUCCESS) {
// what is the error?
error.getErrorMessage();
return;
}
// if success
// get total toll cost of a route
result.getTotalTollCost();
// get toll cost by country
java.util.Map<String, Double> tollCostByCountry = result.getTollCostByCountry();
// get toll cost by toll system name
java.util.Map<String, Double> tollCostByTollSystem = result.getTollCostByTollSystemName();
}
});
Street-Level
This section provides an overview of Street-Level Imagery and Street-Level Objects in the HERE Android
SDK. With Street-Level Imagery, developers can add an immersive street visualization experience to their
application; with Street-Level Objects, developers can add objects, such as billboards and markers, to
custom locations in the Street-Level View.
Street-Level Imagery
The HERE Android SDK allows application developers to offer users panoramic street-level imagery for many
cities.
HERE Android SDK Developer's Guide
User Guide
136
Street-level imagery is a collection of interconnected 360-degree panoramas. You can navigate from one
panorama to another by tapping on links that appear on-screen as arrows pointing in various navigable
directions.
Figure 55: Street-level imagery at San Francisco
The key concepts covered in this section include:
how to display the street-level coverage on a map
how to display the street-level imagery in an Android application
how to select the displayed street-level location
how to add, remove and interact with components of the street-level scene
The street-level imagery APIs follow a similar design as the mapping classes: StreetLevelFragment acts
as a View, and StreetLevelModel act as a Model in a Model-View-Controller (MVC) pattern. You can create
a controller class to coordinate interactions using custom logic.
Coverage
Street-level imagery is available in more than ninety cities. To display the street-level imagery
coverage area on a map, the Map.setStreetLevelCoverageVisible(boolean) method from the
com.here.android.mpa.mapping.Map class can be used as described in the code snippet below. The
area where the imagery is available is highlighted on the map.
//Assume that map is instantiated
HERE Android SDK Developer's Guide
User Guide
137
map.setStreetLevelCoverageVisible(true);
Figure 56: Map of San Francisco
Using Street-level Imagery
This section describes how to enhance an application by displaying the appropriate street-level imagery
when a user taps on a location on a map. Map data for a specified location must be already downloaded and
available before the imagery is requested for that location. This is achieved by displaying the map for that
location first, or by pre-downloading the map data for that region.
The first step to integrate street-level imagery into an application is to insert
a StreetLevelFragment into a view layout. This is accomplished by adding
com.here.android.mpa.streetlevel.StreetLevelFragment to the Android XML layout file as per
the following example. StreetLevelFragment is a standard Android Fragment-derived component that
enables the display and gesture interactions with street-level scenes.
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/streetlevel_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<fragment
class="com.here.android.mpa.streetlevel.StreetLevelFragment"
android:id="@+id/streetlevelfragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1"/>
...
</LinearLayout>
After adding a StreetLevelFragment to the layout, the fragment must be initialized by calling the
function StreetLevelFragment.init(OnEngineInitListener). During initialization, a default
StreetLevelModel is created and associated to the street-level fragment. Street-level imagery can be
HERE Android SDK Developer's Guide
User Guide
138
enhanced by displaying an arrow to show the possible navigation directions. This is achieved by adding an
image (for example: an arrow) to the street-level model and making it visible, as shown below:
...
streetLevelFragment = (StreetLevelFragment) getFragmentManager()
.findFragmentById(R.id.streetlevelfragment);
streetLevelFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
com.here.android.mpa.common.Image arrow = new com.here.android.mpa.common.Image();
try {
arrow.setImageResource(R.drawable.panoarrow);
} catch (IOException e) {
//handle error
e.printStackTrace();
}
streetLevelFragment.getStreetLevelModel().setNavigationArrow(arrow);
streetLevelFragment.getStreetLevelModel()
.setNavigationArrowVisible(true);
streetLevelFragment.getStreetLevelModel().setOverlayTransparency(
0.5f);
}
}
});
...
The logic required to launch street-level imagery for a particular user-selected map location
is illustrated in the following MapGesture.OnGestureListener.onTapEvent(PointF
p) method. First, the street-level scene for the specified location is retrieved by calling the
StreetLevelModel.getStreetLevel(GeoCoordinate center,int searchRadius) method. This
method searches for the street level that is closest to the specified coordinate. The search area around the
coordinate is defined by the searchRadius which is expressed in meters. The street-level imagery for the
specified location is then rendered by calling StreetLevelModel.moveTo(StreetLevel streetLevel,
boolean animation, float heading, float pitch, float zoom).
// Map event listener
private MapGesture.OnGestureListener mapGestureListener =
new MapGesture.OnGestureListener() {
...
@Override
public boolean onTapEvent(PointF p) {
final StreetLevelFragment streetLevelFragment =
(StreetLevelFragment) getFragmentManager()
.findFragmentById(R.id.streetlevelfragment);
if (streetLevelFragment.getStreetLevelModel() != null) {
GeoCoordinate coordinate = map.pixelToGeo(p);
// Get street level meta data
StreetLevel level =
streetLevelFragment.getStreetLevelModel()
.getStreetLevel(coordinate, 100);
if (level != null) {
// Render street level imagery
streetLevelFragment.getStreetLevelModel().moveTo(
level, false, map.getOrientation(), 0, 1.0f);
}
}
return false;
}
...
HERE Android SDK Developer's Guide
User Guide
139
};
Issue-Reporting Link
To comply with government regulations, street-level imagery in the HERE SDK is always accompanied by a
link to report incorrect imagery and privacy concerns. By default, the issue-reporting link is displayed in
English. If the user's device language is set to French or German, then the issue-reporting link appears in
these languages.
Note: It is a requirement for the issue-reporting link to be unobscured while street-level imagery is
visible.
Using Gestures in a Street-level Scene
Street-level imagery supports the following default gestures:
Rotate: Pan the Street-level view to rotate or change the pitch
Pinch/Spread to Zoom: Zoom out or zoom in by respectively, pinching or spreading two fingers being
held on the screen
Single Tap: Select and highlight the object tapped
Double Tap: Move to a new location with the center in the vicinity of where the screen was tapped.
The StreetLevelGesture class allows an app to enable, disable, and handle gestures in a street-
level scene. StreetLevelGesture is used in a similar manner as the MapGesture class. To use it, call
StreetLevelFragment.getStreetLevelGesture() to retrieve the associated object instance, then use
setter methods (such as setPinchEnabled(false)) to disable any unwanted gestures.
Note: By default, rotation, pinch, single-tap and double-tap are enabled in StreetLevelGesture.
As with MapGesture.OnGestureListener, you can add custom logic to handle street-level gestures by
implementing StreetLevelGesture.OnGestureListener. The OnGestureListener class contains
methods such as onPinchZoom that are called when a user performs the particular gesture. As with
MapGesture.OnGestureListener, you can allow or prevent the default gesture behavior to be performed
after your implemented callback by returning a boolean value.
private StreetLevelGesture.OnGestureListener myStreetLevelGestureListener =
new StreetLevelGesture.OnGestureListener() {
...
@Override
public boolean onObjectsSelected(List<StreetLevelSelectedObject> selectedObjects) {
boolean consumed = false;
for (StreetLevelSelectedObject o : selectedObjects) {
if (o != null) {
ViewObject vo = (ViewObject) o.getObject();
if (vo instanceof StreetLevelBuilding) {
StreetLevelBuilding b = (StreetLevelBuilding) vo;
b.setHighlight(0.5f);
consumed = true;
break;
}
}
}
return consumed;
}
HERE Android SDK Developer's Guide
User Guide
140
...
// implement the other gesture callbacks
}
To add the listener to your street-level view, include a call to
addOnGestureListener(StreetLevelGesture.OnGestureListener) after the street-level fragment
has been successfully initialized as follows:
...
streetLevelFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// fragment has been successfully initialized
if (streetLevelFragment.getStreetLevelGesture() != null) {
streetLevelFragment.getStreetLevelGesture().addOnGestureListener(
myStreetLevelGestureListener);
}
}
}
});
...
Note: Remember to call removeOnGestureListener(OnGestureListener) when you no longer
need to listen for street-level gesture events to free up application resources.
OnEventListener Interface
The StreetLevelModel.OnEventListener interface represents a listener to provide notification
upon completion of a StreetLevel event such as user interaction with a street-level object. Relevant
StreetLevelModel methods that control adding and removing this kind of listener include:
StreetLevelModel.addStreetLevelModelListener(OnEventListener);
StreetLevelModel.removeStreetLevelModelListener(OnEventListener)
Registration of the OnEventListener should be performed after the StreetLevelFragment is initialized
as described in the code snippet below.
...
streetLevelFragment = (StreetLevelFragment) getFragmentManager().findFragmentById(
R.id.streetlevelfragment);
streetLevelFragment.init(new FragmentInitListener() {
@Override
public void onFragmentInitializationCompleted(InitError error) {
if (error == InitError.NONE) {
StreetLevelModel model =
streetLevelFragment.getStreetLevelModel();
if (model != null) {
model.addStreetLevelModelListener(onEventListener);
}
...
}
}
});
...
Removing the street-level listener can be performed as described in the code snippet below.
HERE Android SDK Developer's Guide
User Guide
141
...
StreetLevelFragment streetLevelFragment =
(StreetLevelFragment) getFragmentManager()
.findFragmentById(R.id.streetlevelfragment);
streetLevelFragment.getStreetLevelModel()
.removeStreetLevelModelListener(onEventListener);
...
Compass Map
By default, a circular map view called a Compass Map is presented with street-level imagery. Users
can view it by panning a street-level view downward towards the ground. Compass Map provides users
with their direction and location context while they are viewing the street-level scene. Users cannot
directly manipulate a Compass Map, but changes from panning or navigating the street-level imagery are
immediately reflected in it.
To disable the Compass Map, use the setCompassMapVisible(boolean) method in StreetLevelModel.
Street-Level Objects
The street-level API exposes access and allows interaction with two different types of objects that are part of
the street-level scene:
PROXY_OBJECT - provided automatically in the street-level scene when it is displayed.
USER_OBJECT - provided by the application and can be added in to the street-level scene.
The supported street-level proxy objects are:
StreetLevelBuilding - a building that is visible in the street-level scene
HERE Android SDK Developer's Guide
User Guide
142
StreetLevelLink - a navigation arrow that can be clicked by the user to navigate from one panorama
to another
The following code snippet highlights the selected building from a street-level scene. All the logic is
implemented in the
StreetLevelGesture.OnGestureListener.onObjectsSelected(List<StreetLevelSelectedObject>
selectedObjects) method.
private StreetLevelGesture.OnGestureListener listener
= new StreetLevelGesture.OnGestureListener() {
...
@Override
public boolean onObjectsSelected
(List<StreetLevelSelectedObject> selectedObjects) {
boolean consumed = false;
for (StreetLevelSelectedObject object : selectedObjects) {
if (object!= null) {
ViewObject viewObject = (ViewObject) object.getObject();
if (viewObject instanceof StreetLevelBuilding) {
StreetLevelBuilding building
= (StreetLevelBuilding) viewObject;
building.setHighlight(0.5f);
consumed = true;
break;
}
}
}
return consumed;
}
...
};
The supported street-level user objects are:
StreetLevelIcon - an image that has a specified location on the street level map
StreetLevelBillboard - a billboard that has a specified location on the street-level map
Note: Both objects can also be attached to a StreetLevelBuilding.
The major differences between these objects are the way the size is specified and how they are rendered
when a zoom operation is performed. The billboard has the size specified in meters so it is always rendered
relative to the size of the building, while the StreetLevelIcon has the size specified in pixels and has
a StreetLevelIconSize.ScalePolicy to define the rendering size. Relevant StreetLevelModel
methods that control adding and removing street-level objects are:
StreetLevelModel.addStreetLevelObject(StreetLevelObject streetLevelObject)
StreetLevelModel.removeStreetLevelObject(StreetLevelObject streetLevelObject)
The easiest way to enhance an application by displaying a street-level user object is to create the object, set
the content (desired image) and properties (image size and building identifier) and add it to the street-level
model as described in the code snippet below.
@Override
public boolean onObjectsSelected(List<StreetLevelSelectedObject> selectedObjects) {
boolean consumed = false;
HERE Android SDK Developer's Guide
User Guide
143
for (StreetLevelSelectedObject object : selectedObjects) {
if (object != null) {
ViewObject viewObject = (ViewObject) object.getObject();
if (viewObject instanceof StreetLevelBuilding) {
StreetLevelBuilding building = (StreetLevelBuilding) viewObject;
building.setHighlight(0.5f);
consumed = true;
// Create Image
com.here.android.mpa.common.Image streetLevelImage =
new com.here.android.mpa.common.Image();
try {
streetLevelImage.setImageResource(
R.drawable.streetLevelIconImage);
} catch (Exception io) {
System.out.println(
"ERROR: Cannot create street " + "level icon image");
}
// Create Icon and set properties
StreetLevelIcon streetLevelIcon = new
StreetLevelIcon(building.getPosition(),streetLevelImage);
StreetLevelIconSize size = new StreetLevelIconSize(100,100);
streetLevelIcon.setSize(size);
streetLevelIcon.setAttachmentIdentifier(building.getIdentifier());
// Add icon to the street level
streetLevelModel.addStreetLevelObject(streetLevelIcon);
break;
}
}
}
return consumed;
}
Note: It is not necessary to have both the StreetLevelFragment and the MapFragment in the
same activity. However, before a StreetLevelFragment can be used, the area to be displayed in
the StreetLevelFragment must be previously shown on the Map in order for the related data to be
downloaded onto the device.
Placing Street-level Objects
The HERE Android SDK also allows you to control the placement of a street-level object. For example, you
may wish to put a large billboard to cover the entire side of a building, or you may want a small icon in the
middle of a road. Whether it is a billboard or an icon, you can use the StreetLevelIconPlacement class
to control how your street-level object is presented to the user.
The first step to place your object is to determine whether your street-level object is attached to a building,
or placed according a geocoordinate location.
For objects attached to a building, call setAttachmentIdentifier(Identifier) with a building Id.
For objects not attached to a building, the HERE SDK places the object at its geocoordinate position. You
can optionally call setAnchorPoint(PointF) to indicate which part of the billboard is used as the
anchor, hovering exactly over the specified geocoordinate position.
Note: Using the StreetLevelIconPlacement.HorizontalPlacement.DEFAULT placement
mode places the object at its geocoordinate position, even if setAttachmentIdentifier() has
been set.
HERE Android SDK Developer's Guide
User Guide
144
Next, call the StreetLevelIconPlacement constructor to create a StreetLevelIconPlacement
object, and call setPlacementMode() to set it to the street-level object. See the following tables to see
descriptions of the valid vertical and horizontal placement modes.
VerticalPlacement value Notes
TERRAIN The vertical placement height parameter is evaluated as meters above the current terrain.
ATTACHMENT Used with objects that are attached to buildings. The height parameter is evaluated as a ratio of the
building height, with 0 indicating the ground level, and 1 being the top of the building.
FACADE Used with HorizontalPlacement.FACADE. Refer to the table below. (If this value is used with
another horizontal placement mode, the HERE SDK treats it as HorizontalPlacement.TERRAIN.)
DEFAULT The vertical placement height parameter is evaluated as meters above sea level.
HorizontalPlacement value Notes
FACADE Used for objects attached to buildings
Places the street-level object on the side of the building that is most visible to the camera
Object placement is updated as the camera moves
Using it with VerticalPlacement.FACADE places the object at a height as defined by you or
the HERE SDK, whichever is higher
SURFACE Used for objects attached to buildings
"Snaps" object to the closest point on the building, as determined by the object's
geocoordinate position
Object is viewable through the attached building's faces (For example, an object that has
"snapped" to building face A is viewable through building face B, even if A is obstructed)
TRACK_CAMERA Used for objects not attached to buildings
Object is placed at the camera location. The object's geocoordinate is ignored
VerticalPlacement mode is ignored, regardless of the set value
Vertical placement height is evaluated as meters above or below the camera
CENTROID Used for objects attached to buildings
Can only be used for icons, not billboards
When used, icon is placed as if it is in the center of the attached building
You can see the icon through the faces of the attached building
DEFAULT The object is placed at its geocoordinate position, even if it is associated with a building.
Orienting Street-level Objects
You can control the orientation of street-level billboards by using the
StreetLevelBillboardOrientation class. To use this class, call its constructor to create an object
instance, and then set it to your billboard object using StreetLevelBillboard.setOrientation().
The StreetLevelBillboardOrientation constructor has three arguments: an orientation mode enum, a
normal vector indicating how the billboard is oriented, and an up vector indicating how the billboard stands.
Vectors may be ignored depending on the orientation mode.
The following is a list of the possible orientation mode values:
HERE Android SDK Developer's Guide
User Guide
145
FIXED - Orients the billboard according to a normal and up vector.
VERTICAL_FIXED - The billboard is always upright. The horizontal orientation of the billboard is set
according to a normal vector.
BILLBOARD - The billboard is always upright and oriented towards the camera.
Turn-by-Turn Navigation for Walking and Driving
Note: [Important] Application developers using the Turn-by-turn Guidance APIs are required to
thoroughly test their applications in all expected usage scenarios to ensure safe and correct behavior.
Application developers are responsible for warning their users of the following obligations:
1. Do not follow instructions that may lead to an unsafe or illegal situation
2. Obey all local laws.
3. Be aware that using a mobile phone or some of its features while driving may be prohibited.
4. Always keep hands free to operate the vehicle while driving.
5. The first priority while driving should be road safety.
The HERE Android SDK supports navigation on pedestrian , truck, and car routes. Using this feature, your
app can check the current device position against a calculated route and get just-in-time navigational
instructions. Both visual and audio instructions are supported.
The HERE Android SDK can also track the current position and display it on the map without a calculated
route.
HERE Android SDK Developer's Guide
User Guide
146
Note: Your application should switch to the navigation-specific map schemes while performing
navigation. For more information on using these schemes, see Map Schemes on page 30.
Figure 57: Turn-by-turn Navigation with Speed Warning
Note: MapEngine.getInstance().onResume() should be called when the engine is required
for headless navigation operations. (For example, if you are providing your own map tiles.) This puts
the engine in the "active state". MapEngine.getInstance().onPause() puts the engine into a
suspended state and release cached in memory data. The onResume() and onPause() methods are
reference-counted and should be called an equal number of times.
The NavigationManager Class
The NavigationManager class is responsible for providing voice and visual instructions to
the user while driving or walking. An instance of NavigationManager can be retrieved using
NavigationManager.getInstance(). It should be associated with a map with the setMap(Map) method
before navigation is started.
Navigation can be started in three different modes:
Simulation Mode - simulate(Route, long) - This mode does not require any GPS data from the
device, as the position is simulated along the given route.
Navigation Mode - startNavigation(Route) - This mode takes the calculated route and matches the
position against the route. Before using this mode, PositioningManager is required to be running
using GPS data.
Tracking Mode - startTracking() - This mode does not require a calculated route, as it only tracks
and shows the current position on the map.
HERE Android SDK Developer's Guide
User Guide
147
Note: The Android permission android.permission.ACCESS_FINE_LOCATION is required to use
the NavigationManager. Otherwise, the class returns Error.POSITIONING_FAILED. In addition,
to ensure that the app receives location updates, the user needs to have the Location permission
enabled (toggled to "on") during runtime.
The following is an example of performing navigation on a calculated route:
NavigationManager navigationManager = NavigationManager.getInstance();
//set the map where the navigation will be performed
navigationManager.setMap(getMap());
// if user wants to start real navigation, submit calculated route
// for more information on calculating a route, see the "Directions" section
NavigationManager.Error error = navigationManager.startNavigation(route);
Note: During a navigation session, it is recommended that you handle gestures by calling
NavigationManager.setMapUpdateMode(MapUpdateMode.NONE). This stops the map from
moving, but it does not affect position indicator movement and voice navigation. To re-enable map
movement, call NavigationManager.setMapUpdateMode(MapUpdateMode) with the previous
update mode enum, such as MapUpdateMode.ROADVIEW.
Background Navigation
If you are using the Turn-by-Turn Navigation Mode for driving, you can also set the HERE SDK to perform
guidance (including voice instructions and event callbacks) while the app is in the background. However,
unlike the foreground navigation scenario, HERE SDK does not stream map data during background
navigation. To properly support background navigation, HERE SDK requires your app to preload map data
(such as for the current city or state) using the MapLoader class.
Map Matching During Navigation
Map Matching is automatically enabled in both navigation mode and tracking mode. In simulation mode, the
map-matched position is simulated along the route with a user-defined speed.
Tunnel Extrapolation
Tunnel extrapolation is also performed internally by NavigationManager. It uses the last
available position data, which contains speed, orientation and GeoCoordinate, to estimate
the position of your vehicle inside a tunnel. If your application listens to position updates from
NavigationManager.PositionListener, there are regular position updates during tunnel
extrapolation. However, if your application also listens to the onPositionFixChanged() callback from
PositioningManager.OnPositionChangedListener, then it receives this callback, signifying a position
fix change. (For more information on the OnPositionChangedListener, see the Positioning section.) If
the road element at position contains the tunnel attribute, it implies that the current location is provided
by tunnel extrapolation. Position updates during tunnel extrapolation should be treated the same way as
regular updates.
The following sample code demonstrates how to determine if tunnel extrapolation is active:
// At startup, have a member variable position manager setup
// and listening to events
positioningManager = PositioningManager.getInstance();
HERE Android SDK Developer's Guide
User Guide
148
positioningManager.addListener(
new WeakReference<PositioningManager.OnPositionChangedListener>(this);
positioningManager.start(LocationMethod.GPS_NETWORK);
......
// upon callback, determine if tunnel extrapolation is active
public void onPositionFixChanged(LocationMethod method, LocationStatus status) {
if (method == LocationMethod.GPS) {
boolean isExtrapolated =
((positioningManager.getRoadElement() != null) &&
((positioningManager.getRoadElement().getAttributes()
.contains(RoadElement.Attribute.TUNNEL))));
boolean hasGps = status == LocationStatus.AVAILABLE;
}
}
Natural Guidance
The NavigationManager.setNaturalGuidanceMode() method can be used to enable natural guidance.
Natural guidance refers to a type of dynamic information available during navigation where route guidance
instructions contain contextual elements around a decision point. These contextual elements may include
services, catographic features, traffic signals, and stop signs. Some examples of natural guidance instructions
are:
"Go past the park on your right, then turn left at Anderson school on Bayview street"
"Go through the traffic light and turn right before the petrol station"
"Continue on your route, passing the dome building on your right"
Three options are available for natural guidance, and they are defined by the
NavigationManager.NaturalGuidanceMode enumerations. Note that STOP_SIGN,
TRAFFIC_LIGHT and JUNCTION can be used together. To disable natural guidance, call the
setNaturalGuidanceMode(EnumSet<NaturalGuidanceMode>) method with an empty EnumSet.
TRAFFIC_LIGHT - Natural guidance for traffic lights
STOP_SIGN - Natural guidance for stop signs
JUNCTION - Natural guidance for junctions such as landmarks
To use the natural guidance feature, set your voice package to the map display language. Also, to get the
best results, use the appropriate voice package for the current location. For example, use the French voice
package in the city of Paris. Natural guidance currently supports the following text-to-speech voice packages:
U.S. English
U.K. English
• Italian
• Spanish
• German
• French
HERE Android SDK Developer's Guide
User Guide
149
Navigation Events
NavigationManager Listeners
The NavigationManager contains a number of listeners that are responsible for for monitoring navigation
status and getting instructions during navigation. The following table shows the name of the available
listeners and the information provided them.
Listener Name Purpose
PositionListener Whether the current position has updated
NavigationManagerEventListener Whether the navigation session has started, updated, or ended
NewInstructionEventListener Whether a new navigation instruction is available to be fetched
GpsSignalListener Whether the system has lost its GPS signal
RerouteListener Whether a route recalculation has begun as a result of the current position deviating
from the original route
TrafficRerouteListener Whether a route recalculation to avoid traffic has begun
SpeedWarningListener Whether the user has exceeded the speed limit
SafetySpotListener Whether safety spots, such as speed cameras and red light cameras, are upcoming
LaneInformationListener Whether lane information should be presented
RealisticViewListener Listens for events related to a realistic view image
AudioFeedbackListener Whether a voice command or vibration alert is available
Listener instances can be added to NavigationManger through their respective add and remove
methods. For example, the LaneInformationListener can be added and removed by using
addLaneInformationListener(WeakReference<LaneInformationListener>) and
removeLaneInformationListener(WeakReference<LaneInformationListener>).
Note: NavigationManager.SpeedWarningListener only returns car speed warnings. Truck
speed warnings are not currently supported.
New Instructions and Maneuvers
The Maneuver class represents the action required to go from one segment to the next within a calculated
Route. Each Maneuver object provides information such as:
Location of the maneuver
Action required to complete the maneuver
Distance between maneuvers
Current road
Next road
Estimated times of the maneuver
Signposts (if any) indicating entrance, exit, or merge information
HERE Android SDK Developer's Guide
User Guide
150
The NavigationManager provides a new Maneuver object after every onNewInstructionEvent()
callback. You can implement NewInstructionEventListener and implement this callback to provide
display logic. For example:
@Override
public void onNewInstructionEvent() {
Maneuver maneuver = navigationManager.getNextManeuver();
if (maneuver != null) {
if (maneuver.getAction() == Maneuver.Action.END) {
//notify the user that the route is complete
}
//display current or next road information
//display maneuver.getDistanceToNextManeuver()
}
}
Rerouting
While navigation is in progress, the following three types of rerouting can occur:
Basic Route Recalculation - This is performed automatically by the guidance engine. The guidance
engine checks the current position to see if it is on the route and approaching the target
destination. If it is not, then it triggers a route recalculation and updates the navigation session. The
RerouteListener.onRerouteBegin() and RerouteListener.onRerouteEnd() callbacks also
occur.
Dynamic Traffic Reroute - This mode is enabled by default. In this mode, the HERE SDK regularly requests
a traffic-aware route recalculation from the server, and the navigation manager switches to this route
automatically. For more information, see Traffic-Aware Navigation on page 155.
Manual Traffic Reroute - This mode can be optionally enabled. In this mode, the HERE SDK also requests
a traffic-aware route recalculation from the server, but it notifies the client before using the new route in
the navigation manager. For more information, see Traffic-Aware Navigation on page 155.
Lane Information
NavigationManager.LaneInformationListener provides the
onLaneInformation(List<LaneInformation>, RoadElement) callback method. This
callback occurs when the user has arrived at a point in the route where lane information should
be presented, such as before a highway exit. The LaneInformation class represents a lane turn
direction and whether this lane is on the current route. For example, an application may receive the
onLaneInformation(List<LaneInformation>, RoadElement) callback as the user navigates to an
intersection. If the route requires a left turn, and the current road has three lanes—a left-turn lane and two
straight lanes—then the callback returns with three LaneInformation objects. Since LaneInformation
objects are always returned in the callback method in a left-to-right order, the first LaneInformation has
a direction of LEFT and LaneInformation.getRecommendationState() returns a recommendation on
whether the lane can be taken for the current route. If there isn't enough data to determine whether the lane
is on or off-route, getRecommendationState() returns NOT_AVAILABLE.
HERE Android SDK Developer's Guide
User Guide
151
Realistic View: 2D Signposts and Junction View
In addition to the data offered through the Lane Info feature, the HERE Android SDK also offers image
previews of signposts and junctions on certain highways. These two features together are known as Realistic
View.
Figure 58: An Example of a 2D Signpost Figure 59: An Example of a Junction View
The 2D Signpost feature provides images that illustrate road signposts. For example, as a user approaches
a fork on a highway, your application can use show a preview of the instruction signs above the highway.
The Junction View feature provides images that illustrate road junctions. For example, as a user approaches
a junction on a highway, your application can show the lanes near the junction, with indicator arrows
highlighting the correct lane to take. Signpost and junction view images are provided as SVG images through
the following RealisticViewListener callback methods, which occur just after the previous maneuver
and before entering the junction:
onRealisticViewShow(AspectRatio, Image, Image)
onRealisticViewNextManeuver(AspectRatio, Image, Image)
Realistic view is disabled by default. To enable it, call
NavigationManager.setRealisticViewMode(RealisticViewMode) and set the view mode to
RealisticViewMode.DAY or RealisticViewMode.NIGHT. Next, register the desired image aspect
ratios by using addRealisticViewAspectRatio(AspectRatio ratio). After adding your listener
implementation, your application begins to receive the above event callbacks as the HERE SDK arrives to a
highway section that supports Realistic View.
Note: It is possible to add multiple aspect ratios and receive multiple images of the same signpost or
junction view.
The following is an example of onJunctionViewShow() and enabling realistic view:
// In the RealisticViewListener implementation
public void onRealisticViewShow(AspectRatio ratio, Image junction, Image signpost) {
if (junction.getType() == Image.Type.SVG) {
// full size is too big (will cover most of the screen), so cut the size in half
Bitmap bmpImage = junction.getBitmap((int) (junction.getWidth() * 0.5),
(int) (junction.getHeight() * 0.5));
if (bmpImage != null) {
//
// show bmpImage on-screen
//
}
HERE Android SDK Developer's Guide
User Guide
152
}
...
}
navigationManager.setRealisticViewMode(NavigationManager.RealisticViewMode.DAY);
navigationManager.addRealisticViewAspectRatio(AspectRatio.AR_4x3);
navigationManager.addRealisticViewListener(
new WeakReference<NavigationManager.RealisticViewListener>(viewListener));
Voice Instructions
You can use voice instructions with turn-by-turn navigation. Voice instructions are offered in a variety of
languages, which are available through downloadable text-to-speech (TTS) and pre-recorded voice skins.
Pre-recorded voice skins provide basic maneuver instructions, such as "turn right in 300 meters", while text-
to-speech voices also supports spoken street names, such as "turn right in 300 meters onto Granville Street".
You can check Navigation Voices on page 234 for a list of the supported voices in the HERE SDK.
Voice skins information and voice skins downloads can be managed through the voice catalog. The following
section describes how you can use the voice catalog, download voice skins, and use a voice skin with turn-
by-turn navigation.
Note: Voice instructions are only supported in Navigation Mode for driving. Users of the pedestrian
Navigation Mode receive audio beeps and vibrations alerts at the change of each maneuver.
Note: Voice navigation with routes that contain via waypoints is only supported through pre-recorded
voices.
The VoiceCatalog Class
The VoiceCatalog class is used to access voice skin files from the local device. A VoiceCatalog
object instance can be retrieved by calling VoiceCatalog.getInstance(). Then, using
getLocalVoiceSkins() method, you can fetch a list of VoiceSkin files that are stored on the device.
Be sure to check if VoiceCatalog.getCatalogList() is empty. Since the voice catalog is downloaded
based on the current device language, changing the device language causes an empty list of downloadable
voice skins. When this happens, the user needs to re-download the voice catalog.
Note: A set of sample voice skins are packaged with the HERE Android SDK in the {HERE
Android SDK}.zip/misc directory. To deploy these voice skins into your test device, extract the
voiceskins.tar.gz file, then call the following ADB command from the parent folder of the
voices folder:
adb push voices /sdcard/Android/data/{YourAppNamespace}/files/voices-download
The VoicePackage Class
The VoicePackage class represents an entry within the voice catalog. Each voice package shares a common
ID value with a downloadable voice skin. You can use this class to display information about the voice skin
before launching a download.
A list of VoicePackage can be accessed by using the VoiceCatalog.getCatalogList() method.
HERE Android SDK Developer's Guide
User Guide
153
The VoiceSkin Class
The VoiceSkin class encapsulates voice-generation scripts. The scripts are used to generate voice
instructions for navigation. A voice skin is language-specific and can either support Text-to-Speech or voice
audio files. Multiple voice skins can be loaded to the device, but only one can be selected for navigation
voice playback.
A list of loaded VoiceSkin instances can be accessed by using the VoiceCatalog singleton instance.
Each VoiceSkin can be fetched by the getLocalVoiceSkins() method. Voice skins can be passed to
NavigationManager by calling NavigationManager.setVoiceSkin(VoiceSkin).
Selecting a Voice Skin and Starting Navigation
The following is an example of how to start navigation using a calculated route and an English text-to-speech
voice skin:
1. Get a NavigationManager by calling NavigationManager.getInstance()
// Declare the navigationManager member variable
private NavigationManager navigationManager = null;
...
...
// Get the NavigationManager
navigationManager = NavigationManager.getInstance();
2. Get a calculated Route from CoreRouter. Refer to the code samples in the Routing section.
3. Declare NewInstructionEventListener and PositionListener member variables
// declare the listeners
// add application specific logic in each of the callbacks.
private NavigationManager.NewInstructionEventListener instructListener
= new NavigationManager.NewInstructionEventListener() {
@Override
public void onNewInstructionEvent() {
// Interpret and present the Maneuver object as it contains
// turn by turn navigation instructions for the user.
navigationManager.getNextManeuver();
}
};
private NavigationManager.PositionListener positionListener
= new NavigationManager.PositionListener() {
@Override
public void onPositionUpdated(GeoPosition loc) {
// the position we get in this callback can be used
// to reposition the map and change orientation.
loc.getCoordinate();
loc.getHeading();
loc.getSpeed();
// also remaining time and distance can be
// fetched from navigation manager
navigationManager.getTta(TrafficPenaltyMode.DISABLED, true);
navigationManager.getDestinationDistance();
}
};
HERE Android SDK Developer's Guide
User Guide
154
4. Add the listeners to NavigationManager to listen to the callbacks
// start listening to navigation events
navigationManager.addNewInstructionEventListener(
new WeakReference<NewInstructionEventListener>(instructListener));
// start listening to position events
navigationManager.addPositionListener(
new WeakReference<PositionListener>(positionListener));
5. Retrieve the VoiceCatalog and download the latest updates.
VoiceCatalog voiceCatalog = VoiceCatalog.getInstance();
voiceCatalog.downloadCatalog(new OnDownloadDoneListener() {
@Override
public void onDownloadDone(Error errorCode) {
if (errorCode == Error.NONE) {
// catalog download successful
}
}
});
6. Using the voice catalog, find the desired voice package. In this example, choose "English TTS" from the
voice catalog.
// Get the list of voice packages from the voice catalog list
List<VoicePackage> voicePackages = VoiceCatalog.getInstance().getCatalogList();
long id = -1;
// select
for (VoicePackage vPackage : voicePackages) {
if (vPackage.getMarcCode().compareToIgnoreCase("eng") == 0) {
if (vPackage.isTts()) {
id = vPackage.getId();
break;
}
}
}
Note: Some voice packages in the voice catalog may not be supported by the
installed TTS engine. You can check whether the language is supported by using the
isLanguageAvailable(Locale) method in android.speech.tts.TextToSpeech.
7. If the ID of the voice package does not match an item in the list of installed voice skins, install it. When
the installation operation completes, a callback to the onDownloadDone(Error) method occurs.
if (!voiceCatalog.isLocalVoiceSkin(id))
{
voiceCatalog.downloadVoice(id, new OnDownloadDoneListener() {
@Override
public void onDownloadDone(Error errorCode) {
if (errorCode == Error.NONE){
//voice skin download successful
}
}
});
}
8. Start navigation according to user selection. Navigation can be started in three different modes, but only
one of them can be started at a time:
HERE Android SDK Developer's Guide
User Guide
155
// if user wants to start simulation,
// submit calculated route and a simulation speed in meters per second
error = navigationManager.simulate(route, 60);
// set the voice skin for use by navigation manager
navigationManager.setVoiceSkin(voiceCatalog.getLocalVoiceSkin(id));
9. If the user decides to abort navigation, call stop().
// abort navigation
navigationManager.stop();
Traffic-Aware Navigation
With the HERE SDK, developers can enable turn-by-turn route navigation that takes live traffic information
into account. NavigationManager.setTrafficAvoidanceMode() can be used to set the way in which
traffic should be handled during navigation.
Three modes are available for traffic avoidance, and they are defined by the following
NavigationManager.TrafficAvoidanceMode enumerations. The default mode is DISABLE.
DYNAMIC - Performs traffic-aware rerouting without user input.
In this mode, the guidance engine performs periodic route calculations while the device is online.
A route calculation is a server request where the server finds the most optimal route by avoiding
traffic congestions and calculating speed limits. If the calculated route is different from the
current route, the navigation manager automatically switches to the new route. It also triggers the
NavigationManager.NavigationManagerEventListener.onRouteUpdated(Route) callback
method.
Note: You can set the frequency of the route request by using
NavigationManager.setRouteRequestInterval().
MANUAL - Provides notifications about upcoming traffic incidents and requires user confirmation before
rerouting. For more information, see the next section.
DISABLE - Disables traffic-based rerouting.
Manual Traffic-Based Rerouting
If the device is online and NavigationManager.TrafficAvoidanceMode.MANUAL is selected,
the guidance engine considers all incoming traffic event within proximity and checks if the event
is on the current route route, and whether the route is reroutable. If these conditions are true, the
engine triggers a route calculation. You can listen to this recalculation event by implementing the
onTrafficRerouteBegin(TrafficNotification) method in TrafficRerouteListener.
Route recalculation is a server request where the server finds the most optimal route
by avoiding live traffic congestions and calculating road speed limits. If the calculated
route is different from the current route, the new route is returned through the
NavigationManager.TrafficRerouteListener.onTrafficRerouted(Route) callback
method. A voice note is also played by the guidance engine. You can then set the new Route to the
NavigationManager manually.
HERE Android SDK Developer's Guide
User Guide
156
The TrafficWarner Class
The TrafficWarner class is responsible for enabling and handling traffic notifications. Traffic notifications
occur if there is a traffic event on the current route and the user's current position is near the event.
To retrieve an instance of the TrafficWarner object, call NavigationManager.getTrafficWarner().
You then can call TrafficWarner.init() to initialize and start the TrafficWarner.
One or more of the following methods can be used to operate traffic warner, or to retrieve further
information about traffic notifications:
isAhead(TrafficNotification) - determines whether or not a traffic notification is ahead of the
last callback position
isOnRoute(Route, TrafficNotification) - determines if a traffic notification is on a given route
isValid() - determines if the traffic warner is valid
setAskAvoidOutput(TrafficNotification) - sets the output of the traffic notification to "Do you
want to avoid.. ?"
setInformAvoidOutput(TrafficNotification) - sets the output of the traffic notication to "You
are rerouted because of..."
stop() - stops the traffic warner
start() - starts the traffic warner
To listen for traffic notifications, a listener must be added via TrafficWarner.addListener().
The TrafficNotification and TrafficNotificationInfo Classes
TrafficWarner.Listener provides a callback that returns a TrafficNotification object
that is relevant to the current navigation session. This TrafficNotification contains a list of
TrafficNotificationInfo instances associated with the traffic notification, retrievable through
TrafficNotification.getInfoList().
The TrafficNotificationInfo class encapsulates the details of a traffic notification.
TrafficNotificationInfo.Type defines the type of traffic notification with regards to the current route.
The following methods can be used to retrieve details about a TrafficNotificationInfo instance:
getType() - gets the type of traffic notification info
getEvent() - gets the traffic event (TrafficEvent) associated with the traffic notification info
getDistanceInMeters() - gets the distance from the last callback position to the traffic notification
Audio Management
Manage Voice Volume
If your application uses voice navigation, it is recommended that you implement volume ducking and volume
control through hardware keys.
Volume ducking is the practice of manipulating volume based on audio focus. It allows another app, such as
a phone call, to flag its audio as having higher priority and "takes over" the current device audio. To grant
HERE Android SDK Developer's Guide
User Guide
157
or request audio focus, call NavigationManager.AudioPlayer.getStreamId() to retrieve the current
audio stream, and then use it with the Android AudioManager. For example:
int result = audioManager.requestAudioFocus(afChangeListener,
NavigationManager.getInstance().getAudioPlayer().getStreamId(),
AudioManager.AUDIOFOCUS_GAIN_TRANSIENT_MAY_DUCK);
By default, the HERE SDK uses AudioManager.STREAM_MUSIC as the audio stream. For more information
on volume ducking, consult this article: "Managing Audio Focus" .
To control voice navigation volume through hardware keys, call
Activity.setVolumeControlStream(NavigationManager.AudioPlayer.getStreamId()) at an
early point in your app's lifecycle. This ensures that presses on the hardware keys modify the volume for the
navigation manager's audio stream. For more information on hardware keys and application audio volume,
consult this article: "Controlling Your App's Volume and Playback" .
Overriding Default Audio Playback
The HERE SDK provides a way for you to take over audio playback by the
NavigationManager. To do this, implement the AudioPlayerDelegate class, and call
NavigationManager.AudioPlayer.setDelegate(AudioPlayerDelegate). Note that setting a
delegate stops all audio and text-to-speech playback by the SDK.
The AudioPlayerDelegate interface contains two callback methods. When you are implementing your own
delegate, follow these recommendations:
AudioPlayerDelegate.playText(String)
If you are using your own text-to-speech engine, the locale used in the engine should match up with the
VoiceSkin.
In most cases, the text can be directly submitted to the engine's playback API. For example, for the
Android system text-to-speech engine, you can submit the text to TextToSpeech.speak(String,
int, HashMap).
For the best user experience, the speech rate and pitch should be adjusted.
AudioPlayerDelegate.playFiles(String[])
The list of file paths come in a sequence. The order in the array indicates the exact order the files should
be played. The files are single words used for composing commands with numbers and units.
Since recordings may contain padding in the end, do not play the files in a sequence, as
this sounds too slow and robotic. Instead, you can add each file into individual instances of
android.Media.MediaPlayer, and at almost the end of playback for one file, start the next one in
parallel. In this manner, the resulting sentence sounds more natural. The finite timing before the end of
playback can be adjusted and experimented to achieve the best user experience.
Urban Mobility
This section provides an overview of the Urban Mobility features in the HERE SDK. These features allow
developers to query and use advanced information related to public transit systems.
HERE Android SDK Developer's Guide
User Guide
158
Note: Before using Urban Mobility, be aware of the following:
All Urban Mobility features is currently offered as a beta feature. APIs may change without notice.
Access to the Next Nearby Departures, All Next Departures, and Transit Routing features are
restricted. Please contact a HERE representative (https://developer.here.com/contact-us?
interest=mobile-sdk#contact-sales) for more information.
Coverage Search
Urban Mobility Coverage Search provides detailed information about the regions and cities with public
transit data that are supported by HERE SDK. For example, you can get a list of cities that have transit
data coverage by using a query request with a search area. You can create this type of request by using
RequestManager.createCityCoverageRequest(ResponseListener<CityCoverageResult>) to
generate a city coverage request object.
// Geo coordinate of a reference point
GeoCoordinate coordinates = new GeoCoordinate(40.750488, -73.993546); //somewhere in NY
// listener that will be notified after request is completed
RequestManager.ResponseListener<CityCoverageResult> responseListener = new
RequestManager.ResponseListener<CityCoverageResult>() {
@Override public void onSuccess(CityCoverageResult searchResult) {
List<City> foundCities = searchResult.getCities();
for (City city : foundCities)
{
String cityName = city.getDisplayName();
float percentCovered = city.getQuality();
// ...
}
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// report error
}
};
// creating and executing the request
// search coverage by city name
CityCoverageRequest request = new RequestManager()
.createCityCoverageRequest(responseListener).setLocation(coordinates) // if not specified,
returns all cities
.setRadius(150000) // meters
.setUpdateType(CityCoverageRequest.UpdateType.ALL) // all cities
.setTime(null); // works together with the UpdateType parameter
request.execute();
Another supported type of coverage search uses a query string to look for cities with
names that begin with this substring. You can create this type of request by using
RequestManager.createCitySearchRequest(String, ResponseListener<CitySearchResult>).
// name of the city to search
String name = "New York";
// listener that will be notified after request is completed
RequestManager.ResponseListener<CitySearchResult> responseListener = new
RequestManager.ResponseListener<CitySearchResult>() {
@Override public void onSuccess(CitySearchResult citySearchResult) {
for (City city: citySearchResult.getCities())
{
String name = city.getName();
HERE Android SDK Developer's Guide
User Guide
159
GeoCoordinate coordinates = city.getLocation();
int population = city.getPopulation();
// ...
}
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// report error
}
};
// creating and executing the request
// search coverage by city name
CitySearchRequest request = new RequestManager().createCitySearchRequest(
name, responseListener);
request.execute();
You can also use RequestManager.createNearbyCoverageRequest(GeoCoordinate,
ResponseListener<NearbyCoverageResult>) to search for coverage information around a given
location. This type of search returns information of the city that contains this location. If there is no transit
stop within 2 kilometers of the location, the request returns the first five nearest transit stops outside of the
2 kilometers area. This type of search result is also known as an "Explored Coverage". The following code
demonstrates how to retrieve both nearby and explored coverage results.
GeoCoordinate coordinates = new GeoCoordinate(40.750488, -73.993546); //somewhere in NY
// listener that will be notified after request is completed
RequestManager.ResponseListener<NearbyCoverageResult> responseListener = new
RequestManager.ResponseListener<NearbyCoverageResult>() {
@Override public void onSuccess(NearbyCoverageResult nearbyCoverage) {
City city = nearbyCoverage.getCity();
ExploredCoverage exploredCoverage = nearbyCoverage.getExploredCoverage();
...
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// report error
}
};
// creating and executing the request
// search coverage nearby
NearbyCoverageRequest request = new RequestManager().createNearbyCoverageRequest(coordinates,
responseListener);
request.execute();
HERE Android SDK Developer's Guide
User Guide
160
Transit Station Search
Figure 60: Station Search by Coordinates
The Transit Stations Search feature allows users to discover transit stations by searching for stations around
a specified location. For example, your application can look for the nearest subway station by retrieving all
subway stations at the current location with the specified radius.
The following code demonstrates how to trigger a station search by location:
GeoCoordinate centerCoordinates = new GeoCoordinate(40.750488, -73.993546); //somewhere in NY
// listener that will be notified after request is completed
RequestManager.ResponseListener<StationSearchResult> responseListener = new
RequestManager.ResponseListener<StationSearchResult>() {
@Override public void onSuccess(StationSearchResult searchResult) {
List<Station> foundStations = searchResult.getStations();
Collection<Transport> transports = searchResult.getTransports();
for (Station station: foundStations) {
String stationName = station.getAddress().getName();
// ...
}
// ...
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// report error
}
HERE Android SDK Developer's Guide
User Guide
161
};
// creating and executing the request
// search stations nearby
StationSearchRequest requestNearby = new RequestManager().createStationSearchRequest(
centerCoordinates, "", responseListener)
.setMaximumResults(3)
.setRadius(1000);
requestNearby.execute();
Figure 61: Station Search by Name
You can also search for public transit stations by providing its name. For example, a user searching for
"Penn" retrieves all stations that match that name. This search is location-aware, so results are sorted by
proximity to the current location.
The following code demonstrates how to perform a station search and filter by the specified name:
// search stations nearby with given name filter, returning transports information
StationSearchRequest requestName = new RequestManager().createStationSearchRequest(
centerCoordinates, "Penn", responseListener)
.setStationNameMatchingMethod(StationSearchRequest.NameMatchingMethod.FUZZY)
.setRequestStationDetailsEnabled(true);
requestName.execute();
You can also retrieve a station directly by specifying the station IDs while creating the
StationSearchRequest, as demonstrated in the following:
Set<String> ids = new HashSet<String>();
ids.add("717010002");
HERE Android SDK Developer's Guide
User Guide
162
ids.add("717001746");
// search stations by given IDs
StationSearchRequest requestIds = new RequestManager().createStationSearchRequest(
ids, responseListener);
requestIds.execute();
Next Nearby Departures
You can use the HERE SDK to query for the next transit departures for a particular station. Next nearby
departure information is based on the timetable information provided by transit agencies, and it includes all
types and times of departures from one station at a given time.
Note: Next Nearby Departures and All Next Departures are currently offered as beta features. APIs
may change without notice.
Figure 62: Station Departures
To query for the departures, create a request by using the stationId and stationCoordinates and
implement a ResponseListener. The returned DepartureBoard contains a list of Departure objects
that is sorted by the departure times.
// ID of a station, can be obtained from station search
String stationId = "717010002";
// Geocoordinate of a station
GeoCoordinate stationCoordinates = new GeoCoordinate(40.750488, -73.993546); //somewhere in NY
// listener that will be notified after request is completed
HERE Android SDK Developer's Guide
User Guide
163
RequestManager.ResponseListener<DepartureBoard> responseListener = new
RequestManager.ResponseListener<DepartureBoard>() {
@Override
public void onSuccess(DepartureBoard departureBoard) {
List<Departure> departures = departureBoard.getDepartures();
for (Departure departure : departures) {
Station station = departure.getStation();
Date departureTime = departure.getTime();
Transport line = departure.getTransport();
String direction = departure.getTransport().getDirection();
// ...
}
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// Handle error
}
};
// creating and executing the request
DepartureBoardRequest request = new RequestManager().createDepartureBoardRequest(
stationCoordinates, stationId, responseListener);
request.execute();
All Next Departures
To query for departure information of stations in a given area, create a request by using the coordinates
and implement a ResponseListener. The returned MultiBoardResult contains a list of
StationWithDepartureBoard objects that contain departure information, which are sorted by the
departure times. StationWithDepartureBoard is a child implementation of the Station class.
// Geocoordinate of a reference point
GeoCoordinate coordinates = new GeoCoordinate(40.750488, -73.993546); //somewhere in NY
// listener that will be notified after request is completed
RequestManager.ResponseListener<MultiBoardResult> responseListener = new
RequestManager.ResponseListener<MultiBoardResult>() {
@Override
public void onSuccess(MultiBoardResult multiBoard) {
Collection<StationWithDepartureBoard> stations = multiBoard.getStations();
Collection<Transport> transports = multiBoard.getTransports();
for (StationWithDepartureBoard station: stations) {
String stationName = station.getAddress().getName();
List<Departure> departures = station.getDepartureBoard().getDepartures();
for (Departure departure : departures) {
Date departureTime = departure.getTime();
Transport transport = departure.getTransport();
String direction = departure.getTransport().getDirection();
// etc.
}
}
}
@Override public void onError(ErrorCode errorCode, String errorMessage) {
// Handle error
}
};
// creating and executing the request
MultiBoardRequest requestNearby = new RequestManager().createMultiBoardRequest(
coordinates, responseListener);
HERE Android SDK Developer's Guide
User Guide
164
// You can set other search parameters here before calling execute()
requestNearby.execute();
You can call requestNearby.setRadius(int) to limit the search area before executing the search. You
can also limit the search to specific stations by using an overloaded createMultiboardRequest.
3D Venues
This section gives an overview of the classes and interfaces associated with the 3D Venues feature. Examples
of available 3D venues include shopping malls and airports. This section also explores three use cases:
searching for a venue, opening a venue, and getting a notification when a venue is visible in the viewport.
The classes covered in this section include:
VenueMapFragment
VenueMapView
VenueService
VenueMapFragment.VenueListener
VenueLayerAdapter
VenueService.VenueServiceListener
Note: To use this feature, your application must include the Gson library (release 2.2.4 or a
compatible version) on its class path.
Figure 63: 3D venue map of a Berlin shopping center
The 3D Venues feature can be used with or without a map. To use it with a map, use the VenueMapFragment
or VenueMapView. To use 3D Venues without a map, use the VenueService class.
HERE Android SDK Developer's Guide
User Guide
165
Using VenueMapFragment
VenueMapFragment provides developers with access to all 3D venue-related features. As with
MapFragment, VenueMapFragment needs to be added to the layout file of the application, for example:
<!-- Example fragment. This can be integrated and annotated like any other android
Fragment of View widget -->
<fragment
android:id="@+id/map_fragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
class="com.here.android.mpa.venues3d.VenueMapFragment" />
The fragment must then be initialized in the same manner as MapFragment.
VenueListener
To receive venue-related events, implement VenueMapFragment.VenueListener and add
it to the VenueMapFragment, similar to the following code example. As with a MapFragment,
you can mark VenueMapFragment initialization as successfully completed by looking for the
OnEngineInitListener.Error.NONE error status code.
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Search for the VenueMapFragment
final VenueMapFragment mapFragment = (VenueMapFragment)
getFragmentManager().findFragmentById(R.id.mapfragment);
// initialize the Map Fragment and
// retrieve the map that is associated to the fragment
mapFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted( OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// add listeners
mapFragment.addListener(myVenueListener);
mapFragment.getVenueService().addListener(myVenueServicelistener);
map = mapFragment.getMap();
} else {
System.out.println("ERROR: Cannot initialize VenueMapFragment");
}
}
});
}
In this example, myVenueListener is assumed to implement VenueMapFragment.VenueListener, and
myVenueServiceListener implements VenueService.VenueServiceListener. For more information
about these listener classes, see VenueService and VenueServiceListener on page 168.
Using VenueMapView
VenueMapView provides developers with similar features as VenueMapFragment, but as a MapView-based
class. Like MapView, VenueMapView needs to be added to the layout file of the application:
<!-- An example VenueMapView -->
<com.here.android.mpa.venues3d.VenueMapView
HERE Android SDK Developer's Guide
User Guide
166
android:id="@+id/mapcanvas"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
The view must then be initialized in the same manner as MapView. As with a MapView,
you can mark VenueMapView initialization as successfully completed by looking for the
OnEngineInitListener.Error.NONE error status:
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Search for the VenueMapView
final VenueMapView mVenueMapView = (VenueMapView)findViewById(R.id.venuemapview);
// get and initialize the MapEngine and
// assign the VenueMapView to it
ApplicationContext context = new ApplicationContext(this);
MapEngine.getInstance().init(context, new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted( OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// create and assign map
mMap = new Map();
mVenueMapView.setMap(mMap);
mVenueMapView.init(this, mVenueServiceListener);
mVenueMapView.addListener(mVenueListener);
} else {
System.out.println("ERROR: Cannot initialize VenueMapView");
}
}
});
}
Working with 3D Venue Models
Once a VenueMapFragment or VenueMapView is correctly initialized, 3D-enabled venues become visible
on the map. These venues can be distinguished by their colors and icons, as in the screenshot below. This
screenshot was taken from an app that uses VenueMapFragment, but the same visuals also appear on a
VenueMapView.
Figure 64: A 3D venue on the Map
HERE Android SDK Developer's Guide
User Guide
167
VenueMapFragment offers two ways to select a venue and open the indoor map view. When a
user taps the venue, the onVenueTapped(VenueController, float, float) method in
VenueMapFragment.VenueListener is called with a Venue object as a parameter. The venue can then be
opened by giving the Venue object to selectVenue(Venue). For example:
public void onVenueTapped(Venue venue, float x, float y) {
mapFragment.selectVenue(venue);
}
When the venue is selected, the onVenueSelected(Venue) callback of the
VenueMapFragment.VenueListener interface is called. A venue can also be selected and opened by
giving its identifier by using the selectVenueAsync(String venueId) method of VenueLayerAdapter,
which is implemented by VenueMapFragment. For example, a typical scenario is a venue search where a
successful search results in an opened venue.
The selectVenue(Venue) method opens the venue right away in a synchronous manner by taking
a downloaded Venue object as a parameter. However, the selectVenueAsync(String) and
selectVenueAsync(String, String) methods may involve downloading the venue from the
backend, asynchronously, while the venue is selected and opened. You can get a notification for when
asynchronous loading is complete by listening to the onGetVenueCompleted(Venue) callback in
VenueService.ServiceListener.
It is also possible to receive a notification when there is a venue in the viewport. You can use this callback to
implement a feature, such as drawing user attention to the venue when it is visible.
The triggering area for this is a rectangle at the center of the viewport. The width of the area is two-thirds
of the screen width, and the height is equal to the width. When the center point of the venue enters
this triggering area, such as during map panning, onVenueVisibleInViewport(Venue, boolean)
of VenueMapFragment.VenueListener is called. The boolean parameter indicates whether the
venue is entering or exiting from the triggering area. Note that to get the notifications, you must first set
setVenuesInViewportCallback(boolean) to true. For example:
// enabling onVenueVisibleInViewport notification
mapFragment.setVenuesInViewportCallback(true);
//...
@Override
public void onVenueVisibleInViewport(Venue venue, boolean visible) {
if (visible) {
// venue entered triggering area
} else {
// venue disappeared from triggering area
}
}
Note: This feature is not processor-intensive, as checking only occurs once as map movement stops.
The notification is not sent during continuous movement, even when there is a venue in the triggering
area.
To change the current floor for a given venue, retrieve a VenueController object
by using the getVenueController(String venueId) method, and then call the
VenueController.selectLevel(Level) method.
HERE Android SDK Developer's Guide
User Guide
168
You can enable animations for venue selection and floor transitions by calling
setFloorChangingAnimation(true) and setVenueEnteringAnimation(true).
VenueService and VenueServiceListener
In the case where you are not using a VenueMapFragment, you can use the
VenueService instead. The service initialization status is provided as a parameter
to the onInitializationCompleted(InitStatus) callback method in the
VenueService.VenueServiceListener interface. You can also retrieve the status using the
getInitStatus() method in VenueService.
boolean cacheInUse = false
//...
@Override
public void onInitializationCompleted(InitStatus result) {
if (result == InitStatus.ONLINE_SUCCESS) {
// init ok, online content available
} else if (result == InitStatus.OFFLINE_SUCCESS) {
// cached content available
cacheInUse = true;
} else if (result == InitStatus.ONLINE_FAILED && cacheInUse) {
// failed to authenticate, but cached content available
} else {
// something else has gone wrong
}
}
VenueService offers methods for searching and loading venues without using a map. For example, the
code below retrieves the closest venue inside a given radius near a given location. The area can also be
defined by GeoBoundingBox rather than a radius.
private void loadClosestVenue() {
VenueService venueService = VenueService.getInstance(getActivity().getApplicationContext());
GeoCoordinate myLocation = new GeoCoordinante(60.43704, 22.21710);
float radiusInMeters = 5000.0f;
VenueInfo closestVenue = venueService.getVenuesAt(myLocation, radiusInMeters);
venueService.getVenueAsync(closestVenue);
}
@Override
public void onVenueLoadCompleted(Venue venue, VenueInfo venueInfo, VenueLoadStatus loadStatus) {
// closest venue available through the venue object
}
Note: The VenueService is also invoked when VenueMapFragment is used. As such, some venue
features can be used in a common manner between these classes.
Venue Objects
The following is a list of venue objects (as Java classes) in the com.here.android.mpa.venues3d
package. These objects are presented here from the lowest to the highest level of conceptual detail, and
each level is related in a has-a relationship. For example, each Venue object may have multiple Level
member objects, which contain multiple OuterArea objects.
HERE Android SDK Developer's Guide
User Guide
169
Java class Description
com.here.android.mpa.venues3d.Venue Represents a building which may contain one or more structures and
levels.
com.here.android.mpa.venues3d.Level Represents a floor or horizontal layer within a Venue.
com.here.android.mpa.venues3d.OuterArea Represents a part of one Level, contained within one exterior wall of a
structure.
com.here.android.mpa.venues3d.Space Represents a spatial area on a Level, like a store or a facility, such as an
escalator. It may contain subspaces which represent the next level of
detail about a space.
com.here.android.mpa.venues3d.Content Point of interest information about a spatial area within the venue.
A Venue object consists of one or more Level objects. The Level objects represents physical levels of the
venue. Each Level object consist of one or more OuterArea objects. For example, a building with common
ground level areas can contain two separate towers on top of that common area, and so there would be two
OuterArea objects in higher levels in that venue. An OuterArea consist of one or more Space objects.
Note that both Venue and Space classes have a member Content class, which holds point-of-interest
information. This allows for a venue (such as a museum) and a space (such as a shop within a shopping mall)
to hold separate address and phone numbers. Your app can use methods such as getPhoneNumber(),
getWebsite() and getOpeningTimes() to retrieve the relevant directory information from Content
objects.
Working with Venues
Venue, OuterArea and Space objects can be interacted by the user through tapping. For an opened venue,
use the VenueMapFragment.VenueListener.onVenueSelected(Venue) callback. For a selected space,
use the callback VenueMapFragment.VenueListener.onSpaceSelected(Venue, Space). Selected
spaces are highlighted with different color in an opened venue.
Both Venue and Space objects contain Content objects. Content encapsulates information related to
the object, such as name, address, other contact information and category of the venue or space. There is
HERE Android SDK Developer's Guide
User Guide
170
also a concept of selected floor, which is the same as the visible floor. This is demonstrated in the following
screenshot. Note that the floor selection widget in this screenshot is not a part of the HERE SDK.
Figure 65: Selected Space
The following example shows how to add a MapMarker to a space upon a onSpaceSelected event, and
how to remove it when the space is deselected.
@Override
public void onSpaceSelected(Venue venue, Space space) {
removeMarker();
Bitmap bitmap =BitmapFactory.decodeResource(getResources(), R.drawable.pin_start);
Image image = new Image();
image.setBitmap(bitmap);
m_marker = new MapMarker(space.getCenter(), image);
m_marker.setAnchorPoint(new PointF(image.getWidth() / 2f, 0.9f * image.getHeight()));
m_marker.setOverlayType(MapOverlayType.FOREGROUND_OVERLAY);
m_marker.setZIndex(100);
getMap().addMapObject(m_marker);
}
@Override
public void onSpaceDeselected(Venue venue, Space space) {
removeMarker();
}
private void removeMarker() {
if (m_marker != null) {
getMap().removeMapObject(m_marker);
m_marker = null;
}
}
Open Mode
When open mode is enabled, venues that are in the viewport are opened automatically, rather than requiring
the user to click on the venue to open it. The venue closest to the center of the screen is always selected.
Open mode can be enabled on VenueMapLayer, VenueMapView, VenueMapFragment, or
VenueMapAdapter.
venueMapLayer.setOpenMode(true);
HERE Android SDK Developer's Guide
User Guide
171
boolean isOpenMode = venueMapLayer.getOpenMode();
Dynamic Styles
StyleSettings encapsulates the parameters that have an impact on the visual appearances of opened
venues. You can set space names, icons, and colors by using this object. The fill and outline colors can be
also set separately to selected and unselected spaces.
The following example shows how to set the name, label, fill color, and outline color to the given Space
object. The code snippet does not contain completed code but assumes that variables have been initialized.
import com.here.android.mpa.common.Image;
//...
private void updateStyles(Venue venue, Space space) {
Integer selectedColor = 0xFFFF0000; // red, format 0xAARRGGBB
Integer unselectedColor = 0xFFFFFF00; // yellow
Integer outlineColor = 0xFF0000FF; // blue
VenueController controller = m_venueMapFragment.getVenueController(venue);
StyleSettings settings = new StyleSettings();
settings.setLabelName("My Space");
Image img = new Image();
img.setImageResource(com.example.android.UnitTest.R.drawable.png);
settings.setLabelImage(img);
settings.setSelectedFillColor(selectedColor);
settings.setFillColor(unselectedColor);
settings.setOutlineColor(outlineColor);
controller.setStyleSettings(settings, space);
}
Nearby Spaces
You can find all spaces in a radius around a given position by using a Level or an OuterArea object. The
position needs to be given as a geocoordinate, and the radius in meters. The returned list of spaces contains
all spaces that fall within or intersect the radius.
GeoCoordinate myLocation = new GeoCoordinante(60.43704, 22.21710);
List nearbySpaces = level.getNearbySpaces(myLocation, 10.0);
Area at Position
You can retrieve areas in a level by specifying a position. The area returned will either be a Space or an
OuterArea. Similarly, you can also get spaces in a OuterArea.
In case of nested spaces, the innermost nested space encompassing the position is be returned.
GeoCoordinate myLocation = new GeoCoordinante(60.43704, 22.21710);
Area area = level.getAreaAtPosition(myLocation);
Space space = outerArea.getSpaceAtPosition(myLocation);
HERE Android SDK Developer's Guide
User Guide
172
Frequently Asked Questions
You can find additional information about 3D Venues in the 3D Venues FAQ on page 213.
Venue Zoom
Certain 3D venues may have fine details that are not visible even at the maximum map zoom level. The HERE
SDK offers a way to activate a venue-focused extended zoom mode to show a venue in a closer view. These
fine details are not available for all venues.
Figure 66: A venue at the max zoom level Figure 67: A venue with Venue Zoom enabled
To enable this extended Venue Zoom feature, call VenueService.enableVenueZoom(true) at any time.
// Get an instance of VenueService:
VenueService service = m_mapFragment.getVenueService();
// To enable Venue Zoom:
service.enableVenueZoom(true);
//...
// To disable Venue Zoom:
service.enableVenueZoom(false);
After enabling Venue Zoom, you can use one of the following ways to activate the feature. If the application
input is based on gestures, the most convenient way is to register an instance of VenueGestureListener,
which implements OnGestureListener to receive gesture events. When the map is zoomed using gestures
HERE Android SDK Developer's Guide
User Guide
173
to the maximum level and Venue Zoom is enabled, 3D venues are automatically shown in an enlarged
mode. Note that VenueGestureListener only handles pinch zoom events and activates Venue Zoom in a
supported area. In all other situations it returns false for the gesture events, and thus has effectively no
impact on gesture handling.
The example code below shows how the gesture handler can be used with Venue Zoom:
private VenueGestureListener m_gestureListener = null;
// to be done in onCreate/onResume:
if ( myExtendedZoomLevel == false ) {
// Max map zoom level is depending on display metrics
DisplayMetrics metrics = getResources().getDisplayMetrics();
m_gestureListener = new VenueGestureListener(m_mapFragment, m_zoomLevelText,
metrics.densityDpi);
m_mapFragment.getMapGesture().addOnGestureListener(m_gestureListener);
service.enableVenueZoom(true);
} else if (m_gestureListener != null) {
m_mapFragment.getMapGesture().removeOnGestureListener(m_gestureListener);
m_gestureListener = null;
service.enableVenueZoom(false);
}
Note: You can also use VenueMapFragment.VenueZoomListener to determine whether the Venue
Zoom feature was successfully activated.
Another way to activate Venue Zoom is to use the useVenueZoom(true) method of VenueController to
immediately and activate Venue Zoom in a supported area.
// Get VenueController:
venueController = m_mapFragment.getVenueController(venue);
// To activate Venue Zoom (only works in a supported Venue)
venueController.useVenueZoom(true);
// To return to a normal zoom level
venueController.useVenueZoom(false);
While venue zoom is activated, only 3D Venues are shown, and the base map becomes hidden. If venue zoom
is activated while a venue route is being displayed, only the indoor portions of the routes are shown. You can
use VenueZoomListener to determine whether the feature was successfully activated.
Once activated, the visible map becomes two zoom levels larger than they would appear without Venue
Zoom. For example, if Venue Zoom is activated at map zoom level 18, the venues are shown as if the map is
at zoom level 20. Note that this behavior only occurs when the map is at zoom level 18 or higher.
Scaling Custom Map Objects
For custom polygon-based map objects, the HERE SDK offers scaling methods to scale them
to be used with Venue Zoom. Each point of the polygon need to be scaled to be used in Venue
Zoom using VenueController.getScaledGeoCoordinate(GeoCoordinate). If the
reverse operation is desired, where the starting point is a scaled polygon or geolocation, the
getNormalGeoCoordinate(GeoCoordinate) method returns geocoordinates for a non-scaled
geolocation.
HERE Android SDK Developer's Guide
User Guide
174
Note: While both MapGeoModel and MapLocalModel can be scaled by these scaling methods,
it is recommended to use MapGeoModel, since only the anchor point location can be scaled in a
MapLocalModel.
In most cases it makes most sense to create two map objects, one for used in normal zoom
mode and one used in Venue Zoom mode. Use Map.addMapObject(MapObject) and
Map.removeMapObject(MapObject) to swap between objects when changing between normal and Venue
Zoom mode.
Enlarged 3D Models and Venue Zoom
Venue Zoom displays enlarged venue models that are automatically generated. Model generation happens in
the following situations:
Venue Zoom is enabled and a venue is downloaded from the backend.
Venue Zoom is enabled and a venue is opened, and there is no enlarged model generated yet.
Note that if a venue is opened in 3D mode and then Venue Zoom is enabled, Venue Zoom would not
successfully activate if the enlarged venue model has not been generated. In this case, the Venue Zoom can
be used after the venue is closed and then opened again. If an enlarged model has already been generated
earlier, then Venue Zoom can be used immediately after it has been enabled.
Private Venues
This feature allows you to use a different source of venue data in addition to or instead of the default HERE
backend. The private content backend must be configured by HERE, which is an operation transparent to a
developer using the HERE Android SDK. Access to private venue data is at the discretion of its legal owner,
and by definition, it is not public.
Note: For more information about configuring a private venue data backend, contact your HERE
representative.
If a private backend has been configured, call the setPrivateContent(boolean) method on the
VenueService class at MapFragment initialization to indicate that you want your application to use it.
The code below demonstrates a call to this method. Note that the code does not show the entire
MapFragment initialization sequence.
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
// Initialize the Map Fragment to have a map created and attached to
// the fragment
m_mapFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(Error error) {
if (error == Error.NONE) {
m_map = (Map) m_mapFragment.getMap();
// Set access to private venue data:
m_mapFragment.getVenueService().setPrivateContent(true);
// Remember to start or restart Venue Service after setting private content
} else {
System.out.println("ERROR: Cannot initialize Map Fragment" + error.toString());
}
}
});
HERE Android SDK Developer's Guide
User Guide
175
}
Dynamic Content
By default, the HERE SDK uses public HERE 3D venue content. It is possible to use customer-specific content
instead by calling the VenueService.setPrivateContent(boolean) method, as shown in the examples
below. It is also possible use both private and public content together, and define which one has priority. If
this kind of combined content is needed, use VenueService.setIsCombinedContent(boolean).
// Obtain VenueService
VenueService service = m_mapView.getVenueService();
// Use only HERE SDK content (this is the default behavior)
Service.setPrivateContent(false);
Service.setIsCombinedContent(false);
// Use only private content
Service.setPrivateContent(true);
Service.setIsCombinedContent(false);
// Prefer HERE SDK content and use private as an alternative
Service.setPrivateContent(false);
Service.setIsCombinedContent(true);
// Prefer private content and use HERE SDK as an alternative
Service.setPrivateContent(true);
Service.setIsCombinedContent(true);
Multiple VenueService objects can run at the same time. For example, if some part of an application
requires access to only private content, and another part requires HERE SDK content, two VenueService
objects can be instantiated and configured differently. Activities in one service do not have an impact
on another service. For example, notifications related to loading (onVenueLoadCompleted(Venue,
VenueInfo, VenueLoadStatus)) are sent only to the client that initiated the load. To obtain an
additional VenueService object, use the static createAdditionalService(Context) method.
VenueService mMainInstance;
VenueService mAdditionalInstance;
mMainInstance =
VenueService.getInstance(getActivity().getApplicationContext());
mAdditionalInstance =
VenueService.createAdditionalService(getActivity().getApplicationContext());
For more information, see the API Reference.
Note: VenueService is also invoked when VenueMapFragment or VenueMapView is used. As such,
some venue features can be used in a common manner between these classes.
Venue Routing
The HERE Android SDK extends its 3D venue maps functionality to provide indoor routing. The SDK supports
the following use cases:
Routing from store A to store B within a venue
Routing from an outside point to a point in a venue
Routing from a point in a venue to an outside point
Routing from a venue to another venue, with endpoints being a store or a point in a venue
HERE Android SDK Developer's Guide
User Guide
176
Both on-line and off-line routing are supported. The classes that support this feature can be found in the
com.here.android.mpa.venues3d and com.here.android.mpa.routing packages.
Note that if HERE has no routing information for an area between the outdoor part of the route and the
venue entry point, the route visualization represents the unknown section of the route with a dotted line.
Routing Between Locations in a Venue
This section demonstrates how to calculate and display an indoor route by using a code example. The
example is based on a scenario where a device user wants to find out how to reach another location in the
same venue. In real life, the user would select the starting point and destination for the route by tapping on
the map of the venue. However, for the sake of simplicity, the code below calculates a route by assuming the
spaces are already selected.
Note: See the Getting Indoor Location Based on a Tap Point section for a code example of how to
handle tap events to get a location for indoor venue routes.
The code below shows the implementation and is assumed to be part of an application. Previous
initialization steps are assumed.
// Add the application as a listener for route-calculation-completed:
m_venueMapFragment.getRoutingController().addListener(m_activity);
// Route start and end set-up – they are spaces in a user-selected 3D venue.
// Set route start. You can choose an item from all spaces associated with the venue, or
// allow the application user to select an item and then use the callback onSpaceSelected().
SpaceLocation startLocation = new SpaceLocation(startSpace,
m_venueMapFragment.getVenueController(venue));
// Set route end.
SpaceLocation endLocation = new SpaceLocation(endSpace,
m_venueMapFragment.getVenueController(venue));
// Get route option objects
VenueRouteOptions venueRouteOptions = new VenueRouteOptions();
RouteOptions options = venueRouteOptions.getRouteOptions();
// Set route type, transport mode, number of routes to calculate:
options.setRouteType(Type.values()[m_routingOptionType.getSelectedItemPosition()]);
options.setTransportMode(
TransportMode.values()[m_routingOptionMode.getSelectedItemPosition()]);
options.setRouteCount(1);
// Set route options:
venueRouteOptions.setRouteOptions(options);
// Calculate route - this is an asynchronous call, once the calculation is done
// onCombinedRouteCompleted() is called – see below.
routingController.calculateCombinedRoute(startLocation, endLocation,
venueRouteOptions);
//...
// Callback invoked when the route calculation is done to display the route passed
// to it as an argument.
public void onCombinedRouteCompleted(CombinedRoute route) {
// Use RoutingController to show route:
m_venueMapFragment.getRoutingController().showRoute(route);
HERE Android SDK Developer's Guide
User Guide
177
Routing Between Venues
You can perform routing between venues by using separate VenueController objects. For example, in the
following, two different venues are used to retrieve VenueController objects:
// In this example m_startVenue and m_endVenue are assumed to be initialized
// with proper references.
SpaceLocation startLocation = new SpaceLocation(startSpace,
m_venueMapFragment.getVenueController(m_startVenue));
SpaceLocation endLocation = new SpaceLocation(endSpace,
m_venueMapFragment.getVenueController(m_endVenue));
}
// Other parts like in the previous example
Routing Using an Arbitrary Indoor Location
It is also possible to use an arbitrary indoor location that is not at a store or designated space as a route
endpoint. An example of this kind of location is a point in a corridor. The next code snippet demonstrates the
initialization of such an endpoint.
// Create a free point location to be used as a start location
// Here we assume that both current level and geo position is available in
// m_currentPosition. This can be obtained from, for example, some indoor positioning service.
LevelLocation startLocation = new LevelLocation(m_currentPosition.getLevel(),
m_currentPosition.getGeoCoordinate(),
m_venueMapFragment.getVenueController(venue));
The LevelLocation class extends BaseLocation and can be used as start or end location in
calculateCombinedRoute() method of RoutingController, similar to SpaceLocation and
OutdoorLocation.
The next example demonstrates route calculation from an indoor location, using type LevelLocation, to
some location outside the venue, represented by an OutdoorLocation class.
// Create a free point location to be used as a start location
// Here we assume that both current level and geo position is available in
// m_currentPosition. This could be obtained from some indoor positioning
// service (not covered in this section).
LevelLocation startLocation = new LevelLocation(m_currentPosition.getLevel(),
m_currentPosition.getGeoCoordinate(),
m_venueMapFragment.getVenueController(venue));
// Create an outdoor location.
GeoCoordinate endPosition = new GeoCoordinate(52.517072, 13.411232);
OutdoorLocation endLocation = new OutdoorLocation(endPosition);
// Get route options objects
VenueRouteOptions venueRouteOptions = new VenueRouteOptions();
RouteOptions options = venueRouteOptions.getRouteOptions();
// Set route type, transport mode, number of routes to calculate:
options.setRouteType(Type.FASTEST);
options.setTransportMode(TransportMode.CAR);
options.setRouteCount(1);
// Set route options:
venueRouteOptions.setRouteOptions(options);
HERE Android SDK Developer's Guide
User Guide
178
// Calculate route - this is an asynchronous call, once the calculation is done
// onCombinedRouteCompleted() is called – see below.
routingController.calculateCombinedRoute(startLocation, endLocation,
venueRouteOptions);
//...
// Callback invoked when the route calculation is done to display the route passed
// to it as an argument.
public void onCombinedRouteCompleted(CombinedRoute route) {
// Use RoutingController to show route:
m_venueMapFragment.getRoutingController().showRoute(route);
}
Venue Route Options
VenueRouteOptions encapsulate options used in indoor routing. It is possible to set many parameters
related to visualization of the route line (for example color, line width, visibility of start and end flags) as
well as parameters related to how the route is calculated (for example if elevators are allowed, if stairs are
allowed, if corridors are preferred). The next example shows route calculation from one level to another level
while avoiding stairs. Initialization steps for used variables are assumed.
// set up start and end locations, assuming they're on different levels
// ...
// Set venue route options, including flag to avoid stairs:
VenueRouteOptions venueRouteOptions = new VenueRouteOptions();
venueRouteOptions.setStairsAllowed(false);
venueRouteOptions.setCorridorsPreferred(true);
// Set other route options
RouteOptions options = venueRouteOptions.getRouteOptions();
options.setRouteType(Type.SHORTEST);
options.setTransportMode(TransportMode.PEDESTRIAN);
options.setRouteCount(1);
venueRouteOptions.setRouteOptions(options);
// Calculate route - this is an asynchronous call, once the calculation is done
// onCombinedRouteCompleted() is called
routingController.calculateCombinedRoute(startLocation, endLocation,
venueRouteOptions);
//...
Getting Indoor Location Based on a Tap Point
The next code example shows how to add a route point to an indoor route using the onTapEvent(PointF
point) method of com.here.android.mpa.mapping.MapGesture.OnGestureListener.
public boolean onTapEvent(PointF point) {
// convert tap point to GeoGoordinate
Map map = m_venueLayer.getMap();
GeoCoordinate tapPoint = map.pixelToGeo(point);
if (tapPoint == null || !tapPoint.isValid()) {
return false;
}
// If any venue is selected, get related VenueController
Venue venue = m_venueLayer.getSelectedVenue();
HERE Android SDK Developer's Guide
User Guide
179
VenueController venueController = null;
if (venue != null) {
venueController = m_venueLayer.getVenueController(venue);
}
// If no venue was selected, consider tapped location as OutdoorLocation
// and add it as route point.
if (venueController == null) {
BaseLocation location = new OutdoorLocation(tapPoint);
addRoutePoint(location);
return false;
}
// Otherwise consider tapped location as SpaceLocation and add it as route point.
BaseLocation location = venueController.getLocation(point, m_preferSpaceSelection);
 addRoutePoint(location);
 return false;
 }
 private void addRoutePoint(BaseLocation location) {
//Logic for saving route points.
 }
}
Calculating Route Length
The following code example shows how the total length of a route can be calculated:
@Override
public void onCombinedRouteCompleted(CombinedRoute combinedRoute) {
double distance = 0.0;
final List<IRouteSection> routeSections = route.getRouteSections();
for (IRouteSection section : routeSections) {
switch (section.getRouteSectionType()) {
case VENUE:
List<VenueManeuver> maneuvers = ((VenueRoute)section).getVenueManeuvers();
distance += maneuvers.get(maneuvers.size() - 1).getDistanceFromStart();
break;
case LINK:
GeoCoordinate from = ((LinkingRoute)section).getFrom();
GeoCoordinate to = ((LinkingRoute)section).getTo();
distance += from.distanceTo(from);
break;
case OUTDOOR:
com.here.android.mpa.routing.Route route = ((OutdoorRoute)section).getRoute();
distance += route.getLength();
break;
default:
break;
}
}
}
// do something with distance information
};
Natural Guidance for Venue Maneuvers
Venue maneuvers provide the names of the closest POIs for natural guidance purposes. For each maneuver,
this is the closest POI within a natural guidance radius around the position of the maneuver. If no POI exists
HERE Android SDK Developer's Guide
User Guide
180
within this radius, an empty string is returned. The natural guidance radius is a global parameter common to
all maneuvers that may be set and queried by the user.
Note: For more information about natural guidance, see Turn-by-Turn Navigation for Walking and
Driving on page 145.
VenueManeuver.setNaturalGuidanceRadius(10.0);
floar naturalGuidanceRadius = VenueManeuver.getNaturalGuidanceRadius();
String naturalGuidance = myManeuver.getNaturalGuidancePOI();
Bounding Boxes for Parts of Venue Routes
Venue and outdoor route sections provide axis-aligned bounding boxes for the route. Axis-aligned bounding
boxes are provided for individual route segments for each level. These methods return null if a route has
no segment on the given level.
GeoBoundingBox obb = outdoorRoute.getBoundingBox();
GeoBoundingBox vbb = venueRoute.getBoundingBox();
GeoBoundingBox lbb = venueRoute.getBoundingBox(level);
The bounding box for the venue route (vbb in the example) also provides altitude information that may be
extracted using the getTopLeftFront() and getBottomRightBack() methods of GeoBoundingBox.
LiveSight
LiveSight enables user experiences that use the real world as an interface. With LiveSight, developers can
overlay geospatial content on the real world, which is displayed using the device's camera. Additionally, an
immersive experience is created by using the device's sensors to track movement in space and update the
view accordingly.
The key concepts covered in this section include adding LiveSight to an Android application, transitioning
from Map Mode to LiveSight Mode, and customizing the LiveSight experience. The classes covered include
CompositeFragment and ARController.
Note: LiveSight requires the following sensors enabled:
• GPS
• Compass
• Accelerometer
• Gyroscope
LiveSight does not function properly, or does not function at all, if these sensors are not working or
incorrectly calibrated.
CompositeFragment
The Fragment subclass related to LiveSight functionality is the CompositeFragment. It is called
"composite" because it exposes both Map and LiveSight functionality in one Android UI component,
with an easy way to switch between the two; therefore, in addition to methods related to LiveSight
functionality, the CompositeFragment also includes all of the methods found in the MapFragment.
The CompositeFragment is useful in the situation where an application wants to include both map and
LiveSight functionality.
HERE Android SDK Developer's Guide
User Guide
181
The remainder of this section uses the CompositeFragment in code samples and discussions.
Note: The CompositeFragment.getScreenCapture(OnScreenCaptureListener) method has
the same functionality as MapFragment.getScreenCapture(OnScreenCaptureListener). It
does not support taking screen snapshots of the LiveSight Camera View or AR Objects on a map.
Adding and Initializing the CompositeFragment
The first step to integrate LiveSight functionality into an application is to insert a CompositeFragment into
the view layout. This is accomplished by adding com.here.android.mpa.ar.CompositeFragment to the
Android XML layout file as follows:
<!-- Example fragment. This can be integrated and annotated
like any other android Fragment or View widget -->
<fragment
class="com.here.android.mpa.ar.CompositeFragment"
android:id="@+id/compositefragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent"/>
Note: When using the CompositeFragment, you do not have to also use the MapFragment. The
CompositeFragment is a superset of the MapFragment.
After adding the CompositeFragment to the layout, the fragment must be initialized by calling the
CompositeFragment.init(OnEngineInitListener) method. During this asynchronous initialization,
the MapEngine is initialized to create an instance of Map that is associated with the CompositeFragment.
The ARController is also be created. For more information about ARController, see Customizing
LiveSight on page 188.
The following code example illustrates the basic initialization flow when an Activity is created. The
init(OnEngineInitListener) method uses the OnEngineInitListener parameter to signal the caller
when the asynchronous initialization is completed.
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// Search for the Composite Fragment
final CompositeFragment compositeFragment = (CompositeFragment)
getFragmentManager().findFragmentById(R.id.compositefragment);
// initialize the Composite Fragment and
// retrieve the map that is associated to the fragment
compositeFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(
OnEngineInitListener.Error error) {
if (error == OnEngineInitListener.Error.NONE) {
// now the map is ready to be used
map = compositeFragment.getMap();
// the arController is also ready to be used now
arController = compositeFragment.getARController();
} else {
System.out.println(
"ERROR: Cannot initialize CompositeFragment");
}
}
});
}
HERE Android SDK Developer's Guide
User Guide
182
Note: com.here.android.mpa.ar.CompositeFragment has
Fragment.setRetainInstance(boolean) set to true; therefore, onCreate(Bundle) should not
be called again when Activity is re-created (for example, after an orientation change).
Starting and Stopping LiveSight
It is important to make a distinction between the two operating modes provided by the
CompositeFragment, Map Mode and LiveSight Mode. Map Mode is the mode of operation that is the same
as that provided by the MapFragment. As with MapFragment, Map Mode behavior and functionality are as
described under Maps. LiveSight Mode is the mode of operation that provides the LiveSight experience and
has separate functionality and behavior.
Note: It may be confusing that the map is still displayed even when LiveSight Mode is enabled. While
this map view is a part of the LiveSight experience, it has different functionality and behavior than
Map Mode.
Figure 68: Map Mode Figure 69: LiveSight Mode
To switch between Map Mode and LiveSight Mode, two methods from the ARController, start() and
stop(), are used. The start() method triggers the transition from Map Mode to LiveSight Mode, which
includes a short cinematic transition animation by default. Calling start() while already in LiveSight Mode
results in the Error.INVALID_OPERATION error code being returned. Use the stop() method to transition
from LiveSight Mode to Map Mode. By default the CompositeFragment starts in Map Mode.
// Triggers the transition from Map Mode to LiveSight Mode
Error error = arController.start();
...
// Exits LiveSight Mode and returns to Map Mode
Error error = arController.stop(true);
HERE Android SDK Developer's Guide
User Guide
183
Reading the Current Pose
The ARController provides a convenient way to retrieve the current positional and directional
(pose) values of your LiveSight session. By calling ARController.getPose(), you can retrieve the
ARPoseReading instance, which contains the following values:
• Heading
• Pitch
• Roll
• Latitude
• Longitude
• Altitude
• Timestamp
Although these ARPoseReading values are derived from device sensors, they are interpolated and
smoothed by the LiveSight engine.
Adding and Interacting with LiveSight Content
This section covers how to add content to be displayed in LiveSight and how to handle user interactions with
that content. The classes covered in this section are ARObject and ARIconObject. Additionally, several
ARController methods are used:
addARObject(ARObject)
removeARObject(ARObject)
addOnTapListener(OnTapListener)
press(PointF)
focus(ARObject)
defocus()
getObjects(PointF)
getObjects(ViewRect)
The LiveSight Object Model
A LiveSight object has several visual representations. The representation to be displayed is determined
based on the current state of the LiveSight view, which is defined as a function of the device's pitch by
default, as well as the state of the object itself. The object state that influences display is the Focus state.
The Focus state is discussed in detail later.
The LiveSight view states are the "Down" state and the "Up" state. By default, when the view is pitched
downwards (for example, if the device screen is face-up), then LiveSight is in the Down state and set to the
default Map view. As the device is pitched further upwards (angled negatively around the x-axis), LiveSight
transitions to the Up state, which has the Camera view as its default view.
Down Object Representation
HERE Android SDK Developer's Guide
User Guide
184
While in the Down state, a LiveSight object is represented by an icon associated with the Down state.
When transitioning to the Up state, a fly-in transition animation occurs, and the larger front icon is
displayed.
Figure 70: An Icon in the Down State
Up Object Representation
While the Down state representation consists of just a single icon, the Up state representation is more
complex. While in the Up state, there are two planes where an object can be displayed, and the object
representation is different in each. The planes are the "Front" plane and the "Back" plane. By default,
objects that are geographically closer to the LiveSight center are displayed in the Front plane, and
HERE Android SDK Developer's Guide
User Guide
185
objects that are further away are displayed in the Back plane. Objects can be moved from one plane to
the other using the vertical pan gesture.
Figure 71: Icons in the Up State Figure 72: Visualization of the Front and Back Planes
While in the Front plane, a LiveSight object is represented by both its icon and an information view
(Info View) that extends out from the side of the icon. This information view is intended to act as a
mechanism for displaying more detailed information about the object. In the Back plane, an object is
initially represented by a single icon. It is possible to have an object in the Back plane display its Info
View by putting it in focus. The icon for the Front plane and the Back plane can be different, and by
default, the transition from one plane to the other is animated.
The ARObject Abstract Class
ARObject is the base implementation for all other objects that can be added to LiveSight in order to be
displayed. It contains methods common to all LiveSight objects, enabling the following operations:
Set and retrieve the object's current position
Set and retrieve the object's down, front, or back icon
Set and retrieve the object's down, front, and back icon sizes
Set and retrieve the size, image, and extension state of the information view
Set and clear an image texture on the object's down, front, back icons and information view
HERE Android SDK Developer's Guide
User Guide
186
The ARIconObject Class
Currently, the single concrete ARObject is the ARIconObject. ARIconObject represents the object model
described in The LiveSight Object Model on page 183. Because it is the only concrete ARObject, all of its
functions reside in the ARObject.
Adding and Interacting with ARObjects
Adding an ARObject to LiveSight is accomplished with the ARController.addARObject(ARObject)
method:
arIconObject = new ARIconObject(
new GeoCoordinate(49.276744, -123.112049, 2.0), view, image);
arController.addARObject(arIconObject);
Similarly, ARObjects can be removed using the ARController.removeObject(ARObject) method:
boolean success = arController.removeARObject(arIconObject);
To facilitate interactivity with ARObjects, an ARController.OnTapListener can be registered with
the ARController.addOnTapListener(OnTapListener) method. When a tap event occurs, the
ARObject at the tap point can be found through the press(PointF) method. Calling press(PointF)
also causes an animation on the ARObject. Additionally, the ARObject can be put into focus with the
ARController.focus(ARObject) method. While in focus, an ARObject that is in the back plane displays
its info pane. Only one ARObject may have focus at a time.
arController.addOnTapListener(new ARController.OnTapListener() {
@Override
public boolean onTap(PointF point) {
// retrieve ARObject at point (if one exists)
// and trigger press animation
ARObject arObject = arController.press(point);
if (arObject != null) {
// focus object
arController.focus(arObject);
}
return false;
}
});
To defocus an ARObject, call focus() on another ARObject. You can also call the
ARController.defocus() method to defocus from the currently focused ARObject.
In addition to event driven ARObject retrieval, the ARController.getObjects(PointF) and
ARController.getObjects(ViewRect) methods can be used to programmatically get ARObject at a
screen location:
PointF point = new PointF(50, 50);
List<ARObject> objectsAtPoint = arController.getObjects(point);
ViewRect viewRect = new ViewRect(50, 50, 25, 25);
HERE Android SDK Developer's Guide
User Guide
187
List<ARObject> objectsInViewRect = arController.getObjects(viewRect);
Selecting ARObjects
After retrieving an ARObject, you can choose to select and unselect it by calling the select() and
unselect() methods. Selecting an object causes objects to change their properties (such as size and
opacity) according to ARObject.SelectedItemParams. Only one ARObject may be selected at a time.
Note: A single ARObject cannot be focused and selected simultaneously. However, it is possible to
have one ARObject focused and another ARObject selected at the same time.
ARObject Occlusion
Figure 73: Occluded Objects in the Map View
Occlusion refers to whether a certain ARObject is behind a building, with respect to the user's point of view.
If the point represented by the ARObject is not visible in real life because it is blocked by a building, then
that point is considered occluded. Because occlusion is dependent of the user's point of view, this feature is
dependant on having accurate building data for the user's location.
With the ARController, you can check for occluded LiveSight objects and change their opacity by using the
following methods:
ARController.isOccluded(ARObject arObject)
ARController.setOcclusionOpacity(float opacity)
ARController.setOcclusionEnabled(boolean enable)
3D Objects
LiveSight also supports two types of 3D objects: ARBillboardObject and ARMeshObject
. Both of these classes are the derivatives of ARModelObject, which provides the
HERE Android SDK Developer's Guide
User Guide
188
ability to control basic properties such as object opacity, scale, and rotation. Because
ARModelObject classes do not derive from the ARObject class, you cannot use them with
some ARController methods such as focus(ARObject) or press(ARObject). To add or
remove an ARModelObject, use the ARController.addARObject(ARModelObject) and
ARController.removeARObject(ARModelObject) methods.
An ARBillboardObject can be oriented in the Up state in two ways. In the FIXED orientation mode, it may
be "attached" to a surface by specifying the up and normal vectors using the setUpDirection(Vector3f)
and setSurfaceNormal(Vector3f) methods. In the BILLBOARD orientation mode, a billboard is set to
be always upright and facing the camera. An ARBillboardObject can be positioned in one of the following
ways:
Anchored to a specific geo-location using constructors ARBillboardObject(GeoCoordinate)
and ARBillboardObject(GeoCoordinate, Image), as well as the
setGeoPosition(GeoCoordinate) method.
Anchored relative to the camera using constructors ARBillboardObject(Vector3f) and
ARBillboardObject(Vector3f, Image), as well as the setLocalPosition(Vector3f) method.
The Vector3f represents the location of the center of the billboard in meters away from the camera.
An ARMeshObject represents a 3D object mesh. As with an ARBillboardObject, a mesh object may be
anchored to a geo location or relative to the screen. You can control the orientation of the ARMeshObject
by providing a GeoCoordinate that the object can point towards.
Customizing LiveSight
LiveSight is highly configurable, allowing developers and designers to create many different and immersive
experiences. The ARController class serves as a facade for overall LiveSight functionality, containing all of
the methods and callbacks available for controlling and customizing LiveSight behavior.
The methods used to customize LiveSight reside in the ARController and also the following inner classes:
ARController.UpViewParams
ARController.UpViewTransitionParams
ARController.DownViewParams
ARController.IntroAnimationParams
ARController.IconParams
ARController.InfoParams
ARController.CameraParams
ARController.FilterParams
ARController.SelectedItemParams
UpViewParams, UpViewTransitionParams, and DownViewParams
UpViewParams and DownViewParams encapsulate the customizable parameters that are applicable for the
Up and Down views. UpViewTransitionParams encapsulates customizable parameters that are applicable
when you move up from the down view and enter the camera view.
HERE Android SDK Developer's Guide
User Guide
189
IntroAnimationParams
IntroAnimationParams encapsulates parameters about various intro animations. Intro animation refers
to the animation that is used while the app is entering LiveSight. During LiveSight entry, a few transition
operations happen simultaneously, and each of these can be assigned a different animation style. These
customizable transition operations are: map zoom (the map zooms in towards the ground level), heading
change (the current heading changes to the current device heading), position change (the current position
changes to the current device position or a LiveSight-specific position), and pitch change (the pitch changes
according to the 3D orientation of the device).
IconParams and InfoParams
IconParams encapsulates customizable parameters for the front, back, and down icons. In addition to
setting icon sizes, you can also set how icons animate when they first appear ("pop-up"), receive a tap, or
appear while transitioning from the Down to Up view ("fly"). For more information on down, front, and back
icons, consult the section Adding and Interacting with LiveSight Content on page 183.
InfoParams allow you to customize how Info Views animate when they first appear ("pop-up"), receive a
tap, or appear while transitioning from the Down to Up view ("fly").
CameraParams
CameraParams encapsulates parameters that are related to the camera-enabled Up view. The
CameraParams.setSize(Size) method allows you to set the camera resolution to be used for the
LiveSight camera view. Note that using a high camera resolution may cause performance degradation. The
default camera resolution is 680x480.
HeadingFilterParams, PitchFilterParams, and ZoomFilterParams
HeadingFilterParams, PitchFilterParams, and ZoomFilterParams are all instances of the
ARController.FilterParams class. These objects encapsulate the customizable parameters for the
heading, pitch, and zoom data sampling. Methods in Filter allow you to customize how data samples are
read from the device sensors.
SelectedItemParams
SelectedItemParams encapsulates parameters that control behavior when an ARObject is in the selected
or unselected state. For example, you can increase the size of a selected icon. By default, objects are neither
in the selected or unselected state. When an ARObject is selected, all other ARObjects are changed to the
unselected state. When selection is canceled, all objects are returned to the neutral state.
Other ARController Settings
In addition to the previous parameter classes, you can use methods in ARController to customize the
following areas in LiveSight:
Alternative Center Location — LiveSight is not only limited to the current device location. It is possible to
use the ARController to set an alternative location ("space shift") for your LiveSight experience.
HERE Android SDK Developer's Guide
User Guide
190
Icon Display Behavior — Adjust settings related to the icon display, such as as only showing Front items,
or using Down icons in the map.
Device Orientation Behavior — Set whether the Down view is updated with the device sensor's
orientation data.
Layout Updates — By default, LiveSight icons are set to update dynamically according to the current
device position. However, you can set ARController so that the Layout (containing the front and back
icons) does not update until the device position has changed significantly past a threshold.
External Sensor Data
LiveSight also provides the ability to switch from using integrated device sensor data to one or more data
feeds provided by external sources. You may need to do this when more accuracy is required for object
projection results in the Up state, or when you require a distributed LiveSight solution where data from
multiple sensors are provided over TCP/IP.
ARController.ExternalSensors is the entry point for using external sensor data. You can enable
or disable input from one or more external sensors by using this class with the values defined in the
ARController.SensorType enum, with the exception of CAMERA. For example:
arController.ExternalSensors.utilize(SensorType.GPS, true);
Note: This call should only be made when ARController is stopped or paused.
After the external sensor is enabled, the integrated device sensor data is no longer used, and you must start
providing sensor data into the LiveSight engine using the pushData(SensorType, double, double,
double, long) method. Note that the parameters are treated differently if a different SensorType is
used. For more information on providing data using this method, see the API reference.
Animation Interpolators
The visual appearance of many of the LiveSight animations can be changed by using different animation
interpolators. The available interpolator types include:
LINEAR - Linear interpolation
ACCELERATE - Starts slow, and then accelerates
DECELERATE - Starts quick, and then decelerates
ACCELERATE_DECELERATE - Starts and ends slowly, but accelerates through the middle
OVERSHOOT - Flings forward and overshoots the last value, then comes back
ANTICIPATE - Starts backward, then flings forward
ANTICIPATE_OVERSHOOT - Starts forward, then flings forward and overshoots the target value, and
finially goes back to the final value
BOUNCE - Rate of change 'bounces' at the end
Listeners provided by ARController
The ARController class provides a variety of listener classes that can be used to trigger event-driven code
in your application. The listeners provided are:
HERE Android SDK Developer's Guide
User Guide
191
Listener Name Purpose
OnCameraEnteredListener Listener for the Camera view-entered event. This event is triggered just before the
camera frame is displayed.
OnCameraExitedListener Listener for the Camera view-exited event. This event is triggered just after the camera
frame is exited.
OnCompassCalibrationChangedListener
Listener for compass calibration changed event. This event is triggered by the system
when the compass calibration status changes.
OnMapEnteredListener Listener for the "Map view entered" event. This event is triggered just before the Map
view is displayed.
OnMapExitedListener Listener for the "Map view exited" event. This event is triggered just after the Map view is
exited.
OnObjectTappedListener Listener for object selection events.
OnPanListener Listener for pan events.
OnPoseListener Listener for pose update events.
OnPreDrawListener Listener for pre-draw event. This event is triggered just before a draw is performed. This
listener is useful in case a client wants to update things while in LiveSight Mode and
serialize the update action with the LiveSight draw cycle. This callback is performed in
both Map view and Camera view.
OnPreDrawMapListener Listener for the map pre-draw event. This event is triggered just before the map is being
drawn. This listener is useful in the case where the client wants to update things on the
map and serialize the update action with the draw cycle.
OnPrePresentListener Listener for the event that occurs before the frame is composited. This event occurs after
the draw event.
OnPostPresentListener Listener for the event that occurs after the frame is composited.
OnLivesightStatusListener Listener for hardware and component errors related to LiveSight.
OnPitchFunction Listener for pitch changes. Allows you to override the default LiveSight pitch/zoom curve.
OnRadarUpdateListener Listener for radar update events.
OnSensorCalibrationChangedListener Listener for sensor calibration events.
OnTapListener Listener for tap events.
OnTouchDownListener Listener for touch "down" events.
OnTouchUpListener Listener for touch "up" events.
Note: OnPreDrawMapListener is a replacement for the OnMapRenderListener.onPreDraw()
callback, which is not triggered while in LiveSight Mode.
All of these Listeners are added and removed by way of their respective addOnXYZListener and
removeOnXYZListener methods provided by the ARController.
Draw and Present Phases
To understand how to use OnPreDrawMapListener, OnPrePresentListener, and
OnPostPresentListener, it is important to understand the order and differences between Present and
Draw. The order of LiveSight phases and events are as follows:
1. Pre-Draw event
HERE Android SDK Developer's Guide
User Guide
192
2. Draw phase
3. Pre-Present event
4. Present phase
5. Post-Present event
The Draw phase is the action of filling graphics buffers with the various components of the scene, which are
applicable for the current LiveSight View. In the Draw phase, the LiveSight engine is composing different
layers in a frame, such as a map and icons for the Down view, and the camera feed and icons for the Up view.
This phase occurs before the Present phase, and since the Pre-Draw event is triggered before this phase, you
should use the Pre-Draw event if you want, for example, for an icon to change for the next frame.
Note the absence of the Post-Draw event. If you want to do something just before presenting, use the Pre-
Present event, which is the same as Post-Draw, since the Pre-Present event occurs after "Draw" but before
the "Present" phase.
The Present phase refers to the composition of the buffers filled in the draw phase into the frame. In other
words, this phase takes buffers and blends their contents into one buffer to be displayed. For example, this
is how icons are placed on top of the camera frame. After the "Present" phase, the Post-Present event is
triggered.
Platform Data Extension
Platform Data Extension (PDE) provides the ability to easily access the Platform Data Extension API from
the HERE Android SDK. You can use this extension to access a wide range of data that can be later used for
different use cases. Some examples include displaying road elevation, slopes, and traffic signs. For more
information about use cases and the types of data that can be accessed through PDE, check the Platform
Data Extension API Developer's Guide .
PDE Thematic Layers
PDE divides map content across many thematic layers. Each thematic data layer serves a specific use case
and only contains the data required for it, such as road elevation. To use PDE, you need to first decide on the
required data for your app and select the PDE thematic layers accordingly. The available thematic layers can
be found via the PDE Layers API. You can then check the targeted thematic layers via the individual Layer
API. Before starting to use PDE in your app, you need to select the correct thematic layers, and then decide
on what data to use and how to use it. This is a crucial step.
Note: It is common for routes to start on smaller roads, climb to bigger roads, stay on motorways
for the main part, and finally steps down to smaller roads again when approaching the destination.
Since retrieving all information about smaller roads along the entire route requires a large amount
of data, road link-related thematic layers are actually split into five layers each, corresponding to
the functional road classes in the HERE map. Functional Class 1 roads are generally motorways,
while Functional Class 5 roads are small roads that are only used near a destination. To use these
layers, you need to specify the tile layer by appending the functional class suffix "_FCx", where x is
a number from 1 to 5. For example, ROAD_GEOM_FC1. If a layer isn't related to road links, such as the
PSTLCB_GEN layer, you don't need to append the "_FCx" suffix and specify the tile layer.
HERE Android SDK Developer's Guide
User Guide
193
PDE Classes
Class Description
PlatformDataRequest Used to create and execute a PDE data request with the specified layers and
GeoBoundingBox object.
PlatformDataResult The result of running a PDE data request. Contains data for requested layers,
which are accessible by the layer name. This implements the java.util.Map
interface for ease of use and interoperability, although objects of this class
are unmodifiable. Provides extract method to convert the result into an
Map<String, List<Map<String, String>>> which is a raw representation
of the underlying data.
PlatformDataItemCollection Represents layer data in the form of an array of PlatformDataItem objects.
This is what you get by asking PlatformDataResult for a specific layer—
for example, by calling platformDataResult.get("ROAD_GEOM_FC1").
PlatformDataItemCollection implements the java.util.List
interface for ease of use and interoperability, although objects of this class are
unmodifiable. It also provides an extract() method to convert the collection
into an List<Map<String, String>> object.
PlatformDataItem Represents actual data records in a layer as a map of attribute names and
values. This is what you get from PlatformDataItemCollection by iterating
over its contents or asking for an item at a specific index. Note that for several
attributes, shortcut methods are provided, such as item.getLinkId(),
which can be used instead of item.get("LINK_ID"). This implements the
java.util.Map interface for ease of use and interoperability, although
objects of this class are unmodifiable. Provides extract() method to convert
it into an Map<String, String> object.
In summary, PlatformDataRequest produces PlatformDataResult, a Map of layer names to
PlatformDataItemCollection objects, which in turn are List of PlatformDataItem objects, with each
containing attribute names and their values in the form of a Map.
Example: Requesting the PDE Data
The example below shows how a feature is implemented using the PDE data. The goal is to colorize each road
segment according to its average height. For this feature, you need the PDE data from the ROAD_GEOM_FC1
and BASIC_HEIGHT_FC1 layers. As of now, the only way to request the PDE data requires the layers
specified with an GeoBoundingBox.
Note: The ROAD_GEOM_FC[number] and BASIC_HEIGHT_FC[number] layers are also referred to as
"tile" layers, since their data is split into multiple tiles. Due to server limitations, up to 15 tiles can be
requested at a time. PDE also supports non-tile layers.
To use the data from both layers, you need to join the two layers by using the LINK_ID property. This is
demonstrated in the next section.
HERE Android SDK Developer's Guide
User Guide
194
The following are sample results from the Layer request.
ROAD_GEOM_FC1 Layer API result:
{
"description": "Ungeneralized road, ferry and rail ferry geometry (polylines).<br/>If a road link
crosses a tile boundary, it will be written into each of the tiles, each including the full link
geometry. This simplifies use cases other than pure display of all geometry within a rectangle.",
"attributes": {
"LINK_ID": "Permanent link ID. Positive 64 bit Integer that globally identifies the road, carto or
buildin footprint link, also across map releases. Link IDs are never reused.",
"LONG_HAUL": "This link or polygon or POI is of major importance. It should be displayed at high
zoom lavels, and it should be included for routing in/through regions where no detailed routing is
supported.",
"NAME": "A name of this road line. Roads can have multiple names, in the same or multiple
languages. This field contains any of those.",
"NAMES": "List of all names for this object, in all languages [...]",
"TUNNEL": "Is this navigable link or railroad a tunnel?",
"BRIDGE": "Is this navigable link or railroad a bridge?",
"LAT": "Latitude coordinates [10^-5 degree WGS84] along the polyline. ",
"LON": "Longitude coordinates [10^-5 degree WGS84] along the polyline. ",
"ZLEVEL": "(-4 ... 11) indicates the height of the point relative to another point on a grade
separated crossing with any other line. Comma separated. If z-level is null then the value '0' is
left out."
},
"referencedStaticContents": [],
"tileRequestsLevel": 9,
"tileX": 499,
"tileY": 403,
"isStaticContent": false
}
BASIC_HEIGHT_FC1 Layer API result:
{
HERE Android SDK Developer's Guide
User Guide
195
"description": "Link height values computed from a Digital Terrain Model, cleaned up for continuity
along links, bridges and tunnels. Less accurate than ADAS link height values, but full coverage and
sufficient for certain use cases.",
"attributes": {
"LINK_ID": "Permanent link ID. Positive 64 bit Integer that globally identifies the road, carto or
buildin footprint link, also across map releases. Link IDs are never reused.",
"DTM_MIN_HEIGHT": "The minimum height [cm above WGS84 ellipsoid] encountered along the link.",
"DTM_MAX_HEIGHT": "The maximum height [cm above WGS84 ellipsoid] encountered along the link.",
"DTM_AVG_HEIGHT": "The average height [cm above WGS84 ellipsoid] along the link.",
"DTM_REF_ZCOORD": "Height [cm above WGS84 ellipsoid] at the reference node of the link.",
"DTM_NONREF_ZCOORD": "Height [cm above WGS84 ellipsoid] at the non-reference node of the link."
},
"referencedStaticContents": [],
"tileRequestsLevel": 9,
"tileX": 496,
"tileY": 358,
"isStaticContent": false
}
To begin using the PDE layers, create a PlatformDataRequest object:
Set<String> layers = new HashSet<String>(Arrays.asList("LINK_FC1", "BASIC_HEIGHT_FC1"));
GeoBoundingBox box = mapView.getBoundingBox();
PlatformDataRequest request =
PlatformDataRequest.createBoundingBoxRequest(RoadElevationProcessor.LAYERS, box);
Note that trying to create a request with invalid parameters causes a
java.lang.IllegalArgumentException.
Next, you need to supply a Listener<PlatformDataResult> object to get the results of the request.
request.execute(new PlatformDataRequest.Listener<PlatformDataResult>() {
@Override
public void onCompleted(PlatformDataResult data, PlatformDataRequest.Error error) {
if (error != null) {
Log.w(TAG, "PlatformDataRequest failed with error: " + error);
} else {
// process received data
RoadElevationProcessor processor = new RoadElevationProcessor(data);
processor.process(new Listener<List<MapObject>>() {
@Override
public void onResult(List<MapObject> result) {
m_elevationPolylines = result;
m_elevationLegend.setVisibility(View.VISIBLE);
m_map.addMapObjects(m_elevationPolylines);
onRequestEnd(null);
}
});
}
}
});
Example: Processing the PDE Data
After the data result is successfully retrieved, you need to process the data. In the example above, you have
asked for ROAD_GEOM_FC1 and BASIC_HEIGHT_FC1 data, restricted with the map view's bounding box. For
tutorial purposes, we then implemented a sample data processor class, PlatformDataProcessor, which
provides methods to join the layers and can be extended to consume the joined data. We use these classes
to implement the colorize feature.
public abstract class PlatformDataProcessor<T> {
HERE Android SDK Developer's Guide
User Guide
196
protected final PlatformDataResult m_data;
private Handler m_handler = new Handler(Looper.getMainLooper());
public PlatformDataProcessor(PlatformDataResult data) {
m_data = data;
}
public void process(final Listener<T> listener) {
new Thread(new Runnable() {
@Override
public void run() {
final T result = doProcess();
m_handler.post(new Runnable() {
@Override
public void run() {
listener.onResult(result);
}
});
}
}).start();
}
protected abstract T doProcess();
protected Map<String, PlatformDataItem> map(Indexer indexer, PlatformDataItemCollection items) {
Map<String, PlatformDataItem> ret = new HashMap<String, PlatformDataItem>();
map(indexer, items, ret);
return ret;
}
protected void map(Indexer indexer, PlatformDataItemCollection items,
Map<String, PlatformDataItem> output) {
for (PlatformDataItem item : items) {
output.put(indexer.getIndexValue(item), item);
}
}
protected Map<String, List<PlatformDataItem>> multimap(MultiIndexer indexer,
PlatformDataItemCollection items) {
Map<String, List<PlatformDataItem>> ret = new HashMap<String, List<PlatformDataItem>>();
multimap(indexer, items, ret);
return ret;
}
protected void multimap(MultiIndexer indexer, PlatformDataItemCollection items,
Map<String, List<PlatformDataItem>> output) {
for (PlatformDataItem item : items) {
for (String value : indexer.getIndexValue(item)) {
List<PlatformDataItem> entry = output.get(value);
if (entry == null) {
entry = new ArrayList<PlatformDataItem>();
output.put(value, entry);
}
entry.add(item);
}
}
}
protected Map<PlatformDataItem, PlatformDataItem> join(Indexer commonIndexer,
PlatformDataItemCollection mainLayer, PlatformDataItemCollection otherLayer) {
return join(commonIndexer, mainLayer, commonIndexer, otherLayer);
}
protected Map<PlatformDataItem, PlatformDataItem> join(Indexer mainIndexer,
PlatformDataItemCollection mainLayer, Indexer otherIndexer,
PlatformDataItemCollection otherLayer) {
Map<PlatformDataItem, PlatformDataItem> ret =
HERE Android SDK Developer's Guide
User Guide
197
new HashMap<PlatformDataItem, PlatformDataItem>();
Map<String, PlatformDataItem> mappedItems = map(otherIndexer, otherLayer);
for (PlatformDataItem item : mainLayer) {
String value = mainIndexer.getIndexValue(item);
PlatformDataItem matchedItem = mappedItems.get(value);
ret.put(item, matchedItem);
}
return ret;
}
protected Map<PlatformDataItem, List<PlatformDataItem>> join(MultiIndexer mainIndexer,
PlatformDataItemCollection mainLayer, PlatformDataItemCollection otherLayer) {
return join(mainIndexer, mainLayer, mainIndexer, otherLayer);
}
protected Map<PlatformDataItem, List<PlatformDataItem>> join(MultiIndexer mainIndexer,
PlatformDataItemCollection mainLayer, MultiIndexer otherIndexer,
PlatformDataItemCollection otherLayer) {
Map<String, List<PlatformDataItem>> mappedItems = multimap(otherIndexer, otherLayer);
Map<PlatformDataItem, List<PlatformDataItem>> ret =
new HashMap<PlatformDataItem, List<PlatformDataItem>>();
for (PlatformDataItem item : mainLayer) {
for (String value : mainIndexer.getIndexValue(item)) {
List<PlatformDataItem> matchedItems = mappedItems.get(value);
List<PlatformDataItem> entry = ret.get(item);
if (entry == null) {
entry = new ArrayList<PlatformDataItem>();
ret.put(item, entry);
}
if (matchedItems != null) {
entry.addAll(matchedItems);
}
}
}
return ret;
}
interface Indexer {
String getIndexValue(PlatformDataItem item);
}
interface MultiIndexer {
String[] getIndexValue(PlatformDataItem item);
}
interface Listener<T> {
void onResult(T result);
}
}
Note that the PlatformDataProcessor.join() method is for inner joining the thematic layers with
properties where more than one data item is possible. For example, the TRAFFIC_SIGN_FCx thematic layer
has the LINK_IDS property where as much as two LINK_IDs are contained.
Next, create RoadElevationProcessor. The RoadElevationProcessor class extends the
PlatformDataProcessor for coloring the road segments according to their average height. This class
needs the result and a dedicated map container intended for the MapPolyline objects. Note that the base
class PlatformDataProcessor performs the inner joining of the thematic layer data depending on the
indexer blocks provided. The RoadElevationProcessor class utilizes the joined data to implement the
intended feature.
public class RoadElevationProcessor extends PlatformDataProcessor<List<MapObject>> {
HERE Android SDK Developer's Guide
User Guide
198
public static final String ROAD_GEOM_LAYER = "ROAD_GEOM_FC1";
public static final String BASIC_HEIGHT_LAYER = "BASIC_HEIGHT_FC1";
public static final Set<String> LAYERS = new HashSet<String>(Arrays.asList(ROAD_GEOM_LAYER,
BASIC_HEIGHT_LAYER));
public RoadElevationProcessor(PlatformDataResult data) {
super(data);
}
protected List<MapObject> doProcess() {
List<MapObject> polylines = new ArrayList<MapObject>();
PlatformDataItemCollection roadGeomLayer = m_data.get(ROAD_GEOM_LAYER);
PlatformDataItemCollection basicHeightLayer = m_data.get(BASIC_HEIGHT_LAYER);
Map<PlatformDataItem, PlatformDataItem> combinedData =
join(LINK_ID_INDEXER, roadGeomLayer, basicHeightLayer);
for (Map.Entry<PlatformDataItem, PlatformDataItem> entry : combinedData.entrySet()) {
PlatformDataItem roadGeomItem = entry.getKey();
PlatformDataItem basicHeightItem = entry.getValue();
List<GeoCoordinate> linkGeometry = roadGeomItem.getCoordinates();
if (linkGeometry.size() > 1) {
GeoPolyline geoPolyline = new GeoPolyline(linkGeometry);
MapPolyline mapPolyline = new MapPolyline(geoPolyline);
mapPolyline.setLineColor(calculateColor(basicHeightItem.getAverageHeight()));
mapPolyline.setLineWidth(10);
polylines.add(mapPolyline);
}
}
return polylines;
}
private int calculateColor(int height) {
if (height > 75000) {
return 0xff00695c;
} else if (height > 25000) {
return 0xff009688;
} else if (height > 0) {
return 0xff4db6ac;
} else if (height > -25000) {
return 0xff7986cb;
} else if (height > -75000) {
return 0xff5c6bc0;
} else {
return 0xff3f51b5;
}
}
private Indexer LINK_ID_INDEXER = new Indexer() {
@Override
public String getIndexValue(PlatformDataItem item) {
return item.getLinkId();
}
};
}
The main method for the RoadElevationProcessor class is the doProcess() method.
The first thing this method does is joining the data coming from two different thematic layers with the
"indexer" blocks. Here, the data is joined via the LINK_ID's. Note that the linkId property is available
as a shortcut property in the PlatformDataItem class. After joining the data, each ROAD_GEOM_FC1
data item is inner joined with the relevant BASIC_HEIGHT_FC1 data item, and the joined data is returned
as a dictionary where the actual type is Map<PlatformDataItem, PlatformDataItem>. Each key-
HERE Android SDK Developer's Guide
User Guide
199
value pairs provides the necessary data for the feature: the key of PlatformDataItem type representing
the ROAD_GEOM_FC1 thematic layer data provides the road geometry, such as coordinates of the road
segment, and the value of PlatformDataItem type, representing the BASIC_HEIGHT_FC1 thematic layer
data, provides the average height of that road segment. The joined data provides all the data required for
implementing the intended feature.
{
BRIDGE = N;
LAT = "5246124,2";
"LINK_ID" = 936938339;
LON = "1342560,24";
"LONG_HAUL" = Y;
NAME = A100;
NAMES = "GERBNTunnel BritzGERY\"tU|n@l \"brItsGERBNA100GERN\"?a: \"hUn|d6t;GERN\"?aU|to:|ba:n ?aIn|
\"hUn|d6t;GERY\"?a: ?aIn|\"hUn|d6t;GERN\"?aU|to:|ba:n \"hUn|d6tGERBNStadtring BerlinGERY\"Stat|rIN
bEr|\"li:n";
TUNNEL = Y;
ZLEVEL = ",";
} = {
"DTM_AVG_HEIGHT" = 8500;
"DTM_MAX_HEIGHT" = 8693;
"DTM_MIN_HEIGHT" = 8099;
"DTM_NONREF_ZCOORD" = 8500;
"DTM_REF_ZCOORD" = 8500;
"LINK_ID" = 936938339;
}
Note that the key-value pair has the same LINK_ID.
Natural Language Processing (NLP)
The Natural Language Processing (NLP) feature adds a "natural language" interface to the HERE Android SDK.
For example, the end user says "find me a gas station". This prompts the NLP interface to detect that the user
wants to search for gas stations, trigger a search via the HERE SDK, use Places to find gas stations, and speak
the results to the user.
Important: NLP is currently offered as a beta feature, and it is only available for use in the English
language. APIs may change without notice. Do not use this feature in a commercial application.
NLP covers the main features offered by the HERE Android SDK: search, routing, navigation, and traffic. NLP
also saves and handles context for the user's request. For example, it can handle the command "find 3 gas
stations”, followed by "take me to the third one".
Initialization
You can start using the NLP feature by initializing the Nlp class after you have successfully initialized the
MapFragment in your application.
Nlp is a singleton, so you first need to retrieve the instance of it and then call init() to initialize the whole
engine. The Nlp.init(Context, MapFragment, CollectionProvider, SpeechToTextProvider,
OnInitializationListener) method takes the following input parameters, as demonstrated in the next
example:
The application context
HERE Android SDK Developer's Guide
User Guide
200
The MapFragment object
A CollectionProvider (Or null if you don't want to implement a collection feature)
A SpeechToTextProvider to enable the Speech Recognition functionality
An OnInitializationListener
// Create Map NLP object to control voice operations
// Pass Activity as a Context
m_nlp = Nlp.getInstance();
m_speechToTextProvider = new MyASR(getApplicationContext);
m_nlp.init(AppActivity.this, mapFragment,
m_nlpCollectionProvider, m_speechToTextProvider, m_nlpListener);
private OnInitializationListener m_nlpListener = new OnInitializationListener() {
@Override
public void onComplete(Error error) {
if (error == Error.NONE) {
m_speechToTextProvider.setNlp(m_nlp);
// Enable talk-back
m_nlp.setTalkBackEnabled(true);
// Set speech volume percentage
m_nlp.setSpeechVolume(25);
}
}
};
Note: Nlp can only be used after it is successfully initialized.
Note: If you want to support a collection feature in your application via NLP, implement a
CollectionProvider. If the CollectionProvider interface is not implemented, all collection-
related utterances result in "feature not supported" announcements to the user. Collection-handling
use cases include: saving a found place in a collection, creating a collection, renaming a favorite
place, and deleting a collection.
Speech Recognition
You need to create your own Speech Recognition class, by implementing the SpeechToTextProvider
interface, to listen to the user’s voice commands. The example below uses the Android SpeechRecognizer
API, but your application can use any available Automatic Speech Recognition (ASR). Once the ASR results
are received, the recognized text is processed through NLP to be analyzed and understood using the Nlp
understand(String) API.
If the SpeechRecognizer interface is not implemented, NLP will not be able to automatically start listening
when asking a question to the user for clarification or confirmation.
It is also recommended to use Nlp.startListening() API instead of calling your speech recognizer's
start() directly. This will allow NLP to automatically stop navigation instructions from speaking when the
application wants to start listening to user’s speech.
public class MyASR implements SpeechToTextProvider {
private Context m_context = null;
private volatile SpeechRecognizer m_stt = null;
private Nlp m_nlp = null;
HERE Android SDK Developer's Guide
User Guide
201
/**
* Create Speech recognizer
*/
MyASR(Context context, int resStartEarcon, int resStopEarcon, int resErrorEarcon) {
m_context = context;
if (m_stt == null) {
// Creating an instance of Google SpeechRecognizer to listen to user’s utterances
m_stt = SpeechRecognizer.createSpeechRecognizer(m_context);
m_stt.setRecognitionListener(m_sttListener);
}
}
/**
* Schedule to start listening
*/
@Override
public synchronized void start() {
final Intent intent = new Intent(RecognizerIntent.ACTION_RECOGNIZE_SPEECH);
intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE, Locale.US.toString());
intent.putExtra(RecognizerIntent.EXTRA_LANGUAGE_PREFERENCE, Locale.US.toString());
intent.putExtra(RecognizerIntent.EXTRA_MAX_RESULTS, 4);
try {
m_stt.startListening(intent);
} catch (Exception e) {
destroy();
}
}
/**
* Google Speech Recognizer listener
*/
private final RecognitionListener m_sttListener = new RecognitionListener() {
@Override
public void onResults(final Bundle results) {
synchronized (GoogleASR.this) {
final ArrayList<String> data =
results.getStringArrayList(SpeechRecognizer.RESULTS_RECOGNITION);
if (data != null && !data.isEmpty() && m_nlp.isInitialized()) {
m_nlp.understand(data.get(0)); // Pass the utterance to NLP for analysis
}
}
}
};
}
Using the Nlp Class
To receive callbacks when different utterances are said by the users, set listeners after the Nlp has
successfully initialized. For example, if you want to know when the user says "search for restaurants",
you need to override the OnSearchListener callback. All available listeners are listed in the Nlp class
definition.
The following is an example of how to set an OnSearchListener:
private OnInitializationListener m_nlpListener = new OnInitializationListener() {
@Override
public void onComplete(Error error) {
HERE Android SDK Developer's Guide
User Guide
202
if (error == Error.NONE) {
// Create handlers
m_nlp.addListener(m_searchListener);
}
}
};
private OnSearchListener m_searchListener = new OnSearchListener() {
@Override
public void onStart(final String subject, final GeoBoundingBox box) {
android.util.Log.d(TAG, "onStart: Search STRING start event");
}
@Override
public void onStart(final CategoryFilter filter, final GeoBoundingBox box) {
android.util.Log.d(TAG, "onStart: Search CATEGORY start event");
}
@Override
public void onStart(final GeoCoordinate center) {
android.util.Log.d(TAG, "onStart: Search REVERSE start event");
}
@Override
public void onComplete(final Error error,
final String searchString,
final String whereString,
final String nearString,
List<PlaceLink> placeLinks) {
android.util.Log.d(TAG, "onComplete: Search results are available");
if (error == Error.NONE) {
// Show all found places on the map.
}
}
};
HERE Android SDK Developer's Guide
Supplemental Information
203
Chapter 4
Supplemental Information
Topics:
Create a Simple App Using ...
Requesting Android Permiss...
Android Emulator Support
Adding a MapFragment at Ru...
3D Venues FAQ
Size Management
Map Rendering Order
Development Tips
Signpost Parsing
This section provides supplemental information for using the HERE
Android SDK.
HERE Android SDK Developer's Guide
Supplemental Information
204
Create a Simple App Using the HERE SDK
This tutorial provides instructions on how to create a simple application that uses the HERE Android SDK to
render a map on an Android device.
This tutorial assumes that you are using the Android Studio development environment. Development tasks
for this basic application include:
Acquire HERE credentials for accessing map services.
Create a new Android Studio project.
Add necessary resources, permissions, and a map fragment to the project.
Modify AndroidManifest.xml
Initialize the map fragment to create a map instance and associate this map with the map fragment for
rendering on the client device.
Note: The HERE Map Service must be embedded with the application. For more information on this
requirement, see Embedding the Map Service on page 20.
Note: The HERE Android SDK is now distributed as an .AAR instead of a .JAR. Please review your
project configuration if you are upgrading from an older versions of the HERE SDK. Also, be sure to
first remove the old HERE-sdk.jar and native libraries from your Android project before you import
the new .AAR file.
Acquire HERE SDK Credentials
Typically, before developing a new HERE SDK application, you need to acquire a set of credentials by
registering your application on http://developer.here.com. Each application requires a unique set of
credentials. When you register your app, the registered bundle identifier must match the package name in
your project.
Create a New Android Studio Project
The second stage of developing an application using the HERE SDK is to create a new project in Android
Studio as follows:
1. From the Welcome to Android Studio dialogue box, select New Project... to open the Create New Project
dialog.
2. In the New Android Application dialog, under Application name, specify an appropriate application name.
The remainder of this tutorial uses BasicMapSolution as the application name.
3. Under Company Domain, specify an appropriate domain.
4. Edit the package name by clicking the Edit link. The remainder of this tutorial uses
com.here.android.tutorial as the package name.
Important: You must use the same package name as you have registered on developer.here.com.
Failure to do so leads to a blank map to appear in your application.
You can also edit this package name later in your AndroidManifest.xml:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.your.package.name.here"
android:versionCode="1"
HERE Android SDK Developer's Guide
Supplemental Information
205
android:versionName="1.0" >
Figure 74: Edit the Package Name
5. Under Project Location, specify an appropriate project location in the file system.
6. Click Next.
7. Select the form factors supported by your application. For the purpose of this tutorial, check Phone and
Tablet.
8. Under Minimum SDK, select the lowest version of the Android SDK you wish to support. For this sample
application, use Android 4.1.x "Jelly Bean".
9. Click Next.
10. You may be prompted to agree to a License Agreement. Click Accept, and then Next to install SDK
components. After the installation is complete, click Next again.
11. In the "Add an activity to Mobile" dialog box, select Empty Activity and click Next.
12. In the "Customize Activity" dialog box, specify an appropriate activity name in Activity Name. This tutorial
uses the name BasicMapActivity.
13. Under Layout Name, specify an appropriate layout name. (This tutorial uses activity_main.)
14. Click Finish.
Result: Andriod Studio creates the structure for your project and opens the development environment.
A few views are available in the Android Studio development environment. The Android view shows a
flattened view of the application's structure, and the Project view shows a flattened view of the project's
structure, including Gradle-related files.
The Android view provides quick access to key source files of your Android application. Selecting the
activity_main.xml file in Android view opens the file in the Layout Editor and allows you to drag-and-
drop widgets into your layout.
HERE Android SDK Developer's Guide
Supplemental Information
206
The following image shows how to switch between Android and Project view.
Figure 75: Switching Views in Android Studio
Import the HERE SDK Android Archive
The HERE Android SDK library is shipped as an Android Archive (.AAR) file. You can import this library by
doing the following:
1. On the View menu, click Tool Windows> Project.
2. A few tabs are available in this tool window. Select the Project tab to show a file system view of the
application structure.
3. Right-click on the app folder and select New> Directory to create a new folder. Use libs as the new
folder name.
4. In your operating system's file system, navigate to the extracted HERE SDK directory. Copy the HERE-
sdk.aar file and paste it into the newly created libs directory.
5. Optional: To enable quick Javadoc reference within your Android Studio environment, scroll down to the
External Libraries section, right-click on HERE-sdk, and then select Library Properties. Click the + button
and locate HERE-sdk-javadoc.jar from the HERE SDK package.
Modify build.gradle
After importing the .AAR file, modify build.gradle to add the file to your list of dependencies.
1. From the Project view pane, locate the build.gradle file under the app folder and open it for editing.
HERE Android SDK Developer's Guide
Supplemental Information
207
2. In build.gradle, add the following line into the android { ... } section:
repositories {
flatDir {
dirs 'libs'
}
}
3. Next, add the following into the dependencies { ... } section:
compile project(':HERE-sdk')
4. Optional: If you plan on extending this application with HERE Places, Custom Locations, 3D Venues, or
Transit Routing, functionality, add the GSON library to your project. You can add this library by adding
the following line into the dependencies { ... } section:
compile 'com.google.code.gson:gson:2.8.0'
Modify AndroidManifest.xml and Add HERE Credentials
1. Add the HERE credentials to AndroidManifest.xml. For instructions on how to edit this file, see
Authenticating Applications on page 17.
2. Modify the opening <application> by adding the android:hardwareAccelerated="true"
attribute.
<application android:icon="@drawable/icon"
android:label="@string/app_name" android:hardwareAccelerated="true">
3. Add the following markup before the <application></application> tags:
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
Note: If your app uses Android API level 23 (Android 6.0) or above, you must also add code
to request for permissions during runtime. You can find more information in the Request for
Permissions section.
4. Within the same <application></application> section in your AndroidManifest.xml file, add
the following lines:
<service
android:name="com.here.android.mpa.service.MapService"
android:label="HereMapService"
android:process="global.Here.Map.Service.v3"
android:exported="true" >
<intent-filter>
<action android:name="com.here.android.mpa.service.MapService.v3" >
</action>
</intent-filter>
</service>
Result: Your project is able to make use of APIs from the HERE SDK.
Edit activity_main.xml
Along with permissions and credentials, you must add an Android <fragment /> tag to set up the map
fragment that your application activity is associated with. In this section, we add a text label (generated as
part of the default new application) and a map as follows:
HERE Android SDK Developer's Guide
Supplemental Information
208
1. From the Android View, under the res/layout/ folder of your project, double-click the
activity_main.xml file to open it for editing.
2. Ensure that the XML file has <LinearLayout></LinearLayout> as its root element. Depending on
your version of Android Studio, this may be a RelativeLayout instead. If that is the case, replace the
contents of the file with the following:
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<TextView
android:id="@+id/title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World"
tools:context=".BasicMapActivity" />
</LinearLayout>
3. Add the following markup beneath the <TextView/> tag:
<!-- Map Fragment embedded with the map object -->
<fragment
class="com.here.android.mpa.mapping.MapFragment"
android:id="@+id/mapfragment"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
Result: When MapFragment is initialized, your application's BasicMapActivity contains a MapFragment
UI element (with the ID mapfragment) that owns a Map object.
Initializing the Map Fragment
When you have defined the basic layout of the application and acquired necessary permissions, the final
step is to initialize the instance of the MapFragment class, thus creating and associating a Map with the
MapFragment declared in the activity_main.xml file:
From the Android View, double-click the BasicMapActivity.java file under the java folder to open
it for editing.
Revise the import statements and functional logic of BasicMapActivity to look like the following:
package com.here.android.tutorial;
import android.app.Activity;
import android.os.Bundle;
import com.here.android.mpa.common.GeoCoordinate;
import com.here.android.mpa.common.OnEngineInitListener;
import com.here.android.mpa.mapping.Map;
import com.here.android.mpa.mapping.MapFragment;
public class BasicMapActivity extends Activity {
// map embedded in the map fragment
private Map map = null;
// map fragment embedded in this activity
private MapFragment mapFragment = null;
HERE Android SDK Developer's Guide
Supplemental Information
209
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
initialize();
}
private void initialize() {
setContentView(R.layout.activity_main);
// Search for the map fragment to finish setup by calling init().
mapFragment = (MapFragment)getFragmentManager().findFragmentById(
R.id.mapfragment);
mapFragment.init(new OnEngineInitListener() {
@Override
public void onEngineInitializationCompleted(
OnEngineInitListener.Error error)
{
if (error == OnEngineInitListener.Error.NONE) {
// retrieve a reference of the map from the map fragment
map = mapFragment.getMap();
// Set the map center to the Vancouver region (no animation)
map.setCenter(new GeoCoordinate(49.196261, -123.004773, 0.0),
Map.Animation.NONE);
// Set the zoom level to the average between min and max
map.setZoomLevel(
(map.getMaxZoomLevel() + map.getMinZoomLevel()) / 2);
} else {
System.out.println("ERROR: Cannot initialize Map Fragment");
}
}
});
}
}
Request for Permissions
If your app supports Android 6.0 or above, your app needs to ask users to grant certain permissions at
runtime. For more information about this requirement, see Requesting Android Permissions on page 210.
Run the Applciation
You can run your simple application by pressing the key combination Shift + F10 (or Ctrl + R on Macs) from
within Android Studio. The application renders a map retrieved from the HERE servers. When you are running
your application on a device, make sure a dataconnection is enabled.
See the BasicMapSolution folder for a completed example. You need to add your own App_Id and
App_Code for this completed example to work.
HERE Android SDK Developer's Guide
Supplemental Information
210
Requesting Android Permissions
If your application supports Android 6.0 or above, add the following code in your activity file to ask the
application users to grant Android permissions at runtime. For more information about this requirement, see
the Android Developer documentation.
Figure 76: Request Location Permission Figure 77: Request File Access Permission
1. Add the following import statements to the beginning of the file:
import android.content.pm.PackageManager;
import android.support.annotation.NonNull;
import android.support.v4.app.ActivityCompat;
import android.support.v4.content.ContextCompat;
import android.Manifest;
import android.widget.Toast;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
2. Add these static variables to the BasicMapActivity class:
/**
* permissions request code
HERE Android SDK Developer's Guide
Supplemental Information
211
*/
private final static int REQUEST_CODE_ASK_PERMISSIONS = 1;
/**
* Permissions that need to be explicitly requested from end user.
*/
private static final String[] REQUIRED_SDK_PERMISSIONS = new String[] {
Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.WRITE_EXTERNAL_STORAGE };
Note: The Android permission android.permission.ACCESS_FINE_LOCATION is not required
to initialize or use the SDK. However, it is required if you use the following components:
PositioningManager
NavigationManager
PositionSimulator
• LiveSight
3. Add the following methods to the BasicMapActivity class:
/**
* Checks the dynamically-controlled permissions and requests missing permissions from end user.
*/
protected void checkPermissions() {
final List<String> missingPermissions = new ArrayList<String>();
// check all required dynamic permissions
for (final String permission : REQUIRED_SDK_PERMISSIONS) {
final int result = ContextCompat.checkSelfPermission(this, permission);
if (result != PackageManager.PERMISSION_GRANTED) {
missingPermissions.add(permission);
}
}
if (!missingPermissions.isEmpty()) {
// request all missing permissions
final String[] permissions = missingPermissions
.toArray(new String[missingPermissions.size()]);
ActivityCompat.requestPermissions(this, permissions, REQUEST_CODE_ASK_PERMISSIONS);
} else {
final int[] grantResults = new int[REQUIRED_SDK_PERMISSIONS.length];
Arrays.fill(grantResults, PackageManager.PERMISSION_GRANTED);
onRequestPermissionsResult(REQUEST_CODE_ASK_PERMISSIONS, REQUIRED_SDK_PERMISSIONS,
grantResults);
}
}
@Override
public void onRequestPermissionsResult(int requestCode, @NonNull String permissions[],
@NonNull int[] grantResults) {
switch (requestCode) {
case REQUEST_CODE_ASK_PERMISSIONS:
for (int index = permissions.length - 1; index >= 0; --index) {
if (grantResults[index] != PackageManager.PERMISSION_GRANTED) {
// exit the app if one permission is not granted
Toast.makeText(this, "Required permission '" + permissions[index]
+ "' not granted, exiting", Toast.LENGTH_LONG).show();
finish();
return;
}
}
// all permissions were granted
initialize();
break;
}
}
HERE Android SDK Developer's Guide
Supplemental Information
212
4. Finally, change the method call in onCreate(Bundle) from initialize() to checkPermissions()
instead:
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
checkPermissions();
}
Android Emulator Support
Starting from v3.6, HERE Android SDK includes support for the x86 Application Binary Interface (ABI). The x86
ABI enables you to run apps with x86 Android Virtual Devices (AVD). Due to this change, the .aar file size
available in the HERE SDK from http://developer.here.com is larger and contains the libraries for the newly
supported ABIs.
For more information on ABIs, see https://developer.android.com/ndk/guides/abis.html.
For more information on how to create x86 AVDs, see https://developer.android.com/studio/run/managing-
avds.html.
Note: To get the best possible performance on an x86 AVD, install and enable Intel HAXM by following
these instructions: https://developer.android.com/studio/run/emulator-acceleration.html.
By default, you do not need to make any changes to your development environment to include x86 native
libraries. However, any .apk file that you build with the HERE SDK will be larger, since it contains twice
as many native libraries. Optionally, you can follow this guide to create multiple .apk files, with each
containing native libraries for a specific ABI, and thus reducing application sizes.
Adding a MapFragment at Runtime
Earlier tutorials in this document featured adding a MapFragment to an activity by editing the layout XML
file. You can also add a MapFragment to an activity dynamically, during runtime, by performing the following
steps in the Activity class:
1. Create a layout container:
final int CONTAINER_ID = 1234567;
LinearLayout layoutContainer = new LinearLayout(this);
layoutContainer.setOrientation(LinearLayout.HORIZONTAL);
layoutContainer.setId(CONTAINER_ID);
2. Define a map tag:
final String MAP_TAG = "map_tag";
3. Create a map fragment and add it using the fragment manager:
mapFragment = new MapFragment();
getFragmentManager().beginTransaction().add(layoutContainer.getId(), mapFragment,
MAP_TAG).commit();
HERE Android SDK Developer's Guide
Supplemental Information
213
4. Initialize the map fragment by implementing OnEngineInitListener:
MyOnEngineInitListener onEngineInitListener = new MyOnEngineInitListener();
ApplicationContext context = new ApplicationContext(this);
mapFragment.init(context, onEngineInitListener);
5. Finally, show the content view:
setContentView(layoutContainer);
For more information on adding a fragment at runtime, see this article: https://developer.android.com/
training/basics/fragments/fragment-ui.html#AddAtRuntime.
3D Venues FAQ
Can I customize the venue color scheme and venue icon?
Yes. Venue attributes can be customized using the StyleSettings object.
There are two types of icons:
Icons displayed on the map for a space, point-space, or facility (SVG file format)
Icons displayed in native controls, such as a search filter list (PNG file format)
Map icons can be customized in two ways, either by replacing the respective SVG asset files with customized
ones, or by dynamically replacing it at runtime using the StyleSettings object. See the following code
snippet as an example on how to customize icon for a space.
@Override
public void onVenueSelected(Venue venue) {
if (venue.getId().equals("DM_12468")) {
Space t1Space = venue.getSpace("Lv26051Ds3186063");
if (t1Space != null) {
VenueController venueCtlr = m_venueLayer.getVenueController(venue);
Bitmap bitmap = BitmapFactory.decodeResource(m_venueLayer.getActivity().getResources(),
R.drawable.ic_terminal_c);
Image image = new Image();
image.setBitmap(bitmap);
StyleSettings settings = new StyleSettings();
settings.setLabelImage(image);
venueCtlr.setStyleSettings(settings, t1Space);
}
}
}
Note: Using a private HERE account, PNG icons that are displayed in native controls can also be
customized by replacing the respective PNG icon files with customized ones. Note that there are
4 different sizes for each Android resolution type. To make these customizations, contact a HERE
representative.
Can logos be added for individual spaces, such as for a restaurant?
Yes. You can modify the icon for an individual space dynamically using the StyleSettings object. For
details, see the StyleSettings API Reference.
HERE Android SDK Developer's Guide
Supplemental Information
214
Is it possible to expose venue data, in a classified manner, for a single user?
Yes, you can create a private HERE account and expose a "customized" version of the venue to it. Please
contact a HERE representative for more information.
What fonts are supported by the Venues feature?
There is currently no support for fonts. Only the default font is supported.
Are there venue routing penalties for different types of connectors, such as elevators?
Penalties are applied when the route is calculated in "fastest" mode. For "shortest" mode, connectors are
considered only if the geometry has a significant distance.
How can I create a colored MapMarker?
See the following code snippet or the MapMarker API Reference .
MapMarker m_marker;
 @Override
 public void onSpaceSelected(Venue venue, Space space) {
 removeMarker();
 Bitmap bitmap = BitmapFactory.decodeResource(getResources(), R.drawable.pin_start);
 Image image = new Image();
 image.setBitmap(bitmap);
 m_marker = new MapMarker(space.getCenter(), image);
 m_marker.setAnchorPoint(new PointF(image.getWidth() / 2f, 0.9f * image.getHeight()));
 m_marker.setOverlayType(MapOverlayType.FOREGROUND_OVERLAY);
 m_marker.setZIndex(100);
 getMap().addMapObject(m_marker);
 }
 @Override
 public void onSpaceDeselected(Venue venue, Space space) {
 removeMarker();
 }
 private void removeMarker() {
 if (m_marker != null) {
 getMap().removeMapObject(m_marker);
 m_marker = null;
 }
 }
How do I select point-spaces (spaces without geometry) and calculate a route to such a
position?
Take the tapped position and calculate the route from those coordinates. The following is an example of how
to handle the map tap events to get a location for a route.
public boolean onMapTapped(PointF point) {
Map map = m_venueLayer.getMap();
GeoCoordinate tapPoint = map.pixelToGeo(point);
if (tapPoint == null || !tapPoint.isValid()) {
return false;
}
Venue venue = m_venueLayer.getSelectedVenue();
HERE Android SDK Developer's Guide
Supplemental Information
215
VenueController venueController = null;
if (venue != null) {
venueController = m_venueLayer.getVenueController(venue);
}
if (venueController == null) {
// null controller means that there is no venue open in 3d mode,
// so use the tap point as outdoor location
BaseLocation location = new OutdoorLocation(tapPoint);
addRoutePoint(location);
return false;
}
// if the controller is not null, get the tapped point as a location inside venue
BaseLocation location = venueController.getLocation(point, m_preferSpaceSelection);
addRoutePoint(location);
return false;
}
private void addRoutePoint(BaseLocation location) {
//Logic for saving route points.
}
How do I calculate the length of a route?
1. From the CombinedRoute result object, get all the route sections. Route sections can be of three types:
VENUE, LINK, or OUTDOOR.
2. For each route type, you need to calculate its distance individually. See the following example on how to
calculate length of different route types.
private void calculateLength(CombinedRoute combinedRoute) {
List<IRouteSection> sections = combinedRoute.getRouteSections();
double distance = 0.0;
for (IRouteSection section : sections) {
if (section instanceof VenueRoute) {
// get length of indoor sections
List<VenueManeuver> maneuvers = ((VenueRoute)section).getVenueManeuvers();
distance += (double)maneuvers.get(maneuvers.size() - 1).getDistanceFromStart();
} else if (section instanceof LinkingRoute) {
// get length of link sections
distance +=
((LinkingRoute)section).getFrom().distanceTo(((LinkingRoute) section).getTo());
} else if (section instanceof OutdoorRoute) {
// get length of outdoor sections
com.here.android.mpa.routing.Route route = ((OutdoorRoute)section).getRoute();
distance += (double)route.getLength();
}
}
}
How can my app automatically open a venue right after the app starts?
At app start, make sure the VenueService is initialized and then select the desired venue using
VenueMapFragment, as shown in the following example:
//1. make sure VenueService is initialized
if (VenueMapFragment.getVenueService().getInitStatus() == ONLINE_SUCCESS ||
VenueMapFragment.getVenueService().getInitStatus() == OFFLINE_SUCCESS) {
//2. Then, use the method to get the desired venue
HERE Android SDK Developer's Guide
Supplemental Information
216
VenueMapFragment.selectVenueAsync(String id);
}
How can my app detect whether a route passes a specific type of space, such as a security
gate?
To identify if a route passes a certain type or category of space, loop through the route sections and inspect
if a maneuver contains a space in the expected category. For example, the following code snippet shows how
to find the first venue maneuver with category 4, which represents a security gate.
private void findSecurityGate(CombinedRoute route) {
for (IRouteSection section: route.getRouteSections()) {
if (section.getRouteSectionType() == IRouteSection.RouteSectionType.VENUE) {
VenueRoute venueRoute = (VenueRoute) section;
List<VenueManeuver> maneuvers = venueRoute.getVenueManeuvers();
for (VenueManeuver maneuver: maneuvers) {
if (maneuver.getSpace() != null && maneuver.getSpace().getContent() != null) {
Content content = maneuver.getSpace().getContent();
if (content.getCategoryId().equals("4")) {
// create alert;
return;
}
}
}
}
}
}
We get the spaces and facilities by iterating through all the levels and calling the
getSortedSpacesWithFacilities() method. Is it possible to also get the entrances?
This is the correct way to get a list with all the spaces and facilities. However, entrances (accessors) are not
exposed as POIs at the moment.
Is there a way to only show the venue model without showing the map tiles beneath it?
At the moment, a venue can only be shown on top of the map.
Is there a way to integrate 3D Venues with Apache Cordova?
We do not support a Cordova plug-in. Only native Android and iOS SDKs are supported.
Can airport venues be identified by their IATA airport codes?
This can only be done by searching through the core map POI database (for example, using HERE WeGo app)
for the IATA code. For example, you may search for "fra", "Fra", or "FRA" and get the POI result "Frankfurt
Airport (FRA)". By doing this, the venue map model's footprint (DM_9964 - "Frankfurt International Airport")
becomes exposed on the map as an unopened model within the map bounding box.
How can I get a nearby space based on a location and a radius?
This is not currently supported.
HERE Android SDK Developer's Guide
Supplemental Information
217
How can I get a nearby space based on an indoor routing line?
This is not possible at the moment. This is planned for a future release.
How can I get a certain area around a venue model for offline mode?
Once a venue has been downloaded, it is cached and be available later in offline mode. However, you need
to be online and request the venue prior to this.
Can venue entrance markers be customized ?
HERE SDK already marks entrances on the map and on the route with entrance icons. For private venues,
these icons can be customized by contacting HERE representatives.
How do I pre-cache known airports without user interaction?
You need to download venues using VenueService.
v.getVenueAsync()
v.getVenueAt()
v.getVenueById()
v.getVenuesIn()
For more information, see the VenueService API Reference .
How do I translate geo-locations into indoor locations, expressed as latitude, longitude, and
level, for a given functional call within the HERE SDK?
You need to have the geo-location which you want to map inside the venue, as well as the level on which you
intend to place those coordinates. Thus, you can use LevelLocation to construct the indoor location.
GeoCoordinate m_currentPosition;
String m_buildingId;
Integer m_levelId;
Level m_currentLevel;
LevelLocation m_levelLocation;
OutdoorLocation m_outdoorLocation;
@Override
public void onPositionUpdated(LocationMethod locationMethod, GeoPosition currentPosition,
boolean isMapMatched) {
// Get position in GeoCoordinates
m_currentPosition = currentPosition.getCoordinate();
m_map.setZoomLevel(17.0);
m_map.setCenter(m_currentPosition, Animation.NONE);
if (currentPosition.getBuildingId() != null) {
// If inside a venue get building information and initiate venue opening
// Get buidling id (venue id)
m_buildingId = currentPosition.getBuildingId();
// Get level number
m_levelId = currentPosition.getFloorId();
// Get 3d venue based on venue id.
// Venue object is available as parameter of onVenueSelected callback of VenueListener.
// In order to get that callback, register your application to receive this
// callback with VenueService.addVenueLoadListener method.
if (m_venueLayer.getSelectedVenue() == null ||
HERE Android SDK Developer's Guide
Supplemental Information
218
(!m_venueLayer.getSelectedVenue().getId().equals(m_buildingId)))
{
m_venueLayer.selectVenueAsync(m_buildingId);
}
} else {
// In not inside a venue create an outdoor location
m_outdoorLocation = new OutdoorLocation(m_currentPosition);
}
}
@Override
public void onVenueSelected(Venue venue) {
// Get Level object based on level id.
// Java 8 offers more elegant way to iterate using filter but assume we need to stick on Java 7
List<Level> levels = venue.getLevels();
boolean found = false;
for (int i = 0; i < levels.size() && !found; ++i ) {
if (levels.get(i).getFloorNumber() == m_levelId) {
m_currentLevel = levels.get(i);
found = true;
}
}
// Create LevelLocation object
m_levelLocation =
new LevelLocation(m_currentLevel, m_currentPosition, m_venueLayer.getVenueController(venue));
}
Size Management
This section provides tips on reducing the size of the HERE SDK so your application uses less storage on
consumer devices.
Remove Unused Font Files
By default, the HERE Android SDK includes a number of font files to support different languages. These files
may range from a few hundred kilobytes to a few megabytes in size. You can exclude unused font files to
reduce the size of your HERE SDK-enabled application.
To exclude HERE SDK font files, perform these steps:
1. From the Android Studio "Project" Tool Window (Alt+1 on Windows or Linux, Command+1 on Mac), select
the "Project Files" view and navigate to the app folder to reveal its contents.
2. Double-click on the build.gradle file to open it for editing.
3. In the android { ... } section, add packagingOptions so that it looks like the following:
android {
...
packagingOptions {
exclude '/lib/armeabi-v7a/libNanumGothicFontPkg.so'
exclude '/lib/armeabi-v7a/libLohitIndicFontPkg.so'
exclude '/lib/armeabi-v7a/libChineseFontPkg.so'
}
...
}
HERE Android SDK Developer's Guide
Supplemental Information
219
Note:
The "Chinese" font package supports Chinese characters.
"Nanum Gothic" supports Korean characters.
"Lohit Indic" supports Indic scripts.
After completing these steps, your application consumes less space when it is installed on a device. The
maximum amount that you can save with these steps is approximately 5MB.
Map Rendering Order
The HERE SDK renders map elements in a pre-defined order through a set of overlays, so that when an
overlay is rendered, elements that should appear in the foreground are not obscured by background items.
As a developer, you cannot modify this rendering order or overlay grouping, but you can assign new map
objects and raster tiles to a specific map overlay.
The following is a reference of the map overlays that you can set to an object or raster tile, as defined in
the MapOverlayType enum. This reference also includes a listing of the map elements that are rendered
on each overlay. You can use this reference to ensure that your object and tiles are rendered correctly and
unobscured.
MapOverlayType Represents
BACKGROUND_REPLACEMENT Objects on this overlay replace the background. The elements that are rendered on this overlay by
default include:
the background
simple map terrains
a high-level abstract view of the world map
BACKGROUND_OVERLAY Objects on this overlay are directly placed over (on top of) the background map. No other elements
are rendered on this overlay by default.
AREA_OVERLAY Objects on this overlay contain area information. The elements that are rendered on this overlay by
default include:
• deserts
• glaciers
• woodlands
• parks
national parks
urban built-up areas
industrial zones
• parks
• beaches
• runways
bodies of water
outlines of large areas
outlines of buildings
HERE Android SDK Developer's Guide
Supplemental Information
220
MapOverlayType Represents
ROAD_OVERLAY Objects on this overlay contain information about the road network. The elements that are rendered
on this overlay by default include:
ferry paths
• railroads
• streets
country boundaries
street-level imagery coverage
transit paths
traffic flow
traffic incidents
TRANSIT_STOP_OVERLAY Objects on this overlay contain information about transit stops. The elements that are rendered on
this overlay by default include:
extruded buildings
3D landmarks
points of interest (POIs)
transit accesses
transit stops
city centers
user transit routes
POI_OVERLAY Objects on this overlay contain information that are related to points of interest. The elements that
are rendered on this overlay by default include:
certain transit paths
neighborhood labels
park information
highway labels
safety spots
3D venue objects
FOREGROUND_OVERLAY Objects on this overlay are placed on top of other objects. The elements that are rendered on this
overlay by default include:
labels for bodies of water
labels for islands
labels for mountains
labels for national parks
labels for desert
labels for glaciers
labels for woodlands
labels for beaches
labels for industrial areas
labels for buildings
labels for addresses
labels and icons for venue POIs
arrow indicating user location
HERE Android SDK Developer's Guide
Supplemental Information
221
Development Tips
This section provides tips on building your application using the HERE Android SDK.
Logging the HERE SDK Version
For troubleshooting purposes, we recommend that you add the HERE SDK
version number in your application logs. You can get the SDK version by calling
com.here.android.mpa.common.Version.getSdkVersion().
Upgrading from Older Versions of HERE SDK
The HERE Android SDK is now packaged as an Android archive (AAR) file instead of separate JAR, native
library and proguard components. If you are upgrading from an older HERE SDK release, the old components
should be cleaned up before integrating the AAR version of the HERE SDK. To do so, follow these steps:
1. Ensure the HERE-sdk.jar file is removed from your project and the compile entry is removed from
your build.gradle file. The JAR may be located at app/libs/HERE-sdk.jar and included in your
build.gradle file one of the following:
compile files('libs/HERE-sdk.jar')
compile fileTree(dir: 'libs', include: ['*.jar'])
Note that if you were previously using the Google GSON library with the HERE SDK, it is still required to
be included separately.
2. Remove the HERE SDK proguard file and the proguard entry specific to the HERE SDK from the
build.gradle file. The file to remove is named proguard-here-sdk.txt, and the entry of the
same name should also be removed from the proguardFiles property in your build.gradle file.
The proguard instructions for newer versions of the HERE SDK are now applied automatically and are
included in the AAR.
3. Ensure all HERE SDK related native libraries are removed from your project. These files are now a part of
the AAR file and do not need to be included separately. To locate these native libraries, check the app/
src/main/jniLibs/armeabi-v7a folder in your project. If you are not using other standalone native
libraries in your project, you can delete the entire armeabi-v7a folder. A list of the HERE SDK native
libraries, as of SDK release 3.2.2, is:
libCertResourcesPkg.so
libcrypto_here.so
libgnustl_shared.so
libLohitIndicFontPkg.so
libMapsEngineResourcePkg.so
libMAPSJNI.so
libNanumGothicFontPkg.so
libNlpResourcePkg.so
libos_adaptation.context.so
libos_adaptation.network.so
libposclient.so
libPositioningResourcePkg.so
HERE Android SDK Developer's Guide
Supplemental Information
222
libPureArabicFontPkg.so
libPureChineseFontPkg.so
libPureIndicSouthFontPkg.so
libPureThaiFontPkg.so
libSdkResourcePkg.so
libssl_here.so
You can find further info on integrating the AAR version of the HERE SDK into your app in the Run the
Sample Application on page 13 section of the User Guide and the associated HERE-sdk/tutorial/
BasicMapSolution/app/build.gradle file.
Troubleshooting SDK Initialization Errors
If you receive OnEngineInitListener.FILE_RW_ERROR or OnEngineInitListener.UNKNOWN when
trying to initialize the SDK, it can be due to file system corruption or resource locking on the device. You
can usually resolve this issue by restarting the device. If this is not practical, another option is to set a new
isolated disk cache location using the method outlined in Using an Isolated Map Disk Cache with the Map
Service.
If your app users are encountering this issue frequently, check whether your intended disk cache location is
writable using standard Java APIs before setting it for the HERE SDK. If the location is not writable, set it to a
different location which is writable.
Updating Map Data Without Using MapLoader
You can use the MapLoader to check and perform map data updates. However, if your application does not
use MapLoader, you can periodically update map data by deleting the application map data cache located
at the following location:
/sdcard/.here-maps/diskcache-v5/BundleStore
Deleting this cache forces the HERE SDK to download the latest map data.
"Disk Cleaner" Applications
Third-party memory cleaner apps may randomly delete files that are required by the HERE SDK. These apps
may cause problems such as:
Deletion of the SSL certificates, causing network connections and map data downloads to fail
Unintended deletion of the map data cache
It is recommended for users to disable these types of apps while using an app that uses the HERE SDK.
Lapsed Listeners and Garbage Collection
The HERE SDK provides a number of listener interfaces, such as Map.OnSchemeChangedListener,
Map.OnTransformListener, and MapGesture.OnGestureListener. To use these listeners, you are
required to implement and create a listener instance, then register it with another object (using a method
such as addSchemeChangedListener()) to receive event notifications. Unfortunately, this coding pattern
can also lead to the lapsed listener problem, where available memory is consumed by listener objects that
are not explicitly unregistered and not garbage collected.
HERE Android SDK Developer's Guide
Supplemental Information
223
To mitigate this problem, the HERE SDK, in some cases, accepts listener objects in WeakReference
containers. This has the advantage of avoiding lapsed listeners, but it also means that you must be aware of
registered listeners becoming garbage collected. To avoid any unintended issues with this coding pattern, be
sure to retain a strong reference to your listener instances (for example, by assigning it to a class variable) if
you would like to manage its garbage collection lifecycle. Listener objects are not garbage collected as long
as a strong reference exists.
Working with Getters
Classes in the HERE SDK return copies of objects in its getters. For example, MapPolyline.getPolyline()
does not return the same GeoPolyline instance that was used to construct the MapPolyline object;
instead, a copy of the GeoPolyline is returned. Since this returned object is a copy, you cannot dynamically
modify the MapPolyline instance by modifying this object. If you would like to make changes to
MapPolyline, you must call setGeoPolyline(GeoPolyline) instead.
Map Object Limitations
The HERE SDK does not limit the number of map markers, polygons, and polylines that can be added to
a map. However, rendering a large number of map objects can cause performance degradation in your
application. It is recommended that you use techniques such as viewport clipping and marker clustering to
avoid these issues.
Rendering Issue with Extruded Buildings
Devices using the MediaTek MT65XX or PowerVR SGX 5*MP* chipset family have a known GPU shader error
where the rendering of extruded buildings causes flickers of random colors. It is advised to turn off extruded
building rendering on these devices. For example:
private OnMapRenderListener m_renderListener = new OnMapRenderListener() {
@Override
public void onPreDraw() {
String renderer = GLES20.glGetString(GLES20.GL_RENDERER);
if(renderer.contains("PowerVR SGX 544MP"))
{
map.setExtrudedBuildingsVisible(false);
}
}
@Override
public void onPostDraw(boolean invalidated, long renderTime) {
}
@Override
public void onSizeChanged(int width, int height) {
}
@Override
public void onGraphicsDetached() {
}
};
For more information, see the Map.setExtrudedBuildingsVisible(boolean) API Reference.
HERE Android SDK Developer's Guide
Supplemental Information
224
Doze and App Standby
If you are using Android 6.0 (API level 23) or above, be aware that the Doze and App Standby features may
impact your HERE SDK app by disabling network access when the device is unplugged, stationary, and has the
screen off for a period of time. While the HERE Android SDK has the ability to work offline, you should design
your app with these operating system features in mind.
For more information about Doze and App Standby, including how to use notifications and whitelisting to
ensure your app functions properly, see the Android article, "Optimizing for Doze and App Standby".
Native Libraries and ABI Splits
Your app may encounter an error if it also includes other dependencies that have unsupported ABIs. To get
around this issue, enable ABI splits to only build for the armeabi-v7a architecture explicitly by modifying
your app's build.gradle file:
android {
(...)
splits {
abi {
enable true
reset()
include 'armeabi-v7a'
universalApk false
}
}
(...)
}
For more information about the splits Gradle block, see Configure multiple APKs for ABIs in the Android
Studio User Guide.
Signpost Parsing
This section provides guidelines on how to use the HERE Mobile SDK Signpost object to present visual
maneuver instructions which match with the audible voice instruction during turn-by-turn guidance. While
the high-level guidelines in this section are applicable to both the HERE Android and iOS SDKs, the detailed
descriptions are generic and do refer to the specific APIs available on either platform.
Signs represent textual and graphic information posted along roads. The information is always represented
as text, but may originate from a graphical icon. Signpost information may be used for route guidance
(both audible and visual guidance) and map display. A navigation system may prefer using the signpost text
rather than the street/ramp name as the latter may not always match what is on the sign in reality and may
confuse a user. The signpost feature supports the user navigating through complex situations and provides
a conformation for a maneuver by presenting the same direction information as shown on the street signs in
reality.
Signpost Content
The Signpost representation is an association between two links, the “From link” and the “To link”. They
are not necessarily contiguous. The “From link” is the link prior to a maneuver decision point. A maneuver
HERE Android SDK Developer's Guide
Supplemental Information
225
decision is a point where the road splits and the driver is unable to determine the direction to traverse. The
“To link” is the link traversed after the decision point.
Note: Not all maneuvers contain Signpost information.
Based on the map attributes, the HERE Mobile SDKs aggregate the following information into a Signpost
object:
Exit number
Exit text
Exit icon
Exit directions
Foreground / Background color
Exit directions is an array of information shown on the sign and can contain the following information:
Language i.e. the three letter MARC code for the label language
Route direction
Route name
Text representing auxiliary information. Typically the auxiliary information contains a destination name
such as a city or a characteristic place (such as "airport").
Each index in the exit directions array will typically contain only one of Route direction, Route name and
Text. Since the origin data is not always consistent it is advisable to concatenate the route name and route
direction fields.
Parsing Basic Signpost Information
To present an audible or visual maneuver instruction, information from the Maneuver and Signpost objects
can be combined as shown in the figure below:
Figure 78: Parsing for audible instructions for a basic sign
HERE Android SDK Developer's Guide
Supplemental Information
226
Not all exit direction information presented on the real signpost might be relevant to the user’s route. In
order to avoid a flood of information, which easily could lead to confusion, especially for the voice output,
exit directions information which is irrelevant for a driver’s route may be suppressed.
To achieve this, the signpost information of the next maneuver and the next-next maneuver can be
compared and only the exit direction information valid for both maneuvers may be presented for the next
maneuver. An example of this is shown in the figure below.
Figure 79: Filtering out exit directions information
There may be some cases where there is no matching exit direction information in the next maneuver and
the next-next maneuver. In this case the recommendation is to present the first index in the exit directions
array of the next maneuver.
HERE Android SDK Developer's Guide
Coverage Information
227
Chapter 5
Coverage Information
Topics:
Downloadable Maps by Count...
Map Label Languages
Navigation Voices
Safety Camera Coverage
The following list provides coverage information for HERE Android
SDK features. Feature support in the HERE SDK may differ depending
on the language and locale.
Street level
Public Transit
Traffic
Routing
Venue Maps
Guidance
Point Address (such as house numbers)
Online Geocoding / Reverse Geocoding
Online Places and Search
Satellite Imagery: Worldwide
HERE Android SDK Developer's Guide
Coverage Information
228
Downloadable Maps by Country/Region
The following countries and regions have downloadable maps:
• Africa
• Albania
• Algeria
• Andorra
• Angola
• Argentina
• Aruba
• Asia
• Australia
• Australia/Oceania
• Austria
• Azerbaijan
• Bahamas
• Bahrain
• Bangladesh
• Belarus
• Belgium
• Belize
• Benin
• Bermuda
• Bolivia
Bosnia and Herzegovina
• Botswana
• Brazil
• Brunei
• Bulgaria
Burkina Faso
• Burundi
• Cameroon
• Canada
Cape Verde
Cayman Islands
Central African Republic
• Chad
HERE Android SDK Developer's Guide
Coverage Information
229
• Chile
• Colombia
• Comoros
Congo (Republic),
Congo (Zaire),
Costa Rica
Cote d'Ivoire
• Croatia
• Cuba
• Cyprus
Czech Republic
• Denmark
• Djibouti
Dominican Republic
• Ecuador
• Egypt
El Salvador
Equatorial Guinea
• Eritrea
• Estonia
• Ethiopia
• Europe
• Fiji
• Finland
• France
• Gabon
• Gambia
• Georgia
• Germany
• Ghana
• Gibraltar
• Greece
• Guatemala
• Guinea
• Guinea-Bissau
• Guyana
• Honduras
Hong Kong and Macau
• Hungary
HERE Android SDK Developer's Guide
Coverage Information
230
• Iceland
• India
• Indonesia
• Iran
• Iraq
• Israel
• Italy
• Jamaica
• Jordan
• Kazakhstan
• Kenya
• Kuwait
• Latvia
• Lebanon
• Lesotho
• Liberia
• Libya
• Liechtenstein
• Lithuania
• Luxembourg
• Madagascar
• Malawi
• Malaysia
• Maldives
• Mali
• Malta
• Mauritania
• Mauritius
• Mayotte
• Mexico
• Monaco
• Montenegro
• Morocco
• Mozambique
• Namibia
• Nepal
• Netherlands
New Zealand
• Nicaragua
HERE Android SDK Developer's Guide
Coverage Information
231
• Niger
• Nigeria
North and Central America
• Norway
• Oman
• Panama
• Paraguay
• Peru
• Philippines
• Poland
• Portugal
• Qatar
Republic of Ireland
Republic of Moldova
• Romania
• Russia
• Rwanda
Saint Helena
Saint Kitts and Nevis
Saint Vincent and the Grenadines
San Marino
Sao Tome and Principe
Saudi Arabia
• Senegal
• Serbia
• Seychelles
Sierra Leone
• Singapore
• Slovakia
• Slovenia
• Somalia
South Africa
South America
• Spain
Sri Lanka
• Suriname
• Swaziland
• Sweden
• Switzerland
HERE Android SDK Developer's Guide
Coverage Information
232
• Taiwan
• Tanzania
• Thailand
The Former Yugoslav Republic of Macedonia
• Togo
Trinidad and Tobago
• Tunisia
• Turkey
• Uganda
• Ukraine
United Arab Emirates
United Kingdom
• Uruguay
• USA
Vatican City
• Venezuela
• Vietnam
Virgin Islands
• World
• Yemen
• Zambia
• Zimbabwe
Map Label Languages
The HERE Android SDK is a globally-available product with support for many languages. The HERE SDK does
not require any actions from developers to set the appropriate language, as it automatically detects the
current device language setting and applies the same language within the SDK, if it is supported. If the HERE
SDK does not support the device language, a fallback language, which is typically English, is used.
Map labels at the street level are always displayed in the local language. For example, Central Park in
Manhattan, New York is always displayed as "Central Park" irrespective of the device language setting.
Names for states, provinces, regions, cities, mountains, lakes, and rivers, may be localized to the language
corresponding to the device language setting. For example, where the device language is set to French, the
label for South Carolina reads "Caroline du Sud"; if the device language is set to Spanish, the label for New
York reads "Neuva York".
Language Language code Marc code mapping Note
English (UK) EN ENG
French FR FRE
German GE GER
HERE Android SDK Developer's Guide
Coverage Information
233
Language Language code Marc code mapping Note
Spanish SP SPA
Italian IT ITA
Swedish SW SWA
Danish DA DAN
Norwegian NO NOR
Finnish FI FIN
English American AM ENG Mapped to ENG
Swiss French SF FRE Mapped to FRE
Swiss German SG GSW Mapped to GER
Portuguese PO POR
Turkish TU TUR
Icelandic IC ICE
Russian RU RUS
Hungarian HU HUN
Dutch DU DUT
Flemish Belgian BL DUT Mapped to DUT
Australian AU ENG Mapped to ENG
Belgian French BF FRE Mapped to FRE
Austrian AS GER Mapped to GER
New Zealand NZ ENG Mapped to ENG
French International IF FRE Mapped to FRE
Czech CS CZE
Slovak SK SLO
Polish PL POL
Slovenian SL SLV
Chinese Taiwan TC CHT
Hong Kong Chinese HK CHT
Chinese PRC ZH CHI
Japanese JA JPN
Thai TH THA
Afrikaans AF AFR
Arabic AR ARA
Bulgarian BG BUL
Catalan CA CAT
Croatian HR SCR
Canadian English CE ENG Mapped to ENG
HERE Android SDK Developer's Guide
Coverage Information
234
Language Language code Marc code mapping Note
English International IE ENG Mapped to ENG
South African English SA ENG Mapped to ENG
Estonian ET EST
French Canadian CF FRE Mapped to FRE
Greek EL GRE
Greek (Cyprus) CG GRE Mapped to GRE
Hebrew HE HEB
Hindi HI HIN
Indonesian IN IND
Swiss Italian SZ ITA Mapped to ITA
Latvian LV LAV
Lithuanian LT LIT
Malay MS MAY
Marathi MR MAR
Norwegian Nynorsk NN NOR
Brazilian Portuguese BP POR Mapped to POR
Romanian RO RUM
Serbian SR SRP
International Spanish OS SPA Mapped to SPA
Latin American Spanish LS SPA Mapped to SPA
Finland Swedish FS SWE Mapped to SWE
Cyprus Turkish CT TUR Mapped to TUR
Ukrainian UK UKR
Urdu UR URD
Vietnamese VI VIE
Basque BA BAQ
Malay as appropriate for use in Asia-Pacific regions. MA MAY Mapped to ENG
Navigation Voices
The HERE Android SDK supports navigation voices in the following languages, in either text-to-speech or pre-
recorded format.
Pre-recorded voices support spoken maneuver instructions.
Text-to-speech voices, which are also known as speech synthesis voices, support spoken maneuver
instructions and street names.
HERE Android SDK Developer's Guide
Coverage Information
235
Table 12: Supported Navigation Voices
Text-to-Speech
English (US)
English (UK)
French (France)
French (Canada)
• German
Spanish (Spain)
Spanish (Mexico)
• Indonesian
• Italian
• Japanese
• Norwegian
Portugese (Portugal)
Portugese (Brazil)
• Russian
• Swedish
• Finnish
• Danish
• Korean
Chinese (Taiwanese Mandarin)
• Turkish
• Czech
• Polish
Note: This is a list of the potential languages that are supported. Actual audio playback depends on the TTS engine that is
installed on the user's device.
HERE Android SDK Developer's Guide
Coverage Information
236
Pre-recorded
English (UK) - Female
English (US) - Male
English (UK) - Male
Portuguese (Portugal) - Female
Turkish - Female
Icelandic - Female
• Indonesian
Russian - Female
Hungarian - Female
Hungarian - Male
Dutch - Female
Dutch - Male
French - Female
Czech - Female
Slovak - Female
Polish - Female
Slovenian - Female
Mandarin (Taiwan) - Female
German - Female
Cantonese - Female
Mandarin (China) - Female
German - Male
Thai - Male
Afrikaans - Female
Arabic (North African) - Female
Arabic (Saudi Arabia) - Male
Tagalog - Female
Spanish (Spain) - Female
Basque - Female
Galician - Female
Spanish (Latin America) - Female
Bulgarian - Female
Catalan - Female
Croatian - Female
Estonian - Female
Italian - Female
Farsi - Female
French (Canada) - Female
Greek - Female
Hindi - Female
Indonesian - Male
Swedish - Female
Korean (South Korea) -Female
Latvian - Female
Lithuanian - Female
Danish - Female
Malay - Female
Portuguese (Brazil) - Female
Romanian - Female
Serbian - Male
Norwegian - Female
Spanish (Mexico) - Male
Swahili - Male
Tamil - Male
Finnish - Female
Finnish - Male
Ukrainian - Female
Urdu - Female
Vietnamese - Female
Safety Camera Coverage
The following table indicates the safety camera coverage in the indicated countries.
Table 13: Safety Camera Coverage
Country or Region 2017 Q2
Andorra 13
Argentina 549
HERE Android SDK Developer's Guide
Coverage Information
237
Country or Region 2017 Q2
Australia 1397
Austria 660
Belgium 1675
Bosnia and Herzegovina 14
Brazil 15953
Bulgaria 44
Canada 639
Chile 75
Czech Republic 220
Estonia 61
Finland 799
Hungary 26
Iceland 17
Italy 3766
Kazakhstan 937
Kuwait 353
Latvia 21
Lithuania 169
Malaysia 405
Netherlands 1220
New Zealand 126
Norway 328
Poland 555
Portugal 46
Qatar 389
Romania 96
Russia 9632
Saudi Arabia 3510
Singapore 224
HERE Android SDK Developer's Guide
Coverage Information
238
Country or Region 2017 Q2
Slovakia 13
Slovenia 41
South Africa 554
Spain 1144
Sweden 1465
Taiwan 2716
Thailand 87
United Arab Emirates 1044
United Kingdom 5408
United States 4949
HERE Android SDK Developer's Guide
API Reference
239
Chapter 6
API Reference
Topics:
ar
cluster
common
customlocation2
electronic_horizon
fce
guidance
mapping
nlp
odml
pde
routing
search
service
streetlevel
tce
urbanmobility
venues3d
The HERE SDK for Android allows you to add HERE Maps, Routing
and Search functionality to your Android applications. The following
pages provide a detailed reference to the packages and classes that
make up the SDK.
Open Source Software Notices
If you use the HERE Android SDK in your application, you must
embed or link to the HERE copyright and various open source
software licenses. You can find a copy of these licenses in the SDK
Release Notes, or in the [SDK package]/copyright.txt file.
HERE Android SDK Developer's Guide
API Reference
240
ar
The package ar is a member of com.here.android.mpa.
Package Summary
ar
The AR package provides classes, interfaces and enumerations for displaying LiveSight and customizing the
experience.
Package Details
The AR package provides classes, interfaces and enumerations for displaying LiveSight and customizing the
experience.
Some key classes and interfaces in this package are:
CompositeFragment
ARController
ARIconObject
CompositeFragment
The CompositeFragment class is a UI fragment that can be embedded into an activity to render both the Map
and LiveSight. It is composite because it provides Map functionality (such as that provided by MapFragment)
as well as LiveSight functionality. The fragment can be embedded as follows:
<fragment
class="com.here.android.mpa.ar.CompositeFragment"
android:id="@+id/compositefragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
The ARController can be retrieved from the CompositeFragment by way of the getARController() API.
ARController
The ARController serves as a facade for LiveSight functionality. It contains methods and callbacks for
controlling and customizing LiveSight behavior. Some key APIs are:
start() - Start LiveSight, transition from Map mode to LiveSight mode
stop() - Stop LiveSight, transition from LiveSight mode to Map mode
addARObject(ARObject) - Add content to LiveSight
press(PointF) - Return ARObject at PointF and render to simulate pressing
ARIconObject
The ARIconObject is a concrete ARObject which represents the LiveSight object model. It is composed of
Front, Down and Back icons, an info icon and a GeoCoordinate representing the objects position.
HERE Android SDK Developer's Guide
API Reference
241
For more information on using this feature, please consult the "LiveSight" section in the HERE SDK for
Android Developer's Guide.
ARBillboardObject
The class ARBillboardObject is a member of com.here.android.mpa.ar .
Class Summary
public class ARBillboardObject
extends com.here.android.mpa.ar.ARModelObject, java.lang.Object
Represents a 3D AR billboard objects that users can add to a ARController.
[For complete information, see the section Class Details]
Nested Class Summary
Table 14: Nested Classes in ARBillboardObject
Nested Classes
public static final enumeration ARBillboardObject.Orientation
Represents billboard's orientation mode
Constructor Summary
Table 15: Constructors in ARBillboardObject
Constructors
ARBillboardObject (Vector3f position)
Construct AR billboard object
ARBillboardObject (GeoCoordinate position)
Construct AR billboard object
ARBillboardObject (Vector3f position, Image texture)
Construct AR billboard object
ARBillboardObject (GeoCoordinate position, Image texture)
Creates a geo positioned ARBillboardObject
Method Summary
Table 16: Methods in ARBillboardObject
Methods
public GeoCoordinate getGeoPosition ()
Get the position of the billboard
HERE Android SDK Developer's Guide
API Reference
242
Methods
public Vector3f getLocalPosition ()
Get the position of the billboard
public Orientation getOrientation ()
Get the orientation mode of the billboard
public PointF getSize ()
Get the size of the billboard in meters
public Vector3f getSurfaceNormal ()
Get the surface normal
public Vector3f getUpDirection ()
Get the up direction
public void setGeoPosition (GeoCoordinate position)
Set the position of the billboard
public void setLocalPosition (Vector3f position)
Set the position of the billboard
public void setOrientation (Orientation orientation)
Set the orientation mode of the billboard
public void setSize (PointF size)
Set the size of the billboard in meters
public void setSurfaceNormal (Vector3f surfaceNormal)
Set the surface normal
public void setUpDirection (Vector3f upDirection)
Set the up direction
Class Details
Represents a 3D AR billboard objects that users can add to a ARController. There are two types of AR
billboard objects supported: - Geo positioned billboard - Locally positioned billboard
Constructor Details
ARBillboardObject (Vector3f position)
Construct AR billboard object
Parameters:
position
Position of the center of the billboard relative to the camera. Unit is meters
ARBillboardObject (GeoCoordinate position)
HERE Android SDK Developer's Guide
API Reference
243
Construct AR billboard object
Parameters:
position
Geo position of the center of the billboard
ARBillboardObject (Vector3f position, Image texture)
Construct AR billboard object
Parameters:
position
Position of the center of the billboard relative to the camera. Unit is meters
texture
Billboard's texture
ARBillboardObject (GeoCoordinate position, Image texture)
Creates a geo positioned ARBillboardObject
Parameters:
position
Position on earth of the center of the billboard
texture
Billboard's texture
Method Details
public GeoCoordinate getGeoPosition ()
Get the position of the billboard
Returns:
Position on earth of the center of the billboard
public Vector3f getLocalPosition ()
Get the position of the billboard
Returns:
Position of the center of the billboard relative to the camera. Unit is meters
public Orientation getOrientation ()
HERE Android SDK Developer's Guide
API Reference
244
Get the orientation mode of the billboard
Returns:
Orientation mode
public PointF getSize ()
Get the size of the billboard in meters
Returns:
Size in meters (width, height)
public Vector3f getSurfaceNormal ()
Get the surface normal
Returns:
Surface normal
public Vector3f getUpDirection ()
Get the up direction
Returns:
Up direction
public void setGeoPosition (GeoCoordinate position)
Set the position of the billboard
Parameters:
position
Position on earth of the center of the billboard
public void setLocalPosition (Vector3f position)
Set the position of the billboard
Parameters:
position
Position of the center of the billboard relative to the camera. Unit is meters
public void setOrientation (Orientation orientation)
Set the orientation mode of the billboard
HERE Android SDK Developer's Guide
API Reference
245
Parameters:
orientation
Orientation mode
public void setSize (PointF size)
Set the size of the billboard in meters
Parameters:
size
Size in meters (width, height)
public void setSurfaceNormal (Vector3f surfaceNormal)
Set the surface normal
Parameters:
surfaceNormal
Surface normal
public void setUpDirection (Vector3f upDirection)
Set the up direction
Parameters:
upDirection
Up direction
Orientation
The enumeration Orientation is a member of com.here.android.mpa.ar.ARBillboardObject.
Enumeration Summary
public static final enumeration ARBillboardObject.Orientation
extends java.lang.Enum, java.lang.Object
Represents billboard's orientation mode
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
246
Enum Constant Summary
Table 17: Enum Constants in Orientation
Fields
public static final Orientation FIXED
Orientation is fixed, set explicitly using normal and up vectors
public static final Orientation BILLBOARD
Billboard is oriented towards camera
Method Summary
Table 18: Methods in Orientation
Methods
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARBillboardObject.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents billboard's orientation mode
Enum Constant Details
public static final Orientation FIXED
Orientation is fixed, set explicitly using normal and up vectors
public static final Orientation BILLBOARD
Billboard is oriented towards camera
Method Details
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
247
public static ARBillboardObject.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ARBuildingInfo
The class ARBuildingInfo is a member of com.here.android.mpa.ar .
Class Summary
public class ARBuildingInfo
extends java.lang.Object
This class encapsulates information about a building on the map.
[For complete information, see the section Class Details]
Method Summary
Table 19: Methods in ARBuildingInfo
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public float getHeight ()
Gets building height.
public Identifier getIdentifier ()
Gets the Identifier of the building.
public Location getLocation ()
Returns the object's location.
public String getPlaceName ()
Gets the name of the MapBuildingObject.
public GeoCoordinate getPosition ()
Gets the position of the MapBuildingObject
public Vector3f getSelectedFacadeNormal ()
Gets selected facade's normal.
public GeoCoordinate getSelectedFacadeNormalOrigin ()
Gets origin of the selected facade's normal.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
248
Class Details
This class encapsulates information about a building on the map.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public float getHeight ()
Gets building height.
Returns:
Building height in meters.
public Identifier getIdentifier ()
Gets the Identifier of the building. The identifier can be matched against results in PlaceLink
Returns:
Identifier id of the building
public Location getLocation ()
Returns the object's location.
Returns:
Building Location
public String getPlaceName ()
Gets the name of the MapBuildingObject. This information is only available in 3D Landmarks.
Returns:
Name of the landmark
public GeoCoordinate getPosition ()
HERE Android SDK Developer's Guide
API Reference
249
Gets the position of the MapBuildingObject
Returns:
GeoCoordinate position of the building
public Vector3f getSelectedFacadeNormal ()
Gets selected facade's normal.
Returns:
Normal of the selected facade.
public GeoCoordinate getSelectedFacadeNormalOrigin ()
Gets origin of the selected facade's normal.
Returns:
Geo-coordinate of the facade's origin.
public int hashCode ()
For documentation, see java.lang.Object
ARController
The class ARController is a member of com.here.android.mpa.ar .
Class Summary
public final class ARController
extends java.lang.Object
The ARController class serves as a facade for LiveSight functionality.
[For complete information, see the section Class Details]
Nested Class Summary
Table 20: Nested Classes in ARController
Nested Classes
public static final class ARController.CameraParams
Encapsulates parameters which affect the device camera.
public final class ARController.DownViewParams
Encapsulates parameters which affect the Down view.
HERE Android SDK Developer's Guide
API Reference
250
Nested Classes
public static final enumeration ARController.Error
AR Error codes
public final class ARController.ExternalSensors
Encapsulates functionality to replace integrated sensors(all or selected) data feeds with external ones.
public final class ARController.FilterParams
Encapsulates parameters which affect data filtering.
public final class ARController.IconParams
Encapsulates parameters which affect the icons of an ARObject.
public final class ARController.InfoParams
Encapsulates parameters which affect the info of an ARObject.
public static final enumeration ARController.IntroAnimationMode
Intro animation mode.
public final class ARController.IntroAnimationParams
Encapsulates parameters which affect the Intro Animation.
public static abstract interface ARController.OnCameraEnteredListener
Listener for Camera view entered event.
public static abstract interface ARController.OnCameraExitedListener
Listener for Camera view exited event.
public static abstract interface ARController.OnCompassCalibrationChangedListener
Listener for compass calibration changed event.
public static abstract interface ARController.OnLivesightStatusListener
Monitor overall livesight status.
public static abstract interface ARController.OnMapEnteredListener
Listener for Map view entered event.
public static abstract interface ARController.OnMapExitedListener
Listener for Map view exited event.
public static abstract interface ARController.OnObjectTappedListener
Listener for object tap events.
public static abstract interface ARController.OnPanListener
Listener for pan events.
public static abstract interface ARController.OnPitchFunction
Pitch function interface.
public static abstract interface ARController.OnPoseListener
Listener for pose update events.
HERE Android SDK Developer's Guide
API Reference
251
Nested Classes
public static abstract interface ARController.OnPostPresentListener
Listener for the post draw event.
public static abstract interface ARController.OnPreDrawListener
Listener for the livesight frame pre draw event.
public static abstract interface ARController.OnPreDrawMapListener
Listener for the map pre draw event.
public static abstract interface ARController.OnPrePresentListener
Listener for the pre present event.
public static abstract interface ARController.OnProjectionCameraUpdatedListener
Monitor livesight projection camera.
public static abstract interface ARController.OnRadarUpdateListener
Listener for radar update events.
public static abstract interface ARController.OnSensorCalibrationChangedListener
Listener for sensor calibration events.
public static abstract interface ARController.OnTapListener
Listener for tap events.
public static abstract interface ARController.OnTouchDownListener
Listener for touch down events.
public static abstract interface ARController.OnTouchUpListener
Listener for touch up events.
public static final enumeration ARController.ProjectionType
Type of the projection used by the LiveSight engine while displaying ARObjects in the camera/UP view.
public final class ARController.SelectedItemParams
Encapsulates parameters which affect ARObjects which are in the selected or non selected states.
public static final enumeration ARController.SensorType
Type of sensors used by the LiveSight engine.
public final class ARController.UpViewParams
Encapsulates parameters which affect the Up view.
public final class ARController.UpViewTransitionParams
Encapsulates parameters which affect the Up view transition.
public static final enumeration ARController.ViewType
List of all views available in LiveSight
HERE Android SDK Developer's Guide
API Reference
252
Field Summary
Table 21: Fields in ARController
Fields
public static final CameraParams CameraParams
Accessor for ARController.CameraParams instance.
public final DownViewParams DownViewParams
Accessor for ARController.DownViewParams instance.
public final ExternalSensors ExternalSensors
ARController external sensors interface
public final FilterParams HeadingFilterParams
Accessor for ARController.FilterParams instance which affects Heading.
public final IconParams IconParams
Accessor for ARController.IconParams instance.
public final InfoParams InfoParams
Accessor for ARController.InfoParams instance.
public final IntroAnimationParams IntroParams
Accessor for ARController.IntroAnimationParams instance.
public final FilterParams PitchFilterParams
Accessor for ARController.FilterParams instance which affects Pitch.
public final SelectedItemParams SelectedItemParams
Accessor for ARController.SelectedItemParams instance.
public final UpViewParams UpViewParams
Accessor for ARController.UpViewParams instance.
public final UpViewTransitionParams UpViewTransitionParams
Accessor for ARController.UpViewTransitionParams instance.
public final FilterParams ZoomFilterParams
Accessor for ARController.FilterParams instance which affects Zoom.
Method Summary
Table 22: Methods in ARController
Methods
public void addARObject (ARObject arObject)
Add an ARObject that will be displayed in the Camera and Map view.
public void addARObject (ARPolylineObject arPolyObject)
Add an ARPolylineObject that will be displayed in the Camera view.
HERE Android SDK Developer's Guide
API Reference
253
Methods
public void addARObject (ARModelObject arViewObject)
Add an ARModelObject that will be displayed in the Camera view.
public void addOnCameraEnteredListener (OnCameraEnteredListener listener)
Adds a ARController.OnCameraEnteredListener to this ARController to listen for the event triggered when Camera view is
entered.
public void addOnCameraExitedListener (OnCameraExitedListener listener)
Adds a ARController.OnCameraExitedListener to this ARController to listen for the event triggered when Camera view is
exited.
public void addOnCompassCalibrationChangedListener (OnCompassCalibrationChangedListener listener)
Adds a ARController.OnCompassCalibrationChangedListener to this ARController to listen for compass calibration
changed events.
public void addOnLivesightStatusListener (OnLivesightStatusListener listener)
Adds a ARController.OnLivesightStatusListener to this ARController to listen for livesight status notification.
public void addOnMapEnteredListener (OnMapEnteredListener listener)
Adds a ARController.OnMapEnteredListener to this ARController to listen for the event triggered when Map view is
entered.
public void addOnMapExitedListener (OnMapExitedListener listener)
Adds a ARController.OnMapEnteredListener to this ARController to listen for the event triggered when Map view is exited.
public void addOnObjectTappedListener (OnObjectTappedListener listener)
Adds a ARController.OnObjectTappedListener to this ARController to listen for object tap events.
public void addOnPanListener (OnPanListener listener)
Adds a ARController.OnPanListener to this ARController to listen for pan events.
public void addOnPoseListener (OnPoseListener listener)
Adds a ARController.OnPoseListener to this ARController to listen for pose update events.
public void addOnPostPresentListener (OnPostPresentListener listener)
Adds a ARController.OnPostPresentListener to this ARController to listen for the event triggered after a draw is being
performed.
public void addOnPreDrawListener (OnPreDrawListener listener)
Adds a ARController.OnPreDrawListener to this ARController to listen for the event triggered before the livesight frame is
being drawn.
public void addOnPreDrawMapListener (OnPreDrawMapListener listener)
Adds a ARController.OnPreDrawMapListener to this ARController to listen for the event triggered before the map is being
drawn.
public void addOnPrePresentListener (OnPrePresentListener listener)
Adds a ARController.OnPrePresentListener to this ARController to listen for the event triggered before a draw is being
performed.
HERE Android SDK Developer's Guide
API Reference
254
Methods
public void addOnProjectionCameraUpdatedListener (OnProjectionCameraUpdatedListener listener)
Adds a ARController.OnProjectionCameraUpdatedListener to this ARController to listen for livesight projection camera
change notification.
public void addOnRadarUpdateListener (OnRadarUpdateListener listener)
Adds a ARController.OnRadarUpdateListener to this ARController to listen for radar update events.
public void addOnSensorCalibrationChangedListener (OnSensorCalibrationChangedListener listener)
Adds a ARController.OnSensorCalibrationChangedListener to this ARController to listen for sensor calibration changed
events.
public void addOnTapListener (OnTapListener listener)
Adds a ARController.OnTapListener to this ARController to listen for tap events.
public void addOnTouchDownListener (OnTouchDownListener listener)
Adds a ARController.OnTouchDownListener to this ARController to listen for touch down events.
public void addOnTouchUpListener (OnTouchUpListener listener)
Adds a ARController.OnTouchUpListener to this ARController to listen for touch up events.
public void defocus ()
Defocus previously focused ARObject.
public void depress (ARObject arObject)
Depress previously pressed ARObject.
public void focus (ARObject arObject)
Focus an ARObject.
public boolean geoTo3dPosition (GeoCoordinate geoPosition, Vector3f position)
Convert a geo position into a 3d space position
public int getAccelerometerCalibrationStatus ()
Get the accelerometer calibration status.
public float getCompassAccuracy ()
Get compass accuracy in degrees.
public int getCompassCalibrationStatus ()
Get the compass calibration status.
public float getFixedAltitude ()
Get fixed altitude of the livesight's view point.
public int getGyroscopeCalibrationStatus ()
Get the gyroscope calibration status.
public long getObjectId (ARObject arObject)
Get ARObjects unique identifier.
public java.util.List <ARObject> getObjects (PointF point)
Get a list of ARObjects at the specified screen point.
HERE Android SDK Developer's Guide
API Reference
255
Methods
public java.util.List <ARObject> getObjects (ViewRect rect)
Get a list of ARObjects which intersect the given ViewRect
public float getOcclusionOpacity ()
Get opacity of the occlusion items.
public ARPoseReading getPose ()
Get latest pose
public GeoCoordinate getPosition ()
Get the last known position.
public GeoCoordinate getPosition (AtomicBoolean mapMached)
Get the last known position with map matching indicator.
public ProjectionType getProjectionType ()
Get Camera view ARController.ProjectionType
public PointF getScreenViewPoint ()
Get target screen view point.
public long getSensorsWaitTimeout ()
Get sensors wait timeout in ms.
public int getUpdateDistanceDelta ()
Get the update distance delta.
public ViewType getViewType ()
Get enforced ARController.ViewType.
public boolean isOccluded (ARObject arObject)
Check if an ARObject is occluded by a building
public boolean isOcclusionEnabled ()
Check if occlusion is enabled.
public boolean isUsingAlternativeCenter ()
Checks to see if an alternative center is currently being used
public boolean isVisible (ARObject arObject)
Check if an ARObject is visible in the camera view.
public void pan (PointF from, PointF to)
Pans the Camera view from one specified on-screen android.graphics.PointF to another.
public void panTo (GeoCoordinate coordinate)
Pan the Camera view such that the GeoCoordinate passed as a parameter will be in the last location in the Front plane (i.e.
public boolean pixelTo3dPosition (float z, PointF screenPoint, Vector3f position)
Convert a screen point into a 3d space position
HERE Android SDK Developer's Guide
API Reference
256
Methods
public ARObject press (PointF point)
Press an ARObject.
public void press (ARObject arObject)
Press an ARObject.
public boolean removeARObject (ARObject arObject)
Remove an ARObject from the Camera and Map view.
public boolean removeARObject (ARPolylineObject arPolyObject)
Remove an ARPolylineObject from the Camera view.
public boolean removeARObject (ARModelObject arViewObject)
Remove an ARModelObject from the Camera view.
public void removeOnCameraEnteredListener (OnCameraEnteredListener listener)
Removes an existing ARController.OnCameraEnteredListener from this ARController .
public void removeOnCameraExitedListener (OnCameraExitedListener listener)
Removes an existing ARController.OnCameraExitedListener from this ARController .
public void removeOnCompassCalibrationChangedListener (OnCompassCalibrationChangedListener listener)
Removes an existing ARController.OnCompassCalibrationChangedListener from this ARController .
public void removeOnLivesightStatusListener (OnLivesightStatusListener listener)
Removes an existing ARController.OnLivesightStatusListener from this ARController.
public void removeOnMapEnteredListener (OnMapEnteredListener listener)
Removes an existing ARController.OnMapEnteredListener from this ARController .
public void removeOnMapExitedListener (OnMapExitedListener listener)
Removes an existing ARController.OnMapExitedListener from this ARController .
public void removeOnObjectTappedListener (OnObjectTappedListener listener)
Removes an existing ARController.OnObjectTappedListener from this ARController .
public void removeOnPanListener (OnPanListener listener)
Removes an existing ARController.OnPanListener from this ARController .
public void removeOnPoseListener (OnPoseListener listener)
Removes an existing ARController.OnPoseListener from this ARController .
public void removeOnPostPresentListener (OnPostPresentListener listener)
Removes an existing ARController.OnPostPresentListener from this ARController .
public void removeOnPreDrawListener (OnPreDrawListener listener)
Removes an existing ARController.OnPreDrawListener from this ARController .
public void removeOnPreDrawMapListener (OnPreDrawMapListener listener)
Removes an existing ARController.OnPreDrawMapListener from this ARController .
HERE Android SDK Developer's Guide
API Reference
257
Methods
public void removeOnPrePresentListener (OnPrePresentListener listener)
Removes an existing ARController.OnPrePresentListener from this ARController .
public void removeOnProjectionCameraUpdatedListener (OnProjectionCameraUpdatedListener listener)
Removes an existing ARController.OnProjectionCameraUpdatedListener from this ARController.
public void removeOnRadarUpdateListener (OnRadarUpdateListener listener)
Removes an existing ARController.OnRadarUpdateListener from this ARController .
public void removeOnSensorCalibrationChangedListener (OnSensorCalibrationChangedListener listener)
Removes an existing ARController.OnSensorCalibrationChangedListener from this ARController .
public void removeOnTapListener (OnTapListener listener)
Removes an existing ARController.OnTapListener from this ARController .
public void removeOnTouchDownListener (OnTouchDownListener listener)
Removes an existing ARController.OnTouchDownListener from this ARController .
public void removeOnTouchUpListener (OnTouchUpListener listener)
Removes an existing ARController.OnTouchUpListener from this ARController .
public void removePitchFunction ()
Removes an existing ARController.OnPitchFunction from this ARController.
public void select (ARObject arObject)
Select an ARObject.
public void select (ARObject arObject, boolean allowInfo, float scale)
Select an ARObject.
public void setAlternativeCenter (GeoCoordinate coordinate)
Set alternative to current GPS position to use for LiveSight.
public void setCompassAccuracy (float degrees)
Set compass accuracy in degrees.
public void setFixedAltitude (float altitude_m, boolean animate)
Set fixed altitude of the livesight's view point.
public void setInfoAnimationInUpViewOnly (boolean enable)
Choose the moment when INFO animation starts.
public void setMap (Map map)
Set Map to the ARController .
public void setOcclusionEnabled (boolean enable)
Enables or disables occlusion fading.
public void setOcclusionOpacity (float opacity)
Set opacity of the occlusion items.
HERE Android SDK Developer's Guide
API Reference
258
Methods
public void setOrientationAnimation (boolean enabled)
Enable/disable animation during orientation change.
public void setPitchFunction (OnPitchFunction function)
Adds a ARController.OnPitchFunction to this ARController to be able to override current device pitch.
public void setPlanesParameters (float frontNear, float frontFar, float backNear, float
backFar)
Set front and back planes parameters - screen height ratios (0..1f).
public void setProjectionType (ProjectionType type)
Set Camera view ARController.ProjectionType
public void setSensorsWaitTimeout (long timeout)
Set sensors wait timeout in ms.
public void setTapArea (int width, int height)
Sets the tap area width and height.
public void setUpdateDistanceDelta (int delta)
Sets the update distance delta for the items in the camera view.
public void setUseDownIconsOnMap (boolean useDownIcons)
Use Down icons in Map view in LiveSight
public void showFrontItemsOnly (boolean show)
Show only icons in the Front plane in Camera view.
public void showView (ViewType viewType)
Show(enforce) specified ARController.ViewType.
public Error start ()
Start AR
public Error stop (boolean withExitAnimation)
Stop AR
public void unselect ()
Unselect previously selected object.
Class Details
The ARController class serves as a facade for LiveSight functionality. It contains methods and callbacks
for controlling and customizing LiveSight behavior.
Field Details
public static final CameraParams CameraParams
Accessor for ARController.CameraParams instance.
HERE Android SDK Developer's Guide
API Reference
259
public final DownViewParams DownViewParams
Accessor for ARController.DownViewParams instance.
public final ExternalSensors ExternalSensors
ARController external sensors interface
public final FilterParams HeadingFilterParams
Accessor for ARController.FilterParams instance which affects Heading. A Low-bypass filter is used.
public final IconParams IconParams
Accessor for ARController.IconParams instance.
public final InfoParams InfoParams
Accessor for ARController.InfoParams instance.
public final IntroAnimationParams IntroParams
Accessor for ARController.IntroAnimationParams instance.
public final FilterParams PitchFilterParams
Accessor for ARController.FilterParams instance which affects Pitch. A Low-bypass filter is used.
public final SelectedItemParams SelectedItemParams
Accessor for ARController.SelectedItemParams instance.
public final UpViewParams UpViewParams
Accessor for ARController.UpViewParams instance.
public final UpViewTransitionParams UpViewTransitionParams
Accessor for ARController.UpViewTransitionParams instance.
public final FilterParams ZoomFilterParams
HERE Android SDK Developer's Guide
API Reference
260
Accessor for ARController.FilterParams instance which affects Zoom. A Low-bypass filter is used.
Method Details
public void addARObject (ARObject arObject)
Add an ARObject that will be displayed in the Camera and Map view.
Parameters:
arObject
ARObject to add to the ARController
public void addARObject (ARPolylineObject arPolyObject)
Add an ARPolylineObject that will be displayed in the Camera view.
Parameters:
arPolyObject
ARPolylineObject to add to the ARController
public void addARObject (ARModelObject arViewObject)
Add an ARModelObject that will be displayed in the Camera view.
Parameters:
arViewObject
ARModelObject to add to the ARController
public void addOnCameraEnteredListener (OnCameraEnteredListener listener)
Adds a ARController.OnCameraEnteredListener to this ARController to listen for the event triggered when
Camera view is entered. This event is triggered just before the Camera view is entered.
Parameters:
listener
A ARController.OnCameraEnteredListener to add to the ARController
See also:
removeOnCameraEnteredListener(OnCameraEnteredListener)
public void addOnCameraExitedListener (OnCameraExitedListener listener)
HERE Android SDK Developer's Guide
API Reference
261
Adds a ARController.OnCameraExitedListener to this ARController to listen for the event triggered when
Camera view is exited. This event is triggered just after the Camera view is exited.
Parameters:
listener
A ARController.OnCameraExitedListener to add to the ARController
See also:
removeOnCameraExitedListener(OnCameraExitedListener)
public void addOnCompassCalibrationChangedListener
(OnCompassCalibrationChangedListener listener)
Adds a ARController.OnCompassCalibrationChangedListener to this ARController to listen for compass
calibration changed events.
Parameters:
listener
A ARController.OnCompassCalibrationChangedListener to add to the ARController
See also:
removeOnCompassCalibrationChangedListener(OnCompassCalibrationChangedListener)
public void addOnLivesightStatusListener (OnLivesightStatusListener listener)
Adds a ARController.OnLivesightStatusListener to this ARController to listen for livesight status notification.
Parameters:
listener
A ARController.OnLivesightStatusListener to add to the ARController
See also:
removeOnLivesightStatusListener(OnLivesightStatusListener)
public void addOnMapEnteredListener (OnMapEnteredListener listener)
Adds a ARController.OnMapEnteredListener to this ARController to listen for the event triggered when Map
view is entered. This event is triggered just before the Map view is entered.
Parameters:
listener
A ARController.OnMapEnteredListener to add to the ARController
See also:
removeOnMapEnteredListener(OnMapEnteredListener)
HERE Android SDK Developer's Guide
API Reference
262
public void addOnMapExitedListener (OnMapExitedListener listener)
Adds a ARController.OnMapEnteredListener to this ARController to listen for the event triggered when Map
view is exited. This event is triggered just after the Map view is exited.
Parameters:
listener
A ARController.OnMapEnteredListener to add to the ARController
See also:
removeOnMapExitedListener(OnMapExitedListener)
public void addOnObjectTappedListener (OnObjectTappedListener listener)
Adds a ARController.OnObjectTappedListener to this ARController to listen for object tap events.
Parameters:
listener
A ARController.OnObjectTappedListener to add to the ARController
See also:
removeOnObjectTappedListener(OnObjectTappedListener)
public void addOnPanListener (OnPanListener listener)
Adds a ARController.OnPanListener to this ARController to listen for pan events.
Parameters:
listener
A ARController.OnPanListener to add to the ARController
See also:
removeOnPanListener(OnPanListener)
public void addOnPoseListener (OnPoseListener listener)
Adds a ARController.OnPoseListener to this ARController to listen for pose update events.
Parameters:
listener
A ARController.OnPoseListener to add to the ARController
See also:
removeOnPoseListener(OnPoseListener)
HERE Android SDK Developer's Guide
API Reference
263
public void addOnPostPresentListener (OnPostPresentListener listener)
Adds a ARController.OnPostPresentListener to this ARController to listen for the event triggered after a
draw is being performed.
Parameters:
listener
A ARController.OnPostPresentListener to add to the ARController
See also:
removeOnPostPresentListener(OnPostPresentListener)
public void addOnPreDrawListener (OnPreDrawListener listener)
Adds a ARController.OnPreDrawListener to this ARController to listen for the event triggered before the
livesight frame is being drawn.
Parameters:
listener
A ARController.OnPreDrawListener to add to the ARController
See also:
removeOnPreDrawListener(OnPreDrawListener)
public void addOnPreDrawMapListener (OnPreDrawMapListener listener)
Adds a ARController.OnPreDrawMapListener to this ARController to listen for the event triggered before
the map is being drawn.
Parameters:
listener
A ARController.OnPreDrawMapListener to add to the ARController
See also:
removeOnPreDrawMapListener(OnPreDrawMapListener)
public void addOnPrePresentListener (OnPrePresentListener listener)
Adds a ARController.OnPrePresentListener to this ARController to listen for the event triggered before a
draw is being performed.
Parameters:
listener
A ARController.OnPrePresentListener to add to the ARController
HERE Android SDK Developer's Guide
API Reference
264
See also:
removeOnPrePresentListener(OnPrePresentListener)
public void addOnProjectionCameraUpdatedListener
(OnProjectionCameraUpdatedListener listener)
Adds a ARController.OnProjectionCameraUpdatedListener to this ARController to listen for livesight projection
camera change notification.
Parameters:
listener
A ARController.OnProjectionCameraUpdatedListener to add to the ARController
See also:
removeOnProjectionCameraUpdatedListener(OnProjectionCameraUpdatedListener)
public void addOnRadarUpdateListener (OnRadarUpdateListener listener)
Adds a ARController.OnRadarUpdateListener to this ARController to listen for radar update events.
Parameters:
listener
A ARController.OnRadarUpdateListener to add to the ARController
See also:
removeOnRadarUpdateListener(OnRadarUpdateListener)
public void addOnSensorCalibrationChangedListener
(OnSensorCalibrationChangedListener listener)
Adds a ARController.OnSensorCalibrationChangedListener to this ARController to listen for sensor
calibration changed events.
Parameters:
listener
A ARController.OnSensorCalibrationChangedListener to add to the ARController
See also:
removeOnSensorCalibrationChangedListener(OnSensorCalibrationChangedListener)
public void addOnTapListener (OnTapListener listener)
HERE Android SDK Developer's Guide
API Reference
265
Adds a ARController.OnTapListener to this ARController to listen for tap events.
Parameters:
listener
A ARController.OnTapListener to add to the ARController
See also:
removeOnTapListener(OnTapListener)
public void addOnTouchDownListener (OnTouchDownListener listener)
Adds a ARController.OnTouchDownListener to this ARController to listen for touch down events.
Parameters:
listener
A ARController.OnTouchDownListener to add to the ARController
See also:
removeOnTouchDownListener(OnTouchDownListener)
public void addOnTouchUpListener (OnTouchUpListener listener)
Adds a ARController.OnTouchUpListener to this ARController to listen for touch up events.
Parameters:
listener
A ARController.OnTouchUpListener to add to the ARController
See also:
removeOnTouchUpListener(OnTouchUpListener)
public void defocus ()
Defocus previously focused ARObject. Bring the object back to its position among all objects in Camera view.
public void depress (ARObject arObject)
Depress previously pressed ARObject. Render the item to simulate depressing.
Parameters:
arObject
The ARObject to be marked as no longer pressed
public void focus (ARObject arObject)
HERE Android SDK Developer's Guide
API Reference
266
Focus an ARObject. Bring the object in front of other items and expand Info. The object becomes defocused
automatically if other object is chosen to be focused. Only one object can be focused.
Focus only has a visible affect on ARObject s which are in the Back plane.
Parameters:
arObject
ARObject to focus
public boolean geoTo3dPosition (GeoCoordinate geoPosition, Vector3f position)
Convert a geo position into a 3d space position
Parameters:
geoPosition
Geo position to convert
position
Filled on return with the corresponding 3d space position
Returns:
true on success
public int getAccelerometerCalibrationStatus ()
Get the accelerometer calibration status.
Status can be one of the following values:
• -1
• SensorManager.SENSOR_STATUS_UNRELIABLE
• SensorManager.SENSOR_STATUS_ACCURACY_LOW
• SensorManager.SENSOR_STATUS_ACCURACY_MEDIUM
• SensorManager.SENSOR_STATUS_ACCURACY_HIGH
Returns:
the accelerometer calibration status. -1 indicates the status has not been retrieved yet.
public float getCompassAccuracy ()
Get compass accuracy in degrees.
Returns:
Accuracy in degrees.
public int getCompassCalibrationStatus ()
HERE Android SDK Developer's Guide
API Reference
267
Get the compass calibration status.
Status can be one of the following values:
• -1
• SensorManager.SENSOR_STATUS_UNRELIABLE
• SensorManager.SENSOR_STATUS_ACCURACY_LOW
• SensorManager.SENSOR_STATUS_ACCURACY_MEDIUM
• SensorManager.SENSOR_STATUS_ACCURACY_HIGH
Returns:
the compass calibration status. -1 indicates the status has not been retrieved yet.
public float getFixedAltitude ()
Get fixed altitude of the livesight's view point.
Returns:
Altitude in meters of the view point above the ground
public int getGyroscopeCalibrationStatus ()
Get the gyroscope calibration status.
Status can be one of the following values:
• -1
• SensorManager.SENSOR_STATUS_UNRELIABLE
• SensorManager.SENSOR_STATUS_ACCURACY_LOW
• SensorManager.SENSOR_STATUS_ACCURACY_MEDIUM
• SensorManager.SENSOR_STATUS_ACCURACY_HIGH
Returns:
the gyroscope calibration status. -1 indicates the status has not been retrieved yet.
public long getObjectId (ARObject arObject)
Get ARObjects unique identifier.
Parameters:
arObject
ARObject to retrieve unique identifier for
Returns:
ARObjects unique identifier. -1 returned if object has not been found
public java.util.List <ARObject> getObjects (PointF point)
HERE Android SDK Developer's Guide
API Reference
268
Get a list of ARObjects at the specified screen point.
Parameters:
point
Screen point to check for ARObjects
Returns:
List of ARObjects. null if no objects are located at point.
public java.util.List <ARObject> getObjects (ViewRect rect)
Get a list of ARObjects which intersect the given ViewRect
Parameters:
rect
ViewRect to check for ARObjects
Returns:
List of ARObjects. null if no objects are located in rect.
public float getOcclusionOpacity ()
Get opacity of the occlusion items.
Returns:
A value of opacity.
public ARPoseReading getPose ()
Get latest pose
Returns:
An ARPoseReading object representing the latest available pose
public GeoCoordinate getPosition ()
Get the last known position.
Returns:
GeoCoordinate representing the last known position or null if no position fix is available
public GeoCoordinate getPosition (AtomicBoolean mapMached)
Get the last known position with map matching indicator. See NavigationManager, PositioningManager.
Parameters:
HERE Android SDK Developer's Guide
API Reference
269
mapMached
Set to true on return if the position was changed such that it matches the closest road. Usually enabled
during navigation.
Returns:
GeoCoordinate representing the last known position or null if no position fix is available
public ProjectionType getProjectionType ()
Get Camera view ARController.ProjectionType
Returns:
A value of ProjectionType
public PointF getScreenViewPoint ()
Get target screen view point. This point is a final first person view on the screen.
Returns:
A value of the timeout in ms.
public long getSensorsWaitTimeout ()
Get sensors wait timeout in ms.
Returns:
A value of the timeout in ms.
public int getUpdateDistanceDelta ()
Get the update distance delta.
Returns:
Distance delta in meters.
See also:
setUpdateDistanceDelta(int)
public ViewType getViewType ()
Get enforced ARController.ViewType. If view type is AUTO the value depends on the device tilt and high and
low pich thresholds.
Returns:
A ViewType.
HERE Android SDK Developer's Guide
API Reference
270
public boolean isOccluded (ARObject arObject)
Check if an ARObject is occluded by a building
Parameters:
arObject
ARObject
Returns:
true if object is occluded by a building, false otherwise.
See also:
ARIconObject
public boolean isOcclusionEnabled ()
Check if occlusion is enabled.
Returns:
true if occlusion is enabled, false otherwise.
public boolean isUsingAlternativeCenter ()
Checks to see if an alternative center is currently being used
Returns:
true if alternative center is used, false otherwise
See also:
setAlternativeCenter(GeoCoordinate)
public boolean isVisible (ARObject arObject)
Check if an ARObject is visible in the camera view.
Parameters:
arObject
ARObject
Returns:
true if object is visible in camera view, false otherwise.
See also:
ARIconObject
HERE Android SDK Developer's Guide
API Reference
271
public void pan (PointF from, PointF to)
Pans the Camera view from one specified on-screen android.graphics.PointF to another.
Parameters:
from
An originating on-screen PointF (pre-pan)
to
An on-screen PointF representing the end of the pan
public void panTo (GeoCoordinate coordinate)
Pan the Camera view such that the GeoCoordinate passed as a parameter will be in the last location in the
Front plane (i.e. on the boundary between Front and Back plane).
This can be used in conjunction with getCoordinate() to pan so that a given ARObject will be in the last
position in the Front plane.
Parameters:
coordinate
GeoCoordinate to be the last location in Front plane.
public boolean pixelTo3dPosition (float z, PointF screenPoint, Vector3f
position)
Convert a screen point into a 3d space position
Parameters:
z
Position depth relative to which the conversion is made
screenPoint
Screen point to convert. It is relative to the AR view
position
Filled on return with the corresponding 3d space position
Returns:
true on success, false otherwise.
public ARObject press (PointF point)
Press an ARObject. Render the item to simulate pressing.
Parameters:
point
HERE Android SDK Developer's Guide
API Reference
272
android.graphics.PointF on the screen to press.
Returns:
Pressed ARObject. null if no object is located at point.
public void press (ARObject arObject)
Press an ARObject. Render the item to simulate pressing.
Parameters:
arObject
The ARObject to be marked as pressed
public boolean removeARObject (ARObject arObject)
Remove an ARObject from the Camera and Map view.
Parameters:
arObject
ARObject to remove
Returns:
true if object is successfully removed from ARController, false otherwise.
See also:
ARIconObject
public boolean removeARObject (ARPolylineObject arPolyObject)
Remove an ARPolylineObject from the Camera view.
Parameters:
arPolyObject
ARPolylineObject to remove
Returns:
true if object is successfully removed from ARController, false otherwise.
public boolean removeARObject (ARModelObject arViewObject)
Remove an ARModelObject from the Camera view.
Parameters:
arViewObject
ARModelObject to remove
HERE Android SDK Developer's Guide
API Reference
273
Returns:
true if object is successfully removed from ARController, false otherwise.
public void removeOnCameraEnteredListener (OnCameraEnteredListener listener)
Removes an existing ARController.OnCameraEnteredListener from this ARController .
Parameters:
listener
A ARController.OnCameraEnteredListener to remove from the ARController
public void removeOnCameraExitedListener (OnCameraExitedListener listener)
Removes an existing ARController.OnCameraExitedListener from this ARController .
Parameters:
listener
A ARController.OnCameraExitedListener to remove from the ARController
public void removeOnCompassCalibrationChangedListener
(OnCompassCalibrationChangedListener listener)
Removes an existing ARController.OnCompassCalibrationChangedListener from this ARController .
Parameters:
listener
A ARController.OnCompassCalibrationChangedListener to remove from the ARController
public void removeOnLivesightStatusListener (OnLivesightStatusListener listener)
Removes an existing ARController.OnLivesightStatusListener from this ARController.
Parameters:
listener
A ARController.OnLivesightStatusListener to remove from the ARController
public void removeOnMapEnteredListener (OnMapEnteredListener listener)
Removes an existing ARController.OnMapEnteredListener from this ARController .
Parameters:
listener
A ARController.OnMapEnteredListener to remove from the ARController
HERE Android SDK Developer's Guide
API Reference
274
public void removeOnMapExitedListener (OnMapExitedListener listener)
Removes an existing ARController.OnMapExitedListener from this ARController .
Parameters:
listener
A ARController.OnMapExitedListener to remove from the ARController
public void removeOnObjectTappedListener (OnObjectTappedListener listener)
Removes an existing ARController.OnObjectTappedListener from this ARController .
Parameters:
listener
A ARController.OnObjectTappedListener to remove from the ARController
public void removeOnPanListener (OnPanListener listener)
Removes an existing ARController.OnPanListener from this ARController .
Parameters:
listener
A ARController.OnPanListener to remove from the ARController
public void removeOnPoseListener (OnPoseListener listener)
Removes an existing ARController.OnPoseListener from this ARController .
Parameters:
listener
A ARController.OnPoseListener to remove from the ARController
public void removeOnPostPresentListener (OnPostPresentListener listener)
Removes an existing ARController.OnPostPresentListener from this ARController .
Parameters:
listener
A ARController.OnPostPresentListener to remove from the ARController
public void removeOnPreDrawListener (OnPreDrawListener listener)
Removes an existing ARController.OnPreDrawListener from this ARController .
HERE Android SDK Developer's Guide
API Reference
275
Parameters:
listener
A ARController.OnPreDrawListener to remove from the ARController
public void removeOnPreDrawMapListener (OnPreDrawMapListener listener)
Removes an existing ARController.OnPreDrawMapListener from this ARController .
Parameters:
listener
A ARController.OnPreDrawMapListener to remove from the ARController
public void removeOnPrePresentListener (OnPrePresentListener listener)
Removes an existing ARController.OnPrePresentListener from this ARController .
Parameters:
listener
A ARController.OnPrePresentListener to remove from the ARController
public void removeOnProjectionCameraUpdatedListener
(OnProjectionCameraUpdatedListener listener)
Removes an existing ARController.OnProjectionCameraUpdatedListener from this ARController.
Parameters:
listener
A ARController.OnProjectionCameraUpdatedListener to remove from the ARController
public void removeOnRadarUpdateListener (OnRadarUpdateListener listener)
Removes an existing ARController.OnRadarUpdateListener from this ARController .
Parameters:
listener
A ARController.OnRadarUpdateListener to remove from the ARController
public void removeOnSensorCalibrationChangedListener
(OnSensorCalibrationChangedListener listener)
Removes an existing ARController.OnSensorCalibrationChangedListener from this ARController .
HERE Android SDK Developer's Guide
API Reference
276
Parameters:
listener
A ARController.OnSensorCalibrationChangedListener to remove from the ARController
public void removeOnTapListener (OnTapListener listener)
Removes an existing ARController.OnTapListener from this ARController .
Parameters:
listener
A ARController.OnTapListener to remove from the ARController
public void removeOnTouchDownListener (OnTouchDownListener listener)
Removes an existing ARController.OnTouchDownListener from this ARController .
Parameters:
listener
A ARController.OnTouchDownListener to remove from the ARController
public void removeOnTouchUpListener (OnTouchUpListener listener)
Removes an existing ARController.OnTouchUpListener from this ARController .
Parameters:
listener
A ARController.OnTouchUpListener to remove from the ARController
public void removePitchFunction ()
Removes an existing ARController.OnPitchFunction from this ARController.
public void select (ARObject arObject)
Select an ARObject. Any item in Camera view can be in selected state. This implies that the item is rendered
differently. The ARObject becomes unselected automatically if another ARObject is selected. Only one
ARObject can be selected at a time.
When selected: Details portion, (if present), of the item collapses, background image replaces foreground
image, (if item is on foreground), item's image is scaled, (if specified), item's opacity is changed, (if specified),
all non-selected items opacity, (if specified), are changed as well.
Parameters:
arObject
HERE Android SDK Developer's Guide
API Reference
277
The ARObject to be marked as selected
See also:
setOpacity(float)
setNonSelectedItemsOpacity(float)
public void select (ARObject arObject, boolean allowInfo, float scale)
Select an ARObject. Any item in Camera view can be in selected state. This implies that the item is rendered
differently. The ARObject becomes unselected automatically if another ARObject is selected. Only one
ARObject can be selected at a time.
Parameters:
arObject
The ARObject to be marked as selected
allowInfo
If true and info is visible, it will continue to be visible. If false, BACK icon replaces FRONT icon and info
portion will collapse.
scale
The size multiplier to be applied while the item is in selected state. If scale is x1,
SelectedItemParams#setSize is used for width and height. Otherwise scale is applied to the current
projected size.
When selected: If allowInfo is set to false - details portion(if present) collapses and background image
replaces foreground image(if item is on foreground), item's image is scaled by the factor of scale, item's
opacity is changed(if specified), all non-selected items opacity(if specified) are changed as well.
See also:
setOpacity(float)
setNonSelectedItemsOpacity(float)
public void setAlternativeCenter (GeoCoordinate coordinate)
Set alternative to current GPS position to use for LiveSight. Passing null will cause LiveSight to resume using
GPS position.
Parameters:
coordinate
GeoCoordinate representing alternative center to use
See also:
isUsingAlternativeCenter()
public void setCompassAccuracy (float degrees)
HERE Android SDK Developer's Guide
API Reference
278
Set compass accuracy in degrees.
Parameters:
degrees
Accuracy in degrees.
public void setFixedAltitude (float altitude_m, boolean animate)
Set fixed altitude of the livesight's view point. Default value is 2 meters in order to see closest to the viewer
surronding area. If the value is negative, the positioning service altitude will be used. Example: Setting
altitude to 1000 meters would allow to create binocular magnification effect looking at the distance from
1000 meters above the ground.
Parameters:
altitude_m
Altitude in meters of the view point above the ground
animate
To control transition from current altitude to new one
public void setInfoAnimationInUpViewOnly (boolean enable)
Choose the moment when INFO animation starts.
Parameters:
enable
If true, INFO open and close occurs in UP view only, that is after flying in and before flying out from UP
view.
public void setMap (Map map)
Set Map to the ARController . ARController will handle transitions between views.
Parameters:
map
Existing Map object
public void setOcclusionEnabled (boolean enable)
Enables or disables occlusion fading. If an item gets obstructed by a building its opacity will be reduced.
Parameters:
enable
Enables if true or disables if false. By default, occlusion is disabled.
HERE Android SDK Developer's Guide
API Reference
279
public void setOcclusionOpacity (float opacity)
Set opacity of the occlusion items.
Parameters:
opacity
Opacity value to use when item is obstracted by a building.
public void setOrientationAnimation (boolean enabled)
Enable/disable animation during orientation change. It has effect on the camera scene only. This call should
be made when livesight is stopped.
Parameters:
enabled
If true, orientation animation is used
public void setPitchFunction (OnPitchFunction function)
Adds a ARController.OnPitchFunction to this ARController to be able to override current device pitch.
Parameters:
function
A OnPitchFunction to add to the ARController
See also:
removePitchFunction()
public void setPlanesParameters (float frontNear, float frontFar, float
backNear, float backFar)
Set front and back planes parameters - screen height ratios (0..1f). The livesight by default is using two plane
scheme. The first one is the front plane where icons are shown in close proximity as a composition of two
parts: front icon image and info icon image attached on the right. The back plane is for "far" icons. They are
displayed with back icon images only. The front plane takes lower portion of the view. The back plane takes
higher portion of the view. Both planes are limited by two horizontal lines described as a proportion of the
hight of the view. Using push/pull gesture allows to move icons closer or farther from the viewer in each
plane.
Parameters:
frontNear
Front plane near screen height ratio. Example: 0.95
frontFar
Front plane far screen height ratio. Example: 0.6
HERE Android SDK Developer's Guide
API Reference
280
backNear
Back plane near screen height ratio. Example: 0.2
backFar
Back plane far screen height ratio. Example: 0.5
public void setProjectionType (ProjectionType type)
Set Camera view ARController.ProjectionType
Parameters:
type
A value of ProjectionType.
public void setSensorsWaitTimeout (long timeout)
Set sensors wait timeout in ms. In exceptional situations sensors may not produce valid data due to system
level malfunction. To handle the situation, provided timeout is used to wait until the sensors data is
available. This call should be made before livesight start() command for the value to take effect, otherwise it
will be used on next sensors verification. See ARController.OnLivesightStatusListener and ARController.Error
codes.
Parameters:
timeout
A value of the timeout in ms.
public void setTapArea (int width, int height)
Sets the tap area width and height. Whenever user touches the screen, a tap event is triggered. Whenever the
user starts moving the finger on the screen, a pan event is triggered. The tap area is a rectangle having the
initial touch point as the center. As long as the user moves the finger on the screen and the touch point is
inside the tap area, no pan event will be triggered.The default tap area has a width and height of 51 pixels.
Parameters:
width
The tap area width in pixels
height
The tap area height in pixels
public void setUpdateDistanceDelta (int delta)
Sets the update distance delta for the items in the camera view.
When the distance between the current geo position and a new one is bigger than specified value the AR
layout items projection is updated.
HERE Android SDK Developer's Guide
API Reference
281
Parameters:
delta
Distance delta in meters. Default: 3 meters.
public void setUseDownIconsOnMap (boolean useDownIcons)
Use Down icons in Map view in LiveSight
Parameters:
useDownIcons
Enable using Down icons in Map view of LiveSight. By default, down icons are being used.
public void showFrontItemsOnly (boolean show)
Show only icons in the Front plane in Camera view.
Parameters:
show
If true, only front items will be displayed in Camera view
public void showView (ViewType viewType)
Show(enforce) specified ARController.ViewType.
Parameters:
viewType
ViewType to show
public Error start ()
Start AR
Returns:
NONE on success. Otherwise, one of the error codes in Error.
public Error stop (boolean withExitAnimation)
Stop AR
Parameters:
withExitAnimation
If true, exit animation is used before stopping LiveSight.
Returns:
HERE Android SDK Developer's Guide
API Reference
282
NONE on success. Otherwise, one of the error codes in Error.
public void unselect ()
Unselect previously selected object.
When unselected: Details portion(if present) expands, front image is used instead of background(if item is on
foreground), item is scaled to normal size, all opacities change to default values.
See also:
setOpacity(float)
setNonSelectedItemsOpacity(float)
CameraParams
The class CameraParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public static final class ARController.CameraParams
extends java.lang.Object
Encapsulates parameters which affect the device camera.
[For complete information, see the section Class Details]
Method Summary
Table 23: Methods in CameraParams
Methods
public int getFps ()
Get camera FPS.
public float getHorizontalFov ()
Get horizontal field of view of Camera view in the CompositeFragment.
public Size[] getPreviewSizes ()
Get the array of supported camera resolutions for Camera view.
public Size getSize ()
Get camera resolution for Camera view.
public float getVerticalFov ()
Get vertical field of view of Camera view in the CompositeFragment.
public CameraParams setFps (int fps)
Set camera FPS.
HERE Android SDK Developer's Guide
API Reference
283
Methods
public CameraParams setSize (Size size)
Set camera resolution for Camera view.
Class Details
Encapsulates parameters which affect the device camera. The device camera is used when in CAMERA view.
Method Details
public int getFps ()
Get camera FPS.
Returns:
Camera FPS. If not available -1.
public float getHorizontalFov ()
Get horizontal field of view of Camera view in the CompositeFragment. This is not camera hardware filed of
view. IMPORTANT! View has to exist in the CompositeFragment in order to retrieve the value, otherwise invalid
value is returned.
Returns:
horizontal field of view, in degrees
public Size[] getPreviewSizes ()
Get the array of supported camera resolutions for Camera view.
Returns:
The array of supported camera resolutions. null if camera not found. See Size
public Size getSize ()
Get camera resolution for Camera view.
Returns:
size Camera resolution. See Size
public float getVerticalFov ()
Get vertical field of view of Camera view in the CompositeFragment. This is not camera hardware filed of
view. IMPORTANT! View has to exist in the CompositeFragment in order to retrieve the value, otherwise invalid
value is returned.
HERE Android SDK Developer's Guide
API Reference
284
Returns:
vertical field of view, in degrees
public CameraParams setFps (int fps)
Set camera FPS. This call should be made prior to creating CompositeFragment object.
Parameters:
fps
Camera FPS.
Returns:
CameraParams object.
public CameraParams setSize (Size size)
Set camera resolution for Camera view. Currently, any size equal to or greater than 640X480 is supported.
This call should be made prior to creating CompositeFragment object.
When a custom size is set, it will be matched to the closest supported size for a given device, as reported by
getPreviewSizes().
Setting the camera size to high resolutions has a significant performance impact.
Parameters:
size
Camera resolution. See Size
Returns:
CameraParams object.
DownViewParams
The class DownViewParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.DownViewParams
extends java.lang.Object
Encapsulates parameters which affect the Down view.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
285
Method Summary
Table 24: Methods in DownViewParams
Methods
public AnimationInterpolator getCenterInterpolator ()
Get auto TFC interpolation algorithm.
public long getFadeInAnimationDelay ()
Get delay of Down view fade-in animation.
public long getFadeInAnimationTime ()
Get duration of Down view fade-in animation.
public AnimationInterpolator getFadeInInterpolator ()
Get the interpolator for Down view fade-in animation.
public long getFadeOutAnimationDelay ()
Get delay of Down view fade-out animation.
public long getFadeOutAnimationTime ()
Get duration of Down view fade-out animation.
public AnimationInterpolator getFadeOutInterpolator ()
Get the interpolator for Down view fade-out animation.
public AnimationInterpolator getGeoCenterInterpolator ()
Get auto GPS interpolation algorithm.
public AnimationInterpolator getHeadingInterpolator ()
Get auto heading interpolation algorithm.
public float getMaxAlpha ()
Get maximum alpha value for DOWN view.
public float getMaxZoomOutScale ()
Get max zoom out level for Down view.
public float getMinAlpha ()
Get minimum alpha value for DOWN view.
public float getMinPitch ()
Get minimum Down view pitch.
public AnimationInterpolator getPitchInterpolator ()
Get auto pitch interpolation algorithm.
public float getPitchThreshold ()
Get pitch threshold when Up view transitions to Down view
public AnimationInterpolator getZoomInterpolator ()
Get auto zoom interpolation algorithm.
HERE Android SDK Developer's Guide
API Reference
286
Methods
public boolean isAutoGeoCenterEnabled ()
Get Down view auto geo center setting.
public boolean isAutoHeadingEnabled ()
Get Down view auto heading setting.
public boolean isAutoPitchEnabled ()
Get Down view auto pitch setting.
public boolean isAutoTFCEnabled ()
Get Down view auto tfc setting.
public boolean isAutoZoomEnabled ()
Get Down view auto zoom setting.
public DownViewParams setAutoControlOnEntryExit (boolean enabled)
Enable/disable map auto control during Entry and Exit animations.
public DownViewParams setAutoGeoCenterEnabled (boolean enabled, boolean animate)
Enable/disable auto geo center control.
public DownViewParams setAutoHeadingEnabled (boolean enabled, boolean animate)
Enable/disable auto heading control.
public DownViewParams setAutoPitchEnabled (boolean enabled, boolean animate)
Enable/disable auto pitch control.
public DownViewParams setAutoTFCEnabled (boolean enabled, boolean animate)
Enable/disable auto transform center control.
public DownViewParams setAutoZoomEnabled (boolean enabled, boolean animate)
Enable/disable auto zoom control.
public DownViewParams setCenterInterpolator (AnimationInterpolator value)
Set auto TFC interpolation algorithm.
public DownViewParams setFadeInAnimationDelay (long value)
Set Down view fade-in animation delay.
public DownViewParams setFadeInAnimationTime (long value)
Set Down view fade-in animation duration.
public DownViewParams setFadeInInterpolator (AnimationInterpolator value)
Set the interpolator for Down view fade-in animation.
public DownViewParams setFadeOutAnimationDelay (long value)
Set Down view fade-out animation delay.
public DownViewParams setFadeOutAnimationTime (long value)
Set Down view fade-out animation duration.
HERE Android SDK Developer's Guide
API Reference
287
Methods
public DownViewParams setFadeOutInterpolator (AnimationInterpolator value)
Set the interpolator for Down view fade-out animation.
public DownViewParams setGeoCenterInterpolator (AnimationInterpolator value)
Set auto GPS interpolation algorithm.
public DownViewParams setHeadingInterpolator (AnimationInterpolator value)
Set auto heading interpolation algorithm
public DownViewParams setMaxAlpha (float value)
Set maximum alpha value for DOWN view.
public DownViewParams setMaxZoomOutScale (float value, boolean animate, boolean
pitchCorrection)
Set max zoom out level for Down view.
public DownViewParams setMinAlpha (float value)
Set minimum alpha value for DOWN view.
public DownViewParams setMinPitch (float value)
Sets minimum Down view pitch.
public DownViewParams setPitchInterpolator (AnimationInterpolator value)
Set auto pitch interpolation algorithm
public DownViewParams setPitchThreshold (float value)
Set Pitch threshold when Up view transitions to Down view
public DownViewParams setTransformCenter (PointF center, boolean animate)
Set down view transform center in the livesight.
public DownViewParams setZoomInterpolator (AnimationInterpolator value)
Set auto zoom interpolation algorithm.
Class Details
Encapsulates parameters which affect the Down view.
Method Details
public AnimationInterpolator getCenterInterpolator ()
Get auto TFC interpolation algorithm.
Returns:
auto TFC interpolation algorithm enumerator.
public long getFadeInAnimationDelay ()
Get delay of Down view fade-in animation.
HERE Android SDK Developer's Guide
API Reference
288
Returns:
delay of Down view fade-in animation in ms.
public long getFadeInAnimationTime ()
Get duration of Down view fade-in animation.
Returns:
duration of Down view fade-in animation in ms.
public AnimationInterpolator getFadeInInterpolator ()
Get the interpolator for Down view fade-in animation.
Returns:
The AnimationInterpolator for Down view fade-in animation
public long getFadeOutAnimationDelay ()
Get delay of Down view fade-out animation.
Returns:
delay of Down view fade-out animation in ms.
public long getFadeOutAnimationTime ()
Get duration of Down view fade-out animation.
Returns:
duration of Down view fade-out animation in ms.
public AnimationInterpolator getFadeOutInterpolator ()
Get the interpolator for Down view fade-out animation.
Returns:
The AnimationInterpolator for Down view fade-out animation
public AnimationInterpolator getGeoCenterInterpolator ()
Get auto GPS interpolation algorithm.
Returns:
auto GPS interpolation algorithm enumerator.
HERE Android SDK Developer's Guide
API Reference
289
public AnimationInterpolator getHeadingInterpolator ()
Get auto heading interpolation algorithm.
Returns:
auto heading interpolation algorithm enumerator.
public float getMaxAlpha ()
Get maximum alpha value for DOWN view. Range 0..1f.
Returns:
max alpha channel value of DOWN view.
public float getMaxZoomOutScale ()
Get max zoom out level for Down view. Zoom value in down view changes dynamically as a function of pitch.
Full zoom range is from 0(most farthest) to 1.0(most closest).
Returns:
max zoom out level
public float getMinAlpha ()
Get minimum alpha value for DOWN view. Range 0..1f.
Returns:
min alpha channel value of DOWN view
public float getMinPitch ()
Get minimum Down view pitch. Default value is Map's min pitch.
Returns:
minimum map pitch.
See also:
setTilt(float, Animation)
getMinTilt()
getMaxTilt()
public AnimationInterpolator getPitchInterpolator ()
Get auto pitch interpolation algorithm.
HERE Android SDK Developer's Guide
API Reference
290
Returns:
auto pitch interpolation algorithm enumerator.
public float getPitchThreshold ()
Get pitch threshold when Up view transitions to Down view
Returns:
pitch value which triggers transition from Up view to Down view
public AnimationInterpolator getZoomInterpolator ()
Get auto zoom interpolation algorithm.
Returns:
auto zoom interpolation algorithm enumerator.
public boolean isAutoGeoCenterEnabled ()
Get Down view auto geo center setting.
Returns:
Auto geo center setting
public boolean isAutoHeadingEnabled ()
Get Down view auto heading setting.
Returns:
Auto heading setting
public boolean isAutoPitchEnabled ()
Get Down view auto pitch setting.
Returns:
Auto pitch setting
public boolean isAutoTFCEnabled ()
Get Down view auto tfc setting.
Returns:
Auto tfc setting
HERE Android SDK Developer's Guide
API Reference
291
public boolean isAutoZoomEnabled ()
Get Down view auto zoom setting.
Returns:
Auto zoom setting
public DownViewParams setAutoControlOnEntryExit (boolean enabled)
Enable/disable map auto control during Entry and Exit animations. If certain map parameters such as auto
pitch, auto heading are disabled, they are treated enabled during Entry and Exit animations only.
Parameters:
enabled
If true, map auto control is enabled during Entry and Exit animations.
Returns:
The updated DownViewParams object itself
public DownViewParams setAutoGeoCenterEnabled (boolean enabled, boolean
animate)
Enable/disable auto geo center control. When enabled, ARController sets geo center automatically
Parameters:
enabled
If true, geo center is set automatically
animate
If true, start animation from current value to the calculated by liveisght
Returns:
The updated DownViewParams object itself
public DownViewParams setAutoHeadingEnabled (boolean enabled, boolean
animate)
Enable/disable auto heading control. When enabled, ARController adjusts the heading automatically
Parameters:
enabled
If true, heading is adjusted automatically
animate
If true, start animation from current value to the calculated by liveisght
HERE Android SDK Developer's Guide
API Reference
292
Returns:
The updated DownViewParams object itself
public DownViewParams setAutoPitchEnabled (boolean enabled, boolean
animate)
Enable/disable auto pitch control. When enabled, ARController adjusts the pitch automatically
Parameters:
enabled
If true, pitch is adjusted automatically
animate
If true, start animation from current value to the calculated by liveisght
Returns:
The updated DownViewParams object itself
public DownViewParams setAutoTFCEnabled (boolean enabled, boolean animate)
Enable/disable auto transform center control. When enabled, ARController adjusts the transform center
automatically
Parameters:
enabled
If true, transform center is adjusted automatically
animate
If true, start animation from current value to the calculated by liveisght
Returns:
The updated DownViewParams object itself
public DownViewParams setAutoZoomEnabled (boolean enabled, boolean animate)
Enable/disable auto zoom control. When enabled, ARController adjusts the zoom level automatically
Parameters:
enabled
If true, zoom is adjusted automatically
animate
If true, start animation from current value to the calculated by liveisght
Returns:
The updated DownViewParams object itself
HERE Android SDK Developer's Guide
API Reference
293
public DownViewParams setCenterInterpolator (AnimationInterpolator value)
Set auto TFC interpolation algorithm.
Parameters:
value
auto TFC interpolation algorithm.
Returns:
The updated DownViewParams object itself
public DownViewParams setFadeInAnimationDelay (long value)
Set Down view fade-in animation delay.
Parameters:
value
Down view fade-in animation delay in ms
Returns:
The updated DownViewParams object itself
public DownViewParams setFadeInAnimationTime (long value)
Set Down view fade-in animation duration.
Parameters:
value
Down view fade-in animation duration in ms
Returns:
The updated DownViewParams object itself
public DownViewParams setFadeInInterpolator (AnimationInterpolator value)
Set the interpolator for Down view fade-in animation.
Parameters:
value
The AnimationInterpolator for Down view fade-in animation
Returns:
The updated DownViewParams object itself
HERE Android SDK Developer's Guide
API Reference
294
public DownViewParams setFadeOutAnimationDelay (long value)
Set Down view fade-out animation delay.
Parameters:
value
Down view fade-out animation delay in ms
Returns:
The updated DownViewParams object itself
public DownViewParams setFadeOutAnimationTime (long value)
Set Down view fade-out animation duration.
Parameters:
value
Down view fade-out animation duration in ms
Returns:
The updated DownViewParams object itself
public DownViewParams setFadeOutInterpolator (AnimationInterpolator value)
Set the interpolator for Down view fade-out animation.
Parameters:
value
The AnimationInterpolator for Down view fade-out animation
Returns:
The updated DownViewParams object itself
public DownViewParams setGeoCenterInterpolator (AnimationInterpolator value)
Set auto GPS interpolation algorithm.
Parameters:
value
auto GPS interpolation algorithm.
Returns:
The updated DownViewParams object itself
public DownViewParams setHeadingInterpolator (AnimationInterpolator value)
HERE Android SDK Developer's Guide
API Reference
295
Set auto heading interpolation algorithm
Parameters:
value
auto heading interpolation algorithm.
Returns:
The updated DownViewParams object itself
public DownViewParams setMaxAlpha (float value)
Set maximum alpha value for DOWN view. Range 0..1f.
Parameters:
value
The DOWN view alpha channel.
Returns:
The updated DownViewParams object itself
public DownViewParams setMaxZoomOutScale (float value, boolean animate,
boolean pitchCorrection)
Set max zoom out level for Down view. Zoom value in down view changes dynamically as a function of pitch.
Full map's zoom scale range is from 0(most zoomed out) to 1.0(most zoomed in). Example: Setting value of
0.8 would limit livesight zoom to 0.8(most zoomed out) to 1.0(most zoomed in).
Parameters:
value
max zoom out level.
animate
true to animate change from previous value to new one.
pitchCorrection
true to consider current pitch when zoom scale was applied. The final max zoom out value will be equal
or greater then specified.
Returns:
The updated DownViewParams object itself
public DownViewParams setMinAlpha (float value)
Set minimum alpha value for DOWN view. Range 0..1f.
Parameters:
value
HERE Android SDK Developer's Guide
API Reference
296
The DOWN view alpha channel
Returns:
The updated DownViewParams object itself
public DownViewParams setMinPitch (float value)
Sets minimum Down view pitch. Value's range should be [min map tilt, max map tilt]. Map.
Parameters:
value
minimum map pitch.
Returns:
The updated DownViewParams object itself
See also:
setTilt(float, Animation)
getMinTilt()
getMaxTilt()
public DownViewParams setPitchInterpolator (AnimationInterpolator value)
Set auto pitch interpolation algorithm
Parameters:
value
auto pitch interpolation algorithm.
Returns:
The updated DownViewParams object itself
public DownViewParams setPitchThreshold (float value)
Set Pitch threshold when Up view transitions to Down view
Parameters:
value
Pitch value ranges from 0...180
Returns:
The updated DownViewParams object itself
public DownViewParams setTransformCenter (PointF center, boolean animate)
HERE Android SDK Developer's Guide
API Reference
297
Set down view transform center in the livesight. By default map transform center and first person view are
coincide. The API enables separation of these points and creating "fly around" effect, where viewer is "flying
around" specified map transform center.
Parameters:
center
Normalized screen coordinates. Example {0.5, 1} corresponds to {width/2, height}
animate
A flag to enable/disable animation from current view point to new one.
Returns:
The updated DownViewParams object itself
public DownViewParams setZoomInterpolator (AnimationInterpolator value)
Set auto zoom interpolation algorithm.
Parameters:
value
auto zoom interpolation algorithm.
Returns:
The updated DownViewParams object itself
Error
The enumeration Error is a member of com.here.android.mpa.ar.ARController.
Enumeration Summary
public static final enumeration ARController.Error
extends java.lang.Enum, java.lang.Object
AR Error codes
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 25: Enum Constants in Error
Fields
public static final Error NONE
There is no error
HERE Android SDK Developer's Guide
API Reference
298
Fields
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call.
public static final Error INVALID_PARAMETERS
Parameters passed to API are not valid.
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied.
public static final Error CAMERA_UNAVAILABLE
Camera cannot be opened
public static final Error SENSORS_UNAVAILABLE
Sensors unavailable
public static final Error STOPPED
Livesight stopped
Method Summary
Table 26: Methods in Error
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARController.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
AR Error codes
Enum Constant Details
public static final Error NONE
There is no error
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call. For example, calling start() a second time before calling stop
public static final Error INVALID_PARAMETERS
Parameters passed to API are not valid.
HERE Android SDK Developer's Guide
API Reference
299
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final Error CAMERA_UNAVAILABLE
Camera cannot be opened
public static final Error SENSORS_UNAVAILABLE
Sensors unavailable
public static final Error STOPPED
Livesight stopped
Method Details
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARController.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ExternalSensors
The class ExternalSensors is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.ExternalSensors
extends java.lang.Object
Encapsulates functionality to replace integrated sensors(all or selected) data feeds with external ones.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
300
Method Summary
Table 27: Methods in ExternalSensors
Methods
public void pushData (SensorType sensorType, double x, double y, double z, long timeStamp)
Push sensors readings into the LiveSight engine.
public ExternalSensors utilize (SensorType sensorType, boolean onOff)
IMPORTANT! This call should be made when ARController is stopped or paused.
Class Details
Encapsulates functionality to replace integrated sensors(all or selected) data feeds with external ones. The
interface is used to allow utilization of higher precision sensors to produce more accurate 3D projection
results instead of using internal sensors on the device. ARController.FilterParams are also applicabe to the
external sensors data.
Method Details
public void pushData (SensorType sensorType, double x, double y, double z,
long timeStamp)
Push sensors readings into the LiveSight engine.
Parameters:
sensorType
Sensor type. ARController.SensorType.
x
Accelerometer: Acceleration force along the x axis (m/s^2). Gyroscope: Rate of rotation around the x axis
(rad/s). Compass: The X (northward) component of the magnetic field in nanoteslas Location: Latitude in
degrees.
y
Accelerometer: Acceleration force along the y axis (m/s^2). Gyroscope: Rate of rotation around the y axis
(rad/s). Compass: The Y (eastward) component of the magnetic field in nanoteslas. Location: Longitude
in degrees.
z
Accelerometer: Acceleration force along the z axis (m/s^2). Gyroscope: Rate of rotation around the z axis
(rad/s). Compass: The Z (downward) component of the magnetic field in nanoteslas. Location: Altitude in
meters.
timeStamp
Timestamp of the sensor's reading.
HERE Android SDK Developer's Guide
API Reference
301
public ExternalSensors utilize (SensorType sensorType, boolean onOff)
IMPORTANT! This call should be made when ARController is stopped or paused. Enable/disable the external
sensor(s) to feed data into the LiveSight. Once the external sensor is turned on, integrated sensor's data feed
is stopped and from this moment on the client has to start feeding the sensor's data into LiveSight engine.
See pushData().
Parameters:
sensorType
Sensor type. ARController.SensorType.
onOff
If true, the integrated sensor's data feed is stopped and switched to external sensor data feed provided
by the client. If false, intergrated sensor's feed is turned back on and external sensor's data feed is
ignored, if continued.
Returns:
The updated ExternalSensors object itself.
FilterParams
The class FilterParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.FilterParams
extends java.lang.Object
Encapsulates parameters which affect data filtering.
[For complete information, see the section Class Details]
Method Summary
Table 28: Methods in FilterParams
Methods
public float getCoeff ()
Get filter coefficient
public int getSize ()
Get number of collected samples for filter.
public FilterParams setCoeff (float coeff)
Set filter coefficient.
public FilterParams setSize (int size)
Set number of collected samples for filter.
HERE Android SDK Developer's Guide
API Reference
302
Class Details
Encapsulates parameters which affect data filtering.
Method Details
public float getCoeff ()
Get filter coefficient
Returns:
filter coefficient
public int getSize ()
Get number of collected samples for filter.
Returns:
filter size
public FilterParams setCoeff (float coeff)
Set filter coefficient.
Changing this value affects smoothing of filtered data. Increasing smoothing may increase the time before
raw data changes influence filtered output (i.e. latency).
Parameters:
coeff
filter coefficient
Returns:
The updated FilterParams object itself.
public FilterParams setSize (int size)
Set number of collected samples for filter.
Changing this value affects smoothing of filtered data. Increasing smoothing may increase the time before
raw data changes influence filtered output (i.e. latency).
Parameters:
size
filter size
Returns:
The updated FilterParams object itself.
HERE Android SDK Developer's Guide
API Reference
303
IconParams
The class IconParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.IconParams
extends java.lang.Object
Encapsulates parameters which affect the icons of an ARObject.
[For complete information, see the section Class Details]
Method Summary
Table 29: Methods in IconParams
Methods
public long getDepressAnimationDelay ()
Get delay of icon's depress animation.
public long getDepressAnimationTime ()
Get duration of icon's depress animation.
public float getDownIconOpacity ()
Get down icon's opacity.
public long getFlyAnimationDelay ()
Get delay of icon's fly animation.
public long getFlyAnimationTime ()
Get duration of icon's fly animation.
public AnimationInterpolator getFlyInterpolator ()
Get the interpolator for icon flying animation.
public Vector3f getFlyRotateAngles ()
Get icon's fly rotation angles.
public long getFlyRotateAnimationDelay ()
Get delay of icon's fly rotation animation.
public long getFlyRotateAnimationTime ()
Get duration of icon's fly rotation animation.
public long getPopUpAnimationDelay ()
Get delay of icon's first appearance animation(pop-up).
public long getPopUpAnimationTime ()
Get duration of icon's first appearance animation(pop-up).
HERE Android SDK Developer's Guide
API Reference
304
Methods
public AnimationInterpolator getPopUpInterpolator ()
Get the interpolator for icon pop up animation.
public long getPressAnimationDelay ()
Get delay of icon's tap animation.
public long getPressAnimationTime ()
Get duration of icon's press animation.
public AnimationInterpolator getTurnInterpolator ()
Get the interpolator for icon rotation animation.
public boolean getUseDownIconOpacity ()
Get enabled status of down icon's opacity.
public IconParams setBackIconMaxSize (int width, int height)
Set back icon maximum size
public IconParams setBackToFrontIconSizeRatio (float ratio)
Set back to front icon size ratio.
public IconParams setDefaultIcons (int frontIconId, int backIconId, int downIconId)
Set default icons resource ids.
public IconParams setDepressAnimationDelay (long time)
Set delay of icon's depress animation.
public IconParams setDepressAnimationTime (long time)
Set duration of icon's depress animation.
public IconParams setDownIconOpacity (float opacity)
Set down icon's opacity.
public IconParams setFlyAnimationDelay (long value)
Set icon's fly animation delay.
public IconParams setFlyAnimationTime (long value)
Set icon's fly animation duration.
public IconParams setFlyIconSizeOnMap (ARObject object, int width, int height)
Set fly animation initial icon size while transitioning from MAP to CAMERA view and final icon size while transitioning from
CAMERA to MAP view
public IconParams setFlyInterpolator (AnimationInterpolator value)
Set the interpolator for icon flying animation.
public IconParams setFlyRotateAngles (Vector3f value)
Set icon's fly rotation angles.
public IconParams setFlyRotateAnimationDelay (long value)
Set icon's fly rotation animation delay.
HERE Android SDK Developer's Guide
API Reference
305
Methods
public IconParams setFlyRotateAnimationTime (long value)
Set icon's fly rotation animation duration.
public IconParams setFrontIconMaxSize (int width, int height)
Set front icon maximum size
public IconParams setPopUpAnimationDelay (long value)
Set icon's first appearance animation(pop-up) delay.
public IconParams setPopUpAnimationTime (long value)
Set icon's first appearance animation(pop-up) duration.
public IconParams setPopUpInterpolator (AnimationInterpolator value)
Set the interpolator for icon pop up animation.
public IconParams setPressAnimationDelay (long time)
Set delay of icon's press animation.
public IconParams setPressAnimationTime (long time)
Set duration of icon's press animation.
public IconParams setTurnInterpolator (AnimationInterpolator value)
Set the interpolator for icon rotation animation.
public IconParams setUseDownIconOpacity (boolean enabled)
Enables/disables usage of down icon opacity, by default, it is enabled.
Class Details
Encapsulates parameters which affect the icons of an ARObject.
Method Details
public long getDepressAnimationDelay ()
Get delay of icon's depress animation.
Returns:
delay of icon's depress animation in ms.
public long getDepressAnimationTime ()
Get duration of icon's depress animation.
Returns:
duration of icon's depress animation in ms.
public float getDownIconOpacity ()
HERE Android SDK Developer's Guide
API Reference
306
Get down icon's opacity.
Returns:
down icon's opacity.
public long getFlyAnimationDelay ()
Get delay of icon's fly animation.
Returns:
delay of icon's fly animation in ms.
public long getFlyAnimationTime ()
Get duration of icon's fly animation.
Returns:
duration of icon's fly animation in Ms.
public AnimationInterpolator getFlyInterpolator ()
Get the interpolator for icon flying animation.
Returns:
AnimationInterpolator.
public Vector3f getFlyRotateAngles ()
Get icon's fly rotation angles.
Returns:
angles of rotation in degrees.
public long getFlyRotateAnimationDelay ()
Get delay of icon's fly rotation animation.
Returns:
delay of icon's fly rotation animation in ms.
public long getFlyRotateAnimationTime ()
Get duration of icon's fly rotation animation.
Returns:
HERE Android SDK Developer's Guide
API Reference
307
duration of icon's fly rotation animation in ms.
public long getPopUpAnimationDelay ()
Get delay of icon's first appearance animation(pop-up).
Returns:
delay of icon's first appearance animation(pop-up) in ms.
public long getPopUpAnimationTime ()
Get duration of icon's first appearance animation(pop-up).
Returns:
duration of icon's first appearance animation(pop-up) in ms.
public AnimationInterpolator getPopUpInterpolator ()
Get the interpolator for icon pop up animation.
Returns:
AnimationInterpolator.
public long getPressAnimationDelay ()
Get delay of icon's tap animation.
Returns:
delay of icon's tap animation in ms.
public long getPressAnimationTime ()
Get duration of icon's press animation.
Returns:
duration of icon's press animation in ms.
public AnimationInterpolator getTurnInterpolator ()
Get the interpolator for icon rotation animation.
Returns:
AnimationInterpolator.
HERE Android SDK Developer's Guide
API Reference
308
public boolean getUseDownIconOpacity ()
Get enabled status of down icon's opacity.
Returns:
down icon's opacity status.
public IconParams setBackIconMaxSize (int width, int height)
Set back icon maximum size
Parameters:
width
Maximum width of back icon in pixels
height
Maximum height of back icon in pixels
Returns:
The updated IconParams object itself.
public IconParams setBackToFrontIconSizeRatio (float ratio)
Set back to front icon size ratio. The ratio is taken into account ONLY if icon and info sizes are NOT set
explicitly. For example, a ratio of 0.5 means the back icon has half the width and height of the front icon.
Parameters:
ratio
back to front icon size ratio
Returns:
The updated IconParams object itself.
public IconParams setDefaultIcons (int frontIconId, int backIconId, int
downIconId)
Set default icons resource ids.
Parameters:
frontIconId
Front fallback icon resource Id
backIconId
Back fallback icon resource Id
downIconId
Down fallback icon resource Id
HERE Android SDK Developer's Guide
API Reference
309
Returns:
The updated IconParams object itself.
public IconParams setDepressAnimationDelay (long time)
Set delay of icon's depress animation.
Parameters:
time
delay of icon's depress animation in ms.
Returns:
The updated IconParams object itself.
public IconParams setDepressAnimationTime (long time)
Set duration of icon's depress animation.
Parameters:
time
duration of icon's depress animation in ms.
Returns:
The updated IconParams object itself.
public IconParams setDownIconOpacity (float opacity)
Set down icon's opacity.
Parameters:
opacity
Down icon's opacity.
Returns:
The updated IconParams object itself.
public IconParams setFlyAnimationDelay (long value)
Set icon's fly animation delay.
Parameters:
value
fly animation delay in ms
Returns:
HERE Android SDK Developer's Guide
API Reference
310
The updated IconParams object itself.
public IconParams setFlyAnimationTime (long value)
Set icon's fly animation duration.
Parameters:
value
fly animation duration in ms
Returns:
The updated IconParams object itself.
public IconParams setFlyIconSizeOnMap (ARObject object, int width, int
height)
Set fly animation initial icon size while transitioning from MAP to CAMERA view and final icon size while
transitioning from CAMERA to MAP view
Parameters:
object
An ARObject to set the size to
width
An icon width at the start/end of animation
height
An icon height at the start/end of animation
Returns:
The updated IconParams object itself.
public IconParams setFlyInterpolator (AnimationInterpolator value)
Set the interpolator for icon flying animation.
Parameters:
value
of AnimationInterpolator
Returns:
The updated IconParams object itself.
public IconParams setFlyRotateAngles (Vector3f value)
Set icon's fly rotation angles.
HERE Android SDK Developer's Guide
API Reference
311
Parameters:
value
icon's fly rotation angles in degrees.
Returns:
The updated IconParams object itself.
public IconParams setFlyRotateAnimationDelay (long value)
Set icon's fly rotation animation delay.
Parameters:
value
fly rotation animation delay in ms
Returns:
The updated IconParams object itself.
public IconParams setFlyRotateAnimationTime (long value)
Set icon's fly rotation animation duration.
Parameters:
value
fly rotation animation duration in ms
Returns:
The updated IconParams object itself.
public IconParams setFrontIconMaxSize (int width, int height)
Set front icon maximum size
Parameters:
width
Maximum width of front icon in pixels
height
Maximum height of front icon in pixels
Returns:
The updated IconParams object itself.
public IconParams setPopUpAnimationDelay (long value)
HERE Android SDK Developer's Guide
API Reference
312
Set icon's first appearance animation(pop-up) delay.
Parameters:
value
pop-up animation delay in ms
Returns:
The updated IconParams object itself.
public IconParams setPopUpAnimationTime (long value)
Set icon's first appearance animation(pop-up) duration.
Parameters:
value
pop-up animation duration in ms
Returns:
The updated IconParams object itself.
public IconParams setPopUpInterpolator (AnimationInterpolator value)
Set the interpolator for icon pop up animation.
Parameters:
value
of AnimationInterpolator
Returns:
The updated IconParams object itself.
public IconParams setPressAnimationDelay (long time)
Set delay of icon's press animation.
Parameters:
time
delay of icon's tap animation in ms.
Returns:
The updated IconParams object itself.
public IconParams setPressAnimationTime (long time)
Set duration of icon's press animation.
HERE Android SDK Developer's Guide
API Reference
313
Parameters:
time
duration of icon's press animation in ms.
Returns:
The updated IconParams object itself.
public IconParams setTurnInterpolator (AnimationInterpolator value)
Set the interpolator for icon rotation animation.
Parameters:
value
The AnimationInterpolator for the icon rotation animation
Returns:
The updated IconParams object itself.
public IconParams setUseDownIconOpacity (boolean enabled)
Enables/disables usage of down icon opacity, by default, it is enabled. When enabled, down icons will use
the opacity specified through setDownIconOpacity(float), instead of the opacity computed for up icons.
Parameters:
enabled
Enabled status
Returns:
The updated IconParams object itself.
InfoParams
The class InfoParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.InfoParams
extends java.lang.Object
Encapsulates parameters which affect the info of an ARObject.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
314
Method Summary
Table 30: Methods in InfoParams
Methods
public float getAnimationMinWidthFactor ()
Get info's animation minimum width factor.
public long getCloseAnimationDelay ()
Get delay of Info's close animation.
public long getCloseAnimationTime ()
Get duration of Info's close animation.
public AnimationInterpolator getCloseInterpolator ()
Get the interpolator for info icon close animation.
public long getOpenAnimationDelay ()
Get delay of Info's open animation.
public long getOpenAnimationTime ()
Get duration of Info's open animation.
public AnimationInterpolator getOpenInterpolator ()
Get the interpolator for info icon open animation.
public InfoParams setAnimationMinWidthFactor (float value)
Set info's minimum width factor during animation.
public InfoParams setCloseAnimationDelay (long value)
Set Info's close animation delay.
public InfoParams setCloseAnimationTime (long value)
Set Info's close animation duration.
public InfoParams setCloseInterpolator (AnimationInterpolator value)
Set the interpolator for info close animation.
public InfoParams setOpenAnimationDelay (long value)
Set Info's open animation delay.
public InfoParams setOpenAnimationTime (long value)
Set Info's open animation duration.
public InfoParams setOpenInterpolator (AnimationInterpolator value)
Set the interpolator for info open animation.
Class Details
Encapsulates parameters which affect the info of an ARObject.
HERE Android SDK Developer's Guide
API Reference
315
Method Details
public float getAnimationMinWidthFactor ()
Get info's animation minimum width factor.
Returns:
info animation's minimum width factor.
public long getCloseAnimationDelay ()
Get delay of Info's close animation.
Returns:
delay of Info's close animation in ms.
public long getCloseAnimationTime ()
Get duration of Info's close animation.
Returns:
duration of Info's close animation in ms.
public AnimationInterpolator getCloseInterpolator ()
Get the interpolator for info icon close animation.
Returns:
AnimationInterpolator.
public long getOpenAnimationDelay ()
Get delay of Info's open animation.
Returns:
delay of open animation in ms.
public long getOpenAnimationTime ()
Get duration of Info's open animation.
Returns:
duration of Info's open animation in ms.
public AnimationInterpolator getOpenInterpolator ()
HERE Android SDK Developer's Guide
API Reference
316
Get the interpolator for info icon open animation.
Returns:
AnimationInterpolator.
public InfoParams setAnimationMinWidthFactor (float value)
Set info's minimum width factor during animation.
Parameters:
value
minimum width factor.
Returns:
The updated InfoParams object itself.
public InfoParams setCloseAnimationDelay (long value)
Set Info's close animation delay.
Parameters:
value
pop-up animation delay in ms.
Returns:
The updated InfoParams object itself.
public InfoParams setCloseAnimationTime (long value)
Set Info's close animation duration.
Parameters:
value
pop-up animation duration in ms.
Returns:
The updated InfoParams object itself.
public InfoParams setCloseInterpolator (AnimationInterpolator value)
Set the interpolator for info close animation.
Parameters:
value
The AnimationInterpolator for info close animation.
HERE Android SDK Developer's Guide
API Reference
317
Returns:
The updated InfoParams object itself.
public InfoParams setOpenAnimationDelay (long value)
Set Info's open animation delay.
Parameters:
value
pop-up animation delay in ms.
Returns:
The updated InfoParams object itself.
public InfoParams setOpenAnimationTime (long value)
Set Info's open animation duration.
Parameters:
value
pop-up animation duration in ms.
Returns:
The updated InfoParams object itself.
public InfoParams setOpenInterpolator (AnimationInterpolator value)
Set the interpolator for info open animation.
Parameters:
value
The AnimationInterpolator for info open animation.
Returns:
The updated InfoParams object itself.
IntroAnimationMode
The enumeration IntroAnimationMode is a member of com.here.android.mpa.ar.ARController.
Enumeration Summary
public static final enumeration ARController.IntroAnimationMode
HERE Android SDK Developer's Guide
API Reference
318
extends java.lang.Enum, java.lang.Object
Intro animation mode.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 31: Enum Constants in IntroAnimationMode
Fields
public static final IntroAnimationMode DEFAULT
All properties of the Map pitch, heading, zoom, pixel and geo transform centers are animated at once.
public static final IntroAnimationMode FLY_TO_LOCATION
Animate flying to current or alternative(See setAlternativeCenter()) geo location and afterwards animate other Map's
properties.
Method Summary
Table 32: Methods in IntroAnimationMode
Methods
public static IntroAnimationMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARController.IntroAnimationMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Intro animation mode. See ARController.IntroAnimationParams.
Enum Constant Details
public static final IntroAnimationMode DEFAULT
All properties of the Map pitch, heading, zoom, pixel and geo transform centers are animated at once. Default
mode.
public static final IntroAnimationMode FLY_TO_LOCATION
Animate flying to current or alternative(See setAlternativeCenter()) geo location and afterwards animate
other Map's properties.
Method Details
public static IntroAnimationMode valueOf (String name)
HERE Android SDK Developer's Guide
API Reference
319
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARController.IntroAnimationMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
IntroAnimationParams
The class IntroAnimationParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.IntroAnimationParams
extends java.lang.Object
Encapsulates parameters which affect the Intro Animation.
[For complete information, see the section Class Details]
Method Summary
Table 33: Methods in IntroAnimationParams
Methods
public long getAnimationTime ()
Get duration of intro transition animation.
public AnimationInterpolator getCenterInterpolator ()
Get the interpolator for intro(LiveSight entry) first person's location animation.
public AnimationInterpolator getHeadingInterpolator ()
Get the interpolator for intro(LiveSight entry) heading animation.
public IntroAnimationMode getIntroAnimationMode ()
Get intro animation mode.
public AnimationInterpolator getPitchInterpolator ()
Get the interpolator for intro(LiveSight entry) pitch animation.
public AnimationInterpolator getPositionInterpolator ()
Get the interpolator for intro(LiveSight entry) position change animation.
public AnimationInterpolator getZoomInterpolator ()
Get the interpolator for intro(LiveSight entry) zoom animation.
HERE Android SDK Developer's Guide
API Reference
320
Methods
public IntroAnimationParams setAnimationTime (long value)
Set the value of intro transition animation duration.
public IntroAnimationParams setCenterInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) first person's location animation.
public IntroAnimationParams setHeadingInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) heading animation.
public IntroAnimationParams setIntroAnimationMode (IntroAnimationMode mode)
Set intro animation mode.
public IntroAnimationParams setPitchInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) pitch animation.
public IntroAnimationParams setPositionInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) position change animation.
public IntroAnimationParams setZoomInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) zoom animation.
Class Details
Encapsulates parameters which affect the Intro Animation. The Intro Animation refers to the animation that
is performed right after calling start().
Method Details
public long getAnimationTime ()
Get duration of intro transition animation.
Returns:
duration of intro transition animation in ms.
public AnimationInterpolator getCenterInterpolator ()
Get the interpolator for intro(LiveSight entry) first person's location animation.
Returns:
AnimationInterpolator.
public AnimationInterpolator getHeadingInterpolator ()
Get the interpolator for intro(LiveSight entry) heading animation.
Returns:
AnimationInterpolator.
HERE Android SDK Developer's Guide
API Reference
321
public IntroAnimationMode getIntroAnimationMode ()
Get intro animation mode.
Returns:
ARController.IntroAnimationMode.
public AnimationInterpolator getPitchInterpolator ()
Get the interpolator for intro(LiveSight entry) pitch animation.
Returns:
AnimationInterpolator.
public AnimationInterpolator getPositionInterpolator ()
Get the interpolator for intro(LiveSight entry) position change animation.
Returns:
AnimationInterpolator.
public AnimationInterpolator getZoomInterpolator ()
Get the interpolator for intro(LiveSight entry) zoom animation.
Returns:
AnimationInterpolator.
public IntroAnimationParams setAnimationTime (long value)
Set the value of intro transition animation duration.
Parameters:
value
intro transition animation duration in ms
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setCenterInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) first person's location animation.
Parameters:
value
HERE Android SDK Developer's Guide
API Reference
322
The AnimationInterpolator for intro first person's location animation
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setHeadingInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) heading animation.
Parameters:
value
The AnimationInterpolator for intro heading animation
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setIntroAnimationMode (IntroAnimationMode mode)
Set intro animation mode.
Parameters:
mode
The ARController.IntroAnimationMode for intro animation
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setPitchInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) pitch animation.
Parameters:
value
The AnimationInterpolator for intro pitch animation
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setPositionInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) position change animation.
Parameters:
value
The AnimationInterpolator for intro position change animation
HERE Android SDK Developer's Guide
API Reference
323
Returns:
The updated IntroAnimationParams object itself.
public IntroAnimationParams setZoomInterpolator (AnimationInterpolator value)
Set the interpolator for intro(LiveSight entry) zoom animation.
Parameters:
value
The AnimationInterpolator for intro zoom animation.
Returns:
The updated IntroAnimationParams object itself.
OnCameraEnteredListener
The interface OnCameraEnteredListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnCameraEnteredListener
Listener for Camera view entered event.
[For complete information, see the section Interface Details]
Method Summary
Table 34: Methods in OnCameraEnteredListener
Methods
public abstract void onCameraEntered ()
A callback indicating that Camera view is entered
Interface Details
Listener for Camera view entered event. This event is triggered just before the Camera view (containing the
camera frame and AR Objects) is displayed.
Method Details
public abstract void onCameraEntered ()
A callback indicating that Camera view is entered
HERE Android SDK Developer's Guide
API Reference
324
OnCameraExitedListener
The interface OnCameraExitedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnCameraExitedListener
Listener for Camera view exited event.
[For complete information, see the section Interface Details]
Method Summary
Table 35: Methods in OnCameraExitedListener
Methods
public abstract void onCameraExited ()
A callback indicating that Camera view is exited
Interface Details
Listener for Camera view exited event. This event is triggered just after the Camera view (containing the
camera frame and AR Objects) is exited.
Method Details
public abstract void onCameraExited ()
A callback indicating that Camera view is exited
OnCompassCalibrationChangedListener
The interface OnCompassCalibrationChangedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnCompassCalibrationChangedListener
Listener for compass calibration changed event.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
325
Method Summary
Table 36: Methods in OnCompassCalibrationChangedListener
Methods
public abstract void onCompassCalibrationChange ()
A callback indicating that compass calibration changed
Interface Details
Listener for compass calibration changed event. This event is triggered by the system when the compass
calibration status changes.
Method Details
public abstract void onCompassCalibrationChange ()
A callback indicating that compass calibration changed
OnLivesightStatusListener
The interface OnLivesightStatusListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnLivesightStatusListener
Monitor overall livesight status.
[For complete information, see the section Interface Details]
Method Summary
Table 37: Methods in OnLivesightStatusListener
Methods
public abstract void onLivesightStatus (Error code)
Notification for overall livesight status
Interface Details
Monitor overall livesight status.
There may be the situations where hardware or other system componets are not behave as expected. This
notification allows application to handle such situations in the most suitable way. The same status may be
reported more then once depensing on the internal state of the livesight.
HERE Android SDK Developer's Guide
API Reference
326
Method Details
public abstract void onLivesightStatus (Error code)
Notification for overall livesight status
Parameters:
code
Error code
OnMapEnteredListener
The interface OnMapEnteredListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnMapEnteredListener
Listener for Map view entered event.
[For complete information, see the section Interface Details]
Method Summary
Table 38: Methods in OnMapEnteredListener
Methods
public abstract void onMapEntered ()
A callback indicating that Map view is entered
Interface Details
Listener for Map view entered event. This event is triggered just before the Map view is displayed.
Method Details
public abstract void onMapEntered ()
A callback indicating that Map view is entered
OnMapExitedListener
The interface OnMapExitedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnMapExitedListener
HERE Android SDK Developer's Guide
API Reference
327
Listener for Map view exited event.
[For complete information, see the section Interface Details]
Method Summary
Table 39: Methods in OnMapExitedListener
Methods
public abstract void onMapExited ()
A callback indicating that Map view is exited
Interface Details
Listener for Map view exited event. This event is triggered just after the Map view is exited.
Method Details
public abstract void onMapExited ()
A callback indicating that Map view is exited
OnObjectTappedListener
The interface OnObjectTappedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnObjectTappedListener
Listener for object tap events.
[For complete information, see the section Interface Details]
Method Summary
Table 40: Methods in OnObjectTappedListener
Methods
public abstract boolean onObjectTapped (java.util.List <ARObject> objects)
A callback indicating that at least one ARObject is located at the users tap point.
Interface Details
Listener for object tap events.
HERE Android SDK Developer's Guide
API Reference
328
Method Details
public abstract boolean onObjectTapped (java.util.List <ARObject> objects)
A callback indicating that at least one ARObject is located at the users tap point.
If there are ARObject s located at the users tap point, this callback will be made before onTap(PointF). If
true is returned from this callback, onTap(PointF) on the tap listener will not be called.
Parameters:
objects
A list of selected ARObject objects
Returns:
true if consumed (which prevents calling of onTap(PointF)), false otherwise.
OnPanListener
The interface OnPanListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPanListener
Listener for pan events.
[For complete information, see the section Interface Details]
Method Summary
Table 41: Methods in OnPanListener
Methods
public abstract boolean onPan (PointF from, PointF to)
A callback indicating that a pan operation occurred.
Interface Details
Listener for pan events. Use of panTo(GeoCoordinate) API does not trigger this callback.
Method Details
public abstract boolean onPan (PointF from, PointF to)
A callback indicating that a pan operation occurred.
Parameters:
from
A PointF representing the start point
HERE Android SDK Developer's Guide
API Reference
329
to
A PointF representing the end point
Returns:
If true, event is consumed, false otherwise. If true is returned, panning will no longer be performed by the
controller.
OnPitchFunction
The interface OnPitchFunction is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPitchFunction
Pitch function interface.
[For complete information, see the section Interface Details]
Method Summary
Table 42: Methods in OnPitchFunction
Methods
public abstract float onPitchFunction (float pitch)
Function applied to the current pitch
Interface Details
Pitch function interface.
It gives ability to apply a function to the current device's pitch/tilt value to change the resulting pitch curve.
Special consideration should be used when setAutoPitchEnabled(boolean, boolean) API is called. This
method uses the current Map's value, which *may* be altered by the pitch function, thus effecting the
animation.
Method Details
public abstract float onPitchFunction (float pitch)
Function applied to the current pitch
Parameters:
pitch
An argument to the function of pitch representing default pitch value
Returns:
HERE Android SDK Developer's Guide
API Reference
330
Result of client pitch function, a custom pitch value for LiveSight to use.
OnPoseListener
The interface OnPoseListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPoseListener
Listener for pose update events.
[For complete information, see the section Interface Details]
Method Summary
Table 43: Methods in OnPoseListener
Methods
public abstract void onPose (ARPoseReading pose)
A callback indicating that the pose has been updated.
Interface Details
Listener for pose update events.
Method Details
public abstract void onPose (ARPoseReading pose)
A callback indicating that the pose has been updated. This can be triggered by the user moving the device
(tilting, rotating or changing position).
Parameters:
pose
An ARPoseReading representing the new pose
OnPostPresentListener
The interface OnPostPresentListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPostPresentListener
Listener for the post draw event.
HERE Android SDK Developer's Guide
API Reference
331
[For complete information, see the section Interface Details]
Method Summary
Table 44: Methods in OnPostPresentListener
Methods
public abstract void onPostPresent ()
A callback indicating that a draw has just been performed
Interface Details
Listener for the post draw event. This event is triggered just after a present is performed.
Called on the Render thread.
Method Details
public abstract void onPostPresent ()
A callback indicating that a draw has just been performed
Called on the Render thread.
OnPreDrawListener
The interface OnPreDrawListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPreDrawListener
Listener for the livesight frame pre draw event.
[For complete information, see the section Interface Details]
Method Summary
Table 45: Methods in OnPreDrawListener
Methods
public abstract void onPreDraw ()
Livesight frame pre draw callback
HERE Android SDK Developer's Guide
API Reference
332
Interface Details
Listener for the livesight frame pre draw event. This event is triggered just before the livesight frame is
being composited. This listener is useful in case client wants to update items before they are drawn and
synchronize the update action with the draw cycle.
Called on the Render thread.
Method Details
public abstract void onPreDraw ()
Livesight frame pre draw callback
Called on the Render thread.
OnPreDrawMapListener
The interface OnPreDrawMapListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPreDrawMapListener
Listener for the map pre draw event.
[For complete information, see the section Interface Details]
Method Summary
Table 46: Methods in OnPreDrawMapListener
Methods
public abstract void onPreDrawMap (float orientationDeg, float tiltDeg, GeoCoordinate center)
Map pre draw callback
Interface Details
Listener for the map pre draw event. This event is triggered just before the map is being drawn. This listener
is useful in case client wants to update things on the map and synchronize the update action with the draw
cycle.
Called on the Render thread.
Method Details
public abstract void onPreDrawMap (float orientationDeg, float tiltDeg,
GeoCoordinate center)
Map pre draw callback
HERE Android SDK Developer's Guide
API Reference
333
Called on the Render thread.
Parameters:
orientationDeg
Current Map orientation in degrees
tiltDeg
Current Map tilt in degrees
center
Current Map center
OnPrePresentListener
The interface OnPrePresentListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnPrePresentListener
Listener for the pre present event.
[For complete information, see the section Interface Details]
Method Summary
Table 47: Methods in OnPrePresentListener
Methods
public abstract void onPrePresent ()
A callback indicating that a draw is going to be performed
Interface Details
Listener for the pre present event. This event is triggered just before a present is performed. This listener
is useful in case client wants to update items in AR just before they are presented to the screen and
synchronize the update action with the AR draw cycle.
Called on the Render thread.
Method Details
public abstract void onPrePresent ()
A callback indicating that a draw is going to be performed
Called on the Render thread.
HERE Android SDK Developer's Guide
API Reference
334
OnProjectionCameraUpdatedListener
The interface OnProjectionCameraUpdatedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnProjectionCameraUpdatedListener
Monitor livesight projection camera.
[For complete information, see the section Interface Details]
Method Summary
Table 48: Methods in OnProjectionCameraUpdatedListener
Methods
public abstract void onProjectionCameraUpdated ()
Notification of projection camera changes
Interface Details
Monitor livesight projection camera.
It gives the ability to react to changes in projection camera. Can be used for updating pixel to local position
associations.
Method Details
public abstract void onProjectionCameraUpdated ()
Notification of projection camera changes
OnRadarUpdateListener
The interface OnRadarUpdateListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnRadarUpdateListener
Listener for radar update events.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
335
Method Summary
Table 49: Methods in OnRadarUpdateListener
Methods
public abstract void onRadarUpdate (ARRadarProperties radar)
A callback indicating that ARRadarProperties have been updated.
Interface Details
Listener for radar update events.
Method Details
public abstract void onRadarUpdate (ARRadarProperties radar)
A callback indicating that ARRadarProperties have been updated.
Parameters:
radar
An ARRadarProperties object representing the updated properties.
OnSensorCalibrationChangedListener
The interface OnSensorCalibrationChangedListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnSensorCalibrationChangedListener
Listener for sensor calibration events.
[For complete information, see the section Interface Details]
Method Summary
Table 50: Methods in OnSensorCalibrationChangedListener
Methods
public abstract void onSensorCalibrationChanged (int type, int status)
Notification for sensor status changed
Interface Details
Listener for sensor calibration events.
HERE Android SDK Developer's Guide
API Reference
336
Method Details
public abstract void onSensorCalibrationChanged (int type, int status)
Notification for sensor status changed
Parameters:
type
can be one of the following values:
Sensor.TYPE_ACCELEROMETER
Sensor.TYPE_MAGNETIC_FIELD
Sensor.TYPE_GYROSCOP
status
can be one of the following values:
SensorManager.SENSOR_STATUS_UNRELIABLE
SensorManager.SENSOR_STATUS_ACCURACY_LOW
SensorManager.SENSOR_STATUS_ACCURACY_MEDIUM
SensorManager.SENSOR_STATUS_ACCURACY_HIGH
OnTapListener
The interface OnTapListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnTapListener
Listener for tap events.
[For complete information, see the section Interface Details]
Method Summary
Table 51: Methods in OnTapListener
Methods
public abstract boolean onTap (PointF point)
A callback indicating a tap has occurred
Interface Details
Listener for tap events.
Method Details
public abstract boolean onTap (PointF point)
HERE Android SDK Developer's Guide
API Reference
337
A callback indicating a tap has occurred
Parameters:
point
A PointF representing the touch point
Returns:
If true, event is consumed, false otherwise. If true is returned, touch action will no longer be performed by
the controller.
OnTouchDownListener
The interface OnTouchDownListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnTouchDownListener
Listener for touch down events.
[For complete information, see the section Interface Details]
Method Summary
Table 52: Methods in OnTouchDownListener
Methods
public abstract boolean onTouchDown (PointF point)
A callback indicating a touch has been initiated
Interface Details
Listener for touch down events.
Method Details
public abstract boolean onTouchDown (PointF point)
A callback indicating a touch has been initiated
Parameters:
point
A PointF representing the touch point
Returns:
If true, event is consumed, false otherwise. If true is returned, touch action will no longer be performed by
the controller.
HERE Android SDK Developer's Guide
API Reference
338
OnTouchUpListener
The interface OnTouchUpListener is a member of com.here.android.mpa.ar.ARController.
Interface Summary
public static abstract interface ARController.OnTouchUpListener
Listener for touch up events.
[For complete information, see the section Interface Details]
Method Summary
Table 53: Methods in OnTouchUpListener
Methods
public abstract boolean onTouchUp (PointF point)
A callback indicating a touch has been released
Interface Details
Listener for touch up events.
Method Details
public abstract boolean onTouchUp (PointF point)
A callback indicating a touch has been released
Parameters:
point
A PointF representing the touch point
Returns:
If true, event is consumed, false otherwise. If true is returned, touch action will no longer be performed by
the controller.
ProjectionType
The enumeration ProjectionType is a member of com.here.android.mpa.ar.ARController.
Enumeration Summary
public static final enumeration ARController.ProjectionType
HERE Android SDK Developer's Guide
API Reference
339
extends java.lang.Enum, java.lang.Object
Type of the projection used by the LiveSight engine while displaying ARObjects in the camera/UP view.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 54: Enum Constants in ProjectionType
Fields
public static final ProjectionType NEAR_FAR
Near-far projection.
public static final ProjectionType DIRECT_3D
Direct 3D projection.
public static final ProjectionType HORIZONTAL
HORIZONTAL projection.
public static final ProjectionType MAP
Map projection.
public static final ProjectionType USE_GLOBAL_PROJECTION_TYPE
USE_GLOBAL_PROJECTION_TYPE projection.
Method Summary
Table 55: Methods in ProjectionType
Methods
public static ProjectionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARController.ProjectionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Type of the projection used by the LiveSight engine while displaying ARObjects in the camera/UP view.
Enum Constant Details
public static final ProjectionType NEAR_FAR
Near-far projection. ARObject s appear in one of two planes defined by setPlanesParameters(float, float,
float, float). In FAR plane items are displayed without details portion with reduced opacity as function of
distance to the view point. In NEAR plane items are displayed with details portion. Default value.
HERE Android SDK Developer's Guide
API Reference
340
public static final ProjectionType DIRECT_3D
Direct 3D projection. ARObject s appear in 3D space as a result of direct projection of Geolocation.
public static final ProjectionType HORIZONTAL
HORIZONTAL projection. ARObject s appear in one horizontal line.
public static final ProjectionType MAP
Map projection. ARObject s appear in the positions retrieved by projectToPixel(GeoCoordinate) API.
public static final ProjectionType USE_GLOBAL_PROJECTION_TYPE
USE_GLOBAL_PROJECTION_TYPE projection. ARObject s appear in the projection set for ARController globaly.
Method Details
public static ProjectionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARController.ProjectionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SelectedItemParams
The class SelectedItemParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.SelectedItemParams
extends java.lang.Object
Encapsulates parameters which affect ARObjects which are in the selected or non selected states.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
341
Method Summary
Table 56: Methods in SelectedItemParams
Methods
public long getBoundingBoxAnimationDelay ()
Get delay of selected item bounding box animation.
public long getBoundingBoxAnimationTime ()
Get delay of selected item bounding box animation.
public AnimationInterpolator getBoundingBoxInterpolator ()
Get the interpolator for selected object bounding box animation.
public float getMaxViewAngle ()
Get selected item max view angle when the item is on the right or left from line of sight.
public float getNonSelectedItemsOpacity ()
Get others icons opacity while one icon is in selected state.
public float getOpacity ()
Get selected item's opacity when icon in camera view is selected.
public Size getSize ()
Get selected item size.
public long getSizeAnimationDelay ()
Get delay of selected item size animation.
public long getSizeAnimationTime ()
Get delay of selected item size animation.
public AnimationInterpolator getSizeInterpolator ()
Get the interpolator for selected object size animation.
public SelectedItemParams setBoundingBox (RectF box)
Set bounding box for a selected item.
public SelectedItemParams setBoundingBoxAnimationDelay (long value)
Set selected item bounding box animation delay.
public SelectedItemParams setBoundingBoxAnimationTime (long value)
Set selected item bounding box animation time.
public SelectedItemParams setBoundingBoxInterpolator (AnimationInterpolator value)
Set the interpolator for selected object bounding box animation.
public SelectedItemParams setMaxViewAngle (float angleDeg)
Set selected item max view angle when the item is on the right or left from line of sight.
public SelectedItemParams setNonSelectedItemsOpacity (float value)
Set others icons opacity while one icon is in selected state.
HERE Android SDK Developer's Guide
API Reference
342
Methods
public SelectedItemParams setOpacity (float value)
Set selected item's opacity when icon in camera view is selected.
public SelectedItemParams setSize (int width, int height)
Set selected item size.
public SelectedItemParams setSizeAnimationDelay (long value)
Set selected item size animation delay.
public SelectedItemParams setSizeAnimationTime (long value)
Set selected item size animation time.
public SelectedItemParams setSizeInterpolator (AnimationInterpolator value)
Set the interpolator for selected object size animation.
Class Details
Encapsulates parameters which affect ARObjects which are in the selected or non selected states.
An ARObject is selected by way of the select(ARObject) method. When an ARObject is selected, all other
ARObject s are considered non selected. When no ARObject is selected, ARObject s are neither selected
nor non selected.
Method Details
public long getBoundingBoxAnimationDelay ()
Get delay of selected item bounding box animation.
Returns:
delay in ms
public long getBoundingBoxAnimationTime ()
Get delay of selected item bounding box animation.
Returns:
delay in ms
public AnimationInterpolator getBoundingBoxInterpolator ()
Get the interpolator for selected object bounding box animation.
Returns:
AnimationInterpolator.
public float getMaxViewAngle ()
HERE Android SDK Developer's Guide
API Reference
343
Get selected item max view angle when the item is on the right or left from line of sight.
Returns:
The view angle at the selected item. The range is: -angleDeg +angleDeg.
public float getNonSelectedItemsOpacity ()
Get others icons opacity while one icon is in selected state.
Returns:
non-selected icon opacity.
public float getOpacity ()
Get selected item's opacity when icon in camera view is selected.
Returns:
selected icon opacity.
public Size getSize ()
Get selected item size. This size is used when ARObject is in selected state.
Returns:
icon size when selected.
See also:
select(ARObject)
unselect()
public long getSizeAnimationDelay ()
Get delay of selected item size animation.
Returns:
delay in ms
public long getSizeAnimationTime ()
Get delay of selected item size animation.
Returns:
delay in ms
HERE Android SDK Developer's Guide
API Reference
344
public AnimationInterpolator getSizeInterpolator ()
Get the interpolator for selected object size animation.
Returns:
AnimationInterpolator.
public SelectedItemParams setBoundingBox (RectF box)
Set bounding box for a selected item. All values(left, top, right and bottom) are the ratios of the view's height
and width. Value of 0 for left an top and 1 for right and bottom indicate that there are no boundaries are
actually used. Values > 0 and < 1 are used to set absolute boundaries considerring selected icon half size, so
that icon is shown on the screen fully.
Parameters:
box
android.graphics.RectF selected item's bounding box. If null, bounding box for the selected item
is not used.
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setBoundingBoxAnimationDelay (long value)
Set selected item bounding box animation delay.
Parameters:
value
Delay in ms
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setBoundingBoxAnimationTime (long value)
Set selected item bounding box animation time.
Parameters:
value
Delay in ms
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setBoundingBoxInterpolator (AnimationInterpolator value)
HERE Android SDK Developer's Guide
API Reference
345
Set the interpolator for selected object bounding box animation.
Parameters:
value
The AnimationInterpolator for selected object bounding box animation.
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setMaxViewAngle (float angleDeg)
Set selected item max view angle when the item is on the right or left from line of sight.
Parameters:
angleDeg
The view angle at the selected item. The range is: -angleDeg +angleDeg.
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setNonSelectedItemsOpacity (float value)
Set others icons opacity while one icon is in selected state.
Parameters:
value
non-selected icons opacity.
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setOpacity (float value)
Set selected item's opacity when icon in camera view is selected.
Parameters:
value
selected icon opacity.
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setSize (int width, int height)
Set selected item size. This size is used when ARObject is in selected state.
HERE Android SDK Developer's Guide
API Reference
346
Parameters:
width
Maximum width of selected icon in pixels
height
Maximum height of selected icon in pixels
Returns:
The updated SelectedItemParams object itself.
See also:
select(ARObject)
unselect()
public SelectedItemParams setSizeAnimationDelay (long value)
Set selected item size animation delay.
Parameters:
value
Delay in ms
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setSizeAnimationTime (long value)
Set selected item size animation time.
Parameters:
value
Delay in ms
Returns:
The updated SelectedItemParams object itself.
public SelectedItemParams setSizeInterpolator (AnimationInterpolator value)
Set the interpolator for selected object size animation.
Parameters:
value
The AnimationInterpolator for selected object size animation.
Returns:
HERE Android SDK Developer's Guide
API Reference
347
The updated SelectedItemParams object itself.
SensorType
The enumeration SensorType is a member of com.here.android.mpa.ar.ARController.
Enumeration Summary
public static final enumeration ARController.SensorType
extends java.lang.Enum, java.lang.Object
Type of sensors used by the LiveSight engine.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 57: Enum Constants in SensorType
Fields
public static final SensorType GPS
GPS coordinates sensor.
public static final SensorType COMPASS
Compass or magnetometer sensor.
public static final SensorType ACCELEROMETER
Accelerometer sensor.
public static final SensorType GYROSCOPE
Gyroscope sensor.
public static final SensorType CAMERA
Camera unit (video sensor).
Method Summary
Table 58: Methods in SensorType
Methods
public static SensorType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARController.SensorType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
348
Enumeration Details
Type of sensors used by the LiveSight engine. See ARController.ExternalSensors.
Enum Constant Details
public static final SensorType GPS
GPS coordinates sensor.
public static final SensorType COMPASS
Compass or magnetometer sensor.
public static final SensorType ACCELEROMETER
Accelerometer sensor.
public static final SensorType GYROSCOPE
Gyroscope sensor.
public static final SensorType CAMERA
Camera unit (video sensor).
Method Details
public static SensorType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARController.SensorType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UpViewParams
The class UpViewParams is a member of com.here.android.mpa.ar.ARController.
HERE Android SDK Developer's Guide
API Reference
349
Class Summary
public final class ARController.UpViewParams
extends java.lang.Object
Encapsulates parameters which affect the Up view.
[For complete information, see the section Class Details]
Method Summary
Table 59: Methods in UpViewParams
Methods
public float getCameraFrameMaxZoomScale ()
Gets current Max zoom scale as increase from the original
public float getPitchThreshold ()
Get pitch threshold when Down view transitions to Up view
public boolean isCameraFrameZoomEnabled ()
Check if camera frame zoom is enabled in UP view
public boolean isEdgeDetectionEnabled ()
Check if edge detection mode is enabled.
public boolean isPanEnabled ()
Check if pan is enabled in UP view
public boolean isPinchEnabled ()
Check if pinch is enabled in UP view
public boolean isPitchLocked ()
Check if pitch is locked in UP view
public boolean isShowGridEnabled ()
Check if showing the bottom plane grid is enabled in UP view
public UpViewParams setCameraFrameMaxZoomScale (float value)
Sets Max zoom scale as increase from the original to be used when pulled in UP view
public UpViewParams setCameraFrameZoomEnabled (boolean enable)
Enables or disables camera frame zoom, when pushed or pulled in LiveSight
public void setEdgeDetectionEnabled (boolean enabled)
Enable/disable mode where the camera frame gets processed for accurate placement of the LiveSight objects in the
camera scene.
public UpViewParams setPanEnabled (boolean enable)
Enables or disables pan gesture in UP view
public UpViewParams setPinchEnabled (boolean enable)
Enables or disables pinch gesture in UP view
HERE Android SDK Developer's Guide
API Reference
350
Methods
public UpViewParams setPitchLocked (boolean locked)
Enable/disable locked pitch in UP view
public UpViewParams setPitchThreshold (float value)
Set Pitch threshold when Down view transitions to Up View
public UpViewParams setShowGridEnabled (boolean enabled)
Enable/disable showing the bottom plane grid in UP view
Class Details
Encapsulates parameters which affect the Up view.
Method Details
public float getCameraFrameMaxZoomScale ()
Gets current Max zoom scale as increase from the original
Returns:
Max camera zoom scale
public float getPitchThreshold ()
Get pitch threshold when Down view transitions to Up view
Returns:
pitch value which triggers transition to Up view
public boolean isCameraFrameZoomEnabled ()
Check if camera frame zoom is enabled in UP view
Returns:
Camera zoom enable setting
public boolean isEdgeDetectionEnabled ()
Check if edge detection mode is enabled.
Returns:
true if edge detection is enabled.
See also:
setEdgeDetectionEnabled(boolean)
HERE Android SDK Developer's Guide
API Reference
351
public boolean isPanEnabled ()
Check if pan is enabled in UP view
Returns:
Pan enable setting
public boolean isPinchEnabled ()
Check if pinch is enabled in UP view
Returns:
Pinch enable setting
public boolean isPitchLocked ()
Check if pitch is locked in UP view
Returns:
Pitch lock setting
public boolean isShowGridEnabled ()
Check if showing the bottom plane grid is enabled in UP view
Returns:
flag indicating if this feature is enabled
public UpViewParams setCameraFrameMaxZoomScale (float value)
Sets Max zoom scale as increase from the original to be used when pulled in UP view
Parameters:
value
max frame zoom when pulled
Returns:
The updated UpViewParams object itself.
public UpViewParams setCameraFrameZoomEnabled (boolean enable)
Enables or disables camera frame zoom, when pushed or pulled in LiveSight
Parameters:
enable
HERE Android SDK Developer's Guide
API Reference
352
Enables if true or disables if false. This is disabled by default.
Returns:
The updated UpViewParams object itself.
public void setEdgeDetectionEnabled (boolean enabled)
Enable/disable mode where the camera frame gets processed for accurate placement of the LiveSight
objects in the camera scene. Enabled by default. It is recommended to disable the edge detection in low light
conditions.
Parameters:
enabled
If true, edge detection mode is enabled.
public UpViewParams setPanEnabled (boolean enable)
Enables or disables pan gesture in UP view
Parameters:
enable
Enables if true or disables if false. Default: enabled.
Returns:
The updated UpViewParams object itself.
public UpViewParams setPinchEnabled (boolean enable)
Enables or disables pinch gesture in UP view
Parameters:
enable
Enables if true or disables if false. By default, pinch gesture is enabled.
Returns:
The updated UpViewParams object itself.
public UpViewParams setPitchLocked (boolean locked)
Enable/disable locked pitch in UP view
Parameters:
locked
HERE Android SDK Developer's Guide
API Reference
353
Lock value
Returns:
The updated UpViewParams object itself.
public UpViewParams setPitchThreshold (float value)
Set Pitch threshold when Down view transitions to Up View
Parameters:
value
Pitch value ranges from 0...180
Returns:
The updated UpViewParams object itself.
public UpViewParams setShowGridEnabled (boolean enabled)
Enable/disable showing the bottom plane grid in UP view
Parameters:
enabled
Flag indicating if this feature is enabled
Returns:
The updated UpViewParams object itself.
UpViewTransitionParams
The class UpViewTransitionParams is a member of com.here.android.mpa.ar.ARController.
Class Summary
public final class ARController.UpViewTransitionParams
extends java.lang.Object
Encapsulates parameters which affect the Up view transition.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
354
Method Summary
Table 60: Methods in UpViewTransitionParams
Methods
public long getMaxAnimationTime ()
Get maximum duration of up view transition animation.
public long getMinAnimationTime ()
Get minimum duration of up view transition animation.
public AnimationInterpolator getPitchInterpolator ()
Get the interpolator for pitch change after crossing threshold of up view.
public UpViewTransitionParams setMaxAnimationTime (long value)
Set the maximum value of up view transition animation duration.
public UpViewTransitionParams setMinAnimationTime (long value)
Set the minimum value of up view transition animation duration.
public UpViewTransitionParams setPitchInterpolator (AnimationInterpolator value)
Set the interpolator for pitch change after crossing threshold of up view.
Class Details
Encapsulates parameters which affect the Up view transition. The Up view transition is the action that occurs
when transitioning from the Down view to the Up view.
Method Details
public long getMaxAnimationTime ()
Get maximum duration of up view transition animation.
Returns:
maximum duration of up view transition animation in ms.
public long getMinAnimationTime ()
Get minimum duration of up view transition animation.
Returns:
minimum duration of up view transition animation in ms.
public AnimationInterpolator getPitchInterpolator ()
Get the interpolator for pitch change after crossing threshold of up view.
Returns:
HERE Android SDK Developer's Guide
API Reference
355
AnimationInterpolator.
public UpViewTransitionParams setMaxAnimationTime (long value)
Set the maximum value of up view transition animation duration.
Parameters:
value
up view transition animation maximum duration in ms
Returns:
The updated UpViewTransitionParams object itself.
public UpViewTransitionParams setMinAnimationTime (long value)
Set the minimum value of up view transition animation duration.
Parameters:
value
up view transition animation minimum duration in ms
Returns:
The updated UpViewTransitionParams object itself.
public UpViewTransitionParams setPitchInterpolator (AnimationInterpolator value)
Set the interpolator for pitch change after crossing threshold of up view.
Parameters:
value
The AnimationInterpolator for pitch change
Returns:
The updated UpViewTransitionParams object itself.
ViewType
The enumeration ViewType is a member of com.here.android.mpa.ar.ARController.
Enumeration Summary
public static final enumeration ARController.ViewType
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
356
List of all views available in LiveSight
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 61: Enum Constants in ViewType
Fields
public static final ViewType AUTO
Default behavior.
public static final ViewType MAP
MAP view with POIs.
public static final ViewType CAMERA
Camera view.
Method Summary
Table 62: Methods in ViewType
Methods
public static ViewType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARController.ViewType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
List of all views available in LiveSight
Enum Constant Details
public static final ViewType AUTO
Default behavior. Switching between views is performed automatically based on the current pitch value and
the up and down view pitch thresholds
public static final ViewType MAP
MAP view with POIs. Down view.
public static final ViewType CAMERA
Camera view. UP view.
HERE Android SDK Developer's Guide
API Reference
357
Method Details
public static ViewType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARController.ViewType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ARIconObject
The class ARIconObject is a member of com.here.android.mpa.ar .
Class Summary
public final class ARIconObject
extends com.here.android.mpa.ar.ARObject, java.lang.Object
Concrete ARObject which represents the LiveSight object model.
[For complete information, see the section Class Details]
Constructor Summary
Table 63: Constructors in ARIconObject
Constructors
ARIconObject (GeoCoordinate coordinate, Bitmap info)
Construct the object using specified Image
ARIconObject (GeoCoordinate coordinate, Bitmap info, Image icon)
Construct the object using specified Image
ARIconObject (GeoCoordinate coordinate, Bitmap info, int iconResourceId)
Construct the object using provided image resource id.
ARIconObject (GeoCoordinate coordinate, Bitmap info, Image frontIcon, Image downIcon, Image
backIcon)
Construct the object using specified FRONT, DOWN and BACK Images
ARIconObject (GeoCoordinate coordinate, Bitmap info, int frontIconResourceId, int
downIconResourceId, int backIconResourceId)
Construct the object using provided image resource ids for FRONT, DOWN and BACK icons.
HERE Android SDK Developer's Guide
API Reference
358
Constructors
ARIconObject (GeoCoordinate coordinate, Bitmap info, String frontIconUrl, String downIconUrl,
String backIconUrl)
Construct the object using FRONT, DOWN and BACK icons URLs.
ARIconObject (GeoCoordinate coordinate, View info)
Construct the object using specified Image
ARIconObject (GeoCoordinate coordinate, View info, Image icon)
Construct the object using specified Image
ARIconObject (GeoCoordinate coordinate, View info, int iconResourceId)
Construct the object using provided image resource id.
ARIconObject (GeoCoordinate coordinate, View info, Image frontIcon, Image downIcon, Image
backIcon)
Construct the object using specified FRONT, DOWN and BACK images Image
ARIconObject (GeoCoordinate coordinate, View info, int frontIconResourceId, int
downIconResourceId, int backIconResourceId)
Construct the object using provided image resource ids for FRONT, DOWN and BACK icons.
ARIconObject (GeoCoordinate coordinate, View info, String frontIconUrl, String downIconUrl,
String backIconUrl)
Construct the object using FRONT, DOWN and BACK icon URLs.
Class Details
Concrete ARObject which represents the LiveSight object model. Composed of FRONT, DOWN and BACK icons,
an info icon and a GeoCoordinate representing the objects position.
Constructor Details
ARIconObject (GeoCoordinate coordinate, Bitmap info)
Construct the object using specified Image
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
ARIconObject (GeoCoordinate coordinate, Bitmap info, Image icon)
Construct the object using specified Image
Parameters:
coordinate
HERE Android SDK Developer's Guide
API Reference
359
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
icon
Image representing image to be used for FRONT, DOWN and BACK icons
ARIconObject (GeoCoordinate coordinate, Bitmap info, int iconResourceId)
Construct the object using provided image resource id. Falls back to default images if resource id is invalid.
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
iconResourceId
Representing image resource id to be used for FRONT, DOWN and BACK icons
ARIconObject (GeoCoordinate coordinate, Bitmap info, Image frontIcon, Image
downIcon, Image backIcon)
Construct the object using specified FRONT, DOWN and BACK Images
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
frontIcon
Image representing image to be used for both FRONT icon
downIcon
Image representing image to be used for both DOWN icon
backIcon
Image representing image to be used for both BACK icon
ARIconObject (GeoCoordinate coordinate, Bitmap info, int
frontIconResourceId, int downIconResourceId, int backIconResourceId)
Construct the object using provided image resource ids for FRONT, DOWN and BACK icons. Falls back to
default images if either of the icons resources are not valid.
Parameters:
HERE Android SDK Developer's Guide
API Reference
360
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
frontIconResourceId
Representing FRONT image resource id to be used for FRONT icon
downIconResourceId
Representing DOWN image resource id to be used for DOWN icon
backIconResourceId
Representing BACK image resource id to be used for BACK icon
ARIconObject (GeoCoordinate coordinate, Bitmap info, String frontIconUrl,
String downIconUrl, String backIconUrl)
Construct the object using FRONT, DOWN and BACK icons URLs. If either of the URLs are invalid default icons
will be used.
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A android.graphics.Bitmap of info in AR view
frontIconUrl
java.lang.String representing URL of the FRONT icon
downIconUrl
java.lang.String representing URL of the DOWN icon
backIconUrl
java.lang.String representing URL of the BACK icon
ARIconObject (GeoCoordinate coordinate, View info)
Construct the object using specified Image
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
ARIconObject (GeoCoordinate coordinate, View info, Image icon)
HERE Android SDK Developer's Guide
API Reference
361
Construct the object using specified Image
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
icon
Image representing image to be used for FRONT, DOWN and BACK icons
ARIconObject (GeoCoordinate coordinate, View info, int iconResourceId)
Construct the object using provided image resource id. Falls back to default images if resource id is invalid.
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
iconResourceId
Representing image resource id to be used for FRONT, DOWN and BACK icons
ARIconObject (GeoCoordinate coordinate, View info, Image frontIcon, Image
downIcon, Image backIcon)
Construct the object using specified FRONT, DOWN and BACK images Image
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
frontIcon
Image representing image to be used for both FRONT icon
downIcon
Image representing image to be used for both DOWN icon
backIcon
Image representing image to be used for both BACK icon
ARIconObject (GeoCoordinate coordinate, View info, int frontIconResourceId,
int downIconResourceId, int backIconResourceId)
HERE Android SDK Developer's Guide
API Reference
362
Construct the object using provided image resource ids for FRONT, DOWN and BACK icons. Falls back to
default images if either of the icons resources are not valid.
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
frontIconResourceId
Representing FRONT image resource id to be used for FRONT icon
downIconResourceId
Representing DOWN image resource id to be used for DOWN icon
backIconResourceId
Representing DOWN image resource id to be used for BACK icon
ARIconObject (GeoCoordinate coordinate, View info, String frontIconUrl,
String downIconUrl, String backIconUrl)
Construct the object using FRONT, DOWN and BACK icon URLs. If either of the URLs are invalid default icons
will be used.
Parameters:
coordinate
A GeoCoordinate representing coordinates of the AR icon
info
A UI android.view.View of info in AR view
frontIconUrl
java.lang.String representing URL of the FRONT icon
downIconUrl
java.lang.String representing URL of the DOWN icon
backIconUrl
java.lang.String representing URL of the BACK icon
ARMeshObject
The class ARMeshObject is a member of com.here.android.mpa.ar .
Class Summary
public class ARMeshObject
extends com.here.android.mpa.ar.ARModelObject, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
363
Concrete 3D AR model objects with mesh.
[For complete information, see the section Class Details]
Constructor Summary
Table 64: Constructors in ARMeshObject
Constructors
ARMeshObject (GeoCoordinate position)
Construct AR mesh object
ARMeshObject (Vector3f position)
Construct AR mesh object
ARMeshObject (Vector3f position, GeoCoordinate direction)
Construct AR mesh object
ARMeshObject (GeoCoordinate position, LocalMesh mesh, Image texture)
Construct AR mesh object
ARMeshObject (Vector3f position, LocalMesh mesh, Image texture)
Construct AR mesh object
ARMeshObject (Vector3f position, GeoCoordinate direction, LocalMesh mesh, Image texture)
Construct AR mesh object
Method Summary
Table 65: Methods in ARMeshObject
Methods
public GeoCoordinate getGeoDirection ()
Get the geo direction of the mesh
public GeoCoordinate getGeoPosition ()
Get geo position of the mesh
public Vector3f getLocalPosition ()
Get local position of the mesh
public LocalMesh getMesh ()
Get the mesh associated with the object
public void setGeoDirection (GeoCoordinate direction)
Set the geo direction of the mesh
public void setGeoPosition (GeoCoordinate position)
Set the geo position of the mesh
HERE Android SDK Developer's Guide
API Reference
364
Methods
public void setLocalPosition (Vector3f position)
Set local position of the mesh
public void setMesh (LocalMesh mesh)
Set the mesh associated with the object.
Class Details
Concrete 3D AR model objects with mesh. There are three types of AR mesh objects supported: - Geo
positioned mesh object - Locally positioned mesh object - Locally positioned mesh object with additional
geo direction
Constructor Details
ARMeshObject (GeoCoordinate position)
Construct AR mesh object
Parameters:
position
Mesh geo position
ARMeshObject (Vector3f position)
Construct AR mesh object
Parameters:
position
Position of the center of the mesh relative to the camera. Unit is meters
ARMeshObject (Vector3f position, GeoCoordinate direction)
Construct AR mesh object
Parameters:
position
Position of the center of the mesh relative to the camera. Unit is meters
direction
Geo direction of the mesh (where to point to)
ARMeshObject (GeoCoordinate position, LocalMesh mesh, Image texture)
Construct AR mesh object
Parameters:
HERE Android SDK Developer's Guide
API Reference
365
position
Mesh's geo position
mesh
Object's mesh
texture
Object's texture
ARMeshObject (Vector3f position, LocalMesh mesh, Image texture)
Construct AR mesh object
Parameters:
position
Position of the center of the mesh relative to the camera. Unit is meters
mesh
Object's mesh
texture
Object's texture
ARMeshObject (Vector3f position, GeoCoordinate direction, LocalMesh mesh, Image
texture)
Construct AR mesh object
Parameters:
position
Position of the center of the mesh relative to the camera. Unit is meters
direction
Waypoint geo position (where to point to)
mesh
Object's mesh
texture
Object's texture
Method Details
public GeoCoordinate getGeoDirection ()
Get the geo direction of the mesh
Returns:
geo direction of the mesh
HERE Android SDK Developer's Guide
API Reference
366
public GeoCoordinate getGeoPosition ()
Get geo position of the mesh
Returns:
Geo position of the center of the mesh
public Vector3f getLocalPosition ()
Get local position of the mesh
Returns:
Position of the center of the mesh relative to the camera. Unit is meters
public LocalMesh getMesh ()
Get the mesh associated with the object
Returns:
LocalMesh object
public void setGeoDirection (GeoCoordinate direction)
Set the geo direction of the mesh
Parameters:
direction
Geo direction of the mesh
public void setGeoPosition (GeoCoordinate position)
Set the geo position of the mesh
Parameters:
position
Geo position of the center of the mesh
public void setLocalPosition (Vector3f position)
Set local position of the mesh
Parameters:
position
Position of the center of the mesh relative to the camera. Unit is meters
HERE Android SDK Developer's Guide
API Reference
367
public void setMesh (LocalMesh mesh)
Set the mesh associated with the object.
Parameters:
mesh
An object representing the mesh to set.
ARModelObject
The class ARModelObject is a member of com.here.android.mpa.ar .
Class Summary
public abstract class ARModelObject
extends java.lang.Object
Represents a base class for all 3D AR objects that users can add to a ARController.
[For complete information, see the section Class Details]
Nested Class Summary
Table 66: Nested Classes in ARModelObject
Nested Classes
public static final enumeration ARModelObject.ShadingMode
Represents object's shading mode
Method Summary
Table 67: Methods in ARModelObject
Methods
public void clearTransformation ()
Set the model transformation to the identity matrix
public boolean equals (Object obj)
For documentation, see java.lang.Object
public void getDynamicScale (PointF interval, PointF factors)
Get the parameters for dynamic scaling of this object.
public float getOpacity ()
Get opacity
HERE Android SDK Developer's Guide
API Reference
368
Methods
public ShadingMode getShadingMode ()
Get object shading mode
public Image getTexture ()
Get the texture for this object
public float[] getTransformation ()
Get the model transformation
public PointF getVisibilityRange ()
Get the distance range in meters around the camera over which this model is visible
public int hashCode ()
For documentation, see java.lang.Object
public void rotate (Vector3f rotationAxis, float rotationAngleDeg)
Apply a rotation to the model (model matrix is post-multiplied)
public void rotate (float xRotationDeg, float yRotationDeg, float zRotationDeg)
Apply a rotation to the model (model matrix is post-multiplied).
public void scale (float xScale, float yScale, float zScale)
Apply scaling to the model (model matrix is post-multiplied)
public void setDynamicScale (PointF interval, PointF factors)
Set the parameters for dynamic scaling of this object.
public void setOpacity (float opacity)
Set opacity
public void setShadingMode (ShadingMode mode)
Set object shading mode
public void setTexture (Image texture)
Set the texture for this object
public void setTransformation (float[] matrix)
Set the model transformation
public void setVisibilityRange (PointF range)
Set the distance range in meters around the camera over which this model is visible
public void translate (float xTranslation, float yTranslation, float zTranslation)
Apply a translation to the model (model matrix is post-multiplied)
Class Details
Represents a base class for all 3D AR objects that users can add to a ARController.
This class serves as a generalization (or abstract base) for more specified object types (such as
ARBillboardObject and ARMeshObject), bundling their common properties.
HERE Android SDK Developer's Guide
API Reference
369
Method Details
public void clearTransformation ()
Set the model transformation to the identity matrix
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public void getDynamicScale (PointF interval, PointF factors)
Get the parameters for dynamic scaling of this object.
Parameters:
interval
in meters over which scaling is linearly interpolated
factors
x and y are min and max scale factors
public float getOpacity ()
Get opacity
Returns:
Opacity used for this ARModelObject.
public ShadingMode getShadingMode ()
Get object shading mode
Returns:
The current object shading mode.
public Image getTexture ()
Get the texture for this object
Returns:
Image object
public float[] getTransformation ()
HERE Android SDK Developer's Guide
API Reference
370
Get the model transformation
Returns:
array of 16 floats storing the model transformation (4x4 matrix) in column major order
public PointF getVisibilityRange ()
Get the distance range in meters around the camera over which this model is visible
Returns:
x and y are min and max visible distances, respectively
public int hashCode ()
For documentation, see java.lang.Object
public void rotate (Vector3f rotationAxis, float rotationAngleDeg)
Apply a rotation to the model (model matrix is post-multiplied)
Parameters:
rotationAxis
Axis of rotation
rotationAngleDeg
Rotation angle in degrees (right-hand convention)
public void rotate (float xRotationDeg, float yRotationDeg, float
zRotationDeg)
Apply a rotation to the model (model matrix is post-multiplied). The rotation is specified as Euler angles:
Rx(rx) * Ry(ry) * Rz(rz)
Parameters:
xRotationDeg
rotation in degrees around X-axis (right-hand convention)
yRotationDeg
rotation in degrees around Y-axis (right-hand convention)
zRotationDeg
rotation in degrees around Z-axis (right-hand convention)
public void scale (float xScale, float yScale, float zScale)
Apply scaling to the model (model matrix is post-multiplied)
HERE Android SDK Developer's Guide
API Reference
371
Parameters:
xScale
Scaling factor in the X-axis direction
yScale
Scaling factor in the Y-axis direction
zScale
Scaling factor in the Z-axis direction
public void setDynamicScale (PointF interval, PointF factors)
Set the parameters for dynamic scaling of this object. After applying the model transformation the object is
scaled as a linear function of its distance to the camera. The scaling is defined as follows: scaling(distance)
= s_min if distance < d_min, = s_max if distance > d_max, = s_min + (distance - d_min) / (d_max - d_min) *
(s_max - s_min), otherwise
Parameters:
interval
in meters over which scaling is linearly interpolated
factors
x and y are min and max scale factors
public void setOpacity (float opacity)
Set opacity
Parameters:
opacity
to be used for this ARModelObject
public void setShadingMode (ShadingMode mode)
Set object shading mode
Parameters:
mode
Shading mode to be used.
public void setTexture (Image texture)
Set the texture for this object
Parameters:
texture
HERE Android SDK Developer's Guide
API Reference
372
Object Image texture
public void setTransformation (float[] matrix)
Set the model transformation
Parameters:
matrix
array of 16 floats storing the new model transformation (4x4 matrix) in column major order
public void setVisibilityRange (PointF range)
Set the distance range in meters around the camera over which this model is visible
Parameters:
range
- x and y are min and max visible distances, respectively
public void translate (float xTranslation, float yTranslation, float
zTranslation)
Apply a translation to the model (model matrix is post-multiplied)
Parameters:
xTranslation
Translation in meters the X-axis direction
yTranslation
Translation in meters the Y-axis direction
zTranslation
Translation in meters the Z-axis direction
ShadingMode
The enumeration ShadingMode is a member of com.here.android.mpa.ar.ARModelObject.
Enumeration Summary
public static final enumeration ARModelObject.ShadingMode
extends java.lang.Enum, java.lang.Object
Represents object's shading mode
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
373
Enum Constant Summary
Table 68: Enum Constants in ShadingMode
Fields
public static final ShadingMode FLAT_TEXTURED
Textured no lighting
public static final ShadingMode DIFFUSE_TEXTURED
Textured with diffuse lighting
Method Summary
Table 69: Methods in ShadingMode
Methods
public static ShadingMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARModelObject.ShadingMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents object's shading mode
Enum Constant Details
public static final ShadingMode FLAT_TEXTURED
Textured no lighting
public static final ShadingMode DIFFUSE_TEXTURED
Textured with diffuse lighting
Method Details
public static ShadingMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
374
public static ARModelObject.ShadingMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ARObject
The class ARObject is a member of com.here.android.mpa.ar .
Class Summary
public abstract class ARObject
extends java.lang.Object
Represents a base class for all AR related objects that users can add to a ARController.
[For complete information, see the section Class Details]
Nested Class Summary
Table 70: Nested Classes in ARObject
Nested Classes
public static final enumeration ARObject.IconType
Icon types used by ARObject
Method Summary
Table 71: Methods in ARObject
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public RectF getBoundingBox ()
Get bounding box limiting where the ARObject can travel on screen.
public GeoCoordinate getCoordinate ()
Gets the current GeoCoordinate for the ARObject.
public Image getIcon (IconType type)
Gets the icon image for the ARObject
public PointF getIconAnchor (IconType type)
Get down icon's anchor point represented as halfs of width and height of the icon.
public float getIconSizeScale (IconType type)
Gets icon's size scaling factor
HERE Android SDK Developer's Guide
API Reference
375
Methods
public float getMaxViewAngle ()
Get item's max view angle when the item is on the right or left from line of sight.
public float getOpacity ()
Get item's opacity.
public ProjectionType getProjectionType ()
Get Camera view ARController.ProjectionType
public long getUid ()
Get unique identifier.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isInfoExtended ()
Checks if info portion of the ARObject is extended
public void setBoundingBox (RectF box)
Set bounding box to limit travel on the screen.
public void setCoordinate (GeoCoordinate coordinate)
Sets a GeoCoordinate for the ARObject.
public void setIcon (IconType type, Image icon)
Sets an icon image for the ARObject.
public void setIcon (IconType type, View icon)
Sets an icon image for the ARObject.
public void setIcon (IconType type, Bitmap icon)
Sets an icon image for the ARObject.
public void setIconAnchor (IconType type, PointF anchor)
Set icon's anchor point represented as halfs of width and height of the icon.
public void setIconSizeScale (IconType type, float scale)
Sets icon's size scaling factor
public void setIconTexture (IconType type, int texture, int width, int height)
Sets an OpenGL texture name for the specified icon in the ARObject.
public void setInfoMaxHeight (int height)
Sets maximum height for the ARObject's info portion of the icon
public void setInfoMaxWidth (int width)
Sets maximum width for the ARObject's info portion of the icon
public void setMaxViewAngle (float angleDeg)
Set item max view angle when the item is on the right or left from line of sight.
HERE Android SDK Developer's Guide
API Reference
376
Methods
public void setOpacity (float value)
Set item's opacity.
public void setProjectionType (ProjectionType type)
Set Camera view ARController.ProjectionType
Class Details
Represents a base class for all AR related objects that users can add to a ARController.
This class serves as a generalization (or abstract base) for more specified object types (such as
ARIconObject), bundling their common properties.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public RectF getBoundingBox ()
Get bounding box limiting where the ARObject can travel on screen.
Returns:
The android.graphics.RectF representing the bounding box.
public GeoCoordinate getCoordinate ()
Gets the current GeoCoordinate for the ARObject.
Returns:
The current GeoCoordinate
public Image getIcon (IconType type)
Gets the icon image for the ARObject
Parameters:
type
An ARObject.IconType.
Returns:
An Image representing the front icon
HERE Android SDK Developer's Guide
API Reference
377
public PointF getIconAnchor (IconType type)
Get down icon's anchor point represented as halfs of width and height of the icon.
Parameters:
type
An ARObject.IconType.
Returns:
down icon's opacity.
public float getIconSizeScale (IconType type)
Gets icon's size scaling factor
Parameters:
type
ARObject.IconType
Returns:
scale A size scaling factor
public float getMaxViewAngle ()
Get item's max view angle when the item is on the right or left from line of sight.
Returns:
The view angle of the item. The range is: - angleDeg to + angleDeg.
public float getOpacity ()
Get item's opacity. NOTE: Setting item's opacity overrides calculated value.
Returns:
A value of the opacity.
public ProjectionType getProjectionType ()
Get Camera view ARController.ProjectionType
Returns:
A value of ProjectionType
public long getUid ()
HERE Android SDK Developer's Guide
API Reference
378
Get unique identifier. Helper method to accommodate faster mapping of the ARObject and application
specific objects (Example: items "radar" implementation)
Returns:
Unique object identifier
public int hashCode ()
For documentation, see java.lang.Object
public boolean isInfoExtended ()
Checks if info portion of the ARObject is extended
Returns:
True, if object has expended info portion of the icon.
public void setBoundingBox (RectF box)
Set bounding box to limit travel on the screen. Left, top, right and bottom values are the ratios of the view's
height and width. Value of 0 for left an top and 1 for right and bottom indicate that there are no boundaries
are actually used. Values > 0 and < 1 are used to set absolute screen boundaries.
Parameters:
box
android.graphics.RectF Item's bounding box. If null, bounding box is set to {0, 0, 1, 1}.
public void setCoordinate (GeoCoordinate coordinate)
Sets a GeoCoordinate for the ARObject.
Parameters:
coordinate
Desired GeoCoordinate for ARObject
public void setIcon (IconType type, Image icon)
Sets an icon image for the ARObject.
Parameters:
type
An ARObject.IconType.
icon
An Image representing the icon type.
HERE Android SDK Developer's Guide
API Reference
379
public void setIcon (IconType type, View icon)
Sets an icon image for the ARObject.
Parameters:
type
An ARObject.IconType.
icon
An android.view.View representing the icon type.
public void setIcon (IconType type, Bitmap icon)
Sets an icon image for the ARObject.
Parameters:
type
An ARObject.IconType.
icon
An android.graphics.Bitmap representing the icon type.
public void setIconAnchor (IconType type, PointF anchor)
Set icon's anchor point represented as halfs of width and height of the icon. Example: value of (1, 1) means
that the center of the icon corresponds to the actual geo position. Value (1,2) means that half width and
bottom of the icon corresponds to the actual geo position. Default value is (1, 1).
Parameters:
type
An ARObject.IconType.
anchor
X and Y offset coefficients represented as halfs of the icon width and height. Range is 0 to 2.0f. 0 --- 1 ---
2 | | | 1 --- x --- x | | | 2 --- x --- x
public void setIconSizeScale (IconType type, float scale)
Sets icon's size scaling factor
Parameters:
type
ARObject.IconType
scale
A size scaling factor
HERE Android SDK Developer's Guide
API Reference
380
public void setIconTexture (IconType type, int texture, int width, int
height)
Sets an OpenGL texture name for the specified icon in the ARObject. Previously set image (using
setIcon(ARObject.IconType, Image) for example) is not disposed and can be used when texture is cleaned.
Texture can be cleaned by passing -1 for texture parameter (i.e. setIconTexture(IconType.FRONT, -1, 0, 0)).
Parameters:
type
An ARObject.IconType
texture
An OpenGL texture name corresponding to the icon type specified.
width
An OpenGL texture width
height
An OpenGL texture height
public void setInfoMaxHeight (int height)
Sets maximum height for the ARObject's info portion of the icon
Parameters:
height
A maximum height of the ARObject info portion on the screen
public void setInfoMaxWidth (int width)
Sets maximum width for the ARObject's info portion of the icon
Parameters:
width
A maximum width of the ARObject info portion on the screen
public void setMaxViewAngle (float angleDeg)
Set item max view angle when the item is on the right or left from line of sight.
Parameters:
angleDeg
The view angle of the item. The range is: - angleDeg to + angleDeg.
public void setOpacity (float value)
HERE Android SDK Developer's Guide
API Reference
381
Set item's opacity. Setting item's opacity overrides the calculated value. Setting negative value resets
previous setting to the default - calculated one.
Parameters:
value
A value of the opacity.
public void setProjectionType (ProjectionType type)
Set Camera view ARController.ProjectionType
Parameters:
type
A value of ProjectionType.
IconType
The enumeration IconType is a member of com.here.android.mpa.ar.ARObject.
Enumeration Summary
public static final enumeration ARObject.IconType
extends java.lang.Enum, java.lang.Object
Icon types used by ARObject
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 72: Enum Constants in IconType
Fields
public static final IconType DOWN
Icon representing ARObject in DOWN scene when device is tilted down.
public static final IconType FRONT
Icon representing ARObject in UP scene when device is tilted up and the item appears in foreground.
public static final IconType BACK
Icon representing ARObject in UP scene when device is tilted up and the item appears in background.
public static final IconType INFO
Icon representing ARObject in UP scene adjacent to the FRONT icon on the right when device is tilted up and the item
appears in foreground.
HERE Android SDK Developer's Guide
API Reference
382
Method Summary
Table 73: Methods in IconType
Methods
public static IconType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ARObject.IconType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Icon types used by ARObject
Enum Constant Details
public static final IconType DOWN
Icon representing ARObject in DOWN scene when device is tilted down. Actual switch to down scene happens
based on the down pitch threshold. See setPitchThreshold(float).
public static final IconType FRONT
Icon representing ARObject in UP scene when device is tilted up and the item appears in foreground. Actual
switch to up scene happens based on the pitch threshold. See setPitchThreshold(float).
public static final IconType BACK
Icon representing ARObject in UP scene when device is tilted up and the item appears in background. Actual
switch to up scene happens based on the pitch threshold. See setPitchThreshold(float).
public static final IconType INFO
Icon representing ARObject in UP scene adjacent to the FRONT icon on the right when device is tilted up
and the item appears in foreground. Actual switch to up scene happens based on the pitch threshold. See
setPitchThreshold(float).
Method Details
public static IconType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
383
A string containing the name of the enumeration member whose value is to be retrieved.
public static ARObject.IconType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ARPolylineObject
The class ARPolylineObject is a member of com.here.android.mpa.ar .
Class Summary
public final class ARPolylineObject
extends java.lang.Object
Represent a ARPolyline that users can add to a ARController.
[For complete information, see the section Class Details]
Constructor Summary
Table 74: Constructors in ARPolylineObject
Constructors
ARPolylineObject (GeoPolyline polyline)
Create ARPolylineObject with GeoPolyline.
ARPolylineObject (GeoPolyline polyline, LineAttributes lineAttributes)
Create ARPolylineObject with a GeoPolyline and a line attribute.
Method Summary
Table 75: Methods in ARPolylineObject
Methods
public GeoPolyline getGeoPolyLine ()
Get the GeoPolyline used for this ARPolyline.
public LineAttributes getLineAttributes ()
Get the LineAttributes used for this ARPolyline.
public void setGeoPolyline (GeoPolyline polyline)
Changes the GeoPolyline rendered by this ARPolylineObject
public void setLineAttributes (LineAttributes lineAttributes)
Changes the LineAttributes rendered by this ARPolylineObject
HERE Android SDK Developer's Guide
API Reference
384
Class Details
Represent a ARPolyline that users can add to a ARController. This class also provide features to customize
polyline attributes such as width of line, color and so on.
Constructor Details
ARPolylineObject (GeoPolyline polyline)
Create ARPolylineObject with GeoPolyline. In this case, a default line attributes LineAttributes will be used.
Parameters:
polyline
a GeoPolyline.
Throws:
NullPointerException
if GeoPolyline is null.
ARPolylineObject (GeoPolyline polyline, LineAttributes lineAttributes)
Create ARPolylineObject with a GeoPolyline and a line attribute.
Parameters:
polyline
a GeoPolyline
lineAttributes
attributes to customize line features such as width, color, line end cap style.
Throws:
NullPointerException
if GeoPolyline is null OR lineAttributes is null.
Method Details
public GeoPolyline getGeoPolyLine ()
Get the GeoPolyline used for this ARPolyline.
Returns:
GeoPolyline used for this ARPolyline.
public LineAttributes getLineAttributes ()
Get the LineAttributes used for this ARPolyline.
HERE Android SDK Developer's Guide
API Reference
385
Returns:
LineAttributes used for this ARPolyline.
public void setGeoPolyline (GeoPolyline polyline)
Changes the GeoPolyline rendered by this ARPolylineObject
Parameters:
polyline
GeoPolyline to be rendered
public void setLineAttributes (LineAttributes lineAttributes)
Changes the LineAttributes rendered by this ARPolylineObject
Parameters:
lineAttributes
GeoPolyline to be rendered
ARPoseReading
The class ARPoseReading is a member of com.here.android.mpa.ar .
Class Summary
public final class ARPoseReading
extends java.lang.Object
Represents a model class comprising the latitude, longitude, altitude, pitch, heading, roll and time stamp for
the current AR pose.
[For complete information, see the section Class Details]
Method Summary
Table 76: Methods in ARPoseReading
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public float getAltitude ()
Get the altitude in meters as height above the WGS84 ellipsoid.
HERE Android SDK Developer's Guide
API Reference
386
Methods
public float getHeading ()
Get the y-axis rotation in radians.
public double getLatitude ()
Get the latitude in WGS84 degrees.
public double getLongitude ()
Get the longitude in WGS84 degrees.
public float getPitch ()
Get the x-axis rotation (pitch) in radians.
public float getRoll ()
Get the z-axis rotation (roll) in radians.
public long getTimestamp ()
Get a timestamp indicating the time at which the pose reading was taken.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a model class comprising the latitude, longitude, altitude, pitch, heading, roll and time stamp for
the current AR pose. This object can be retrieved by calling getPose().
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public float getAltitude ()
Get the altitude in meters as height above the WGS84 ellipsoid.
Returns:
The altitude in meters as height above the WGS84 ellipsoid.
public float getHeading ()
Get the y-axis rotation in radians.
Returns:
The y-axis rotation in radians.
HERE Android SDK Developer's Guide
API Reference
387
public double getLatitude ()
Get the latitude in WGS84 degrees.
Returns:
The latitude in WGS84 degrees.
public double getLongitude ()
Get the longitude in WGS84 degrees.
Returns:
The longitude in WGS84 degrees.
public float getPitch ()
Get the x-axis rotation (pitch) in radians.
Returns:
The x-axis rotation (pitch) in radians.
public float getRoll ()
Get the z-axis rotation (roll) in radians.
Returns:
The z-axis rotation (roll) in radians.
public long getTimestamp ()
Get a timestamp indicating the time at which the pose reading was taken.
Returns:
A timestamp indicating the time at which the pose reading was taken.
public int hashCode ()
For documentation, see java.lang.Object
ARRadarItem
The class ARRadarItem is a member of com.here.android.mpa.ar .
HERE Android SDK Developer's Guide
API Reference
388
Class Summary
public final class ARRadarItem
extends java.lang.Object
Represents a model class comprising the Uid, bearing, distance, spread distance, pan distance for an AR item
that will be displayed on the radar.
[For complete information, see the section Class Details]
Method Summary
Table 77: Methods in ARRadarItem
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public ARObject getARObject ()
Returns ARObject associated with the ARRadarItem
public float getBearing ()
Returns the bearing in degrees of the item relative to the current position.
public float getDistance ()
Returns the distance in meters to the item from the current position.
public float getPanDistance ()
Returns the pan distance in meters of the item.
public RectF getScreenRect ()
Returns the screen rectangle occupied by the ARObject associated with this item, when visible.
public float getSpreadDistance ()
Returns the spread distance in meters of the item.
public int getUid ()
Returns the unique identifier of the item associated with the ARObject.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isOccluded ()
Checks if ARObject is occluded by buildings
public boolean isVisible ()
Checks if ARObject is visible in the UP view
Class Details
Represents a model class comprising the Uid, bearing, distance, spread distance, pan distance for an AR item
that will be displayed on the radar. The list of ARRadarItems can be retrieved by calling getItems().
HERE Android SDK Developer's Guide
API Reference
389
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public ARObject getARObject ()
Returns ARObject associated with the ARRadarItem
Returns:
ARObject object.
public float getBearing ()
Returns the bearing in degrees of the item relative to the current position.
Returns:
The bearing in degrees of the item relative to the current position.
public float getDistance ()
Returns the distance in meters to the item from the current position.
Returns:
The distance in meters to the item from the current position.
public float getPanDistance ()
Returns the pan distance in meters of the item. If this is smaller than the dimming limit then items is not
visible. Item should be grayed out or not displayed on the radar.
Returns:
The pan distance in meters of the item.
public RectF getScreenRect ()
Returns the screen rectangle occupied by the ARObject associated with this item, when visible. If any of the
value is outside of the view, then the item is partially visible.
Returns:
The screen rectangle.
See also:
HERE Android SDK Developer's Guide
API Reference
390
getARObject()
public float getSpreadDistance ()
Returns the spread distance in meters of the item.
Returns:
The spread distance in meters of the item.
public int getUid ()
Returns the unique identifier of the item associated with the ARObject.
Returns:
The unique identifier.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isOccluded ()
Checks if ARObject is occluded by buildings
Returns:
True, if object is occluded by buildings.
public boolean isVisible ()
Checks if ARObject is visible in the UP view
Returns:
True, if object is visible on the screen.
ARRadarProperties
The class ARRadarProperties is a member of com.here.android.mpa.ar .
Class Summary
public final class ARRadarProperties
extends java.lang.Object
Represents a model class comprising the radar properties such as the visible area details and radar items.
HERE Android SDK Developer's Guide
API Reference
391
[For complete information, see the section Class Details]
Method Summary
Table 78: Methods in ARRadarProperties
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public double getAngle ()
Get the heading (rotation on Y axis) in degrees.
public float getBackPlaneStart ()
Return the z in meters at which the back plane starts.
public float getDimmingLimit ()
Return the z limit in meters.
public float getFrontPlaneEnd ()
Return the z in meters at which the front plane ends.
public float getFrontPlaneStart ()
Return the z in meters at which the front plane starts.
public java.util.List <ARRadarItem> getItems ()
Returns the list of radar items.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a model class comprising the radar properties such as the visible area details
and radar items. Each radar item corresponds to one of the ARObjects added to the
ARController. In order to get the radar properties, the client must register a listener using
addOnRadarUpdateListener(ARController.OnRadarUpdateListener)}.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public double getAngle ()
Get the heading (rotation on Y axis) in degrees.
HERE Android SDK Developer's Guide
API Reference
392
Returns:
The heading (rotation on Y axis) in degrees.
public float getBackPlaneStart ()
Return the z in meters at which the back plane starts.
Returns:
The z in meters at which the back plane starts.
public float getDimmingLimit ()
Return the z limit in meters. AR Objects that have smaller z value will not be visible on the screen.
Returns:
The z limit in meters.
public float getFrontPlaneEnd ()
Return the z in meters at which the front plane ends.
Returns:
The z in meters at which the front plane ends.
public float getFrontPlaneStart ()
Return the z in meters at which the front plane starts.
Returns:
The z in meters at which the front plane starts.
public java.util.List <ARRadarItem> getItems ()
Returns the list of radar items.
Returns:
The list of radar items.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
393
AnimationInterpolator
The enumeration AnimationInterpolator is a member of com.here.android.mpa.ar .
Enumeration Summary
public final enumeration AnimationInterpolator
extends java.lang.Enum, java.lang.Object
Animation Interpolator types.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 79: Enum Constants in AnimationInterpolator
Fields
public static final AnimationInterpolator LINEAR
Linear interpolation
public static final AnimationInterpolator ACCELERATE
Accelerate.
public static final AnimationInterpolator DECELERATE
Decelerate.
public static final AnimationInterpolator ACCELERATE_DECELERATE
Accelerate - Decelerate.
public static final AnimationInterpolator OVERSHOOT
Overshoot.
public static final AnimationInterpolator ANTICIPATE
Anticipate.
public static final AnimationInterpolator ANTICIPATE_OVERSHOOT
Anticipate - Overshoot.
public static final AnimationInterpolator BOUNCE
Bounce.
public static final AnimationInterpolator CYCLE
Cycle.
HERE Android SDK Developer's Guide
API Reference
394
Method Summary
Table 80: Methods in AnimationInterpolator
Methods
public static AnimationInterpolator valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static AnimationInterpolator[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Animation Interpolator types. Function of time. Returned value is determined by the type of the
interpolation.
Enum Constant Details
public static final AnimationInterpolator LINEAR
Linear interpolation
public static final AnimationInterpolator ACCELERATE
Accelerate. An interpolator where the rate of change starts out slowly and then accelerates
public static final AnimationInterpolator DECELERATE
Decelerate. An interpolator where the rate of change starts out quickly and then decelerates
public static final AnimationInterpolator ACCELERATE_DECELERATE
Accelerate - Decelerate. An interpolator where the rate of change starts and ends slowly but accelerates
through the middle
public static final AnimationInterpolator OVERSHOOT
Overshoot. An interpolator where the change flings forward and overshoots the last value then comes back.
public static final AnimationInterpolator ANTICIPATE
Anticipate. An interpolator where the change starts backward then flings forward.
public static final AnimationInterpolator ANTICIPATE_OVERSHOOT
HERE Android SDK Developer's Guide
API Reference
395
Anticipate - Overshoot. An interpolator where the change starts backward then flings forward and overshoots
the target value and finally goes back to the final value.
public static final AnimationInterpolator BOUNCE
Bounce. An interpolator where the change bounces at the end.
public static final AnimationInterpolator CYCLE
Cycle. Repeats the animation for a specified number of cycles. The rate of change follows a sinusoidal
pattern.
Method Details
public static AnimationInterpolator valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static AnimationInterpolator[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CompositeFragment
The class CompositeFragment is a member of com.here.android.mpa.ar .
Class Summary
public class CompositeFragment
extends java.lang.Object
Composite fragment which enables usage of AR and Map functionality within the same view context.
[For complete information, see the section Class Details]
See also:
MapFragment
HERE Android SDK Developer's Guide
API Reference
396
Constructor Summary
Table 81: Constructors in CompositeFragment
Constructors
CompositeFragment ()
Constructor
Method Summary
Table 82: Methods in CompositeFragment
Methods
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
public ARController getARController ()
Get ARController
public ViewRect getClipRect ()
Returns the ViewRect representing the clip rectangle for this CompositeFragment.
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle.
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
public CopyrightLogoPosition getCopyrightLogoPosition ()
Returns the on-screen position of the HERE copyright logo as a CopyrightLogoPosition value.
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map
area to the edge of the logo.
public int getHeight ()
Gets the current height of the fragment, in pixels.
public Map getMap ()
Returns the instance of Map associated with this fragment
public MapGesture getMapGesture ()
Returns the MapGesture object representing the current gesture handler for the CompositeFragment.
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the CompositeFragment.
HERE Android SDK Developer's Guide
API Reference
397
Methods
public int getWidth ()
Gets the current width of the fragment, in pixels.
public void init (OnEngineInitListener listener)
Users of CompositeFragment must call this function after the fragment is first attached to its activity.
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
User of CompositeFragment must call this function after the fragment is created.
public void init (Context context, MapVariant variant, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
User of CompositeFragment must call this function after the fragment is created.
public void init (ApplicationContext context, OnEngineInitListener listener)
Users of CompositeFragment must call this function after the fragment is first attached to its activity.
public View onCreateView (LayoutInflater inflater, ViewGroup container, Bundle
savedInstanceState)
For documentation, see android.app.Fragment.onCreateView(LayoutInflater, viewGrup, Bundle)
public void onDestroyView ()
For documentation, see android.app.Fragment.onDestroyView()
public void onInflate (Activity activity, AttributeSet attrs, Bundle savedInstanceState)
Deprecated: Deprecated as of release 3.5.
For documentation, see android.app.Fragment.onInflate(Activity, AttributeSet, Bundle)
public void onInflate (Context context, AttributeSet attrs, Bundle savedInstanceState)
For documentation, see android.app.Fragment.onInflate(Context, AttributeSet, Bundle)
public void onPause ()
Called when this fragment is no longer resumed.
public void onResume ()
Called when this fragment is visible to the user and actively running.
public void onSaveInstanceState (Bundle outState)
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the CompositeFragment.
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to this CompositeFragment.
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the CompositeFragment 's boundary, for the placement of the
HERE copyright logo.
HERE Android SDK Developer's Guide
API Reference
398
Methods
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
Sets a position for the HERE copyright logo.
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map area to the
edge of the logo (depending on the placement).
public void setMapMarkerDragListener (OnDragListener listener)
Sets a OnDragListener to be invoked whenever any MapMarker on a Map that is attached to this fragment is dragged.
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the CompositeFragment.
Class Details
Composite fragment which enables usage of AR and Map functionality within the same view context. This
class contains methods which are specific to Map as well as methods specific to AR. Concretely, provides the
same functionality as MapFragment in addition to AR functionality.
See also:
MapFragment
Constructor Details
CompositeFragment ()
Constructor
Method Details
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
Parameters:
listener
A OnMapRenderListener to add to the CompositeFragment
See also:
removeOnMapRenderListener(OnMapRenderListener)
public ARController getARController ()
Get ARController
Returns:
HERE Android SDK Developer's Guide
API Reference
399
ARController object
public ViewRect getClipRect ()
Returns the ViewRect representing the clip rectangle for this CompositeFragment.
Returns:
The clip rectangle for rendering MapObjects and similar map-related screen elements. null if
the view's layout process has yet to be completed. If the process is not yet complete, users can
either retry later or subscribe as a OnMapRenderListener and call this method upon the callback
OnMapRenderListener.onSizeChanged(int,int).
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle. Returns null if a boundary rect has not been set
previously.
Returns:
The copyright logo's boundary rect. null if a boundary rect has not been set previously.
See also:
setCopyrightBoundaryRect(Rect)
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
This method only returns a valid value once fragment initialization has taken completed.
Returns:
The height of the copyright logo, in number of pixels
public CopyrightLogoPosition getCopyrightLogoPosition ()
Returns the on-screen position of the HERE copyright logo as a CopyrightLogoPosition value.
Returns:
The position of the logo.
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
This method only returns a valid value once fragment initialization has completed.
Returns:
The width of the copyright logo, in number of pixels
HERE Android SDK Developer's Guide
API Reference
400
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the
visible map area to the edge of the logo.
This method only returns a valid value once fragment initialization has taken place.
Returns:
The current offset from the edge of the CompositeFragment, in number of pixels
public int getHeight ()
Gets the current height of the fragment, in pixels.
Returns:
The current height
public Map getMap ()
Returns the instance of Map associated with this fragment
Returns:
The Map object currently displayed in this fragment.
public MapGesture getMapGesture ()
Returns the MapGesture object representing the current gesture handler for the CompositeFragment.
Applications can intercept this object and override the default event behaviors.
Returns:
The MapGesture
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the CompositeFragment. This method is asynchronous and will
invoke a callback once the operation is completed through the operation is completed through the
OnScreenCaptureListener the CompositeFragment must be visible to create the screen capture. Note that
the current functionality of this API is limited to getting a screen capture of the Map. Future releases maybe
enhanced to support getting screen capture of the AR and Map composite.
Parameters:
listener
A OnScreenCaptureListener to listen for the callback when screen capture is complete.
HERE Android SDK Developer's Guide
API Reference
401
public int getWidth ()
Gets the current width of the fragment, in pixels.
Returns:
The current width
public void init (OnEngineInitListener listener)
Users of CompositeFragment must call this function after the fragment is first attached to its activity. This
automatically initializes the MapEngine and creates an ARController for use. This method is a convenience
method that can be used for fragments embedded in a layout XML. This method should not be used when
programmatically creating an CompositeFragment .
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
listener
A OnEngineInitListener object that will be called when CompositeFragment and MapEngine
initialization is finished. A null object can be supplied if callers do not expect any notification when
initialization completes.
See also:
OnEngineInitListener
init(ApplicationContext, OnEngineInitListener)
init(Context, OnEngineInitListener)
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
User of CompositeFragment must call this function after the fragment is created. This automatically
initialises the MapEngine and creates an ARController for use. This method can be used when
programmatically creating an CompositeFragment .
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
context
Application context.
listener
A OnEngineInitListener object that will be called when CompositeFragment and MapEngine
initialization is finished. A null object can be supplied if callers do not expect any notification when
initialization completes.
HERE Android SDK Developer's Guide
API Reference
402
See also:
OnEngineInitListener
init(Context, OnEngineInitListener)
init(OnEngineInitListener)
public void init (Context context, MapVariant variant, OnEngineInitListener
listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
User of CompositeFragment must call this function after the fragment is created. This automatically
initialises the MapEngine and creates an ARController for use. This method can be used when
programmatically creating an CompositeFragment .
This method can configure map variant which will be used by MapEngine. If initialization fails -
OPERATION_NOT_ALLOWED will be reported. Currently following variants are supported: - GLOBAL - initialize
MapEngine to use international map variant; - KOREA - initialize MapEngine to use Korean map variant; -
null - initialize MapEngine to use stored map variant or international map variant for first run. This method
is used to configure MapEngine to use certain map variant. If MapEngine was already configured and
passed variant differs - error will be reported and initialization fails.
Parameters:
context
Application context.
variant
Map variant to use.
listener
A OnEngineInitListener object that will be called when CompositeFragment and MapEngine
initialization is finished. A null object can be supplied if callers do not expect any notification when
initialization completes.
See also:
OnEngineInitListener
init(Context, OnEngineInitListener)
init(OnEngineInitListener)
public void init (ApplicationContext context, OnEngineInitListener listener)
Users of CompositeFragment must call this function after the fragment is first attached to its activity. This
automatically initializes the MapEngine and creates an ARController for use. This method is a convenience
method that can be used for fragments embedded in a layout XML. This method should not be used when
programmatically creating an CompositeFragment .
HERE Android SDK Developer's Guide
API Reference
403
Parameters:
context
ApplicationContext to be used during initialization.
listener
A OnEngineInitListener object that will be called when CompositeFragment and MapEngine
initialization is finished. A null object can be supplied if callers do not expect any notification when
initialization completes.
See also:
OnEngineInitListener
init(ApplicationContext, OnEngineInitListener)
init(ApplicationContext, OnEngineInitListener)
public View onCreateView (LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
For documentation, see android.app.Fragment.onCreateView(LayoutInflater, viewGrup, Bundle)
Parameters:
inflater
container
savedInstanceState
public void onDestroyView ()
For documentation, see android.app.Fragment.onDestroyView()
public void onInflate (Activity activity, AttributeSet attrs, Bundle
savedInstanceState)
Deprecated: Deprecated as of release 3.5.
Use onInflate(Context, android.util.AttributeSet, android.os.Bundle) instead.
For documentation, see android.app.Fragment.onInflate(Activity, AttributeSet, Bundle)
Parameters:
activity
attrs
savedInstanceState
public void onInflate (Context context, AttributeSet attrs, Bundle
savedInstanceState)
For documentation, see android.app.Fragment.onInflate(Context, AttributeSet, Bundle)
HERE Android SDK Developer's Guide
API Reference
404
Parameters:
context
attrs
savedInstanceState
public void onPause ()
Called when this fragment is no longer resumed. All MapEngine activities will be paused automatically.
See also:
android.app.Fragment#onPause()
public void onResume ()
Called when this fragment is visible to the user and actively running. All MapEngine activities will be resumed
automatically.
See also:
android.app.Fragment#onResume()
public void onSaveInstanceState (Bundle outState)
Parameters:
outState
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
Parameters:
listener
A OnMapRenderListener to remove from the CompositeFragment
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the CompositeFragment. Only the area specified by the ViewRect will be used for
rendering, while the rest of the view will be masked in black. This rectangle will be reset to the full size of the
CompositeFragment upon screen rotation or upon recreating the screen.
Note that setting a clipping rectangle will also reset the CompositeFragment 's viewing rectangle to its full
default size.
If the ViewRect is not valid, this method does nothing.
Parameters:
rect
HERE Android SDK Developer's Guide
API Reference
405
A ViewRect for rendering MapObjects and similar map-related screen elements
transformCenter
A android.graphics.PointF representing the center coordinate for map transformations such as
zooming and rotation
See also:
setClipRect(ViewRect)
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to this CompositeFragment. Only the area specified by the ViewRect will be used for
rendering, while the rest of the view will be masked in black. This rectangle will be reset to the full size of the
CompositeFragment upon screen rotation or upon recreating the screen.
If the ViewRect is not valid, this method does nothing.
Parameters:
rect
A ViewRect for rendering MapObjects and similar map-related screen elements
See also:
setClipRect(ViewRect, PointF)
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the CompositeFragment 's boundary, for the
placement of the HERE copyright logo.
If the specified rectangle is not contained completely within the current visible map area, their area of
intersection will be used instead of the specified rectangle's area. The copyright logo and copyright margin
must fit into the rectangle, otherwise specified rectangle will be ignored.
The rectangle is reset upon screen rotation or upon screen re-creation, or it can be done by setting a null -
android.graphics.Rect .
Parameters:
rect
A android.graphics.Rect representing the desired rectangular container to be used for positioning
the copyright logo. Use null android.graphics.Rect to reset the boundary container.
Throws:
IllegalArgumentException
if android.graphics.Rect supplied is invalid
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
HERE Android SDK Developer's Guide
API Reference
406
Sets a position for the HERE copyright logo. The current default is to place the logo at the center-bottom of
the visible map view area.
After the logo's position is set, the position stays effective even when the screen is rotated or re-created.
Parameters:
position
A CopyrightLogoPosition value representing the desired placement of the HERE copyright logo with
respect to the visible map view area
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map
area to the edge of the logo (depending on the placement).
Parameters:
margin
Desired offset from the edge of the CompositeFragment
public void setMapMarkerDragListener (OnDragListener listener)
Sets a OnDragListener to be invoked whenever any MapMarker on a Map that is attached to this fragment is
dragged.
Parameters:
listener
An MapMarker.OnDragListener to set for this CompositeFragment
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the
CompositeFragment.
Parameters:
listener
An android.view.OnTouchListener to set for the CompositeFragment
See also:
android.view.View.OnTouchListener
LineAttributes
The class LineAttributes is a member of com.here.android.mpa.ar .
HERE Android SDK Developer's Guide
API Reference
407
Class Summary
public class LineAttributes
extends java.lang.Object
Line/Shape outline attributes.
[For complete information, see the section Class Details]
Constructor Summary
Table 83: Constructors in LineAttributes
Constructors
LineAttributes ()
Constructs a LineAttributes object from default parameters.
LineAttributes (int widthInPixel, int color, CapStyle capStyle, boolean perspective)
Constructs a LineAttributes object from passed parameters.
Field Summary
Table 84: Fields in LineAttributes
Fields
protected LineAttributesImpl m_basePimpl
Method Summary
Table 85: Methods in LineAttributes
Methods
public LineAttributes enablePerspective (boolean enable)
Enable perspective.
public CapStyle getCapStyle ()
Get the line end rendering cap style
public int getDashPrimaryLength ()
Returns the current length of the primary dash segment of a dashed line, in pixels.
public int getDashSecondaryLength ()
Returns the current length of the secondary (empty) dash segments of a dashed line, in pixels.
public int getLineColor ()
Gets the current line color, returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getLineWidth ()
Returns the current line width, in pixels.
HERE Android SDK Developer's Guide
API Reference
408
Methods
public boolean isDashEnabled ()
Returns a boolean indicating whether the LineAttributes appears as a dashed line.
public boolean isPerspectiveEnable ()
Queries if perspective is enabled.
public LineAttributes setCapStyle (CapStyle style)
Set the line end rendering cap style.
public LineAttributes setDashEnabled (boolean enabled)
Sets the appearance as either a dashed or solid line.
public LineAttributes setDashPrimaryLength (int length)
Sets a length, in pixels, for the primary dash segment of a dashed line.
public LineAttributes setDashSecondaryLength (int length)
Sets a length, in pixels, for the secondary (empty) dash segments of a dashed line.
public LineAttributes setLineColor (int color)
Sets line color, using an ARGB (Alpha/Red/Green/Blue) integer color value.
public LineAttributes setLineWidth (int width)
Sets a line width, in pixels, an int value within the [0..100] range.
Class Details
Line/Shape outline attributes. specify the drawing attributes of a line or the outline of a shape. This class can
be used together with GeoPolyline to form a ARPolylineObject.
Constructor Details
LineAttributes ()
Constructs a LineAttributes object from default parameters.
Default parameters are:
Width of Line - 1 px
Color of the line - android.graphics.Color#BLUE
The line ending styles - ROUND
Perspective - false
LineAttributes (int widthInPixel, int color, CapStyle capStyle, boolean
perspective)
Constructs a LineAttributes object from passed parameters.
Parameters:
widthInPixel
HERE Android SDK Developer's Guide
API Reference
409
Width in pixels of the line. The value will be clipped to the valid range [0, 100].
color
Color of the line using an ARGB (Alpha/Red/Green/Blue) integer color value.
capStyle
The line ending styles.
perspective
if true, the line looks thinner further away when the map is tilted.
Field Details
protected LineAttributesImpl m_basePimpl
Method Details
public LineAttributes enablePerspective (boolean enable)
Enable perspective. The line looks thinner further away when the map is tilted.
Parameters:
enable
Value to set.
Returns:
The updated LineAttributes itself.
public CapStyle getCapStyle ()
Get the line end rendering cap style
Returns:
CapStyle cap style.
public int getDashPrimaryLength ()
Returns the current length of the primary dash segment of a dashed line, in pixels.
Returns:
The current length of the primary dash
See also:
getDashSecondaryLength()
HERE Android SDK Developer's Guide
API Reference
410
public int getDashSecondaryLength ()
Returns the current length of the secondary (empty) dash segments of a dashed line, in pixels.
Returns:
The current length of the empty dash
See also:
getDashPrimaryLength()
public int getLineColor ()
Gets the current line color, returning an ARGB (Alpha/Red/Green/Blue) integer color value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution
See also:
android.graphics.Color
public int getLineWidth ()
Returns the current line width, in pixels.
Returns:
The current line width.
public boolean isDashEnabled ()
Returns a boolean indicating whether the LineAttributes appears as a dashed line. By default, dash is
disabled.
Returns:
True if the LineAttributes is dashed, false otherwise
public boolean isPerspectiveEnable ()
Queries if perspective is enabled.
Returns:
perspective state.
public LineAttributes setCapStyle (CapStyle style)
HERE Android SDK Developer's Guide
API Reference
411
Set the line end rendering cap style.
Parameters:
style
CapStyle
Returns:
The updated LineAttributes itself.
public LineAttributes setDashEnabled (boolean enabled)
Sets the appearance as either a dashed or solid line.
Parameters:
enabled
A boolean specifying whether line should be dashed.
Returns:
The updated LineAttributes itself.
public LineAttributes setDashPrimaryLength (int length)
Sets a length, in pixels, for the primary dash segment of a dashed line. By default, the primary dash length is
1.
Parameters:
length
Desired length of the primary dash
Returns:
The updated LineAttributes itself.
Throws:
IllegalArgumentException
if length is smaller or equal to 0.
See also:
setDashSecondaryLength(int)
public LineAttributes setDashSecondaryLength (int length)
Sets a length, in pixels, for the secondary (empty) dash segments of a dashed line. By default, the secondary
dash length is 1.
Parameters:
length
HERE Android SDK Developer's Guide
API Reference
412
Desired length of the empty dash
Returns:
The updated LineAttributes itself.
Throws:
IllegalArgumentException
if length is smaller or equal to 0.
See also:
setDashPrimaryLength(int)
public LineAttributes setLineColor (int color)
Sets line color, using an ARGB (Alpha/Red/Green/Blue) integer color value. The default line color is
Color.BLUE .
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated LineAttributes itself.
See also:
android.graphics.Color
public LineAttributes setLineWidth (int width)
Sets a line width, in pixels, an int value within the [0..100] range. By default, the line width is 1.
Parameters:
width
Desired width of the line. Must be within the [0..100] range.
Returns:
The updated LineAttributes itself.
Throws:
IllegalArgumentException
is width is out of range.
HERE Android SDK Developer's Guide
API Reference
413
cluster
The package cluster is a member of com.here.android.mpa.
Package Summary
cluster
This package provides classes, interfaces, and enumerations for Marker clustering.
Package Details
This package provides classes, interfaces, and enumerations for Marker clustering. With this feature, markers
that are close together are automatically replaced by numbered cluster markers to indicate that multiple
map markers are represented.
Some key classes and interfaces in this package are:
ClusterLayer
ClusterTheme
ClusterStyle
For more information for using this feature, please consult the "Marker Clustering" section in the HERE SDK
for Android Developer's Guide.
BasicClusterStyle
The class BasicClusterStyle is a member of com.here.android.mpa.cluster .
Class Summary
public class BasicClusterStyle
extends com.here.android.mpa.cluster.ClusterStyle, java.lang.Object
Basic implementation of ClusterStyle.
[For complete information, see the section Class Details]
See also:
ClusterTheme
ClusterStyle
HERE Android SDK Developer's Guide
API Reference
414
Constructor Summary
Table 86: Constructors in BasicClusterStyle
Constructors
BasicClusterStyle ()
Creates new style with default icon stroke, fill and font colors.
BasicClusterStyle (int strokeColor, int fillColor, int fontColor)
Creates new style with specific stroke, fill and font colors.
Method Summary
Table 87: Methods in BasicClusterStyle
Methods
public int getFillColor ()
Returns the current color for filling the cluster icon.
public int getFontColor ()
Returns color of the font which is used to display the density in the cluster icon.
public int getStrokeColor ()
Return the color of the cluster icon outline.
public BasicClusterStyle setFillColor (int fillColor)
Set the color for filling the cluster icon.
public BasicClusterStyle setFontColor (int fontColor)
Sets color of the font, which is used to display the density in the cluster icon.
public BasicClusterStyle setStrokeColor (int strokeColor)
Set the color of the cluster icon outline.
public String toString ()
For documentation, see java.lang.Object
Class Details
Basic implementation of ClusterStyle. This cluster style can be used if you need to apply some basic
customizations to the default cluster style.
Note that in the default and basic cluster styles, the size of the circle grows as the density grows.
The colors in this class need to be specified in an ARGB packed integer format. This packed integer is made
up of 4 bytes: alpha, red, green, blue. Each color component has a value range from [0..255] with 0 meaning
no contribution for that component, and 255 meaning 100% contribution.
See also:
ClusterTheme
HERE Android SDK Developer's Guide
API Reference
415
ClusterStyle
Constructor Details
BasicClusterStyle ()
Creates new style with default icon stroke, fill and font colors.
BasicClusterStyle (int strokeColor, int fillColor, int fontColor)
Creates new style with specific stroke, fill and font colors.
Parameters:
strokeColor
Color of the icon's outline, as a 4-byte ARGB value.
fillColor
Fill color of the icon, as a 4-byte ARGB value.
fontColor
Color of the font inside the icon, as a 4-byte ARGB value.
Method Details
public int getFillColor ()
Returns the current color for filling the cluster icon.
Returns:
Fill color of the icon, as a 4-byte ARGB value.
public int getFontColor ()
Returns color of the font which is used to display the density in the cluster icon.
Returns:
Color of the font inside the icon, in a 4-byte ARGB value.
public int getStrokeColor ()
Return the color of the cluster icon outline.
Returns:
Stroke color of the icon, as a 4-byte ARGB value.
public BasicClusterStyle setFillColor (int fillColor)
HERE Android SDK Developer's Guide
API Reference
416
Set the color for filling the cluster icon.
Parameters:
fillColor
Fill color of the icon, as a 4-byte ARGB value.
Returns:
The updated BasicClusterStyle object itself.
public BasicClusterStyle setFontColor (int fontColor)
Sets color of the font, which is used to display the density in the cluster icon.
Parameters:
fontColor
Color of the font inside the icon as a 4-byte ARGB value.
Returns:
The updated BasicClusterStyle object itself.
public BasicClusterStyle setStrokeColor (int strokeColor)
Set the color of the cluster icon outline.
Parameters:
strokeColor
Stroke color of the icon, as a 4-byte ARGB value.
Returns:
The updated BasicClusterStyle object itself.
public String toString ()
For documentation, see java.lang.Object
ClusterDensityRange
The class ClusterDensityRange is a member of com.here.android.mpa.cluster .
Class Summary
public class ClusterDensityRange
extends java.lang.Object
Represents a range of cluster densities that can be represented, such as '5 to 10 markers'.
HERE Android SDK Developer's Guide
API Reference
417
[For complete information, see the section Class Details]
Constructor Summary
Table 88: Constructors in ClusterDensityRange
Constructors
ClusterDensityRange (int from, int to)
Creates a new density range.
Field Summary
Table 89: Fields in ClusterDensityRange
Fields
public static final int MINIMUM_CLUSTER_DENSITY
The lowest allowable density for any map cluster.
public final int from
The lower density limit for this range.
public final int to
The upper density limit for this range.
Method Summary
Table 90: Methods in ClusterDensityRange
Methods
public static boolean isValidDensityRange (int from, int to)
Checks if the provided values comprise a valid range.
public String toString ()
For documentation, see java.lang.Object
Class Details
Represents a range of cluster densities that can be represented, such as '5 to 10 markers'. Cluster density is
the number of map markers that are inside a single cluster.
Cluster density ranges are inclusive of the upper and lower bounds.
Constructor Details
ClusterDensityRange (int from, int to)
Creates a new density range.
Parameters:
HERE Android SDK Developer's Guide
API Reference
418
from
Lower density range limit (inclusive), must be greater or equal to MINIMUM_CLUSTER_DENSITY.
to
Upper density range limit (inclusive), must be smaller or equal lower limit
Throws:
IllegalArgumentException
If lower limit smaller than MINIMUM_CLUSTER_DENSITY or if lower limit greater than upper limit
Field Details
public static final int MINIMUM_CLUSTER_DENSITY
The lowest allowable density for any map cluster. Clusters will only form if there are more than this amount
of map markers.
public final int from
The lower density limit for this range.
public final int to
The upper density limit for this range.
Method Details
public static boolean isValidDensityRange (int from, int to)
Checks if the provided values comprise a valid range. A range is valid if ( from is smaller or equal to to ) and
( from greater or equal to MINIMUM_CLUSTER_DENSITY).
Parameters:
from
lower density range limit
to
upper density range limit
Returns:
true if the range is valid, false otherwise
public String toString ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
419
ClusterLayer
The class ClusterLayer is a member of com.here.android.mpa.cluster .
Class Summary
public class ClusterLayer
extends java.lang.Object
ClusterLayer is a container of MapMarker instances.
[For complete information, see the section Class Details]
Constructor Summary
Table 91: Constructors in ClusterLayer
Constructors
ClusterLayer ()
Creates new cluster layer with a default theme.
Method Summary
Table 92: Methods in ClusterLayer
Methods
public void addMarker (MapMarker marker)
Adds a MapMarker to this layer.
public void addMarkers (java.util.Collection <MapMarker> markers)
Adds a collection of MapMarker to this layer.
public java.util.Collection <MapMarker> getMarkers ()
Retrieves all MapMarker instances added to this layer.
public boolean removeMarker (MapMarker marker)
Removes the given MapMarker from this layer.
public boolean removeMarkers (java.util.Collection <MapMarker> markers)
Removes a collection of MapMarker from this layer.
public void setTheme (ClusterTheme theme)
Sets the theme to be used during cluster marker rendering.
public String toString ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
420
Class Details
ClusterLayer is a container of MapMarker instances.
A newly created layer must be attached to the map before clustering begins. There is no restriction on calling
the methods of this class when it is removed from (not added to) the map.
Once added to the layer, markers will start to cluster when the layer is attached to the map.
Constructor Details
ClusterLayer ()
Creates new cluster layer with a default theme.
Method Details
public void addMarker (MapMarker marker)
Adds a MapMarker to this layer.
The marker is also added to the Map if the layer is added to it.
Parameters:
marker
The MapMarker to be added.
Throws:
NullPointerException
If the marker is null.
See also:
addMarkers(Collection<MapMarker>)
public void addMarkers (java.util.Collection <MapMarker> markers)
Adds a collection of MapMarker to this layer.
The markers are also added to the Map if the layer is added to it.
Parameters:
markers
A collection of MapMarker instances to be added
Throws:
NullPointerException
If the any marker in the collection is null.
See also:
HERE Android SDK Developer's Guide
API Reference
421
addMarker(MapMarker)
public java.util.Collection <MapMarker> getMarkers ()
Retrieves all MapMarker instances added to this layer.
Returns:
a collection of all markers added to this layer
public boolean removeMarker (MapMarker marker)
Removes the given MapMarker from this layer.
The marker is also removed from the Map if the layer is already added to it.
Use removeMarkers(Collection) to remove a batch of map markers.
Parameters:
marker
A MapMarker to remove
Returns:
true if this layer was modified by this operation, false otherwise.
See also:
removeMarkers(Collection<MapMarker>)
public boolean removeMarkers (java.util.Collection <MapMarker> markers)
Removes a collection of MapMarker from this layer.
The markers are also removed from the Map if the layer already added to it.
Parameters:
markers
collection of MapMarker to remove
Returns:
true if this layer was modified by this operation, false otherwise.
public void setTheme (ClusterTheme theme)
Sets the theme to be used during cluster marker rendering.
If no theme is set using this method, a default theme is used.
Parameters:
theme
HERE Android SDK Developer's Guide
API Reference
422
theme to be used
Throws:
NullPointerException
if null is passed
public String toString ()
For documentation, see java.lang.Object
ClusterStyle
The class ClusterStyle is a member of com.here.android.mpa.cluster .
Class Summary
public abstract class ClusterStyle
extends java.lang.Object
A base class for customizing the look of the cluster icon used for a specific density range.
[For complete information, see the section Class Details]
See also:
ClusterTheme
Class Details
A base class for customizing the look of the cluster icon used for a specific density range. Cluster density
represents the number of map markers inside a cluster.
By default, a cluster is represented on a map by a circular icon with the density drawn in the middle.
See also:
ClusterTheme
ClusterTheme
The class ClusterTheme is a member of com.here.android.mpa.cluster .
Class Summary
public class ClusterTheme
extends java.lang.Object
A mapping of cluster density ranges to cluster icon styles.
HERE Android SDK Developer's Guide
API Reference
423
[For complete information, see the section Class Details]
See also:
setTheme(ClusterTheme)
Constructor Summary
Table 93: Constructors in ClusterTheme
Constructors
ClusterTheme ()
Creates a new theme with the default presentation style.
ClusterTheme (ClusterTheme theme)
Creates a new theme by copying ranges and styles from another.
Method Summary
Table 94: Methods in ClusterTheme
Methods
public void setStyleForDensityRange (int from, int to, ClusterStyle style)
Sets particular style for a specific range.
public void setStyleForDensityRange (ClusterDensityRange range, ClusterStyle style)
Sets particular style for a specific range.
Class Details
A mapping of cluster density ranges to cluster icon styles. Cluster density represents the number of markers
inside a cluster.
See also:
setTheme(ClusterTheme)
Constructor Details
ClusterTheme ()
Creates a new theme with the default presentation style.
ClusterTheme (ClusterTheme theme)
Creates a new theme by copying ranges and styles from another.
Parameters:
theme
theme to copy from
HERE Android SDK Developer's Guide
API Reference
424
Method Details
public void setStyleForDensityRange (int from, int to, ClusterStyle style)
Sets particular style for a specific range. Ranges set by this method should be valid and cannot overlap.
The default style is used for the ranges not set manually.
Parameters:
from
lower density range limit (inclusive), must be greater than MINIMUM_CLUSTER_DENSITY
to
upper density range limit (inclusive), must be greater than or equal to lower limit
style
style for this range
Throws:
IllegalArgumentException
If one of the following occurs: the lower limit is smaller than MINIMUM_CLUSTER_DENSITY, the lower
limit is greater than the upper limit, or the range overlaps with one of the already added ranges to this
theme.
NullPointerException
if style is null
See also:
setStyleForDensityRange(ClusterDensityRange, ClusterStyle)
public void setStyleForDensityRange (ClusterDensityRange range, ClusterStyle
style)
Sets particular style for a specific range. Ranges set by this method should be valid and cannot overlap.
The default style is used for the ranges not set manually.
Parameters:
range
density range
style
style for this range
Throws:
IllegalArgumentException
if the range overlaps with one of the already added ranges to this theme
NullPointerException
HERE Android SDK Developer's Guide
API Reference
425
if range or style is null
ClusterViewObject
The class ClusterViewObject is a member of com.here.android.mpa.cluster .
Class Summary
public final class ClusterViewObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a visual manifestation of a marker cluster.
[For complete information, see the section Class Details]
Method Summary
Table 95: Methods in ClusterViewObject
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Type getBaseType ()
Returns the real implementation type of the ViewObject .
This method overrides common.ViewObject.getBaseType(void)
public GeoBoundingBox getBoundingBox ()
Returns a bounding box containing all markers in this cluster.
public java.util.Collection <MapMarker> getMarkers ()
Returns all the markers represented by this cluster.
public Type getType ()
Returns the type of object that the MapProxyObject represents.
This method overrides mapping.MapProxyObject.getType(void)
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
For documentation, see java.lang.Object
Class Details
Represents a visual manifestation of a marker cluster.
HERE Android SDK Developer's Guide
API Reference
426
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public Type getBaseType ()
Returns the real implementation type of the ViewObject .
This method overrides common.ViewObject.getBaseType(void)
public GeoBoundingBox getBoundingBox ()
Returns a bounding box containing all markers in this cluster.
Returns:
A minimal box containing all the markers from this cluster represented by a GeoBoundingBox.
public java.util.Collection <MapMarker> getMarkers ()
Returns all the markers represented by this cluster.
Returns:
A shallow copy of markers clustered in this cluster
public Type getType ()
Returns the type of object that the MapProxyObject represents.
This method overrides mapping.MapProxyObject.getType(void)
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
427
ImageClusterStyle
The class ImageClusterStyle is a member of com.here.android.mpa.cluster .
Class Summary
public final class ImageClusterStyle
extends com.here.android.mpa.cluster.ClusterStyle, java.lang.Object
An implementation of a cluster style that uses an Image as the cluster icon.
[For complete information, see the section Class Details]
See also:
ClusterTheme
Constructor Summary
Table 96: Constructors in ImageClusterStyle
Constructors
ImageClusterStyle (Image image)
Creates an image cluster style using the given Image
ImageClusterStyle (int resId)
Creates an image cluster style from the given Android drawable resource.
Method Summary
Table 97: Methods in ImageClusterStyle
Methods
public String toString ()
For documentation, see java.lang.Object
Class Details
An implementation of a cluster style that uses an Image as the cluster icon.
See also:
ClusterTheme
Constructor Details
ImageClusterStyle (Image image)
Creates an image cluster style using the given Image
HERE Android SDK Developer's Guide
API Reference
428
Parameters:
image
the image to be used to draw the cluster icon
ImageClusterStyle (int resId)
Creates an image cluster style from the given Android drawable resource.
Parameters:
resId
drawable resource to create the style from
Method Details
public String toString ()
For documentation, see java.lang.Object
common
The package common is a member of com.here.android.mpa.
Package Summary
common
This package includes classes, interfaces, and enumerations that are generally used by other packages in the
Android SDK.
Package Details
This package includes classes, interfaces, and enumerations that are generally used by other packages in the
Android SDK.
However, the following classes are key classes that serves as the entry point to services provided by our SDK:
MapEngine - is the entry point for all services provided. It must be initialized before using our services.
PositioningManager - is the entry point for our positioning service.
MapActivity - can be used for applications that uses our headless APIs without having to manually
handle the MapEngine setup.
For more information, please refer to our User Guide or the documentation provided by the individual
classes above.
HERE Android SDK Developer's Guide
API Reference
429
ApplicationContext
The class ApplicationContext is a member of com.here.android.mpa.common .
Class Summary
public final class ApplicationContext
extends java.lang.Object
ApplicationContext manages setting of custom application credentials and map variant.
[For complete information, see the section Class Details]
Constructor Summary
Table 98: Constructors in ApplicationContext
Constructors
ApplicationContext (Context ctx)
Creates a ApplicationContext with specified application context.
Method Summary
Table 99: Methods in ApplicationContext
Methods
public ApplicationContext setAppIdCode (String appId, String appCode)
Sets the application ID and application token that are obtained by registering at http://developer.here.com/.
public ApplicationContext setLicenseKey (String licenseKey)
Sets the license key that are obtained by registering at http://developer.here.com/.
public ApplicationContext setMapVariant (MapVariant mapVariant)
Sets needed map variant.
public ApplicationContext setSdkVersionInCrashStack (boolean value)
Sets whether or not to show the HERE SDK Version in crash stack traces.
Class Details
ApplicationContext manages setting of custom application credentials and map variant. Setting of any
type of configuration should be made before the MapEngine is initialized.
Constructor Details
ApplicationContext (Context ctx)
Creates a ApplicationContext with specified application context.
HERE Android SDK Developer's Guide
API Reference
430
Parameters:
ctx
Application context.
Method Details
public ApplicationContext setAppIdCode (String appId, String appCode)
Sets the application ID and application token that are obtained by registering at http://developer.here.com/.
Parameters:
appId
unique application identifier. It is empty by default.
appCode
unique application code. It is empty by default.
Returns:
The updated ApplicationContext object itself.
public ApplicationContext setLicenseKey (String licenseKey)
Sets the license key that are obtained by registering at http://developer.here.com/.
Parameters:
licenseKey
the license key defining application permissions. It is empty by default.
Returns:
The updated ApplicationContext object itself.
public ApplicationContext setMapVariant (MapVariant mapVariant)
Sets needed map variant.
Parameters:
mapVariant
map variant to use. If never set, then GLOBAL will be used.
Returns:
The updated ApplicationContext object itself.
public ApplicationContext setSdkVersionInCrashStack (boolean value)
Sets whether or not to show the HERE SDK Version in crash stack traces. The default value is true.
HERE Android SDK Developer's Guide
API Reference
431
By default, for Java, a Thread.UncaughtExceptionHandler is added which appends the HERE SDK
Version to the normal stack trace. For Native, a lightweight thread is started which sleeps in a function
containing names as the HERE SDK Version. Setting this to false disables both previously described
behaviours.
Parameters:
value
Indicates whether or not to show the HERE SDK Version in crash stack traces.
Returns:
The updated ApplicationContext object itself.
ConnectionInfo
The class ConnectionInfo is a member of com.here.android.mpa.common .
Class Summary
public final class ConnectionInfo
extends java.lang.Object
Encapsulates information related to network connections.
[For complete information, see the section Class Details]
Constructor Summary
Table 100: Constructors in ConnectionInfo
Constructors
ConnectionInfo ()
Public constructor.
Method Summary
Table 101: Methods in ConnectionInfo
Methods
public long getBytesDownloaded ()
Gets the amount of data downloaded in bytes.
Class Details
Encapsulates information related to network connections.
HERE Android SDK Developer's Guide
API Reference
432
Constructor Details
ConnectionInfo ()
Public constructor.
Method Details
public long getBytesDownloaded ()
Gets the amount of data downloaded in bytes.
The amount is cumulative since the application process was created. If the process is terminated and
recreated, the count will begin again from 0.
Returns:
The data downloaded in bytes
CopyrightLogoPosition
The enumeration CopyrightLogoPosition is a member of com.here.android.mpa.common .
Enumeration Summary
public final enumeration CopyrightLogoPosition
extends java.lang.Enum, java.lang.Object
Represents values that describe on-display view positions for the HERE copyright logo.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 102: Enum Constants in CopyrightLogoPosition
Fields
public static final CopyrightLogoPosition TOP_LEFT
The copyright logo is positioned at the top-left portion of the display view.
public static final CopyrightLogoPosition TOP_CENTER
The copyright logo is positioned at the top-center portion of the display view.
public static final CopyrightLogoPosition TOP_RIGHT
The copyright logo is positioned at the top-right portion of the display view.
public static final CopyrightLogoPosition BOTTOM_CENTER
The copyright logo is positioned at the bottom-center portion of the display view.
HERE Android SDK Developer's Guide
API Reference
433
Method Summary
Table 103: Methods in CopyrightLogoPosition
Methods
public static CopyrightLogoPosition valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CopyrightLogoPosition[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values that describe on-display view positions for the HERE copyright logo.
Enum Constant Details
public static final CopyrightLogoPosition TOP_LEFT
The copyright logo is positioned at the top-left portion of the display view.
public static final CopyrightLogoPosition TOP_CENTER
The copyright logo is positioned at the top-center portion of the display view.
public static final CopyrightLogoPosition TOP_RIGHT
The copyright logo is positioned at the top-right portion of the display view.
public static final CopyrightLogoPosition BOTTOM_CENTER
The copyright logo is positioned at the bottom-center portion of the display view.
Method Details
public static CopyrightLogoPosition valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CopyrightLogoPosition[] values ()
HERE Android SDK Developer's Guide
API Reference
434
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CustomConfigurations
The class CustomConfigurations is a member of com.here.android.mpa.common .
Class Summary
public final class CustomConfigurations
extends java.lang.Object
CustomConfigurations manages setting of custom configurations.
[For complete information, see the section Class Details]
Nested Class Summary
Table 104: Nested Classes in CustomConfigurations
Nested Classes
public static final enumeration CustomConfigurations.Config
Argument keys for set(Hashtable),
Constructor Summary
Table 105: Constructors in CustomConfigurations
Constructors
CustomConfigurations ()
Method Summary
Table 106: Methods in CustomConfigurations
Methods
public static void set (java.util.Hashtable <Config, java.lang.String> configFiles)
Sets custom configuration.
Class Details
CustomConfigurations manages setting of custom configurations. Setting of any type of configuration
should be made before the MapEngine is initialized. MAP config must always be set together with
MAP_RESOURCE Note: This API should only be used in consultation with HERE technical support.
HERE Android SDK Developer's Guide
API Reference
435
Constructor Details
CustomConfigurations ()
Method Details
public static void set (java.util.Hashtable <Config, java.lang.String>
configFiles)
Sets custom configuration. This method must be called before the MapEngine is initialized. MAP config
must always be set in pair with MAP_RESOURCE Note: This API should only be used in consultation with HERE
technical support.
Parameters:
configFiles
A Hashtable of Key/Value pairs where key is of type CustomConfigurations.Config and value is file path
where the specified configuration is located.
Throws:
IllegalStateException
if MapEngine is already initialized.
FileNotFoundException
if at least one of the configuration files does not exist.
IllegalArgumentException
If the Hashtable of configuration key/value pairs provided is invalid, or only one config of types MAP
and MAP_RESOURCE was set.
Config
The enumeration Config is a member of com.here.android.mpa.common.CustomConfigurations.
Enumeration Summary
public static final enumeration CustomConfigurations.Config
extends java.lang.Enum, java.lang.Object
Argument keys for set(Hashtable),
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
436
Enum Constant Summary
Table 107: Enum Constants in Config
Fields
public static final Config MAP
Map Style Configuration
public static final Config MAP_RESOURCE
Map Style Resource
public static final Config TRAFFIC
Traffic Style Resource
public static final Config CUSTOM_PREFERENCE
Custom Configuration
Method Summary
Table 108: Methods in Config
Methods
public static Config valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CustomConfigurations.Config[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Argument keys for set(Hashtable),
Enum Constant Details
public static final Config MAP
Map Style Configuration
public static final Config MAP_RESOURCE
Map Style Resource
public static final Config TRAFFIC
Traffic Style Resource
public static final Config CUSTOM_PREFERENCE
HERE Android SDK Developer's Guide
API Reference
437
Custom Configuration
Method Details
public static Config valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CustomConfigurations.Config[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
DiskCacheUtility
The class DiskCacheUtility is a member of com.here.android.mpa.common .
Class Summary
public final class DiskCacheUtility
extends java.lang.Object
Provides methods for manipulating the disk cache.
Deprecated: Provided only to help with the transition of pre-v3.4 disk caches to the current version.
[For complete information, see the section Class Details]
Nested Class Summary
Table 109: Nested Classes in DiskCacheUtility
Nested Classes
public static final enumeration DiskCacheUtility.MigrationResult
Constructor Summary
Table 110: Constructors in DiskCacheUtility
Constructors
DiskCacheUtility ()
HERE Android SDK Developer's Guide
API Reference
438
Method Summary
Table 111: Methods in DiskCacheUtility
Methods
public static MigrationResult migrate (String sourcePath, String destinationPath)
Migrates disk cache from previous SDK versions to current.
Class Details
Deprecated: Provided only to help with the transition of pre-v3.4 disk caches to the current version.
This class will be removed in a future release.
Provides methods for manipulating the disk cache.
Constructor Details
DiskCacheUtility ()
Method Details
public static MigrationResult migrate (String sourcePath, String
destinationPath)
Migrates disk cache from previous SDK versions to current.
Parameters:
sourcePath
Existing disk cache path. If path does not exist, FAILED will be returned.
destinationPath
Destination disk cache path. This should be used as path of setIsolatedDiskCacheRootPath(String,
String).
Returns:
a DiskCacheUtility.MigrationResult as migration result
MigrationResult
The enumeration MigrationResult is a member of com.here.android.mpa.common.DiskCacheUtility.
Enumeration Summary
public static final enumeration DiskCacheUtility.MigrationResult
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
439
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 112: Enum Constants in MigrationResult
Fields
public static final MigrationResult SUCCESS
Disk cache was migrated successfully.
public static final MigrationResult ALREADY_EXISTS
New disk cache specified as the destination path for migrate(String, String) already exists .
public static final MigrationResult MISSING_OLD_CACHE
Old cache specified as the source path for migrate(String, String) is missing.
public static final MigrationResult PATH_NOT_ALLOWED
The source path or destination path specified in migrate(String, String) cannot be the same as the default shared disk
cache path.
public static final MigrationResult FAILED
Failed to move the cache.
Method Summary
Table 113: Methods in MigrationResult
Methods
public static MigrationResult valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static DiskCacheUtility.MigrationResult[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final MigrationResult SUCCESS
Disk cache was migrated successfully.
public static final MigrationResult ALREADY_EXISTS
New disk cache specified as the destination path for migrate(String, String) already exists .
public static final MigrationResult MISSING_OLD_CACHE
HERE Android SDK Developer's Guide
API Reference
440
Old cache specified as the source path for migrate(String, String) is missing.
public static final MigrationResult PATH_NOT_ALLOWED
The source path or destination path specified in migrate(String, String) cannot be the same as the default
shared disk cache path.
public static final MigrationResult FAILED
Failed to move the cache. It could be missing rights for source or destination directory. It will also fail if you
move the cache across drives.
Method Details
public static MigrationResult valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static DiskCacheUtility.MigrationResult[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
GeoBoundingBox
The class GeoBoundingBox is a member of com.here.android.mpa.common .
Class Summary
public final class GeoBoundingBox
extends java.lang.Object
Represents a rectangular area in a geographic coordinate system.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
441
Constructor Summary
Table 114: Constructors in GeoBoundingBox
Constructors
GeoBoundingBox (GeoCoordinate topLeft, GeoCoordinate bottomRight)
Creates a GeoBoundingBox with specified top-left and bottom-right coordinates.
GeoBoundingBox (GeoCoordinate center, float height, float width)
Creates a GeoBoundingBox with a specified center and width and height in distance.
Method Summary
Table 115: Methods in GeoBoundingBox
Methods
public boolean contains (GeoBoundingBox bbox)
Determines whether the specified GeoBoundingBox is covered entirely by this GeoBoundingBox .
public boolean contains (GeoCoordinate coord)
Determines whether the specified GeoCoordinate is contained within this GeoBoundingBox.
public boolean equals (Object other)
For documentation, see java.lang.Object
public void expand (float latitudeMeters, float longitudeMeters)
Expands the GeoBoundingBox by a fixed distance.
public GeoCoordinate getBottomRight ()
Gets the current bottom-right GeoCoordinate of the GeoBoundingBox with altitude set to zero.
public GeoCoordinate getBottomRightBack ()
Gets the current bottom-right-back GeoCoordinate of the GeoBoundingBox.
public static GeoBoundingBox getBoundingBoxContainingGeoCoordinates (java.util.List <GeoCoordinate>
coordinates)
Constructs a GeoBoundingBox which contains all coordinates in an array.
public GeoCoordinate getCenter ()
Gets the center GeoCoordinate of the GeoBoundingBox.
public double getHeight ()
Gets the current GeoBoundingBox height, in degrees.
public GeoCoordinate getTopLeft ()
Gets the current top-left GeoCoordinate of the GeoBoundingBox with altitude set to zero
public GeoCoordinate getTopLeftFront ()
Gets the current top-left-front GeoCoordinate of the GeoBoundingBox.
HERE Android SDK Developer's Guide
API Reference
442
Methods
public double getWidth ()
Gets the current GeoBoundingBox width, in degrees.
public int hashCode ()
For documentation, see java.lang.Object
public boolean intersects (GeoBoundingBox bbox)
Determines whether the intersection of this GeoBoundingBox instance and the specified GeoBoundingBox is non-empty.
public boolean isEmpty ()
Determines whether the size of the enclosed GeoBoundingBox area is 0.
public GeoBoundingBox merge (GeoBoundingBox bbox)
Merges two GeoBoundingBox objects by returning the smallest GeoBoundingBox covering both this GeoBoundingBox and
the specified GeoBoundingBox .
public static GeoBoundingBox mergeBoxes (java.util.List <GeoBoundingBox> bboxes)
Merges multiple GeoBoundingBox objects by returning the smallest GeoBoundingBox covering all specified
GeoBoundingBox objects.
public void resizeToCenter (GeoCoordinate coord)
Increases the size of the GeoBoundingBox until the specified GeoCoordinate is located at the center.
public boolean setBottomRight (GeoCoordinate bottomRight)
Sets a bottom-right coordinate for the GeoBoundingBox.
public boolean setCoordinates (GeoCoordinate topLeft, GeoCoordinate bottomRight)
Sets coordinates for the GeoBoundingBox.
public boolean setTopLeft (GeoCoordinate topLeft)
Sets a top-left coordinate for the GeoBoundingBox.
public String toString ()
For documentation, see java.lang.Object
Class Details
Represents a rectangular area in a geographic coordinate system.
Although a bounding box is specified by its top-left and bottom-right corner, the box is not necessarily the
smallest rectangle spanned by these two points. It is possible to define geobounding boxes that are wider
than 180 degrees or higher then 90 degrees (e.g. by setting the longitude of the top-left corner to a bigger
value than the longitude of the bottom-right corner). Please note the top-left corner's latitude must be
greater than or equal to bottom-right corner's latitude. Otherwise, the bounding box will be in invalid state.
For example, a geobounding box with longitude of -180 degrees for the top-left corner and a longitude of 180
degrees for the bottom-right corner will construct an area that encircles the globe, whereas a geobounding
box with the same longitude value for both corners will construct an area with a width of 0 degrees.
HERE Android SDK Developer's Guide
API Reference
443
Constructor Details
GeoBoundingBox (GeoCoordinate topLeft, GeoCoordinate bottomRight)
Creates a GeoBoundingBox with specified top-left and bottom-right coordinates.
Parameters:
topLeft
A GeoCoordinate representing the top-left corner of the bounding box
bottomRight
A GeoCoordinate representing the bottom-right corner of the bounding box
Throws:
IllegalArgumentException
if the arguments will construct an invalid GeoBoundingBox.
GeoBoundingBox (GeoCoordinate center, float height, float width)
Creates a GeoBoundingBox with a specified center and width and height in distance.
Parameters:
center
A GeoCoordinate representing the geographical center of the bounding box.
height
The geographical height in meters
width
The geographical width in meters
Method Details
public boolean contains (GeoBoundingBox bbox)
Determines whether the specified GeoBoundingBox is covered entirely by this GeoBoundingBox .
Parameters:
bbox
A GeoBoundingBox to check for containment within this GeoBoundingBox
Returns:
True if covered by the GeoBoundingBox, false otherwise
See also:
contains(GeoCoordinate)
HERE Android SDK Developer's Guide
API Reference
444
public boolean contains (GeoCoordinate coord)
Determines whether the specified GeoCoordinate is contained within this GeoBoundingBox.
Parameters:
coord
A GeoCoordinate to check for containment within this GeoBoundingBox
Returns:
True if contained within the GeoBoundingBox, false otherwise
See also:
contains(GeoBoundingBox)
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public void expand (float latitudeMeters, float longitudeMeters)
Expands the GeoBoundingBox by a fixed distance.
Parameters:
latitudeMeters
The geographical height in meters to expand the GeoBoundingBox
longitudeMeters
The geographical width in meters to expand the GeoBoundingBox
public GeoCoordinate getBottomRight ()
Gets the current bottom-right GeoCoordinate of the GeoBoundingBox with altitude set to zero.
Returns:
The current bottom-right GeoCoordinate.
public GeoCoordinate getBottomRightBack ()
Gets the current bottom-right-back GeoCoordinate of the GeoBoundingBox. The altitude of this
geocoordinate will be valid only when the GeoBoundingBox was created with this information.
Returns:
The current bottom-right-back GeoCoordinate.
HERE Android SDK Developer's Guide
API Reference
445
public static GeoBoundingBox getBoundingBoxContainingGeoCoordinates
(java.util.List <GeoCoordinate> coordinates)
Constructs a GeoBoundingBox which contains all coordinates in an array.
The constructed GeoBoundingBox will be the smallest possible box which contains all the GeoCoordinate in
the input array.
Parameters:
coordinates
An array of GeoCoordinate defining the new GeoBoundingBox
Returns:
The GeoBoundingBox
public GeoCoordinate getCenter ()
Gets the center GeoCoordinate of the GeoBoundingBox.
Returns:
The center coordinate of the GeoBoundingBox
public double getHeight ()
Gets the current GeoBoundingBox height, in degrees.
Returns:
The current height
public GeoCoordinate getTopLeft ()
Gets the current top-left GeoCoordinate of the GeoBoundingBox with altitude set to zero
Returns:
The current top-left GeoCoordinate.
public GeoCoordinate getTopLeftFront ()
Gets the current top-left-front GeoCoordinate of the GeoBoundingBox. The altitude of this geocoordinate will
be valid only when the GeoBoundingBox was created with this information.
Returns:
The current top-left-front GeoCoordinate.
HERE Android SDK Developer's Guide
API Reference
446
public double getWidth ()
Gets the current GeoBoundingBox width, in degrees.
Returns:
The current width
public int hashCode ()
For documentation, see java.lang.Object
public boolean intersects (GeoBoundingBox bbox)
Determines whether the intersection of this GeoBoundingBox instance and the specified GeoBoundingBox
is non-empty.
Parameters:
bbox
A GeoBoundingBox to check for intersection with this GeoBoundingBox
Returns:
True if the intersection of GeoBoundingBox objects is non-empty, false otherwise
public boolean isEmpty ()
Determines whether the size of the enclosed GeoBoundingBox area is 0.
Returns:
True if the size of the enclosed area is 0, false otherwise
public GeoBoundingBox merge (GeoBoundingBox bbox)
Merges two GeoBoundingBox objects by returning the smallest GeoBoundingBox covering both this
GeoBoundingBox and the specified GeoBoundingBox .
Parameters:
bbox
A GeoBoundingBox to merge with this GeoBoundingBox
Returns:
The smallest GeoBoundingBox that covers both of the merged GeoBoundingBox objects
See also:
mergeBoxes(List<GeoBoundingBox>)
HERE Android SDK Developer's Guide
API Reference
447
public static GeoBoundingBox mergeBoxes (java.util.List <GeoBoundingBox>
bboxes)
Merges multiple GeoBoundingBox objects by returning the smallest GeoBoundingBox covering all specified
GeoBoundingBox objects.
Parameters:
bboxes
A list of GeoBoundingBox objects to merge
Returns:
The smallest GeoBoundingBox that covers all of the merged GeoBoundingBox objects
See also:
merge(GeoBoundingBox)
public void resizeToCenter (GeoCoordinate coord)
Increases the size of the GeoBoundingBox until the specified GeoCoordinate is located at the center.
Parameters:
coord
A GeoCoordinate that will become the center of the resized GeoBoundingBox
public boolean setBottomRight (GeoCoordinate bottomRight)
Sets a bottom-right coordinate for the GeoBoundingBox.
Parameters:
bottomRight
A GeoCoordinate representing the desired bottom-right coordinate
Returns:
True if setBottomRight complete successfully.
public boolean setCoordinates (GeoCoordinate topLeft, GeoCoordinate
bottomRight)
Sets coordinates for the GeoBoundingBox.
Parameters:
topLeft
A GeoCoordinate representing the desired top-left coordinate
bottomRight
A GeoCoordinate representing the desired bottom-right coordinate
HERE Android SDK Developer's Guide
API Reference
448
Returns:
True if setCoordinates complete successfully.
public boolean setTopLeft (GeoCoordinate topLeft)
Sets a top-left coordinate for the GeoBoundingBox.
Parameters:
topLeft
A GeoCoordinate representing the desired top-left coordinate
Returns:
True if setTopLeft complete successfully.
public String toString ()
For documentation, see java.lang.Object
GeoCoordinate
The class GeoCoordinate is a member of com.here.android.mpa.common .
Class Summary
public final class GeoCoordinate
extends java.lang.Object
Represents a WGS84 coordinate with double precision.
[For complete information, see the section Class Details]
Constructor Summary
Table 116: Constructors in GeoCoordinate
Constructors
GeoCoordinate (double latitude, double longitude)
Creates a GeoCoordinate with specified latitude and longitude values.
GeoCoordinate (double latitude, double longitude, double altitude)
Creates a GeoCoordinate with specified latitude, longitude and altitude values.
GeoCoordinate (GeoCoordinate coordinate)
Creates a copy of an existing GeoCoordinate object.
HERE Android SDK Developer's Guide
API Reference
449
Field Summary
Table 117: Fields in GeoCoordinate
Fields
public static final int UNKNOWN_ALTITUDE
Definition of an unknown altitude.
Method Summary
Table 118: Methods in GeoCoordinate
Methods
public double distanceTo (GeoCoordinate coord)
Calculates the distance (using the Haversine formula), as measured in meters, between this GeoCoordinate and the
specified GeoCoordinate .
public boolean equals (Object other)
For documentation, see java.lang.Object
public double getAltitude ()
Gets the current altitude, as measured in meters above sea level, of the GeoCoordinate (z-axis on a map).
public double getHeading (GeoCoordinate coord)
Returns heading from this point to the given coordinate in degrees.
public double getLatitude ()
Gets the current latitude, as measured in degrees, of the GeoCoordinate .
public double getLongitude ()
Gets the current longitude, as measured in degrees, of the GeoCoordinate .
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the GeoCoordinate object is valid.
public void setAltitude (double altitude)
Sets an altitude value, in meters above sea level, for the GeoCoordinate .
public void setLatitude (double latitude)
Sets a latitude value, in degrees, for the GeoCoordinate .
public void setLongitude (double longitude)
Sets a longitude value, in degrees, for the GeoCoordinate .
public String toString ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
450
Class Details
Represents a WGS84 coordinate with double precision. A GeoCoordinate encapsulates a latitude and
longitude value, plus an optional altitude value.
Constructor Details
GeoCoordinate (double latitude, double longitude)
Creates a GeoCoordinate with specified latitude and longitude values.
Parameters:
latitude
Initial latitude value, in degrees, between -90.0 and 90.0 inclusive. If a passed value is above the
maximum or below the minimum, it will be adjusted to the nearest acceptable value
longitude
Initial longitude value, in degrees, greater than or equal to -180.0 and less than 180.0. Any unsupported
value will be converted to its equivalent within the supported range (e.g. a value of -200.0 will be
corrected to 160.0 (-200.0 + 360.0))
See also:
GeoCoordinate(double, double, double)
GeoCoordinate (double latitude, double longitude, double altitude)
Creates a GeoCoordinate with specified latitude, longitude and altitude values.
Parameters:
latitude
Initial latitude value, in degrees, between -90.0 and 90.0 inclusive. If a passed value is above the
maximum or below the minimum, it will be adjusted to the nearest acceptable value
longitude
Initial longitude value, in degrees, greater than or equal to -180.0 and less than 180.0. Any unsupported
value will be converted to its equivalent within the supported range (e.g. a value of -200.0 will be
corrected to 160.0 (-200.0 + 360.0))
altitude
Initial altitude value, in meters, between -10000.0 and 10000.0 inclusive. If a passed value is above the
maximum or below the minimum, it will be adjusted to the nearest acceptable value
See also:
GeoCoordinate(double, double)
GeoCoordinate(GeoCoordinate)
GeoCoordinate (GeoCoordinate coordinate)
HERE Android SDK Developer's Guide
API Reference
451
Creates a copy of an existing GeoCoordinate object.
Parameters:
coordinate
A GeoCoordinate object used to initialize the new GeoCoordinate
See also:
GeoCoordinate(double, double, double)
GeoCoordinate(double, double)
Field Details
public static final int UNKNOWN_ALTITUDE
Definition of an unknown altitude.
Method Details
public double distanceTo (GeoCoordinate coord)
Calculates the distance (using the Haversine formula), as measured in meters, between this GeoCoordinate
and the specified GeoCoordinate .
Parameters:
coord
A second GeoCoordinate some distance away
Returns:
The distance between the coordinates
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public double getAltitude ()
Gets the current altitude, as measured in meters above sea level, of the GeoCoordinate (z-axis on a map).
Returns:
The current altitude (returns 0.0 if the altitude is unavailable)
HERE Android SDK Developer's Guide
API Reference
452
public double getHeading (GeoCoordinate coord)
Returns heading from this point to the given coordinate in degrees.
Parameters:
coord
A second GeoCoordinate to which the heading is calculated
Returns:
Heading from this coordinate to the given coordinate, in degrees, from north increasing clockwise.
public double getLatitude ()
Gets the current latitude, as measured in degrees, of the GeoCoordinate . Latitude represents the north-
south coordinate, or the y-axis on a map.
Returns:
The current latitude
public double getLongitude ()
Gets the current longitude, as measured in degrees, of the GeoCoordinate . Longitude represents the east-
west coordinate, or the x-axis on a map.
Returns:
The current longitude
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the GeoCoordinate object is valid. An invalid GeoCoordinate may be returned by
PositioningManager if there is no positive lock on a GPS position.
Returns:
True if the GeoCoordinate is valid, false otherwise
public void setAltitude (double altitude)
Sets an altitude value, in meters above sea level, for the GeoCoordinate .
Parameters:
altitude
HERE Android SDK Developer's Guide
API Reference
453
A double-precision altitude value, a range of between -10000.0 and 10000.0 inclusive. If an invalid value
is specified, it will be adjusted to the closest possible altitude value (For example, a specified value of
-10200.0 will be set to -10000.0)
public void setLatitude (double latitude)
Sets a latitude value, in degrees, for the GeoCoordinate .
Parameters:
latitude
A double-precision latitude value, a range between -90.0 and 90.0 inclusive. If an invalid value is
specified, it will be adjusted to the closest possible latitude value (For example, a specified value of -100
will be set to -90.0)
public void setLongitude (double longitude)
Sets a longitude value, in degrees, for the GeoCoordinate .
Parameters:
longitude
A double-precision longitude value, a range between -180.0 and less than 180.0 inclusive. If an invalid
value is specified, it will be adjusted to the closest possible longitude value (For example, a specified
value of -200.0 will be set to 160.0)
public String toString ()
For documentation, see java.lang.Object
GeoPolygon
The class GeoPolygon is a member of com.here.android.mpa.common .
Class Summary
public final class GeoPolygon
extends com.here.android.mpa.common.GeoPolyline, java.lang.Object
Represents a GeoPolygon a polygon object defined in terms of the geographic coordinates of its vertices.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
454
Constructor Summary
Table 119: Constructors in GeoPolygon
Constructors
GeoPolygon ()
Default Constructor
GeoPolygon (java.util.List <GeoCoordinate> points)
Constructor that creates a new instance of GeoPolygon from a list of points.
Method Summary
Table 120: Methods in GeoPolygon
Methods
public boolean equals (Object other)
Checks whether the given GeoPolygon object is equal to that supplied by the caller.
public int hashCode ()
Obtains the hash code for the given object.
Class Details
Represents a GeoPolygon a polygon object defined in terms of the geographic coordinates of its vertices.
The only difference between a GeoPolygon and a GeoPolyline is that the polygon represents a closed loop
of points. The minimum number of points in a GeoPolygon must be three.
This class can be used with MapPolygon to render a polygon.
Constructor Details
GeoPolygon ()
Default Constructor
GeoPolygon (java.util.List <GeoCoordinate> points)
Constructor that creates a new instance of GeoPolygon from a list of points.
Parameters:
points
A list of points to form the GeoPolygon.
See also:
MapPolygon
HERE Android SDK Developer's Guide
API Reference
455
Method Details
public boolean equals (Object other)
Checks whether the given GeoPolygon object is equal to that supplied by the caller. Two objects are equal if
they are both instances of GeoPolygon and the coordinates of their vertices are the same.
Parameters:
other
A polygon object to compare to the given polygon.
Returns:
true if the polygons are equal, otherwise false.
public int hashCode ()
Obtains the hash code for the given object.
Returns:
A value representing the hash code.
GeoPolyline
The class GeoPolyline is a member of com.here.android.mpa.common .
Class Summary
public class GeoPolyline
extends java.lang.Object
Interface representing a GeoPolyline .
[For complete information, see the section Class Details]
Constructor Summary
Table 121: Constructors in GeoPolyline
Constructors
GeoPolyline ()
Public Constructor
GeoPolyline (java.util.List <GeoCoordinate> points)
Creates a GeoPolyline from a list of points.
HERE Android SDK Developer's Guide
API Reference
456
Method Summary
Table 122: Methods in GeoPolyline
Methods
public void add (java.util.List <GeoCoordinate> points)
Adds a list of new points into the GeoPolyline .
public void add (GeoCoordinate point)
Adds a new point into the GeoPolyline .
public void clear ()
Removes all points from the GeoPolyline
public boolean contains (GeoCoordinate point)
Checks to see if a GeoCoordinate resides within this GeoPolyline .
public boolean equals (Object other)
For documentation, see java.lang.Object
public java.util.List <GeoCoordinate> getAllPoints ()
Gets all points in the GeoPolyline .
public GeoBoundingBox getBoundingBox ()
Gets the geographic bounding box that contains this GeoPolyline .
public GeoCoordinate getNearest (GeoCoordinate point)
Gets the GeoCoordinate along the path of the MapPolyline that is closest to the specified GeoCoordinate .
public int getNearestIndex (GeoCoordinate point)
Gets the index of the point that is closest to the specified GeoCoordinate .
public int getNumberOfPoints ()
Gets the total number of points currently in the GeoPolyline .
public GeoCoordinate getPoint (int index)
Gets a point in the GeoPolyline .
public int hashCode ()
For documentation, see java.lang.Object
public void insert (GeoCoordinate point, int index)
Inserts a point into the GeoPolyline at index .
public double length ()
The geographical length of this GeoPolyline .
public void remove (int index)
Removes a specific point from the GeoPolyline at the given index .
HERE Android SDK Developer's Guide
API Reference
457
Class Details
Interface representing a GeoPolyline . A GeoPolyline consists of 2 or more points. This class can be used
with MapPolyline to render a polyline.
Constructor Details
GeoPolyline ()
Public Constructor
GeoPolyline (java.util.List <GeoCoordinate> points)
Creates a GeoPolyline from a list of points.
Parameters:
points
A list of points to form the GeoPolyline
See also:
MapPolyline
Method Details
public void add (java.util.List <GeoCoordinate> points)
Adds a list of new points into the GeoPolyline .
Parameters:
points
A list of {code GeoCoordinate}s to be added
public void add (GeoCoordinate point)
Adds a new point into the GeoPolyline .
Parameters:
point
Point to be added
public void clear ()
Removes all points from the GeoPolyline
public boolean contains (GeoCoordinate point)
HERE Android SDK Developer's Guide
API Reference
458
Checks to see if a GeoCoordinate resides within this GeoPolyline .
Parameters:
point
The coordinate that will be used to match against the points in this GeoPolyline
Returns:
boolean true if the point is in this GeoPolyline
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public java.util.List <GeoCoordinate> getAllPoints ()
Gets all points in the GeoPolyline .
Returns:
A list of GeoCoordinate.
public GeoBoundingBox getBoundingBox ()
Gets the geographic bounding box that contains this GeoPolyline .
Returns:
GeoBoundingBox that contains this GeoPolyline. Can be null if the line has fewer than 2 points.
public GeoCoordinate getNearest (GeoCoordinate point)
Gets the GeoCoordinate along the path of the MapPolyline that is closest to the specified
GeoCoordinate .
Parameters:
point
A GeoCoordinate reference point for finding the nearest GeoCoordinate along the MapPolyline
path
Returns:
The GeoCoordinate along the MapPolyline path that is closest to the specified GeoCoordinate
See also:
getNearestIndex(GeoCoordinate)
HERE Android SDK Developer's Guide
API Reference
459
public int getNearestIndex (GeoCoordinate point)
Gets the index of the point that is closest to the specified GeoCoordinate .
Parameters:
point
A GeoCoordinate reference point for finding the nearest point's list index
Returns:
The list index of the point that is closest to the specified GeoCoordinate
See also:
getNearest(GeoCoordinate)
public int getNumberOfPoints ()
Gets the total number of points currently in the GeoPolyline .
Returns:
int total number of points
public GeoCoordinate getPoint (int index)
Gets a point in the GeoPolyline .
Parameters:
index
index of the point to get.
Returns:
GeoCoordinate. Returns null if the index is out of bound.
public int hashCode ()
For documentation, see java.lang.Object
public void insert (GeoCoordinate point, int index)
Inserts a point into the GeoPolyline at index .
Parameters:
point
Point to be added
index
Index to add the point into the list. index must be within the bounds of 0 and current count of points.
HERE Android SDK Developer's Guide
API Reference
460
public double length ()
The geographical length of this GeoPolyline .
Returns:
Length in meters.
public void remove (int index)
Removes a specific point from the GeoPolyline at the given index .
Parameters:
index
index of the point to be removed.
GeoPosition
The class GeoPosition is a member of com.here.android.mpa.common .
Class Summary
public class GeoPosition
extends java.lang.Object
Represents position, speed, and heading information as provided by a positioning device.
[For complete information, see the section Class Details]
Constructor Summary
Table 123: Constructors in GeoPosition
Constructors
GeoPosition (GeoCoordinate coordinate)
Public constructor
Field Summary
Table 124: Fields in GeoPosition
Fields
public static final int SOURCE_CACHE
GeoPosition is retuned from server cache.
HERE Android SDK Developer's Guide
API Reference
461
Fields
public static final int SOURCE_FUSION
GeoPosition is retuned as filtered from several sources.
public static final int SOURCE_HARDWARE
GeoPosition is retuned from hardware.
public static final int SOURCE_INDOOR
GeoPosition is retuned from indoor radio maps.
public static final int SOURCE_NONE
Source is unknown or not available.
public static final int SOURCE_OFFLINE
GeoPosition is retuned from radio maps.
public static final int SOURCE_ONLINE
GeoPosition is retuned from server.
public static final int TECHNOLOGY_BLE
GeoPosition is calculated using Bluetooth LE measurements.
public static final int TECHNOLOGY_CELL
GeoPosition is calculated using Cell measurements.
public static final int TECHNOLOGY_GNSS
GeoPosition is calculated by GNSS chip.
public static final int TECHNOLOGY_NONE
Technology is unknown or not available.
public static final int TECHNOLOGY_WIFI
GeoPosition is calculated using Wi-Fi measurements.
public static final int UNKNOWN
Definition of an unknown accuracy, course (heading/bearing) or speed
Method Summary
Table 125: Methods in GeoPosition
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public float getAltitudeAccuracy ()
Gets the current altitude accuracy as measured by the enabled positioning device.
public String getBuildingId ()
Get building ID of this position estimate, if known.
HERE Android SDK Developer's Guide
API Reference
462
Methods
public String getBuildingName ()
Get building name in human readable format, e.g.
public GeoCoordinate getCoordinate ()
Gets the current GeoCoordinate as measured by the enabled positioning device.
public Integer getFloorId ()
FloorId is identifying the floor level in the building.
public double getHeading ()
Gets the current course heading as measured by the enabled positioning device.
public float getLatitudeAccuracy ()
Gets the current latitude accuracy as measured by the enabled positioning device.
public float getLongitudeAccuracy ()
Gets the current longitude accuracy as measured by the enabled positioning device.
public int getPositionSource ()
Returns bitmask of sources for this GeoPosition update.
public int getPositionTechnology ()
Returns bitmask of technologies for this GeoPosition update.
public double getSpeed ()
Gets the current speed as measured by the enabled positioning device.
public Date getTimestamp ()
Gets the timestamp for the last position measured by the enabled positioning device.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the GeoPosition object is valid.
Class Details
Represents position, speed, and heading information as provided by a positioning device.
Constructor Details
GeoPosition (GeoCoordinate coordinate)
Public constructor
Parameters:
coordinate
A GeoCoordinate to be used by this object.
HERE Android SDK Developer's Guide
API Reference
463
Field Details
public static final int SOURCE_CACHE
GeoPosition is retuned from server cache.
public static final int SOURCE_FUSION
GeoPosition is retuned as filtered from several sources.
public static final int SOURCE_HARDWARE
GeoPosition is retuned from hardware.
public static final int SOURCE_INDOOR
GeoPosition is retuned from indoor radio maps.
public static final int SOURCE_NONE
Source is unknown or not available.
public static final int SOURCE_OFFLINE
GeoPosition is retuned from radio maps.
public static final int SOURCE_ONLINE
GeoPosition is retuned from server.
public static final int TECHNOLOGY_BLE
GeoPosition is calculated using Bluetooth LE measurements.
public static final int TECHNOLOGY_CELL
GeoPosition is calculated using Cell measurements.
public static final int TECHNOLOGY_GNSS
GeoPosition is calculated by GNSS chip.
public static final int TECHNOLOGY_NONE
HERE Android SDK Developer's Guide
API Reference
464
Technology is unknown or not available.
public static final int TECHNOLOGY_WIFI
GeoPosition is calculated using Wi-Fi measurements.
public static final int UNKNOWN
Definition of an unknown accuracy, course (heading/bearing) or speed
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public float getAltitudeAccuracy ()
Gets the current altitude accuracy as measured by the enabled positioning device.
Returns:
The current altitude accuracy or GeoPosition.UNKNOWN if unknown.
public String getBuildingId ()
Get building ID of this position estimate, if known.
Returns:
Building ID as String or null if building is not set.
public String getBuildingName ()
Get building name in human readable format, e.g. "London Heathrow Airport". There can be different
buildings with the same name.
Returns:
Building name or null if building name is not set.
public GeoCoordinate getCoordinate ()
Gets the current GeoCoordinate as measured by the enabled positioning device.
HERE Android SDK Developer's Guide
API Reference
465
Returns:
The current GeoCoordinate
public Integer getFloorId ()
FloorId is identifying the floor level in the building. Floor id 0 specifies the floor that is considered the Main
Level of the building. In the case building has multiple levels that can be considered as Main Level, the
lowest level which can be considered as Main Level, will be chosen. Floors below the chosen Main Level will
have negative integers and floors above the chosen Main Level will have positive integers: The floor above
the Main Level has floor id 1 and the floor below the Main Level has floor id -1.
Returns:
Floor ID or null if floor ID is not set.
public double getHeading ()
Gets the current course heading as measured by the enabled positioning device.
Returns:
The current course heading or GeoPosition.UNKNOWN if unknown.
public float getLatitudeAccuracy ()
Gets the current latitude accuracy as measured by the enabled positioning device.
Returns:
The current latitude accuracy or GeoPosition.UNKNOWN if unknown.
public float getLongitudeAccuracy ()
Gets the current longitude accuracy as measured by the enabled positioning device.
Returns:
The current longitude accuracy or GeoPosition.UNKNOWN if unknown.
public int getPositionSource ()
Returns bitmask of sources for this GeoPosition update.
Returns:
Bitmask of sources for this GeoPosition update.
See also:
SOURCE_ONLINE
SOURCE_OFFLINE
HERE Android SDK Developer's Guide
API Reference
466
SOURCE_CACHE
SOURCE_INDOOR
SOURCE_HARDWARE
SOURCE_FUSION
public int getPositionTechnology ()
Returns bitmask of technologies for this GeoPosition update.
Returns:
Bitmask of technologies for this GeoPosition update.
See also:
TECHNOLOGY_WIFI
TECHNOLOGY_CELL
TECHNOLOGY_BLE
TECHNOLOGY_GNSS
public double getSpeed ()
Gets the current speed as measured by the enabled positioning device.
Returns:
The current speed or GeoPosition.UNKNOWN if unknown.
public Date getTimestamp ()
Gets the timestamp for the last position measured by the enabled positioning device.
Returns:
The timestamp
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the GeoPosition object is valid. A GeoPosition is valid if its associated
GeoCoordinate is valid.
Returns:
True if the GeoPosition is valid, false otherwise
HERE Android SDK Developer's Guide
API Reference
467
IconCategory
The enumeration IconCategory is a member of com.here.android.mpa.common .
Enumeration Summary
public final enumeration IconCategory
extends java.lang.Enum, java.lang.Object
Represents all the possible categories for an icon.
[For complete information, see the section Enumeration Details]
See also:
setCategory(IconCategory)
Enum Constant Summary
Table 126: Enum Constants in IconCategory
Fields
public static final IconCategory AIRLINE_ACCESS
public static final IconCategory AMUSEMENT_PARK
public static final IconCategory CAR_DEALER
public static final IconCategory CASINO
public static final IconCategory CINEMA
public static final IconCategory COMPANY
public static final IconCategory CONCERT_HALL
public static final IconCategory CONGRESS
public static final IconCategory COURTHOUSE
public static final IconCategory CULTURAL_CENTRE
public static final IconCategory EXHIBITION_CENTRE
public static final IconCategory GOLF_COURSE
public static final IconCategory GOVERNMENT_OFFICE
public static final IconCategory HOLIDAY_PARK
public static final IconCategory MUSEUM
public static final IconCategory OPERA
public static final IconCategory PARKING_GARAGE
HERE Android SDK Developer's Guide
API Reference
468
Fields
public static final IconCategory PETROL_STATION
public static final IconCategory PLACE_OF_WORSHIP
public static final IconCategory POST_OFFICE
public static final IconCategory RENT_A_CAR_FACILITY
public static final IconCategory REST_AREA
public static final IconCategory RESTAURANT
public static final IconCategory SHOP
public static final IconCategory SHOPPING_CENTRE
public static final IconCategory STADIUM
public static final IconCategory THEATRE
public static final IconCategory TOURIST_ATTRACTION
public static final IconCategory TOURIST_INFORMATION_CENTRE
public static final IconCategory UNIVERSITY
public static final IconCategory ZOO
public static final IconCategory LIBRARY
public static final IconCategory CAMPING
public static final IconCategory BAR_DISCO
public static final IconCategory EMBASSY
public static final IconCategory FERRY_TERMINAL
public static final IconCategory FRONTIER_CROSSING
public static final IconCategory HOSPITAL
public static final IconCategory HOTEL
public static final IconCategory PARKING_AREA
public static final IconCategory POLICE
public static final IconCategory RAILWAY_STATION
public static final IconCategory METRO_STATION
public static final IconCategory AIRPORT
public static final IconCategory MOUNTAIN_PASS
public static final IconCategory MOUNTAIN_PEAK
public static final IconCategory CAR_REPAIR
public static final IconCategory CASH_DISPENSER
HERE Android SDK Developer's Guide
API Reference
469
Fields
public static final IconCategory PARK_RECREATION
public static final IconCategory PHARMACY
public static final IconCategory BEACH
public static final IconCategory BUS_STATION
public static final IconCategory EDUCATION
public static final IconCategory RESIDENTIAL_AREA
public static final IconCategory NIGHT_CLUB
public static final IconCategory PUBLIC_TOILET
public static final IconCategory LAUNDRY
public static final IconCategory TAXI_STAND
public static final IconCategory RAILWAY_ACCESS
public static final IconCategory BARS_CAFES
public static final IconCategory PARKING
public static final IconCategory SPORT_OUTDOOR
public static final IconCategory METRO_ACCESS
public static final IconCategory AUT_METRO_ACCESS
public static final IconCategory AUT_METRO_STOP
public static final IconCategory BEL_METRO_ACCESS
public static final IconCategory BEL_METRO_STOP
public static final IconCategory CZE_METRO_ACCESS
public static final IconCategory CZE_METRO_STOP
public static final IconCategory DEN_METRO_ACCESS
public static final IconCategory DEN_METRO_STOP
public static final IconCategory FIN_METRO_ACCESS
public static final IconCategory FIN_METRO_STOP
public static final IconCategory FRA_METRO_ACCESS
public static final IconCategory FRA_METRO_STOP
public static final IconCategory FRA_RER_ACCESS
public static final IconCategory FRA_RER_STOP
public static final IconCategory DEU_METRO_ACCESS
public static final IconCategory DEU_METRO_STOP
HERE Android SDK Developer's Guide
API Reference
470
Fields
public static final IconCategory DEU_SBAHN_ACCESS
public static final IconCategory DEU_SBAHN_STOP
public static final IconCategory ITA_METRO_ACCESS
public static final IconCategory ITA_METRO_STOP
public static final IconCategory NOR_METRO_ACCESS
public static final IconCategory NOR_METRO_STOP
public static final IconCategory PRT_METRO_ACCESS
public static final IconCategory PRT_METRO_STOP
public static final IconCategory ESP_BARCELONA_METRO_ACCESS
public static final IconCategory ESP_BARCELONA_METRO_STOP
public static final IconCategory ESP_CERCANIAS_METRO_ACCESS
public static final IconCategory ESP_CERCANIAS_METRO_STOP
public static final IconCategory ESP_MADRID_METRO_ACCESS
public static final IconCategory ESP_MADRID_METRO_STOP
public static final IconCategory SWE_METRO_ACCESS
public static final IconCategory SWE_METRO_STOP
public static final IconCategory GBR_GLASGOW_METRO_ACCESS
public static final IconCategory GBR_GLASGOW_METRO_STOP
public static final IconCategory GBR_LONDON_METRO_ACCESS
public static final IconCategory GBR_LONDON_METRO_STOP
public static final IconCategory ALL
Method Summary
Table 127: Methods in IconCategory
Methods
public static IconCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static IconCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents all the possible categories for an icon.
HERE Android SDK Developer's Guide
API Reference
471
See also:
setCategory(IconCategory)
Enum Constant Details
public static final IconCategory AIRLINE_ACCESS
public static final IconCategory AMUSEMENT_PARK
public static final IconCategory CAR_DEALER
public static final IconCategory CASINO
public static final IconCategory CINEMA
public static final IconCategory COMPANY
public static final IconCategory CONCERT_HALL
public static final IconCategory CONGRESS
public static final IconCategory COURTHOUSE
public static final IconCategory CULTURAL_CENTRE
public static final IconCategory EXHIBITION_CENTRE
public static final IconCategory GOLF_COURSE
public static final IconCategory GOVERNMENT_OFFICE
public static final IconCategory HOLIDAY_PARK
HERE Android SDK Developer's Guide
API Reference
472
public static final IconCategory MUSEUM
public static final IconCategory OPERA
public static final IconCategory PARKING_GARAGE
public static final IconCategory PETROL_STATION
public static final IconCategory PLACE_OF_WORSHIP
public static final IconCategory POST_OFFICE
public static final IconCategory RENT_A_CAR_FACILITY
public static final IconCategory REST_AREA
public static final IconCategory RESTAURANT
public static final IconCategory SHOP
public static final IconCategory SHOPPING_CENTRE
public static final IconCategory STADIUM
public static final IconCategory THEATRE
public static final IconCategory TOURIST_ATTRACTION
public static final IconCategory TOURIST_INFORMATION_CENTRE
public static final IconCategory UNIVERSITY
HERE Android SDK Developer's Guide
API Reference
473
public static final IconCategory ZOO
public static final IconCategory LIBRARY
public static final IconCategory CAMPING
public static final IconCategory BAR_DISCO
public static final IconCategory EMBASSY
public static final IconCategory FERRY_TERMINAL
public static final IconCategory FRONTIER_CROSSING
public static final IconCategory HOSPITAL
public static final IconCategory HOTEL
public static final IconCategory PARKING_AREA
public static final IconCategory POLICE
public static final IconCategory RAILWAY_STATION
public static final IconCategory METRO_STATION
public static final IconCategory AIRPORT
public static final IconCategory MOUNTAIN_PASS
HERE Android SDK Developer's Guide
API Reference
474
public static final IconCategory MOUNTAIN_PEAK
public static final IconCategory CAR_REPAIR
public static final IconCategory CASH_DISPENSER
public static final IconCategory PARK_RECREATION
public static final IconCategory PHARMACY
public static final IconCategory BEACH
public static final IconCategory BUS_STATION
public static final IconCategory EDUCATION
public static final IconCategory RESIDENTIAL_AREA
public static final IconCategory NIGHT_CLUB
public static final IconCategory PUBLIC_TOILET
public static final IconCategory LAUNDRY
public static final IconCategory TAXI_STAND
public static final IconCategory RAILWAY_ACCESS
public static final IconCategory BARS_CAFES
public static final IconCategory PARKING
HERE Android SDK Developer's Guide
API Reference
475
public static final IconCategory SPORT_OUTDOOR
public static final IconCategory METRO_ACCESS
public static final IconCategory AUT_METRO_ACCESS
public static final IconCategory AUT_METRO_STOP
public static final IconCategory BEL_METRO_ACCESS
public static final IconCategory BEL_METRO_STOP
public static final IconCategory CZE_METRO_ACCESS
public static final IconCategory CZE_METRO_STOP
public static final IconCategory DEN_METRO_ACCESS
public static final IconCategory DEN_METRO_STOP
public static final IconCategory FIN_METRO_ACCESS
public static final IconCategory FIN_METRO_STOP
public static final IconCategory FRA_METRO_ACCESS
public static final IconCategory FRA_METRO_STOP
public static final IconCategory FRA_RER_ACCESS
HERE Android SDK Developer's Guide
API Reference
476
public static final IconCategory FRA_RER_STOP
public static final IconCategory DEU_METRO_ACCESS
public static final IconCategory DEU_METRO_STOP
public static final IconCategory DEU_SBAHN_ACCESS
public static final IconCategory DEU_SBAHN_STOP
public static final IconCategory ITA_METRO_ACCESS
public static final IconCategory ITA_METRO_STOP
public static final IconCategory NOR_METRO_ACCESS
public static final IconCategory NOR_METRO_STOP
public static final IconCategory PRT_METRO_ACCESS
public static final IconCategory PRT_METRO_STOP
public static final IconCategory ESP_BARCELONA_METRO_ACCESS
public static final IconCategory ESP_BARCELONA_METRO_STOP
public static final IconCategory ESP_CERCANIAS_METRO_ACCESS
public static final IconCategory ESP_CERCANIAS_METRO_STOP
public static final IconCategory ESP_MADRID_METRO_ACCESS
HERE Android SDK Developer's Guide
API Reference
477
public static final IconCategory ESP_MADRID_METRO_STOP
public static final IconCategory SWE_METRO_ACCESS
public static final IconCategory SWE_METRO_STOP
public static final IconCategory GBR_GLASGOW_METRO_ACCESS
public static final IconCategory GBR_GLASGOW_METRO_STOP
public static final IconCategory GBR_LONDON_METRO_ACCESS
public static final IconCategory GBR_LONDON_METRO_STOP
public static final IconCategory ALL
Method Details
public static IconCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static IconCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Identifier
The class Identifier is a member of com.here.android.mpa.common .
HERE Android SDK Developer's Guide
API Reference
478
Class Summary
public final class Identifier
implements android.os.Parcelable
extends java.lang.Object
Represents a 64-bit or 128-bit numeric identifier of an instance of ViewObject .
[For complete information, see the section Class Details]
Field Summary
Table 128: Fields in Identifier
Fields
public static final android.os.Parcelable.Creator <Identifier> CREATOR
Method Summary
Table 129: Methods in Identifier
Methods
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public boolean equals (Object other)
For documentation, see java.lang.Object
public int hashCode ()
Obtains the hash code for the given object.
public String toString ()
Returns a string representing an Identifier in the form of a 64-bit or 128-bit number.
public void writeToParcel (Parcel dest, int flags)
For documentation, see android.os.Parcelable.writeToParcel()
Class Details
Represents a 64-bit or 128-bit numeric identifier of an instance of ViewObject . The identifiers are used by:
TransitDatabase
MapTransitLayer
MapBuildingLayer
MapBuildingGroup
TransitLineObject
TransitLineInfo
TransitAccessInfo
TransitStopInfo
HERE Android SDK Developer's Guide
API Reference
479
Field Details
public static final android.os.Parcelable.Creator <Identifier> CREATOR
Method Details
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public int hashCode ()
Obtains the hash code for the given object.
Returns:
A value representing the hash code.
public String toString ()
Returns a string representing an Identifier in the form of a 64-bit or 128-bit number.
Returns:
A string representation of the Identifier.
public void writeToParcel (Parcel dest, int flags)
For documentation, see android.os.Parcelable.writeToParcel()
Parameters:
dest
flags
Image
The class Image is a member of com.here.android.mpa.common .
HERE Android SDK Developer's Guide
API Reference
480
Class Summary
public final class Image
extends java.lang.Object
Encapsulates an image file.
[For complete information, see the section Class Details]
Nested Class Summary
Table 130: Nested Classes in Image
Nested Classes
public static final enumeration Image.Type
This helps the application know the base type of the Image .
Constructor Summary
Table 131: Constructors in Image
Constructors
Image ()
Public Constructor
Method Summary
Table 132: Methods in Image
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public Bitmap getBitmap (int width, int height)
Creates a new Bitmap object with the given dimension from this Image .
public Bitmap getBitmap ()
Creates an android.graphics.Bitmap from this Image if the type is BITMAP, null otherwise.
public long getHeight ()
Gets the current height of the Image , in pixels.
public Type getType ()
Gets the file type of this Image.
public long getWidth ()
Gets the current width of the Image , in pixels.
HERE Android SDK Developer's Guide
API Reference
481
Methods
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the Image object contains a valid image.
public boolean setBitmap (Bitmap bitmap)
Sets a Bitmap for the Image .
public void setCategory (IconCategory category)
Sets IconCategory for the Image .
public void setImageAsset (String assetName)
Sets Image data by an image in the assets directory.
public void setImageData (byte[] bytes)
Sets an array of byte data for the Image .
public void setImageFile (String fileName)
Sets Image data by an image file located in the internal storage.
public void setImageResource (int id)
Sets data for the Image by way of an application's resource.
public void setLocalUrl (String localUrl)
Sets a local URL that the Image can access for an image.
Class Details
Encapsulates an image file.
An Image object can only be created with BMP, JPEG, and PNG data formats. However, although these 3 data
formats are supported, only basic parsing of a BMP header is done (gamma correction and color profile
information are ignored), and supported BMP data formats are limited to:
BMP v3 (standard BMP) with 24/32 bits per pixel without compression
BMP v4/v5 (newer BMP formats) with 24/32 bits per pixel, bit fields compression and A8R8G8B8 pixel
format
Constructor Details
Image ()
Public Constructor
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
482
Parameters:
other
public Bitmap getBitmap (int width, int height)
Creates a new Bitmap object with the given dimension from this Image . This method only supports Image s
of SVG. null is returned for Image s not of the supported type(s).
Parameters:
width
The width (in pixels) of the new Bitmap to be created.
height
The height (in pixels) of the new Bitmap to be created.
Returns:
A new Bitmap object of the Image.
public Bitmap getBitmap ()
Creates an android.graphics.Bitmap from this Image if the type is BITMAP, null otherwise.
Returns:
An android.graphics.Bitmap or null if this Image is not BITMAP.
public long getHeight ()
Gets the current height of the Image , in pixels.
Returns:
The current height
public Type getType ()
Gets the file type of this Image.
Returns:
The Image.Type for this Image object.
public long getWidth ()
Gets the current width of the Image , in pixels.
Returns:
The current width
HERE Android SDK Developer's Guide
API Reference
483
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
Determines whether the Image object contains a valid image.
Returns:
True if the Image object is valid and can render an image, false otherwise
public boolean setBitmap (Bitmap bitmap)
Sets a Bitmap for the Image .
Parameters:
bitmap
A Bitmap to be used by the Image
Returns:
True if the Bitmap is set successfully, false otherwise
public void setCategory (IconCategory category)
Sets IconCategory for the Image .
Parameters:
category
An category (such as "museum") for the icon image.
public void setImageAsset (String assetName)
Sets Image data by an image in the assets directory. In particular, this calls openFileInput(String).
SVG format files are not supported.
Parameters:
assetName
The name of an image in the assets directory.
Throws:
IOException
throws exception when failure to read the resource
HERE Android SDK Developer's Guide
API Reference
484
public void setImageData (byte[] bytes)
Sets an array of byte data for the Image .
Only JPEG, BMP and PNG formats are supported.
Parameters:
bytes
An array of byte data containing the Image
public void setImageFile (String fileName)
Sets Image data by an image file located in the internal storage. In particular, this calls openFileInput(String).
SVG format files are not supported.
Parameters:
fileName
The name of the image file.
Throws:
IOException
throws exception when failure to read the resource
public void setImageResource (int id)
Sets data for the Image by way of an application's resource.
Parameters:
id
An ID for the resource
Throws:
IOException
Upon a failure to read the resource
public void setLocalUrl (String localUrl)
Sets a local URL that the Image can access for an image.
SVG format files are not supported.
Parameters:
localUrl
The local URL that the Image uses
HERE Android SDK Developer's Guide
API Reference
485
Type
The enumeration Type is a member of com.here.android.mpa.common.Image.
Enumeration Summary
public static final enumeration Image.Type
extends java.lang.Enum, java.lang.Object
This helps the application know the base type of the Image .
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 133: Enum Constants in Type
Fields
public static final Type UNKNOWN
Unknown image type.
public static final Type BITMAP
Bitmap image type.
public static final Type JPEG
JPEG image type.
public static final Type PNG
PNG image type.
public static final Type SVG
SVG image type.
Method Summary
Table 134: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Image.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This helps the application know the base type of the Image .
HERE Android SDK Developer's Guide
API Reference
486
Enum Constant Details
public static final Type UNKNOWN
Unknown image type.
public static final Type BITMAP
Bitmap image type.
public static final Type JPEG
JPEG image type.
public static final Type PNG
PNG image type.
public static final Type SVG
SVG image type. Creation of SVG Image s are not supported. Only used as return Image s.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Image.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
LocationDataSource
The class LocationDataSource is a member of com.here.android.mpa.common .
Class Summary
public abstract class LocationDataSource
HERE Android SDK Developer's Guide
API Reference
487
extends java.lang.Object
Abstract class that defines the interface for providing positions updates from a location data source (e.g.
[For complete information, see the section Class Details]
Constructor Summary
Table 135: Constructors in LocationDataSource
Constructors
LocationDataSource ()
Creates a LocationDataSource instance
Method Summary
Table 136: Methods in LocationDataSource
Methods
public abstract int getGpsStatus ()
Called by PositioningManager to get the current GPS location status.
public abstract int getIndoorStatus ()
Called by PositioningManager to get the current LocationMethod::INDOOR location status.
public abstract Location getLastKnownLocation ()
Called by PositioningManager to get the last known location.
public abstract int getNetworkStatus ()
Called by PositioningManager to get the current LocationMethod::NETWORK location status.
protected void onLocationUpdated (LocationMethod method, Location location)
Must be called by the derived class whenever the last known location is updated or the position fix has been lost.
protected void onStatusUpdated (LocationMethod method, int status)
Must be called by the derived class whenever the location status has been updated
public abstract boolean start (LocationMethod method)
Called by PositioningManager to start location updates using the specified location method.
public abstract void stop ()
Called by PositioningManager to stop location updates.
Class Details
Abstract class that defines the interface for providing positions updates from a location data source (e.g. an
external GPS unit). Location data sources should provide a concrete implementation of this class and pass it
to PositioningManager.start(LocationMethod).
HERE Android SDK Developer's Guide
API Reference
488
Constructor Details
LocationDataSource ()
Creates a LocationDataSource instance
Method Details
public abstract int getGpsStatus ()
Called by PositioningManager to get the current GPS location status.
Returns:
GPS location status. Return OUT_OF_SERVICE if LocationMethod::GPS is not supported for this location
data source.
See also:
android.location.LocationProvider
public abstract int getIndoorStatus ()
Called by PositioningManager to get the current LocationMethod::INDOOR location status.
Returns:
Indoor location status. Return OUT_OF_SERVICE if LocationMethod::INDOOR is not supported for this
location data source.
See also:
android.location.LocationProvider
public abstract Location getLastKnownLocation ()
Called by PositioningManager to get the last known location. Implement this to return the last known
location using the "best" location method available for this location source. No guarantee regarding the
freshness of the returned location is required.
Returns:
Last known location using best location method available. Return null if no location is available or if the
position is lost.
public abstract int getNetworkStatus ()
Called by PositioningManager to get the current LocationMethod::NETWORK location status.
HERE Android SDK Developer's Guide
API Reference
489
Returns:
Network location status. Return OUT_OF_SERVICE if LocationMethod::NETWORK is not supported for this
location data source.
See also:
android.location.LocationProvider
protected void onLocationUpdated (LocationMethod method, Location location)
Must be called by the derived class whenever the last known location is updated or the position fix has been
lost.
Parameters:
method
Location method providing the update.
location
Current location or null if the position has been lost.
protected void onStatusUpdated (LocationMethod method, int status)
Must be called by the derived class whenever the location status has been updated
Parameters:
method
Location method that has an updated status.
status
Updated status.
See also:
android.location.LocationProvider
public abstract boolean start (LocationMethod method)
Called by PositioningManager to start location updates using the specified location method.
Parameters:
method
Location method(s) being requested. If the method requested is a combination of different methods (e.g.
GPS_NETWORK_INDOOR) then only start position updates and return true if at least one of the methods
(e.g. GPS) is available.
Returns:
True if location updates have been started using any of the methods requested. False otherwise.
HERE Android SDK Developer's Guide
API Reference
490
public abstract void stop ()
Called by PositioningManager to stop location updates.
LocationDataSourceAutomotive
The class LocationDataSourceAutomotive is a member of com.here.android.mpa.common .
Class Summary
public abstract class LocationDataSourceAutomotive
extends com.here.android.mpa.common.LocationDataSource, java.lang.Object
Abstract class that defines the interface for providing positions updates from an automotive location data
source (e.g.
[For complete information, see the section Class Details]
Constructor Summary
Table 137: Constructors in LocationDataSourceAutomotive
Constructors
LocationDataSourceAutomotive ()
Method Summary
Table 138: Methods in LocationDataSourceAutomotive
Methods
public float getCourseStandardDeviation ()
Called by PositioningManager to get Standard deviation of the course in degrees.
public float getElevationStandardDeviationn ()
Called by PositioningManager to get Standard deviation of the elevation in meters.
public float getHorizontalLargeStandardDeviation ()
Called by PositioningManager to get Horizontal radial error (large component) as a standard deviation in meters.
public float getHorizontalSmallStandardDeviation ()
Called by PositioningManager to get Horizontal radial error (small component) as a standard deviation in meters.
public float getSpeedStandardDeviation ()
Called by PositioningManager to get Standard deviation of the speed in meters per second.
HERE Android SDK Developer's Guide
API Reference
491
Class Details
Abstract class that defines the interface for providing positions updates from an automotive location
data source (e.g. an external GPS or Dead Reckoning (DR) units). IMPORTANT: This is a Beta API, and is
subject to change without notice. Location data sources should provide a concrete implementation of
this class and pass it to setDataSource(LocationDataSource) Setting a source derived from this class will
force PositioningManager to use a map matching algorithm designed for automotive use cases which
expects a constant stream of position and sensor data from a DR unit at a frequency of 10Hz. The automotive
map matcher algorithm does not support any form of extrapolation so if a constant stream of position
and sensor data is not provided in tunnels or areas of traditionally poor GPS coverage the map matching
performance will be poor. Please note that pedestrian navigation is not supported when automotive location
data source is used. \note Attempts to call setDataSource(LocationDataSource) with an object derived from
LocationDataSourceAutomotive will be ignored and return false if access to this operation is denied. Contact
your HERE representative for more information.
Constructor Details
LocationDataSourceAutomotive ()
Method Details
public float getCourseStandardDeviation ()
Called by PositioningManager to get Standard deviation of the course in degrees. Implement this to
return the Standard deviation of the course in degrees. No guarantee regarding the freshness of the returned
location is required.
Returns:
Standard deviation of the course in degrees.
public float getElevationStandardDeviationn ()
Called by PositioningManager to get Standard deviation of the elevation in meters. Implement this
to return the Standard deviation of the elevation in meters. No guarantee regarding the freshness of the
returned location is required.
Returns:
Standard deviation of the elevation in meters.
public float getHorizontalLargeStandardDeviation ()
Called by PositioningManager to get Horizontal radial error (large component) as a standard deviation
in meters. Implement this to return the Horizontal radial error. No guarantee regarding the freshness of the
returned location is required.
Returns:
HERE Android SDK Developer's Guide
API Reference
492
Horizontal radial error (large component) as a standard deviation in meters.
public float getHorizontalSmallStandardDeviation ()
Called by PositioningManager to get Horizontal radial error (small component) as a standard deviation
in meters. Implement this to return the Horizontal radial error. No guarantee regarding the freshness of the
returned location is required.
Returns:
Horizontal radial error (small component) as a standard deviation in meters.
public float getSpeedStandardDeviation ()
Called by PositioningManager to get Standard deviation of the speed in meters per second. Implement
this to return the Standard deviation of the speed in meters per second. No guarantee regarding the
freshness of the returned location is required.
Returns:
Standard deviation of the speed meters per second.
LocationDataSourceDevice
The class LocationDataSourceDevice is a member of com.here.android.mpa.common .
Class Summary
public abstract class LocationDataSourceDevice
extends com.here.android.mpa.common.LocationDataSource, java.lang.Object
Abstract class that defines the interface for providing positions updates from a platform location data
source.
[For complete information, see the section Class Details]
Constructor Summary
Table 139: Constructors in LocationDataSourceDevice
Constructors
LocationDataSourceDevice ()
HERE Android SDK Developer's Guide
API Reference
493
Method Summary
Table 140: Methods in LocationDataSourceDevice
Methods
public static LocationDataSourceDevice getInstance ()
Get access to the LocationDataSourceDevice Singleton.
Class Details
Abstract class that defines the interface for providing positions updates from a platform location data
source. Instance of this class can be created with getInstance() call.
Constructor Details
LocationDataSourceDevice ()
Method Details
public static LocationDataSourceDevice getInstance ()
Get access to the LocationDataSourceDevice Singleton. MapsEngine has to be successfully initialized before
the call.
Returns:
LocationDataSourceDevice instance
LocationDataSourceHERE
The class LocationDataSourceHERE is a member of com.here.android.mpa.common .
Class Summary
public abstract class LocationDataSourceHERE
extends com.here.android.mpa.common.LocationDataSource, java.lang.Object
Abstract class that defines the interface for providing positions updates from a HERE hybrid location data
source.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
494
Nested Class Summary
Table 141: Nested Classes in LocationDataSourceHERE
Nested Classes
public static final enumeration LocationDataSourceHERE.IndoorPositioningMode
Defines supported indoor positioning modes.
public static final enumeration LocationDataSourceHERE.IndoorPositioningModeSetResult
Defines result codes for indoor positioning mode set call.
Constructor Summary
Table 142: Constructors in LocationDataSourceHERE
Constructors
LocationDataSourceHERE ()
Method Summary
Table 143: Methods in LocationDataSourceHERE
Methods
public abstract IndoorPositioningMode getIndoorPositioningMode ()
Get active indoor positioning mode.
public static LocationDataSourceHERE getInstance ()
Get access to the LocationDataSourceHERE Singleton.
public static LocationDataSourceHERE getInstance (StatusListener statusListener)
Get access to the LocationDataSourceHERE Singleton.
public abstract RadioMapLoader getRadioMapLoader ()
Get instance of positioning radio map loader.
public abstract void setDiagnosticsListener (DiagnosticsListener listener)
Register HERE positioning diagnostics listener instance for receiving positioning related events.
public abstract IndoorPositioningModeSetResult setIndoorPositioningMode (IndoorPositioningMode mode)
Set indoor positioning mode.
Class Details
Abstract class that defines the interface for providing positions updates from a HERE hybrid location data
source. Instance of this class can be created with getInstance(StatusListener) call.
Constructor Details
LocationDataSourceHERE ()
HERE Android SDK Developer's Guide
API Reference
495
Method Details
public abstract IndoorPositioningMode getIndoorPositioningMode ()
Get active indoor positioning mode.
Returns:
Current indoor positioning mode.
See also:
LocationDataSourceHERE.IndoorPositioningMode
public static LocationDataSourceHERE getInstance ()
Get access to the LocationDataSourceHERE Singleton. MapsEngine has to be successfully initialized before
the call.
Returns:
LocationDataSourceHERE instance
Throws:
AccessControlException
if HERE positioning is not licensed.
public static LocationDataSourceHERE getInstance (StatusListener
statusListener)
Get access to the LocationDataSourceHERE Singleton. MapsEngine has to be successfully initialized before
the call.
Parameters:
statusListener
Status listener instance for retrieving HERE positioning related events.
Returns:
LocationDataSourceHERE instance
Throws:
AccessControlException
if HERE positioning has not been licensed.
public abstract RadioMapLoader getRadioMapLoader ()
HERE Android SDK Developer's Guide
API Reference
496
Get instance of positioning radio map loader. Radio map loader can be used for downloading positioning
radio maps for specified areas.
Returns:
Radio map loader instance.
Throws:
AccessControlException
if positioning radio map downloading API has not been licensed.
public abstract void setDiagnosticsListener (DiagnosticsListener listener)
Register HERE positioning diagnostics listener instance for receiving positioning related events. Only one
listener can be registered at a time. To unregister the existing listener, set listener to null .
Parameters:
listener
The Diagnostics listener instance for which HERE positioning related events should be delivered or null if
you are no longer interested in diagnostic events.
public abstract IndoorPositioningModeSetResult setIndoorPositioningMode
(IndoorPositioningMode mode)
Set indoor positioning mode. Mode defines which radio maps HERE positioning is allowed to use.
Parameters:
mode
New indoor positioning mode.
Returns:
Result for the mode change.
See also:
LocationDataSourceHERE.IndoorPositioningMode
IndoorPositioningMode
The enumeration IndoorPositioningMode is a member of
com.here.android.mpa.common.LocationDataSourceHERE.
Enumeration Summary
public static final enumeration LocationDataSourceHERE.IndoorPositioningMode
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
497
Defines supported indoor positioning modes.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 144: Enum Constants in IndoorPositioningMode
Fields
public static final IndoorPositioningMode NONE
Indoor positioning is not supported.
public static final IndoorPositioningMode AUTOMATIC
Let the HERE positioning choose which radio maps to use, based on availability and accuracy.
public static final IndoorPositioningMode COMMUNITY
Use community (public) indoor radio maps only
public static final IndoorPositioningMode PRIVATE
Use private radio maps only
public static final IndoorPositioningMode DRAFT
This is development feature for testing with draft radiomaps before publishing them to production.
Method Summary
Table 145: Methods in IndoorPositioningMode
Methods
public static IndoorPositioningMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LocationDataSourceHERE.IndoorPositioningMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines supported indoor positioning modes.
Enum Constant Details
public static final IndoorPositioningMode NONE
Indoor positioning is not supported. Only supported as return value for mode get result.
public static final IndoorPositioningMode AUTOMATIC
Let the HERE positioning choose which radio maps to use, based on availability and accuracy. This is the
default mode when HERE indoor positioning is started.
HERE Android SDK Developer's Guide
API Reference
498
public static final IndoorPositioningMode COMMUNITY
Use community (public) indoor radio maps only
public static final IndoorPositioningMode PRIVATE
Use private radio maps only
public static final IndoorPositioningMode DRAFT
This is development feature for testing with draft radiomaps before publishing them to production. Devices
which are allowed to use this feature must be defined in AndroidManifest.xml file. Please read HERE Android
SDK documentation for details about this feature and its usage.
Method Details
public static IndoorPositioningMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LocationDataSourceHERE.IndoorPositioningMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
IndoorPositioningModeSetResult
The enumeration IndoorPositioningModeSetResult is a member of
com.here.android.mpa.common.LocationDataSourceHERE.
Enumeration Summary
public static final enumeration LocationDataSourceHERE.IndoorPositioningModeSetResult
extends java.lang.Enum, java.lang.Object
Defines result codes for indoor positioning mode set call.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
499
Enum Constant Summary
Table 146: Enum Constants in IndoorPositioningModeSetResult
Fields
public static final IndoorPositioningModeSetResult OK
Mode set succeeded
public static final IndoorPositioningModeSetResult PENDING
Mode set accepted but could not completed because service connection is being established.
public static final IndoorPositioningModeSetResult INTERNAL_ERROR
Location source not set.
public static final IndoorPositioningModeSetResult FEATURE_NOT_LICENSED
Requested feature not licensed.
public static final IndoorPositioningModeSetResult MODE_NOT_ALLOWED
Requested mode is not allowed for this device.
Method Summary
Table 147: Methods in IndoorPositioningModeSetResult
Methods
public static IndoorPositioningModeSetResult valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LocationDataSourceHERE.IndoorPositioningModeSetResult[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines result codes for indoor positioning mode set call.
Enum Constant Details
public static final IndoorPositioningModeSetResult OK
Mode set succeeded
public static final IndoorPositioningModeSetResult PENDING
Mode set accepted but could not completed because service connection is being established. Requested
mode will be set when service connection is ready.
public static final IndoorPositioningModeSetResult INTERNAL_ERROR
HERE Android SDK Developer's Guide
API Reference
500
Location source not set.
public static final IndoorPositioningModeSetResult FEATURE_NOT_LICENSED
Requested feature not licensed.
public static final IndoorPositioningModeSetResult MODE_NOT_ALLOWED
Requested mode is not allowed for this device. This error is returned if draft radio maps are tried to
be accessed and the device is not listed in the set of allowed devices for draft radio map access in
AndroidManifest.xml file. Check HERE Android SDK documentation for details about draft radio map feature
usage.
Method Details
public static IndoorPositioningModeSetResult valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LocationDataSourceHERE.IndoorPositioningModeSetResult[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapActivity
The class MapActivity is a member of com.here.android.mpa.common .
Class Summary
public class MapActivity
extends java.lang.Object
An activity class for managing the resource state of the MapEngine.
Deprecated: As of SDK 3.3, replaced by MapFragment.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
501
Constructor Summary
Table 148: Constructors in MapActivity
Constructors
MapActivity ()
Method Summary
Table 149: Methods in MapActivity
Methods
protected void onCreate (Bundle savedInstanceState)
Called when an instance of the given class is created (map activity begins).
protected void onInitialized (Error error)
Called when MapEngine initialization completes.
protected void onPause ()
Called when map activity pauses (is suspended).
protected void onResume ()
Called when the given instance of map activity resumes.
Class Details
Deprecated: As of SDK 3.3, replaced by MapFragment.
An activity class for managing the resource state of the MapEngine. When onCreate(Bundle) is called, it
automatically initializes the MapEngine .
Only activities that consume or use an API needs to inherit from MapActivity .
This class overrides the methods android.app.android.app.Activity#onCreate(Bundle),
android.app.android.app.Activity#onResume(), and
android.app.android.app.Activity#onPause() defined in
android.app.android.app.Activity.
This will not work as expected if your targetSdkVersion is set to 23 and above running on device with
Marshmallow and above. MapActivity initializes MapEngine before asking users for permissions resulting in a
blank screen. Use MapFragment instead.
Constructor Details
MapActivity ()
Method Details
protected void onCreate (Bundle savedInstanceState)
HERE Android SDK Developer's Guide
API Reference
502
Called when an instance of the given class is created (map activity begins). The method issues
an initialization request to the MapEngine. When MapEngine initialization has completed,
onInitialized(OnEngineInitListener.Error) is called.
Parameters:
savedInstanceState
An object representing the previous saved state of MapActivity; used if a new instance of this class is
to be recreated from a previous session.
See also:
onInitialized(Error)
protected void onInitialized (Error error)
Called when MapEngine initialization completes. User of MapActivity class can override this to detect
when or if MapEngine is ready for use.
Parameters:
error
An OnEngineInitListener.Error enum value indicates if Engine initialization is successful or if an error has
occurred
protected void onPause ()
Called when map activity pauses (is suspended).
protected void onResume ()
Called when the given instance of map activity resumes.
MapEngine
The class MapEngine is a member of com.here.android.mpa.common .
Class Summary
public final class MapEngine
extends java.lang.Object
MapEngine manages all mapping resources and services provided in this SDK.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
503
Nested Class Summary
Table 150: Nested Classes in MapEngine
Nested Classes
public static final enumeration MapEngine.MapVariant
Supported map variants.
public static abstract interface MapEngine.OnMapDownloadListener
Represents a listener to provide notification upon the start and completion of a data download event.
Method Summary
Table 151: Methods in MapEngine
Methods
public void addMapDataDownloadListener (OnMapDownloadListener listener)
Adds a OnMapDownloadListener to listen for map data download events.
public static MapEngine getInstance ()
Returns the MapEngine singleton, if one has already been created.
public int getResourceReferenceCount ()
Get the current reference count of map resource usage for this application.
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Asynchronously initialize the MapEngine .
public void init (Context context, MapVariant variant, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Asynchronously initialize the MapEngine .
public void init (ApplicationContext context, OnEngineInitListener listener)
Asynchronously initialize the MapEngine .
public static boolean isInitialized ()
Gets the initialization state of MapEngine .
public static boolean isOnlineEnabled ()
Gets the online configuration state of MapEngine .
public void onPause ()
Decrements the reference count of map resource usage.
public void onResume ()
Increments the reference count of map resource usage.
public void removeMapDataDownloadListener (OnMapDownloadListener listener)
Removes an existing MapDataDownloadListener .
HERE Android SDK Developer's Guide
API Reference
504
Methods
public static void setOnline (boolean online)
Alter the data connectivity mode of the MapEngine .
Class Details
MapEngine manages all mapping resources and services provided in this SDK.
MapEngine must be initialized before any of the services can be used. For more information, see
init(Context, OnEngineInitListener).
Users can maintain reference count through the use of onPause() and onResume() thus control when to
relinquish MapEngine services.
MapEngine also allows users to subscribe to data download notifications to provide extra information.
Method Details
public void addMapDataDownloadListener (OnMapDownloadListener listener)
Adds a OnMapDownloadListener to listen for map data download events.
Parameters:
listener
A OnMapDownloadListener to add to the MapEngine
See also:
removeMapDataDownloadListener(OnMapDownloadListener)
public static MapEngine getInstance ()
Returns the MapEngine singleton, if one has already been created.
Once the MapEngine instance is available, it must be initialized through one of the following methods
before it can be used:
MapFragment.init(OnEngineInitListener)
MapFragment.init(ApplicationContext, OnEngineInitListener)
Returns:
MapEngine instance
public int getResourceReferenceCount ()
Get the current reference count of map resource usage for this application. When this returns 0, it indicates
that no reference to map resources is being held and the engine is paused. As a result, SDK functions will not
work. When this returns 1 or greater, it is an indication that a reference to map resources is being held and
the engine is active.
HERE Android SDK Developer's Guide
API Reference
505
It is very important that an application holds a reference to map resources while in active operation and
releases this reference when not in use (e.g. sent to the background). This method is a useful tool to use
while developing an application. This value can be logged while testing to ensure that references to map
resources are handled properly during the lifecycle of the app.
For users of MapFragment and MapActivity classes, map resource usage is handled automatically.
Returns:
The current reference count of map resource usage
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
Asynchronously initialize the MapEngine . MapEngine cannot be used until it has been initialized
successfully.
This method is particularly useful for users of headless APIs as the MapEngine is being automatically
initialized as part of the setup process of MapFragments.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
context
context to be used during initialization.
listener
OnEngineInitListener to provide information when MapEngine initialization completes and if it has been
successful.
See also:
init(OnEngineInitListener)
init(Context, OnEngineInitListener)
public void init (Context context, MapVariant variant, OnEngineInitListener
listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
Asynchronously initialize the MapEngine . MapEngine cannot be used until it has been initialized
successfully.
This method is particularly useful for users of headless APIs as the MapEngine is being automatically
initialized as part of the setup process of MapFragments.
This method can configure map variant which will be used by MapEngine. If initialization fails -
OPERATION_NOT_ALLOWED will be reported. Currently following variants are supported: - GLOBAL - initialize
HERE Android SDK Developer's Guide
API Reference
506
MapEngine to use international map variant; - KOREA - initialize MapEngine to use Korean map variant; -
null - initialize MapEngine to use stored map variant or international map variant for first run. This method
is used to configure MapEngine to use certain map variant. If MapEngine was already configured and
passed variant differs - error will be reported and initialization fails.
Parameters:
context
context to be used during initialization.
variant
map variant to use.
listener
OnEngineInitListener to provide information when MapEngine initialization completes and if it has been
successful.
See also:
init(OnEngineInitListener)
init(Context, OnEngineInitListener)
public void init (ApplicationContext context, OnEngineInitListener listener)
Asynchronously initialize the MapEngine . MapEngine cannot be used until it has been initialized
successfully.
This method is particularly useful for users of headless APIs as the MapEngine is being automatically
initialized as part of the setup process of MapFragments.
This method will initialize MapEngine with ApplicationContext to be used during initialization.
Parameters:
context
ApplicationContext to be used during initialization.
listener
OnEngineInitListener to provide information when MapEngine initialization completes and if it has been
successful.
See also:
init(OnEngineInitListener)
init(ApplicationContext, OnEngineInitListener)
public static boolean isInitialized ()
Gets the initialization state of MapEngine .
Returns:
true if MapEngine is initialized and ready for service.
HERE Android SDK Developer's Guide
API Reference
507
public static boolean isOnlineEnabled ()
Gets the online configuration state of MapEngine .
If false is returned then the HERE SDK will not access the network to download map data, perform searches,
calculate routes or when providing any other service unless the service allows overriding this setting, e.g. see
CoreRouter.Connectivity, Request.Connectivity, and CLE2Request.CLE2ConnectivityMode.
Returns:
true if MapEngine is enabled to use network communications
public void onPause ()
Decrements the reference count of map resource usage. When the count drops to 0 the engine will be
paused. This should usually be called in an activity's onPause .
For users of MapFragment and MapActivity classes, it is not necessary to call onPause() as it is handled
automatically.
public void onResume ()
Increments the reference count of map resource usage. This will open all mapping resources if the reference
count becomes 1. This should usually be called in an activity's onResume .
For users of MapFragment, and MapActivity classes, it is not necessary to call onResume() as it is handled
automatically.
public void removeMapDataDownloadListener (OnMapDownloadListener listener)
Removes an existing MapDataDownloadListener .
Parameters:
listener
A MapDataDownloadListener to remove from the MapEngine
public static void setOnline (boolean online)
Alter the data connectivity mode of the MapEngine .
Parameters:
online
Pass true to set MapEngine connectivity to ONLINE. If false, connectivity is OFFLINE.
If set to false then the HERE SDK will not access the network to download map data, perform searches,
calculate routes or when providing any other service unless the service allows overriding this setting, e.g.
see , , and .
HERE Android SDK Developer's Guide
API Reference
508
MapVariant
The enumeration MapVariant is a member of com.here.android.mpa.common.MapEngine.
Enumeration Summary
public static final enumeration MapEngine.MapVariant
extends java.lang.Enum, java.lang.Object
Supported map variants.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 152: Enum Constants in MapVariant
Fields
public static final MapVariant GLOBAL
public static final MapVariant KOREA
Method Summary
Table 153: Methods in MapVariant
Methods
public static MapVariant fromShort (short val)
public short value ()
public static MapVariant valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapEngine.MapVariant[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Supported map variants. Value will be stored and used on sub-sequent MapEngine initialization. User
must use the same value for sub-sequent MapEngine initialization. Using different values in sub-sequent
initialization will report error and initialization fails.
Enum Constant Details
public static final MapVariant GLOBAL
HERE Android SDK Developer's Guide
API Reference
509
public static final MapVariant KOREA
Method Details
public static MapVariant fromShort (short val)
Parameters:
val
public short value ()
public static MapVariant valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapEngine.MapVariant[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnMapDownloadListener
The interface OnMapDownloadListener is a member of com.here.android.mpa.common.MapEngine.
Interface Summary
public static abstract interface MapEngine.OnMapDownloadListener
Represents a listener to provide notification upon the start and completion of a data download event.
[For complete information, see the section Interface Details]
Method Summary
Table 154: Methods in OnMapDownloadListener
Methods
public abstract void onMapDataDownloadEnd ()
A callback indicating that the map data download has completed
HERE Android SDK Developer's Guide
API Reference
510
Methods
public abstract void onMapDataDownloadInProgress ()
A callback indicating that a map data download is in progress.
public abstract void onMapDataDownloadStart ()
A callback indicating that a map data download has started.
Interface Details
Represents a listener to provide notification upon the start and completion of a data download event.
This listener provides callback notifications for any data download event performed by the SDK regardless
of the type of data that is downloaded (map data, traffic data, route data etc.) and regardless of the
operation that triggered the download. Data download is triggered automatically by the SDK when not
enough offline data is available on the device to perform an operation like: move the Map to a new
location, display traffic, calculate a route etc. There can be multiple cycles of #onMapDataDownloadStart(),
#onMapDataDownloadEnd() before all required map data is downloaded for a specific operation. Users are
suggested to wait at least 1 second after receiving the callback #onMapDataDownloadEnd() to see if there is
any new #onMapDataDownloadStart() notifications. No new notifications means that all required data was
downloaded. The only operation that will not trigger these notifications is when search is performed.
Method Details
public abstract void onMapDataDownloadEnd ()
A callback indicating that the map data download has completed
public abstract void onMapDataDownloadInProgress ()
A callback indicating that a map data download is in progress. This notification will be sent after
onMapDataDownloadStart.
public abstract void onMapDataDownloadStart ()
A callback indicating that a map data download has started.
MapSettings
The class MapSettings is a member of com.here.android.mpa.common .
Class Summary
public final class MapSettings
extends java.lang.Object
Allows clients to modify map settings.
HERE Android SDK Developer's Guide
API Reference
511
[For complete information, see the section Class Details]
Constructor Summary
Table 155: Constructors in MapSettings
Constructors
MapSettings ()
Method Summary
Table 156: Methods in MapSettings
Methods
public static boolean setIsolatedDiskCacheRootPath (String path, String intentAction)
Experimental method to allow switching of the disk cache to a separate service process and disk cache path.
Class Details
Allows clients to modify map settings.
Constructor Details
MapSettings ()
Method Details
public static boolean setIsolatedDiskCacheRootPath (String path, String
intentAction)
Experimental method to allow switching of the disk cache to a separate service process and disk cache path.
The method must be called before the init() methods on MapEngine.
The intent (second parameter) must be unique for the client application and must match the definition of the
service in AndroidManifest.xml.
Parameters:
path
A string containing the new disk cache path.
intentAction
A string containing "IntentAction" for the isolated service; must be unique for the client application.
Returns:
HERE Android SDK Developer's Guide
API Reference
512
false if path matches default disk cache path or path is file or invalid or is not writable or intentAction
matches default service connection name, otherwise true.
See also:
DiskCacheUtility
MatchedGeoPosition
The class MatchedGeoPosition is a member of com.here.android.mpa.common .
Class Summary
public final class MatchedGeoPosition
extends com.here.android.mpa.common.GeoPosition, java.lang.Object
An extended GeoPosition class which provides additional position-related information.
[For complete information, see the section Class Details]
See also:
onPositionUpdated(LocationMethod, GeoPosition, boolean)
Method Summary
Table 157: Methods in MatchedGeoPosition
Methods
public int getMatchQuality ()
Returns a value indicating the quality of the given map-matched position object.
public GeoPosition getRawPosition ()
Obtains the raw position from which the given map-matched position was generated.
public RoadElement getRoadElement ()
Returns the RoadElement at this matched position.
public boolean isExtrapolated ()
Determines if this matched position is extrapolated.
public boolean isOnStreet ()
Determines if this map-matched position matches to a street.
Class Details
An extended GeoPosition class which provides additional position-related information. The class is
designed to support walk or drive navigation.
See also:
HERE Android SDK Developer's Guide
API Reference
513
onPositionUpdated(LocationMethod, GeoPosition, boolean)
Method Details
public int getMatchQuality ()
Returns a value indicating the quality of the given map-matched position object.
Returns:
An integer in the range of [0,7], where 0 indicates a poor match and 7 a good match.
public GeoPosition getRawPosition ()
Obtains the raw position from which the given map-matched position was generated.
Returns:
A GeoPosition representing the raw position.
public RoadElement getRoadElement ()
Returns the RoadElement at this matched position.
Returns:
An object representing the road element at this map-matched position.
public boolean isExtrapolated ()
Determines if this matched position is extrapolated.
Returns:
true if the position is extrapolated, otherwise false
public boolean isOnStreet ()
Determines if this map-matched position matches to a street.
Returns:
true if the position is mapped to a street, otherwise false.
OffScreenRenderer
The interface OffScreenRenderer is a member of com.here.android.mpa.common .
HERE Android SDK Developer's Guide
API Reference
514
Interface Summary
public abstract interface OffScreenRenderer
Base interface for an offscreen renderer.
[For complete information, see the section Interface Details]
See also:
MapOffScreenRenderer
Nested Class Summary
Table 158: Nested Classes in OffScreenRenderer
Nested Classes
public static abstract interface OffScreenRenderer.SurfaceUpdatedListener
Listener interface to be notified when the surface has been re-drawn and comitted.
Method Summary
Table 159: Methods in OffScreenRenderer
Methods
public abstract void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the Map.
public abstract OffScreenRenderer setSize (int width, int height)
Set the size of the requested screen surface
public abstract void start ()
Start the offscreen renderer.
public abstract void start (SurfaceHolder renderTarget, SurfaceUpdatedListener listener)
Start the offscreen renderer.
public abstract void stop ()
Stop the offscreen renderer.
Interface Details
Base interface for an offscreen renderer. This interface is useful for drawing a Map image without an actual
View.
See also:
MapOffScreenRenderer
Method Details
public abstract void getScreenCapture (OnScreenCaptureListener listener)
HERE Android SDK Developer's Guide
API Reference
515
Returns the full screen bitmap for the Map. This method is asynchronous and will invoke a callback once the
operation is completed through the OnScreenCaptureListener. The OffScreenRenderer must be running to
create the screen capture.
Parameters:
listener
A OnScreenCaptureListener to listen for the callback when screen capture is complete.
public abstract OffScreenRenderer setSize (int width, int height)
Set the size of the requested screen surface
Parameters:
width
The screen surface width, in number of pixels
height
The screen surface height, in number of pixels
Returns:
This OffScreenRenderer
public abstract void start ()
Start the offscreen renderer. A new PBuffer based surface will be allocated. Before calling this method,
setSize(int, int) must have been called with valid values.
public abstract void start (SurfaceHolder renderTarget, SurfaceUpdatedListener
listener)
Start the offscreen renderer. The renderer will be attached to the supplied SurfaceHolder argument.
Parameters:
renderTarget
Surface to attach to.
listener
Callback when the surface has been updated
public abstract void stop ()
Stop the offscreen renderer. All resource allocated will be released.
HERE Android SDK Developer's Guide
API Reference
516
SurfaceUpdatedListener
The interface SurfaceUpdatedListener is a member of com.here.android.mpa.common.OffScreenRenderer.
Interface Summary
public static abstract interface OffScreenRenderer.SurfaceUpdatedListener
Listener interface to be notified when the surface has been re-drawn and comitted.
[For complete information, see the section Interface Details]
Method Summary
Table 160: Methods in SurfaceUpdatedListener
Methods
public abstract void onSurfaceUpdated ()
Callback when the surface has been redrawn
Interface Details
Listener interface to be notified when the surface has been re-drawn and comitted.
Method Details
public abstract void onSurfaceUpdated ()
Callback when the surface has been redrawn
OnEngineInitListener
The interface OnEngineInitListener is a member of com.here.android.mpa.common .
Interface Summary
public abstract interface OnEngineInitListener
Represents a listener to provide notification of the engine status upon completion of initialization.
[For complete information, see the section Interface Details]
See also:
init(ApplicationContext, OnEngineInitListener)
HERE Android SDK Developer's Guide
API Reference
517
Nested Class Summary
Table 161: Nested Classes in OnEngineInitListener
Nested Classes
public static final enumeration OnEngineInitListener.Error
Represents values describing initialization errors.
Method Summary
Table 162: Methods in OnEngineInitListener
Methods
public abstract void onEngineInitializationCompleted (Error error)
A callback indicating that map engine initialization has completed.
Interface Details
Represents a listener to provide notification of the engine status upon completion of initialization.
See also:
init(ApplicationContext, OnEngineInitListener)
Method Details
public abstract void onEngineInitializationCompleted (Error error)
A callback indicating that map engine initialization has completed.
Parameters:
error
If map engine initialized successfully, returns NONE. Otherwise, one of the other
OnEngineInitListener.Error enum values indicating the reason of factory initialization failure.
Error
The enumeration Error is a member of com.here.android.mpa.common.OnEngineInitListener.
Enumeration Summary
public static final enumeration OnEngineInitListener.Error
extends java.lang.Enum, java.lang.Object
Represents values describing initialization errors.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
518
See also:
onEngineInitializationCompleted(Error)
Enum Constant Summary
Table 163: Enum Constants in Error
Fields
public static final Error NONE
Initialization completed successfully
public static final Error USAGE_EXPIRED
Initialization failed as the SDK is expired
public static final Error MODEL_NOT_SUPPORTED
Initialization failed as the device's model is not supported by the SDK
public static final Error DEVICE_NOT_SUPPORTED
Initialization failed as the device is not supported by the SDK
public static final Error UNKNOWN
Initialization failed for unknown reasons
public static final Error MISSING_APP_CREDENTIAL
Initialization failed due to missing App ID and App Code.
public static final Error BUSY
Initialization cannot be completed as the system is currently busy.
public static final Error FILE_RW_ERROR
Unable to write to or read from disk cache.
public static final Error MISSING_PERMISSION
One of the permissions required to run the SDK is missing.
public static final Error MISSING_SERVICE
MapService cannot not be found
public static final Error WRONG_SERVICE_INTENT_NAME
Wrong service intent name for MapsEngine with isolated cache
public static final Error MISSING_LIBRARIES
Missing native libraries or missing dependent java libraries which cause native libraries to not load.
public static final Error OPERATION_NOT_ALLOWED
The required permission to initialize component is missing or the license key provided is invalid.
HERE Android SDK Developer's Guide
API Reference
519
Method Summary
Table 164: Methods in Error
Methods
public String getDetails ()
public String getStackTrace ()
public Throwable getThrowable ()
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static OnEngineInitListener.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing initialization errors.
See also:
onEngineInitializationCompleted(Error)
Enum Constant Details
public static final Error NONE
Initialization completed successfully
public static final Error USAGE_EXPIRED
Initialization failed as the SDK is expired
public static final Error MODEL_NOT_SUPPORTED
Initialization failed as the device's model is not supported by the SDK
public static final Error DEVICE_NOT_SUPPORTED
Initialization failed as the device is not supported by the SDK
public static final Error UNKNOWN
Initialization failed for unknown reasons
public static final Error MISSING_APP_CREDENTIAL
HERE Android SDK Developer's Guide
API Reference
520
Initialization failed due to missing App ID and App Code. Please make sure the following lines
are added to AndroidManifest.xml (Replace with your own app_id and app_code pair) <meta-
data android:name="com.here.android.maps.appid" android:value="APPID" /> <meta-data
android:name="com.here.android.maps.apptoken" android:value="APPCODE" />
public static final Error BUSY
Initialization cannot be completed as the system is currently busy. User should check again later.
public static final Error FILE_RW_ERROR
Unable to write to or read from disk cache.
public static final Error MISSING_PERMISSION
One of the permissions required to run the SDK is missing. This refers to android application permission.
public static final Error MISSING_SERVICE
MapService cannot not be found
public static final Error WRONG_SERVICE_INTENT_NAME
Wrong service intent name for MapsEngine with isolated cache
public static final Error MISSING_LIBRARIES
Missing native libraries or missing dependent java libraries which cause native libraries to not load.
public static final Error OPERATION_NOT_ALLOWED
The required permission to initialize component is missing or the license key provided is invalid. This
refers to the permission to be supplied for the entry com.here.android.maps.license.key in the
AndroidManifest.xml.
Method Details
public String getDetails ()
Returns:
More details about the error and tips for the possible solution.
HERE Android SDK Developer's Guide
API Reference
521
public String getStackTrace ()
Returns:
Stack trace of the associated Throwable object, useful for troubleshooting.
public Throwable getThrowable ()
Returns:
Throwable associated with the error.
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static OnEngineInitListener.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnScreenCaptureListener
The interface OnScreenCaptureListener is a member of com.here.android.mpa.common .
Interface Summary
public abstract interface OnScreenCaptureListener
Listener for Screen Capture asynchronous callback.
[For complete information, see the section Interface Details]
See also:
getScreenCapture(OnScreenCaptureListener)
Method Summary
Table 165: Methods in OnScreenCaptureListener
Methods
public abstract void onScreenCaptured (Bitmap bitmap)
A callback indicating the availability and validity of the created bitmap.
HERE Android SDK Developer's Guide
API Reference
522
Interface Details
Listener for Screen Capture asynchronous callback. The API is supported by MapFragment
See also:
getScreenCapture(OnScreenCaptureListener)
Method Details
public abstract void onScreenCaptured (Bitmap bitmap)
A callback indicating the availability and validity of the created bitmap.
Parameters:
bitmap
A Bitmap relative to the Map center. bitmap is null if failed to retrieve or create the bitmap.
PositionSimulator
The class PositionSimulator is a member of com.here.android.mpa.common .
Class Summary
public final class PositionSimulator
extends java.lang.Object
Provides a means to simulate the current device position by injecting Locations read from position log files
into Android LocationManager.
[For complete information, see the section Class Details]
Nested Class Summary
Table 166: Nested Classes in PositionSimulator
Nested Classes
public static final enumeration PositionSimulator.PlaybackError
Playback Errors
Constructor Summary
Table 167: Constructors in PositionSimulator
Constructors
PositionSimulator ()
Create an instance of the PositionSimulator.
HERE Android SDK Developer's Guide
API Reference
523
Method Summary
Table 168: Methods in PositionSimulator
Methods
public int getCurrentPositionIndex ()
Index of the currently playing GeoPosition from the position log file.
public GeoPosition getPosition (int index)
GeoPosition from the currently playing position log file for the given index.
public int getPositionCount ()
Number of GeoPositions in the currently playing position log file.
public PlaybackError startPlayback (String logFilePath)
Starts play back of a position log file by pushing Test Locations to Android LocationManager.
public void stopPlayback ()
Stops any currently playing position log file.
Class Details
Provides a means to simulate the current device position by injecting Locations read from position log files
into Android LocationManager.
Constructor Details
PositionSimulator ()
Create an instance of the PositionSimulator.
Note that you should not attempt to replay position log files concurrently.
Method Details
public int getCurrentPositionIndex ()
Index of the currently playing GeoPosition from the position log file.
Returns:
Position index.
public GeoPosition getPosition (int index)
GeoPosition from the currently playing position log file for the given index.
Parameters:
index
Position index.
HERE Android SDK Developer's Guide
API Reference
524
Returns:
GeoPosition or null if index is out of bounds.
public int getPositionCount ()
Number of GeoPositions in the currently playing position log file.
Returns:
Position count.
public PlaybackError startPlayback (String logFilePath)
Starts play back of a position log file by pushing Test Locations to Android LocationManager.
Any currently playing file will be immediately stopped and the new position log file started.
When the last Position in the position log file has been played the LocationManager status will be set to
unavailable but system GPS updates will not be resumed until stopPlayback() is called.
Position log file playback only works with the default location data source and requires the
ACCESS_FINE_LOCATION and OPSTR_MOCK_LOCATION android application permissions.
Parameters:
logFilePath
Fully qualified file path of the position log file.
Returns:
PlaybackError.NONE if play back was started successfully, otherwise the failure reason.
public void stopPlayback ()
Stops any currently playing position log file. System GPS updates will be resumed.
PlaybackError
The enumeration PlaybackError is a member of com.here.android.mpa.common.PositionSimulator.
Enumeration Summary
public static final enumeration PositionSimulator.PlaybackError
extends java.lang.Enum, java.lang.Object
Playback Errors
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
525
Enum Constant Summary
Table 169: Enum Constants in PlaybackError
Fields
public static final PlaybackError NONE
There is no error.
public static final PlaybackError NO_MOCK_LOCATION_PERMISSION
The application needs the Android OPSTR_MOCK_LOCATION developer permission in order to replay position log files.
public static final PlaybackError LOCATION_MANAGER
Unexpected error from Android LocationManager.
public static final PlaybackError FILE_NOT_FOUND
Position log file was not found.
public static final PlaybackError FILE_PARSING
Error parsing the position log file.
public static final PlaybackError LOCATION_DATA_SOURCE_INVALID
PositioningManager has not yet been started or the current LocationDataSource does not not support log file playback
(currently only SDK default data sources are supported).
public static final PlaybackError NO_LOCATION_PERMISSION
The application is missing the ACCESS_FINE_LOCATION android permission.
Method Summary
Table 170: Methods in PlaybackError
Methods
public static PlaybackError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PositionSimulator.PlaybackError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Playback Errors
Enum Constant Details
public static final PlaybackError NONE
There is no error. Position playback has started.
public static final PlaybackError NO_MOCK_LOCATION_PERMISSION
HERE Android SDK Developer's Guide
API Reference
526
The application needs the Android OPSTR_MOCK_LOCATION developer permission in order to replay position
log files.
public static final PlaybackError LOCATION_MANAGER
Unexpected error from Android LocationManager.
public static final PlaybackError FILE_NOT_FOUND
Position log file was not found.
public static final PlaybackError FILE_PARSING
Error parsing the position log file. This error will be returned if the file is not of a supported format (currently
only GPX is supported).
public static final PlaybackError LOCATION_DATA_SOURCE_INVALID
PositioningManager has not yet been started or the current LocationDataSource does not not support log file
playback (currently only SDK default data sources are supported).
public static final PlaybackError NO_LOCATION_PERMISSION
The application is missing the ACCESS_FINE_LOCATION android permission.
Method Details
public static PlaybackError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PositionSimulator.PlaybackError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
PositioningManager
The class PositioningManager is a member of com.here.android.mpa.common .
HERE Android SDK Developer's Guide
API Reference
527
Class Summary
public final class PositioningManager
extends java.lang.Object
Represents a manager for information received from positioning devices, such as updates to the current
position and the average speed.
[For complete information, see the section Class Details]
Nested Class Summary
Table 171: Nested Classes in PositioningManager
Nested Classes
public static final enumeration PositioningManager.LocationMethod
Represents values describing the location method.
public static final enumeration PositioningManager.LocationStatus
Represents values describing the location status of a particular location method.
public static final enumeration PositioningManager.LogType
Defines the available log types for GPX logging.
public static abstract interface PositioningManager.OnPositionChangedListener
Represents an interface for position update listeners.
Method Summary
Table 172: Methods in PositioningManager
Methods
public void addListener (java.lang.ref.WeakReference <OnPositionChangedListener> listener)
Adds a PositioningManager.OnPositionChangedListener to the PositioningManager .
public double getAverageSpeed ()
Gets the average speed of travel, in meters per second.
public LocationDataSource getDataSource ()
Get the current location data source used to provide position updates
public static PositioningManager getInstance ()
Get access to the PositioningManager Singleton
public GeoPosition getLastKnownPosition ()
Returns the last known (cached) position from the best available provider.
public LocationMethod getLocationMethod ()
Gets the method type used to determine positioning.
HERE Android SDK Developer's Guide
API Reference
528
Methods
public LocationStatus getLocationStatus (LocationMethod method)
Gets the status for a specified LocationMethod .
public java.util.EnumSet <LogType> getLogType ()
Returns the current GPX logging configuration.
public GeoPosition getPosition ()
Gets the GeoPosition for the current PositioningManager.LocationMethod if available.
public RoadElement getRoadElement ()
Get the RoadElement of the current position.
public boolean hasValidPosition ()
Determines whether the current position for the current active PositioningManager.LocationMethod is valid.
public boolean hasValidPosition (LocationMethod method)
Determines whether the current position for the specified LocationMethod is valid.
public boolean isActive ()
Determines whether the PositioningManager is active and whether position updates are being received.
public void removeListener (OnPositionChangedListener listener)
Removes a PositioningManager.OnPositionChangedListener from the PositioningManager .
public boolean setDataSource (LocationDataSource source)
Set the location data source from which to receive position updates.
public void setLogType (java.util.EnumSet <LogType> logType)
Configures position update logging.
public boolean start (LocationMethod method)
Starts receiving position updates from the current location data source.
public void stop ()
Stops receiving position updates from the positioning device.
Class Details
Represents a manager for information received from positioning devices, such as updates to the current
position and the average speed.
If the user of the application revokes the ACCESS_FINE_LOCATION permission at runtime while
PositioningManager is active, the application will stop receiving location updates and methods of
PositioningManager will stop functioning properly until the ACCESS_FINE_LOCATION permission is
restored.
Method Details
public void addListener (java.lang.ref.WeakReference
<OnPositionChangedListener> listener)
HERE Android SDK Developer's Guide
API Reference
529
Adds a PositioningManager.OnPositionChangedListener to the PositioningManager .
Parameters:
listener
A WeakReference of the OnPositionChangedListener to add.
See also:
removeListener(OnPositionChangedListener)
public double getAverageSpeed ()
Gets the average speed of travel, in meters per second.
Returns:
The average speed
public LocationDataSource getDataSource ()
Get the current location data source used to provide position updates
Returns:
LocationDataSource passed to setDataSource or null if the current location data source is the HERE
SDK default.
public static PositioningManager getInstance ()
Get access to the PositioningManager Singleton
Returns:
PositioningManager instance
public GeoPosition getLastKnownPosition ()
Returns the last known (cached) position from the best available provider. This is useful if there is no valid
device position available (i.e. hasValidPosition() returns false). If hasValidPosition() returns true, please
use the getPosition() API.
There is no guarantee regarding the freshness of the returned position. If no cached position is available, an
invalid GeoPosition is returned (can be checked by way of isValid()).
Returns:
Last known position from the best available provider. Or an invalid GeoPosition if not available.
See also:
getPosition()
HERE Android SDK Developer's Guide
API Reference
530
public LocationMethod getLocationMethod ()
Gets the method type used to determine positioning.
Returns:
The LocationMethod
public LocationStatus getLocationStatus (LocationMethod method)
Gets the status for a specified LocationMethod .
Parameters:
method
A LocationMethod used to determine the location status
Returns:
The status of the specified LocationMethod
public java.util.EnumSet <LogType> getLogType ()
Returns the current GPX logging configuration.
Defaults to an empty EnumSet (no logging).
Returns:
The set of all enabled log types.
See also:
PositioningManager.LogType
public GeoPosition getPosition ()
Gets the GeoPosition for the current PositioningManager.LocationMethod if available.
Availability of a position can be checked by way of the hasValidPosition() method, if that method returns
false, the best available cached position can be obtained using the getLastKnownPosition() API.
The position returned is determined by the following criteria:
If Navigation is active, the MatchedGeoPosition is returned, else
If a valid position fix is available for the active PositioningManager.LocationMethod than it is returned.
else,
An invalid GeoPosition is returned (this can be checked by way of isValid()
Returns:
The current GeoPosition
See also:
getLastKnownPosition()
HERE Android SDK Developer's Guide
API Reference
531
public RoadElement getRoadElement ()
Get the RoadElement of the current position.
Returns:
A RoadElement object representing the road element at the current position.
public boolean hasValidPosition ()
Determines whether the current position for the current active PositioningManager.LocationMethod is valid.
Returns:
True if the position is valid, false otherwise
See also:
hasValidPosition(LocationMethod)
public boolean hasValidPosition (LocationMethod method)
Determines whether the current position for the specified LocationMethod is valid.
Parameters:
method
A LocationMethod to check for a valid position
Returns:
True if the position is valid, false otherwise
See also:
hasValidPosition()
public boolean isActive ()
Determines whether the PositioningManager is active and whether position updates are being received.
Returns:
True if the PositioningManager is actively receiving position updates, false otherwise
public void removeListener (OnPositionChangedListener listener)
Removes a PositioningManager.OnPositionChangedListener from the PositioningManager .
Parameters:
listener
A OnPositionChangedListener to remove
HERE Android SDK Developer's Guide
API Reference
532
See also:
addListener(WeakReference<OnPositionChangedListener>)
public boolean setDataSource (LocationDataSource source)
Set the location data source from which to receive position updates.
Note: The default HERE SDK data source supports the GPS and network location methods.
Parameters:
source
LocationDataSource used to provide position updates. Specify null to use the default location data
source provided by the HERE SDK.
Returns:
True if the data source was set successfully, false otherwise. One reason for returning false is that
positioning is currently active and the new location source could not be started with the current location
method.
public void setLogType (java.util.EnumSet <LogType> logType)
Configures position update logging.
LogType.DATA_SOURCE will log "input positions" from the current LocationDataSource if the data source
supports GPX logging. HERE SDK default data sources that use Android Location Manager will log to a GPX file
ending with the suffix "_lm". This GPX file is suitable for playback via PositionSimulator.
LogType.RAW and LogType.MATCHED will log the results of processing the input position from the current
data source. The content of these logs represents historical values that getPosition() would return.
GPX logs produced for these logging types are for analysis only and are not suitable for playback via
PositionSimulator.
GPX logs will be written to a "gpx" sub directory of the Appication's data directory (for example, "/sdcard/
Android/data/com.companyName.appName/files/gpx/". Logs will be prefixed with a timestamp representing
the time logging was enabled and suffix indicating the log type.
To ensure log files are flushed to disk make sure logging is disabled prior to application exit. Logging is
disabled by setting the log type to EnumSet.noneOf(LogType.class).
Defaults to an empty EnumSet (no logging).
IMPORTANT: Logging should NOT be permanently enabled in production builds submitted to the Google Play
Store.
Parameters:
logType
The set of all PositioningManager.LogTypes to be enabled
See also:
PositioningManager.LogType
HERE Android SDK Developer's Guide
API Reference
533
public boolean start (LocationMethod method)
Starts receiving position updates from the current location data source.
When using LocationDataSourceDevice (the default) or LocationDataSourceHERE, this method will
return false and the PositioningManager will not be started if the application does not have the
ACCESS_FINE_LOCATION permission at the time of this call.
Parameters:
method
LocationMethod used to provide position updates
Returns:
True if current location data source was started OK, false otherwise (this may indicate the application does
not have the ACCESS_FINE_LOCATION permission at the time of this call).
public void stop ()
Stops receiving position updates from the positioning device.
LocationMethod
The enumeration LocationMethod is a member of com.here.android.mpa.common.PositioningManager.
Enumeration Summary
public static final enumeration PositioningManager.LocationMethod
extends java.lang.Enum, java.lang.Object
Represents values describing the location method.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 173: Enum Constants in LocationMethod
Fields
public static final LocationMethod NONE
Device positioning is not active.
public static final LocationMethod GPS
Positioning is provided using a GPS device.
public static final LocationMethod NETWORK
Positioning is provided using a wireless network.
HERE Android SDK Developer's Guide
API Reference
534
Fields
public static final LocationMethod GPS_NETWORK
Positioning is provided using a wireless network, or a GPS device, or both.
public static final LocationMethod GPS_NETWORK_INDOOR
Positioning is provided using GPS, or Wi-Fi or Bluetooth LE network.
public static final LocationMethod INDOOR
Positioning is provided using Wi-Fi or Bluetooth LE network using high accuracy radio maps.
Method Summary
Table 174: Methods in LocationMethod
Methods
public static LocationMethod valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PositioningManager.LocationMethod[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the location method.
Enum Constant Details
public static final LocationMethod NONE
Device positioning is not active.
public static final LocationMethod GPS
Positioning is provided using a GPS device.
public static final LocationMethod NETWORK
Positioning is provided using a wireless network.
public static final LocationMethod GPS_NETWORK
Positioning is provided using a wireless network, or a GPS device, or both.
public static final LocationMethod GPS_NETWORK_INDOOR
HERE Android SDK Developer's Guide
API Reference
535
Positioning is provided using GPS, or Wi-Fi or Bluetooth LE network. Returned positions may contain building
and floor information.
public static final LocationMethod INDOOR
Positioning is provided using Wi-Fi or Bluetooth LE network using high accuracy radio maps. Returned
positions may contain building and floor information.
Method Details
public static LocationMethod valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PositioningManager.LocationMethod[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
LocationStatus
The enumeration LocationStatus is a member of com.here.android.mpa.common.PositioningManager.
Enumeration Summary
public static final enumeration PositioningManager.LocationStatus
extends java.lang.Enum, java.lang.Object
Represents values describing the location status of a particular location method.
[For complete information, see the section Enumeration Details]
See also:
PositioningManager.LocationMethod
HERE Android SDK Developer's Guide
API Reference
536
Enum Constant Summary
Table 175: Enum Constants in LocationStatus
Fields
public static final LocationStatus OUT_OF_SERVICE
The device is disabled.
public static final LocationStatus TEMPORARILY_UNAVAILABLE
The device is enabled, but without a location fix.
public static final LocationStatus AVAILABLE
The device is enabled with a GPS location fix.
Method Summary
Table 176: Methods in LocationStatus
Methods
public static LocationStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PositioningManager.LocationStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the location status of a particular location method.
See also:
PositioningManager.LocationMethod
Enum Constant Details
public static final LocationStatus OUT_OF_SERVICE
The device is disabled.
public static final LocationStatus TEMPORARILY_UNAVAILABLE
The device is enabled, but without a location fix.
public static final LocationStatus AVAILABLE
The device is enabled with a GPS location fix.
HERE Android SDK Developer's Guide
API Reference
537
Method Details
public static LocationStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PositioningManager.LocationStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
LogType
The enumeration LogType is a member of com.here.android.mpa.common.PositioningManager.
Enumeration Summary
public static final enumeration PositioningManager.LogType
extends java.lang.Enum, java.lang.Object
Defines the available log types for GPX logging.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 177: Enum Constants in LogType
Fields
public static final LogType DATA_SOURCE
Logs position updates from the current LocationDataSource if it supports GPX logging
public static final LogType RAW
Logs raw position updates to "*_raw.gpx"
public static final LogType MATCHED
Logs map matched position updates to "*_matched.gpx"
HERE Android SDK Developer's Guide
API Reference
538
Method Summary
Table 178: Methods in LogType
Methods
public static LogType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PositioningManager.LogType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines the available log types for GPX logging.
Enum Constant Details
public static final LogType DATA_SOURCE
Logs position updates from the current LocationDataSource if it supports GPX logging
public static final LogType RAW
Logs raw position updates to "*_raw.gpx"
public static final LogType MATCHED
Logs map matched position updates to "*_matched.gpx"
Method Details
public static LogType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PositioningManager.LogType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
539
OnPositionChangedListener
The interface OnPositionChangedListener is a member of
com.here.android.mpa.common.PositioningManager.
Interface Summary
public static abstract interface PositioningManager.OnPositionChangedListener
Represents an interface for position update listeners.
[For complete information, see the section Interface Details]
See also:
addListener(WeakReference<OnPositionChangedListener>)
removeListener(OnPositionChangedListener)
Method Summary
Table 179: Methods in OnPositionChangedListener
Methods
public abstract void onPositionFixChanged (LocationMethod method, LocationStatus status)
A callback indicating that the position fix has changed.
public abstract void onPositionUpdated (LocationMethod method, GeoPosition position, boolean
isMapMatched)
A callback indicating that the position has been updated.
Interface Details
Represents an interface for position update listeners.
See also:
addListener(WeakReference<OnPositionChangedListener>)
removeListener(OnPositionChangedListener)
Method Details
public abstract void onPositionFixChanged (LocationMethod method,
LocationStatus status)
A callback indicating that the position fix has changed.
Parameters:
method
A LocationMethod providing the status update (GPS or Network)
status
HERE Android SDK Developer's Guide
API Reference
540
A LocationStatus representing the updated positioning status
public abstract void onPositionUpdated (LocationMethod method, GeoPosition
position, boolean isMapMatched)
A callback indicating that the position has been updated.
Parameters:
method
A LocationMethod providing the position update (GPS or Network)
position
A GeoPosition representing the updated position. The position can return null if the MapsEngine has
not been initialized.
isMapMatched
A boolean stating if the position is map matched or not. Map matching approximates user coordinates
to the nearest road or navigation route If the value is false then it means an unmatched(raw) position is
received.
RoadElement
The class RoadElement is a member of com.here.android.mpa.common .
Class Summary
public final class RoadElement
extends java.lang.Object
Represents a single segment of a road.
[For complete information, see the section Class Details]
Nested Class Summary
Table 180: Nested Classes in RoadElement
Nested Classes
public static final enumeration RoadElement.Attribute
Defined values for different road attributes
public static final enumeration RoadElement.FormOfWay
Form of Way Types
public static final enumeration RoadElement.PluralType
Plural type identifies when a Junction is made up of multiple Road Elements.
HERE Android SDK Developer's Guide
API Reference
541
Method Summary
Table 181: Methods in RoadElement
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public java.util.EnumSet <Attribute> getAttributes ()
Gets the road attributes.
public float getDefaultSpeed ()
Gets the default speed of the road element.
public FormOfWay getFormOfWay ()
Gets the form of way.
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of the road element.
public double getGeometryLength ()
Returns the length of the polyline associated with this RoadElement in meters.
public Identifier getIdentifier ()
Get the Identifier for this particular RoadElement.
public int getNumberOfLanes ()
Gets number of lanes in this road element.
public long getPermanentDirectedLinkId ()
The Permanent Link ID (stable across different map versions) of the RoadElement with travel direction: positive sign (+)
means driving in the 'canonical' direction of the road and negative sign (-) means driving against the 'canonical' direction of
the road.
public long getPermanentLinkId ()
Returns the Permanent Link ID (stable across different map versions) of the RoadElement .
public PluralType getPluralType ()
Gets the plural type of the road element.
public static RoadElement getRoadElement (GeoCoordinate coordinate, String marcCode)
Get the RoadElement of the current GeoCoordinate .
public static java.util.List <RoadElement> getRoadElements (GeoBoundingBox boundingBox, String
marcCode)
Get the list of RoadElement of the current GeoBoundingBox .
public String getRoadName ()
Gets the name of the road that contains this current road element, such as "Still Creek Drive".
public String getRouteName ()
Gets the route name of the road element.
HERE Android SDK Developer's Guide
API Reference
542
Methods
public float getSpeedLimit ()
Gets the speed limit.
public Date getStartTime ()
Gets the (estimated) time at which this road element starts.
public float getStaticSpeed ()
Gets the static speed of the road element using only free-flow speeds.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isPedestrian ()
Checks, if the road is allowed only for pedestrians.
public boolean isPlural ()
Tests if the road element is plural.
Class Details
Represents a single segment of a road.
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public java.util.EnumSet <Attribute> getAttributes ()
Gets the road attributes.
Returns:
Set of RoadElement.Attribute
public float getDefaultSpeed ()
Gets the default speed of the road element. It uses the same speeds used during routing, includes dynamic
events, for example, if traffic is enabled.
Returns:
The default speed in m/s or 0.0 if the information is not available.
public FormOfWay getFormOfWay ()
HERE Android SDK Developer's Guide
API Reference
543
Gets the form of way.
Returns:
The form of way of the road.
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of the road element. The geometry is a returned as a list of GeoCoordinate that can be
used to create a polyline.
Returns:
a list of GeoCoordinate
public double getGeometryLength ()
Returns the length of the polyline associated with this RoadElement in meters.
Returns:
length of polyline for this RoadElement in meters.
public Identifier getIdentifier ()
Get the Identifier for this particular RoadElement.
Returns:
Identifier
public int getNumberOfLanes ()
Gets number of lanes in this road element.
Returns:
The number of lanes in this road element.
public long getPermanentDirectedLinkId ()
The Permanent Link ID (stable across different map versions) of the RoadElement with travel direction:
positive sign (+) means driving in the 'canonical' direction of the road and negative sign (-) means driving
against the 'canonical' direction of the road. Every road element has two endpoints. Starting from which end
point the link is being traversed? Each link has a geometry associated with it. The geometry gives the link a
'canonical' direction: if you traverse the link in the direction the geometry is stored, you are traveling in the
positive direction. Otherwise, you are traveling in the negative direction. The assigned 'canonical' direction
is completely arbitrary and no assumption should be made about it. This property is unavailable when the
public transport mode RouteOptions.TransportMode#PUBLIC_TRANSPORT is used. For all the other transport
modes, it is available only in routes calculated with the online connectivity mode.
HERE Android SDK Developer's Guide
API Reference
544
Returns:
Permanent Link ID with direction of this element or 0 if not available.
See also:
getPermanentLinkId()
public long getPermanentLinkId ()
Returns the Permanent Link ID (stable across different map versions) of the RoadElement . This property is
unavailable when the public transport mode RouteOptions.TransportMode#PUBLIC_TRANSPORT is used. For
all the other transport modes, it is available only in routes calculated with the online connectivity mode.
Returns:
Permanent Link ID of this element or 0 if not available.
See also:
getPermanentDirectedLinkId()
public PluralType getPluralType ()
Gets the plural type of the road element.
Returns:
The plural type of the road element.
public static RoadElement getRoadElement (GeoCoordinate coordinate, String
marcCode)
Get the RoadElement of the current GeoCoordinate . This method returns null if the GeoCoordinate is
invalid or there is no RoadElement close enough to the GeoCoordinate .
Parameters:
coordinate
The GeoCoordinate that defines the coordinate to retrieve RoadElement
marcCode
The text for RoadElement corresponds to the language MARC code.
Returns:
The RoadElement of the current GeoCoordinate.
Throws:
IllegalArgumentException
If marcCode is an empty string.
NullPointerException
If coordinate is null or marcCode is null.
HERE Android SDK Developer's Guide
API Reference
545
public static java.util.List <RoadElement> getRoadElements (GeoBoundingBox
boundingBox, String marcCode)
Get the list of RoadElement of the current GeoBoundingBox .
Parameters:
boundingBox
The GeoBoundingBox that defines the area to retrieve RoadElement
marcCode
The text for RoadElement corresponds to the language MARC code.
Returns:
The list of RoadElement of the current GeoBoundingBox.
public String getRoadName ()
Gets the name of the road that contains this current road element, such as "Still Creek Drive".
Returns:
The name of the road. Returns null or an empty string if the name is unknown, such as when the road
element is on an unnamed service alley.
public String getRouteName ()
Gets the route name of the road element. The route name is a short label for the road, for example I5 for the
Interstate 5 in the US. The method returns a null string if the route name is unknown.
Returns:
The route name of the road element.
public float getSpeedLimit ()
Gets the speed limit.
Returns:
The speed limit in m/s or 0 if the information is not available.
public Date getStartTime ()
Gets the (estimated) time at which this road element starts. If no departure time was set for the
RouteOptions associated with this road element, than the time is relative to the system time when the route
calculation took place. Otherwise, the times are relative to the specified departure time.
Returns:
HERE Android SDK Developer's Guide
API Reference
546
The start time, or null if not available
See also:
setTime(Date, TimeType)
public float getStaticSpeed ()
Gets the static speed of the road element using only free-flow speeds. It does not include dynamic events,
for example, excludes traffic even if enabled.
Returns:
The static speed in m/s or 0.0 if the information is not available.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isPedestrian ()
Checks, if the road is allowed only for pedestrians.
Returns:
True, if road is allowed only for pedestrians, otherwise false.
public boolean isPlural ()
Tests if the road element is plural.
Returns:
True if the road element is plural.
Attribute
The enumeration Attribute is a member of com.here.android.mpa.common.RoadElement.
Enumeration Summary
public static final enumeration RoadElement.Attribute
extends java.lang.Enum, java.lang.Object
Defined values for different road attributes
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
547
Enum Constant Summary
Table 182: Enum Constants in Attribute
Fields
public static final Attribute DIR_NO_CARS
Road direction.
public static final Attribute DIR_FORWARD
public static final Attribute DIR_BACKWARD
public static final Attribute DIR_BOTH
public static final Attribute DIRT_ROAD
Road type.
public static final Attribute USAGE_FEE_REQUIRED
public static final Attribute CARPOOL
public static final Attribute URBAN
public static final Attribute TOLLROAD
public static final Attribute NO_THROUGH_TRAFFIC
public static final Attribute TUNNEL
public static final Attribute EXPLICATION
public static final Attribute SLIPROAD
public static final Attribute HIGHWAY
public static final Attribute UNDER_CONSTRUCTION
public static final Attribute HAS_LANE_DIR
public static final Attribute HAS_LANE_EXIT
public static final Attribute FERRY
public static final Attribute CAR_SHUTTLE_TRAIN
public static final Attribute DIR_NO_TRUCKS
truck specific
public static final Attribute DIR_TRUCK_FORWARD
public static final Attribute DIR_TRUCK_BACKWARD
public static final Attribute DIR_TRUCK_BOTH
public static final Attribute TRUCK_TOLLROAD
public static final Attribute TRUCK_NO_THROUGH
HERE Android SDK Developer's Guide
API Reference
548
Method Summary
Table 183: Methods in Attribute
Methods
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RoadElement.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defined values for different road attributes
Enum Constant Details
public static final Attribute DIR_NO_CARS
Road direction.
public static final Attribute DIR_FORWARD
public static final Attribute DIR_BACKWARD
public static final Attribute DIR_BOTH
public static final Attribute DIRT_ROAD
Road type.
public static final Attribute USAGE_FEE_REQUIRED
public static final Attribute CARPOOL
public static final Attribute URBAN
public static final Attribute TOLLROAD
HERE Android SDK Developer's Guide
API Reference
549
public static final Attribute NO_THROUGH_TRAFFIC
public static final Attribute TUNNEL
public static final Attribute EXPLICATION
public static final Attribute SLIPROAD
public static final Attribute HIGHWAY
public static final Attribute UNDER_CONSTRUCTION
public static final Attribute HAS_LANE_DIR
public static final Attribute HAS_LANE_EXIT
public static final Attribute FERRY
public static final Attribute CAR_SHUTTLE_TRAIN
public static final Attribute DIR_NO_TRUCKS
truck specific
public static final Attribute DIR_TRUCK_FORWARD
public static final Attribute DIR_TRUCK_BACKWARD
public static final Attribute DIR_TRUCK_BOTH
public static final Attribute TRUCK_TOLLROAD
HERE Android SDK Developer's Guide
API Reference
550
public static final Attribute TRUCK_NO_THROUGH
Method Details
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RoadElement.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FormOfWay
The enumeration FormOfWay is a member of com.here.android.mpa.common.RoadElement.
Enumeration Summary
public static final enumeration RoadElement.FormOfWay
extends java.lang.Enum, java.lang.Object
Form of Way Types
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 184: Enum Constants in FormOfWay
Fields
public static final FormOfWay UNDEFINED
Road form of way is undefined/unknown.
public static final FormOfWay MOTORWAY
Road to which regulations will normally apply with regards to entry and use.
public static final FormOfWay MULTI_CARRIAGEWAY
Road with physically separated carriageways regardless of the number of lanes, which is not a motorway or a freeway.
public static final FormOfWay SINGLE_CARRIAGEWAY
Road where the traffic is not separated by any physical object.
HERE Android SDK Developer's Guide
API Reference
551
Fields
public static final FormOfWay ROUNDABOUT
Road which forms a ring on which traffic travelling in only one direction is allowed.
public static final FormOfWay SPECIAL_TRAFFIC_FIGURE
Road that is part of a roundabout with a higher priority road cutting through the central island.
public static final FormOfWay SLIPROAD
Road especially designed to enter or exit another road.
public static final FormOfWay PEDESTRIAN_ZONE
Road within an area specially designed for use by pedestrians.
public static final FormOfWay PEDESTRIAN_WALKWAY
Paved or unpaved road for exclusive pedestrian use.
public static final FormOfWay SERVICE_ACCESS_PARKING
Deprecated: As of Release 3.4.
Road specially designed to enter or to leave a parking area.
public static final FormOfWay SERVICE_ACCESS_OTHER
Deprecated: As of Release 3.4.
Road designed to enter or to leave an uncategorized area.
public static final FormOfWay SERVICE_ROAD
Deprecated: As of Release 3.4.
Road running parallel to, and designed to connect, a road with a relatively high connectivity function with roads with a
lower connectivity function.
public static final FormOfWay SERVICE_ACCESS
Road running parallel to, and designed to connect, a road with a relatively high connectivity function with roads with a
lower connectivity function.
public static final FormOfWay ETA_PARKING_PLACE
Enclosed traffic area parking within a malls and shopping centers.
public static final FormOfWay ETA_PARKING_BUILDING
Enclosed traffic area parking within a building (also known as a parkage or parking garage).
public static final FormOfWay ETA_UNSTRUCTURED_TRAFFIC_SQUARE
Enclosed traffic area, (partly) enclosed by roads which is used for non-traffic purposes and which is not a roundabout.
public static final FormOfWay ROAD_FOR_AUTHORITIES
Road strictly used by security vehicles.
HERE Android SDK Developer's Guide
API Reference
552
Method Summary
Table 185: Methods in FormOfWay
Methods
public static FormOfWay valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RoadElement.FormOfWay[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Form of Way Types
Enum Constant Details
public static final FormOfWay UNDEFINED
Road form of way is undefined/unknown.
public static final FormOfWay MOTORWAY
Road to which regulations will normally apply with regards to entry and use. It has two or more mostly
physically separated carriageways and no single level-crossings. Also known as a freeway or expressway.
public static final FormOfWay MULTI_CARRIAGEWAY
Road with physically separated carriageways regardless of the number of lanes, which is not a motorway or a
freeway.
public static final FormOfWay SINGLE_CARRIAGEWAY
Road where the traffic is not separated by any physical object.
public static final FormOfWay ROUNDABOUT
Road which forms a ring on which traffic travelling in only one direction is allowed.
public static final FormOfWay SPECIAL_TRAFFIC_FIGURE
Road that is part of a roundabout with a higher priority road cutting through the central island.
public static final FormOfWay SLIPROAD
HERE Android SDK Developer's Guide
API Reference
553
Road especially designed to enter or exit another road.
public static final FormOfWay PEDESTRIAN_ZONE
Road within an area specially designed for use by pedestrians.
public static final FormOfWay PEDESTRIAN_WALKWAY
Paved or unpaved road for exclusive pedestrian use. These walkways are closed to bicycles and normal
vehicles.
public static final FormOfWay SERVICE_ACCESS_PARKING
Deprecated: As of Release 3.4.
No longer supported. No roads will have this form of way value.
Road specially designed to enter or to leave a parking area.
public static final FormOfWay SERVICE_ACCESS_OTHER
Deprecated: As of Release 3.4.
No longer supported. No roads will have this form of way value.
Road designed to enter or to leave an uncategorized area.
public static final FormOfWay SERVICE_ROAD
Deprecated: As of Release 3.4.
No longer supported. It is now replaced with SERVICE_ACCESS
Road running parallel to, and designed to connect, a road with a relatively high connectivity function with
roads with a lower connectivity function.
public static final FormOfWay SERVICE_ACCESS
Road running parallel to, and designed to connect, a road with a relatively high connectivity function with
roads with a lower connectivity function.
public static final FormOfWay ETA_PARKING_PLACE
Enclosed traffic area parking within a malls and shopping centers. At least two roads are connected to the
area.
public static final FormOfWay ETA_PARKING_BUILDING
HERE Android SDK Developer's Guide
API Reference
554
Enclosed traffic area parking within a building (also known as a parkage or parking garage). At least two
roads are connected to the area.
public static final FormOfWay ETA_UNSTRUCTURED_TRAFFIC_SQUARE
Enclosed traffic area, (partly) enclosed by roads which is used for non-traffic purposes and which is not a
roundabout.
public static final FormOfWay ROAD_FOR_AUTHORITIES
Road strictly used by security vehicles.
Method Details
public static FormOfWay valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RoadElement.FormOfWay[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
PluralType
The enumeration PluralType is a member of com.here.android.mpa.common.RoadElement.
Enumeration Summary
public static final enumeration RoadElement.PluralType
extends java.lang.Enum, java.lang.Object
Plural type identifies when a Junction is made up of multiple Road Elements.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
555
Enum Constant Summary
Table 186: Enum Constants in PluralType
Fields
public static final PluralType NONE
Junction is not plural
public static final PluralType MANEUVER
Indicates that only one command should be given despite the fact that two Junctions occur; one at each end of the turn
lane.
public static final PluralType CONNECTOR
Indicates that a road segment should not be viewed as an individual piece of road but as part of the intersection.
public static final PluralType INDETERMINATE
Indicates a maneuver that cannot be explained in one command or at all.
Method Summary
Table 187: Methods in PluralType
Methods
public static PluralType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RoadElement.PluralType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Plural type identifies when a Junction is made up of multiple Road Elements. It also implies that a maneuver
may require different explanation than implied by the geometry.
Enum Constant Details
public static final PluralType NONE
Junction is not plural
public static final PluralType MANEUVER
Indicates that only one command should be given despite the fact that two Junctions occur; one at each end
of the turn lane. It is only necessary to state "turn right" near the beginning of the maneuver because at the
end the driver does not have a choice in direction.
public static final PluralType CONNECTOR
HERE Android SDK Developer's Guide
API Reference
556
Indicates that a road segment should not be viewed as an individual piece of road but as part of the
intersection. A separate guidance maneuver should not exist for this segment. For example, if making a u-
turn in Example A in Figure 4B-113, the driver should receive the instruction to "make the u-turn" and not
"turn left, turn left".
public static final PluralType INDETERMINATE
Indicates a maneuver that cannot be explained in one command or at all. A graphic may be needed to
illustrate the turn. In these situations a driver may need to go right to make a left turn.
Method Details
public static PluralType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RoadElement.PluralType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Size
The class Size is a member of com.here.android.mpa.common .
Class Summary
public final class Size
extends java.lang.Object
Represents size in pixels
[For complete information, see the section Class Details]
Constructor Summary
Table 188: Constructors in Size
Constructors
Size ()
Public constructor
HERE Android SDK Developer's Guide
API Reference
557
Constructors
Size (int width, int height)
Public constructor
Field Summary
Table 189: Fields in Size
Fields
public int height
Height of the screen in pixels
public int width
Width if the screen in pixels
Method Summary
Table 190: Methods in Size
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public int hashCode ()
For documentation, see java.lang.Object
public boolean isNull ()
Has no dimensions
Class Details
Represents size in pixels
Constructor Details
Size ()
Public constructor
Size (int width, int height)
Public constructor
Parameters:
width
Width of screen in pixels
height
HERE Android SDK Developer's Guide
API Reference
558
Height of screen in pixels
Field Details
public int height
Height of the screen in pixels
public int width
Width if the screen in pixels
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public int hashCode ()
For documentation, see java.lang.Object
public boolean isNull ()
Has no dimensions
Returns:
Whether this object has no width and height
TimeInterval
The class TimeInterval is a member of com.here.android.mpa.common .
Class Summary
public final class TimeInterval
extends java.lang.Object
This is the definition of the TimeInterval class.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
559
Method Summary
Table 191: Methods in TimeInterval
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public Date getEndTime ()
gets the end time for the TimeInterval
public Date getStartTime ()
gets the start time for the TimeInterval
public int hashCode ()
For documentation, see java.lang.Object
Class Details
This is the definition of the TimeInterval class. A TimeInterval describes the start time and end time of any
event
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public Date getEndTime ()
gets the end time for the TimeInterval
Returns:
End time as a java.util.Date object.
public Date getStartTime ()
gets the start time for the TimeInterval
Returns:
start time as a java.util.Date object.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
560
TransitType
The enumeration TransitType is a member of com.here.android.mpa.common .
Enumeration Summary
public final enumeration TransitType
extends java.lang.Enum, java.lang.Object
Represents values describing the types of transit that an application user might take.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 192: Enum Constants in TransitType
Fields
public static final TransitType BUS_PUBLIC
A public bus.
public static final TransitType BUS_TOURISTIC
A tourist bus.
public static final TransitType BUS_INTERCITY
An intercity bus.
public static final TransitType BUS_EXPRESS
An express bus.
public static final TransitType RAIL_METRO
A metro railway.
public static final TransitType RAIL_LIGHT
A light railway.
public static final TransitType RAIL_REGIONAL
A regional railway.
public static final TransitType TRAIN_REGIONAL
A regional train.
public static final TransitType TRAIN_INTERCITY
An intercity train.
public static final TransitType TRAIN_HIGH_SPEED
A high-speed train.
HERE Android SDK Developer's Guide
API Reference
561
Fields
public static final TransitType MONORAIL
Monorail
public static final TransitType AERIAL
Aerial transit.
public static final TransitType INCLINED
Inclined transit.
public static final TransitType WATER
A water taxi or ferry.
public static final TransitType AIRLINE
An airline.
public static final TransitType UNKNOWN
An unknown transit type.
public static final TransitType TRAIN_INTERREGIONAL_AND_FAST
An inter-regional and fast train.
public static final TransitType ORDERED_SERVICES_OR_TAXI
An ordered services or taxi.
Method Summary
Table 193: Methods in TransitType
Methods
public static TransitType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the types of transit that an application user might take.
Enum Constant Details
public static final TransitType BUS_PUBLIC
A public bus.
public static final TransitType BUS_TOURISTIC
A tourist bus.
HERE Android SDK Developer's Guide
API Reference
562
public static final TransitType BUS_INTERCITY
An intercity bus.
public static final TransitType BUS_EXPRESS
An express bus.
public static final TransitType RAIL_METRO
A metro railway.
public static final TransitType RAIL_LIGHT
A light railway.
public static final TransitType RAIL_REGIONAL
A regional railway. Usually represents in-city services (such as commuter rail, RER, SBahn) that have a high
frequency and lower speed.
public static final TransitType TRAIN_REGIONAL
A regional train. Usually represents intercity services (such as an Amtrak, DB, SNCF) that are infrequent and
travel at high speeds.
public static final TransitType TRAIN_INTERCITY
An intercity train.
public static final TransitType TRAIN_HIGH_SPEED
A high-speed train.
public static final TransitType MONORAIL
Monorail
public static final TransitType AERIAL
Aerial transit.
HERE Android SDK Developer's Guide
API Reference
563
public static final TransitType INCLINED
Inclined transit.
public static final TransitType WATER
A water taxi or ferry.
public static final TransitType AIRLINE
An airline.
public static final TransitType UNKNOWN
An unknown transit type.
public static final TransitType TRAIN_INTERREGIONAL_AND_FAST
An inter-regional and fast train.
public static final TransitType ORDERED_SERVICES_OR_TAXI
An ordered services or taxi.
Method Details
public static TransitType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UnintializedMapEngineException
The class UnintializedMapEngineException is a member of com.here.android.mpa.common .
HERE Android SDK Developer's Guide
API Reference
564
Class Summary
public final class UnintializedMapEngineException
extends java.lang.RuntimeException, java.lang.Exception, java.lang.Throwable, java.lang.Object
UnintializedMapEngineException will be thrown if any object that require the MapEngine to be initialized is
used without the initialized been initialized.
[For complete information, see the section Class Details]
Constructor Summary
Table 194: Constructors in UnintializedMapEngineException
Constructors
UnintializedMapEngineException ()
Default constructor
Class Details
UnintializedMapEngineException will be thrown if any object that require the MapEngine to be initialized is
used without the initialized been initialized.
Constructor Details
UnintializedMapEngineException ()
Default constructor
Vector3f
The class Vector3f is a member of com.here.android.mpa.common .
Class Summary
public final class Vector3f
extends java.lang.Object
Vector3f represents a 3D-Vector, capable to store x-,y- and z-coordinates in float values.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
565
Constructor Summary
Table 195: Constructors in Vector3f
Constructors
Vector3f ()
Constructs and initializes a Vector3f to (0f,0f,0f).
Vector3f (float x, float y, float z)
Constructs and initializes a Vector3f from the specified xyz coordinates.
Method Summary
Table 196: Methods in Vector3f
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public float getX ()
Retrieves the x-component of the vector.
public float getY ()
Retrieves the y-component of the vector.
public float getZ ()
Retrieves the z-component of the vector.
public int hashCode ()
For documentation, see java.lang.Object
public void setX (float x)
Sets the x-component of the vector.
public void setY (float y)
Sets the y-component of the vector.
public void setZ (float z)
Sets the z-component of the vector.
public String toString ()
For documentation, see java.lang.Object
Class Details
Vector3f represents a 3D-Vector, capable to store x-,y- and z-coordinates in float values.
Constructor Details
Vector3f ()
HERE Android SDK Developer's Guide
API Reference
566
Constructs and initializes a Vector3f to (0f,0f,0f).
Vector3f (float x, float y, float z)
Constructs and initializes a Vector3f from the specified xyz coordinates.
Parameters:
x
the x coordinate
y
the y coordinate
z
the z coordinate
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public float getX ()
Retrieves the x-component of the vector.
Returns:
float representing the x component of the vector.
public float getY ()
Retrieves the y-component of the vector.
Returns:
float representing the y component of the vector.
public float getZ ()
Retrieves the z-component of the vector.
Returns:
float representing the z component of the vector.
HERE Android SDK Developer's Guide
API Reference
567
public int hashCode ()
For documentation, see java.lang.Object
public void setX (float x)
Sets the x-component of the vector.
Parameters:
x
A float value for the x component of the vector.
public void setY (float y)
Sets the y-component of the vector.
Parameters:
y
A float value for the y component of the vector.
public void setZ (float z)
Sets the z-component of the vector.
Parameters:
z
A float value for the z component of the vector.
public String toString ()
For documentation, see java.lang.Object
Version
The class Version is a member of com.here.android.mpa.common .
Class Summary
public final class Version
extends java.lang.Object
Version information for the HERE SDK for Android.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
568
Constructor Summary
Table 197: Constructors in Version
Constructors
Version ()
Method Summary
Table 198: Methods in Version
Methods
public static String getSdkVersion ()
Returns the version of the SDK in the form "major.minor.patch.build number"
Class Details
Version information for the HERE SDK for Android.
Constructor Details
Version ()
Method Details
public static String getSdkVersion ()
Returns the version of the SDK in the form "major.minor.patch.build number"
Returns:
The SDK Version
ViewObject
The class ViewObject is a member of com.here.android.mpa.common .
Class Summary
public abstract class ViewObject
extends java.lang.Object
Represents the base class implementation for all objects that are selectable from a view.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
569
Nested Class Summary
Table 199: Nested Classes in ViewObject
Nested Classes
public static final enumeration ViewObject.Type
Represents values describing various types of selectable view objects.
Method Summary
Table 200: Methods in ViewObject
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Type getBaseType ()
Returns the real implementation type of the ViewObject .
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents the base class implementation for all objects that are selectable from a view.
Selectable objects are featured on these views:
MapFragment
MapView
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public Type getBaseType ()
Returns the real implementation type of the ViewObject .
Returns:
The ViewObject.Type ViewObjectType, either a USER_OBJECT or a PROXY_OBJECT.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
570
For documentation, see java.lang.Object
Type
The enumeration Type is a member of com.here.android.mpa.common.ViewObject.
Enumeration Summary
public static final enumeration ViewObject.Type
extends java.lang.Enum, java.lang.Object
Represents values describing various types of selectable view objects.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 201: Enum Constants in Type
Fields
public static final Type USER_OBJECT
Describes the type of view objects that are added by the application, such as MapMarker.
public static final Type PROXY_OBJECT
Describes the type of view objects that are provided automatically, such as TransitLineObject, TransitStopObject or
TransitAccessObject .
public static final Type UNKNOWN_OBJECT
Describes the type of view objects that are neither a USER_OBJECT nor a PROXY_OBJECT .
Method Summary
Table 202: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ViewObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing various types of selectable view objects.
HERE Android SDK Developer's Guide
API Reference
571
Enum Constant Details
public static final Type USER_OBJECT
Describes the type of view objects that are added by the application, such as MapMarker.
public static final Type PROXY_OBJECT
Describes the type of view objects that are provided automatically, such as TransitLineObject,
TransitStopObject or TransitAccessObject . A proxy object may contain special information about the object,
depending on the type (for example, TransitStopObject may provide transit stop-related information),
but it cannot be created or modified.
public static final Type UNKNOWN_OBJECT
Describes the type of view objects that are neither a USER_OBJECT nor a PROXY_OBJECT .
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ViewObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ViewRect
The class ViewRect is a member of com.here.android.mpa.common .
Class Summary
public final class ViewRect
extends java.lang.Object
Represents a rectangle defined by the top-left corner's coordinate and the width and height of the rectangle.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
572
Constructor Summary
Table 203: Constructors in ViewRect
Constructors
ViewRect (int x, int y, int width, int height)
Constructor that initializes specified X and Y coordinates of the top-left corner plus width and height values, in pixels, for
the new ViewRect object.
Method Summary
Table 204: Methods in ViewRect
Methods
public boolean equals (Object other)
Determines whether the specified Object is equal to this ViewRect object.
public int getHeight ()
Gets the current height, in pixels, of the ViewRect .
public int getWidth ()
Gets the current width, in pixels, of the ViewRect .
public int getX ()
Gets the current X-coordinate of the ViewRect .
public int getY ()
Gets the current Y-coordinate of the ViewRect .
public int hashCode ()
Calculates and returns a hash code value for the ViewRect .
public boolean isValid ()
Determines whether the ViewRect object is valid.
public void setHeight (int height)
Sets a height, in pixels, for the ViewRect .
public void setWidth (int width)
Sets a width, in pixels, for the ViewRect .
public void setX (int x)
Sets an X-coordinate for the ViewRect .
public void setY (int y)
Sets a Y-coordinate for the ViewRect .
Class Details
Represents a rectangle defined by the top-left corner's coordinate and the width and height of the rectangle.
HERE Android SDK Developer's Guide
API Reference
573
Constructor Details
ViewRect (int x, int y, int width, int height)
Constructor that initializes specified X and Y coordinates of the top-left corner plus width and height values,
in pixels, for the new ViewRect object.
Parameters:
x
An initial X-coordinate for the left side of the rectangle
y
An initial Y-coordinate for the top of the rectangle
width
An initial width for the rectangle
height
An initial height for the rectangle
Method Details
public boolean equals (Object other)
Determines whether the specified Object is equal to this ViewRect object.
Parameters:
other
An Object to compare with this ViewRect object for equality
Returns:
True if the compared objects are equal, false otherwise
public int getHeight ()
Gets the current height, in pixels, of the ViewRect .
Returns:
The current height
public int getWidth ()
Gets the current width, in pixels, of the ViewRect .
Returns:
The current width
HERE Android SDK Developer's Guide
API Reference
574
public int getX ()
Gets the current X-coordinate of the ViewRect .
Returns:
The current X-coordinate
public int getY ()
Gets the current Y-coordinate of the ViewRect .
Returns:
The current Y-coordinate
public int hashCode ()
Calculates and returns a hash code value for the ViewRect .
Returns:
The hash code
public boolean isValid ()
Determines whether the ViewRect object is valid.
Returns:
True if the ViewRect is valid, false otherwise
public void setHeight (int height)
Sets a height, in pixels, for the ViewRect .
Parameters:
height
Desired height
public void setWidth (int width)
Sets a width, in pixels, for the ViewRect .
Parameters:
width
Desired width
HERE Android SDK Developer's Guide
API Reference
575
public void setX (int x)
Sets an X-coordinate for the ViewRect .
Parameters:
x
Desired X-coordinate
public void setY (int y)
Sets a Y-coordinate for the ViewRect .
Parameters:
y
Desired Y-coordinate
customlocation2
The package customlocation2 is a member of com.here.android.mpa.
Package Summary
customlocation2
This package provides classes and interfaces that support the more advanced version of custom location
search.
Package Details
This package provides classes and interfaces that support the more advanced version of custom location
search.
The following type of search is available:
Proximity - Search for user-defined locations around a specified point
To perform a search, create a request of the desired search type and execute the request. For example:
CLE2ProximityRequest request = new CLE2ProximityRequest("layer_id", new GeoCoordinate(11.11,
11.11), 100);
request.execute(new CLE2ResultListener() { ... });
For more information on how to use this feature, please see the "Custom Location Search 2" section in the
HERE SDK for Android Developer's Guide
HERE Android SDK Developer's Guide
API Reference
576
CLE2AttributeRequest
The class CLE2AttributeRequest is a member of com.here.android.mpa.customlocation2 .
Class Summary
public class CLE2AttributeRequest
extends com.here.android.mpa.customlocation2.CLE2Request, java.lang.Object
Represents a custom geometry search request to retrieve all user-defined geometries along with its attribute
on a specified layer.
[For complete information, see the section Class Details]
Constructor Summary
Table 205: Constructors in CLE2AttributeRequest
Constructors
CLE2AttributeRequest (String layerId)
Creates an Attribute Request.
Class Details
Represents a custom geometry search request to retrieve all user-defined geometries along with its attribute
on a specified layer.
Constructor Details
CLE2AttributeRequest (String layerId)
Creates an Attribute Request.
Please note that CLE2AttributeRequest only supports CLE2GeometryType#FULL.
Parameters:
layerId
Name of layer specifying the layer to search.
Throws:
IllegalArgumentException
if layerId is invalid.
CLE2BoundingBoxRequest
The class CLE2BoundingBoxRequest is a member of com.here.android.mpa.customlocation2 .
HERE Android SDK Developer's Guide
API Reference
577
Class Summary
public class CLE2BoundingBoxRequest
extends com.here.android.mpa.customlocation2.CLE2Request, java.lang.Object
Represents a custom location search request that uses a bounding box to retrieve user-defined geometries.
[For complete information, see the section Class Details]
Constructor Summary
Table 206: Constructors in CLE2BoundingBoxRequest
Constructors
CLE2BoundingBoxRequest (String layerId, GeoBoundingBox area)
Creates a Bounding Box Geometry Request
Class Details
Represents a custom location search request that uses a bounding box to retrieve user-defined geometries.
This type of request is used to search for user-defined geometries intersecting a specified bounding box.
A new CLE2BoundingBoxRequest should be created for each search.
Constructor Details
CLE2BoundingBoxRequest (String layerId, GeoBoundingBox area)
Creates a Bounding Box Geometry Request
Parameters:
layerId
Name of layer specifying the layer to search.
area
A GeoBoundingBox specifying the area to search.
Throws:
IllegalArgumentException
if area is invalid.
IllegalArgumentException
if area is empty.
CLE2CorridorRequest
The class CLE2CorridorRequest is a member of com.here.android.mpa.customlocation2 .
HERE Android SDK Developer's Guide
API Reference
578
Class Summary
public class CLE2CorridorRequest
extends com.here.android.mpa.customlocation2.CLE2Request, java.lang.Object
Represents an corridor custom location search request to retrieve user-defined geometries previously stored
using one or more search filter(s).
[For complete information, see the section Class Details]
Constructor Summary
Table 207: Constructors in CLE2CorridorRequest
Constructors
CLE2CorridorRequest (String layerId, java.util.List <GeoCoordinate> routeCoordinates, int radius)
Creates an Corridor Request using an array of coordinates defining a route.
Class Details
Represents an corridor custom location search request to retrieve user-defined geometries previously stored
using one or more search filter(s).
This searches for user-defined geometries within the radius of a specified route or the radius of a specified
list of GeoCoordinates.
A new CLE2CorridorRequest should be created for each search.
Constructor Details
CLE2CorridorRequest (String layerId, java.util.List <GeoCoordinate>
routeCoordinates, int radius)
Creates an Corridor Request using an array of coordinates defining a route.
Parameters:
layerId
Name of layer specifying the layer to search.
routeCoordinates
A List of GeoCoordinates representing the polyline used as a corridor center line representing a route.
radius
An int specifying the search radius in meters.
Throws:
IllegalArgumentException
if layerId is invalid.
IllegalArgumentException
if routeCoordinates is null or does not contain at least two GeoCoordinates.
HERE Android SDK Developer's Guide
API Reference
579
IllegalArgumentException
if radius is smaller than or equal to zero.
CLE2DataManager
The class CLE2DataManager is a member of com.here.android.mpa.customlocation2 .
Class Summary
public class CLE2DataManager
extends java.lang.Object
This class is responsible for managing layer data for CLE2 offline use.
[For complete information, see the section Class Details]
Nested Class Summary
Table 208: Nested Classes in CLE2DataManager
Nested Classes
public static abstract interface CLE2DataManager.CLE2DownloadListener
Represents a listener that reports information about the completion of layer download.
public static final enumeration CLE2DataManager.OperationType
Indicated type of operation performed on CLE2 data.
public static final enumeration CLE2DataManager.StorageType
Indicates which class of storage was affected by the data operation.
Method Summary
Table 209: Methods in CLE2DataManager
Methods
public boolean cancelAllLayerDowloads ()
Deprecated: Deprecated as of release 3.4.
Attempts to cancel execution of all ongoing downloads.
public boolean cancelDownload (String layerId)
Deprecated: Deprecated as of release 3.4.
Attempts to cancel execution of a specific layer download.
public boolean deleteAll ()
Deprecated: Deprecated as of release 3.4.
Removes all data from the local storage.
HERE Android SDK Developer's Guide
API Reference
580
Methods
public boolean deleteLayer (String layerId)
Deprecated: Deprecated as release of 3.4.
Delete one specific layer from the local storage.
public void downloadLayer (String layerId, CLE2DownloadListener listener)
Deprecated: Deprecated as of release 3.4.
Request the full download of a specific layer if layer doesn't exist locally and layer is not updated with server data.
public boolean equals (Object other)
For documentation, see java.lang.Object
public static CLE2DataManager getInstance ()
Returns the CLE2DataManager singleton instance.
public int getNumberOfStoredGeometries (String layerId)
Get the number of geometries stored of a given layer.
public int hashCode ()
For documentation, see java.lang.Object
public CLE2Task<CLE2OperationResult> newDeleteLayersTask (List layerIds, StorageType storageType)
Creates a task for deleting specified layers from the service or local storage.
public CLE2Task<CLE2OperationResult> newDownloadLayerTask (String layerId)
Creates a task for downloading a layer from CLE2 service and storing it in local storage.
public CLE2Task<CLE2Geometry> newFetchLocalLayersTask (List layerIds)
Creates a task for retrieving all geometries from specified locally stored layers.
public CLE2Task<CLE2OperationResult> newGeometryTask (OperationType operationType, String layerId,
java.util.List <CLE2Geometry> geometryData, StorageType storageType)
Creates a task for modifying CLE data.
public CLE2Task<String, CLE2LayerMetadata> newListLayersTask (StorageType storageType)
Creates a CLE2 task for getting a list of available layers.
public CLE2Task<CLE2OperationResult> newPurgeLocalStorageTask ()
Creates a task for removing all data from local storage.
public CLE2Task<CLE2OperationResult> newUploadLayerTask (String layerId, java.util.List
<CLE2Geometry> geometryData)
Creates a task for uploading a new layer into CLE service, creating a new layer with specified ID.
Class Details
This class is responsible for managing layer data for CLE2 offline use. To download a full layer, call
downloadLayer(String, CLE2DataManager.CLE2DownloadListener). To store a subset of geometries, create a
CLE2Request and setCachingEnabled(boolean) to true.
HERE Android SDK Developer's Guide
API Reference
581
Method Details
public boolean cancelAllLayerDowloads ()
Deprecated: Deprecated as of release 3.4.
Keep track of your download tasks and use cancel() instead
Attempts to cancel execution of all ongoing downloads. This attempt will fail if the task has already
completed, already been cancelled, or could not be cancelled for some other reason. This call does not
guarantee that any download task will be cancelled. For the end result, inspect CLE2ErrorCode value
obtained from CLE2Error object passed to the listener.
Returns:
true if there was at least one outstanding download task for which cancellation will be attempted; false
otherwise
public boolean cancelDownload (String layerId)
Deprecated: Deprecated as of release 3.4.
Use cancel() on a download task obtained from newDownloadLayerTask(String)
Attempts to cancel execution of a specific layer download. This attempt will fail if the task has already
completed, already been cancelled, or could not be cancelled for some other reason. This call does not
guarantee that the download job will be cancelled. For the end result, inspect CLE2ErrorCode value obtained
from CLE2Error object passed to the listener.
Parameters:
layerId
Name of the layer specifying which download should stop.
Returns:
true if there was a download task for specified layer for which cancellation will be attempted; false
otherwise
public boolean deleteAll ()
Deprecated: Deprecated as of release 3.4.
Use newPurgeLocalStorageTask()
Removes all data from the local storage. This method is synchronous and blocks until database operation is
finished, which in some circumstances can take some time.
Returns:
true if the operation was successful.
public boolean deleteLayer (String layerId)
Deprecated: Deprecated as release of 3.4.
HERE Android SDK Developer's Guide
API Reference
582
Use newDeleteLayersTask(List, CLE2DataManager.StorageType) with LOCAL instead
Delete one specific layer from the local storage. This method is synchronous and blocks until database
operation is finished, which in some circumstances can take some time.
Parameters:
layerId
ID of a layer to remove from cache
Returns:
true if operation successful, false otherwise
public void downloadLayer (String layerId, CLE2DownloadListener listener)
Deprecated: Deprecated as of release 3.4.
Use newDownloadLayerTask(String) instead
Request the full download of a specific layer if layer doesn't exist locally and layer is not updated with server
data.
Please note that this method will make two request. One for checking updates and another for downloading.
If local stored data is up to date with server data, no downloading will happen.
Parameters:
layerId
Name of a layer to download
listener
listener to notify result of operation.
Throws:
IllegalArgumentException
if layerId is null or empty
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public static CLE2DataManager getInstance ()
Returns the CLE2DataManager singleton instance.
Returns:
CLE2LayerDownloader instance.
HERE Android SDK Developer's Guide
API Reference
583
public int getNumberOfStoredGeometries (String layerId)
Get the number of geometries stored of a given layer.
Parameters:
layerId
The number of geometries of this layer will be returned.
Returns:
number of geometries stored for a given layer.
public int hashCode ()
For documentation, see java.lang.Object
public CLE2Task<CLE2OperationResult> newDeleteLayersTask (List layerIds,
StorageType storageType)
Creates a task for deleting specified layers from the service or local storage.
When operating on local storage, this operation will delete all data for specified layers, regardless of how
they got there (ie. search result caching or downloading of whole layer).
Parameters:
layerIds
the list of IDs of layers to remove
storageType
the location of data to be deleted
Returns:
a CLE2 task for removing a layer from the service
Throws:
IllegalArgumentException
if layerIds is null, empty or contains null or empty strings
public CLE2Task<CLE2OperationResult> newDownloadLayerTask (String layerId)
Creates a task for downloading a layer from CLE2 service and storing it in local storage.
When started, this operation will check if locally stored layer exists and if it's out of date before downloading
data from the service. As such, no unnecessary download will take place if local data is up to date with the
service.
Upon success, all data stored locally for the specified layer are the same as on the server at the time of
download.
Parameters:
HERE Android SDK Developer's Guide
API Reference
584
layerId
id of layer to download
Returns:
a CLE2 task for downloading the layer
Throws:
IllegalArgumentException
if @{code layerId} is null or empty
public CLE2Task<CLE2Geometry> newFetchLocalLayersTask (List layerIds)
Creates a task for retrieving all geometries from specified locally stored layers.
Parameters:
layerIds
the list of ids of layers to retrieve data for
Returns:
a CLE2 task for retrieving the geometry data
Throws:
IllegalArgumentException
if layerIds is null, empty or contains null or empty strings
public CLE2Task<CLE2OperationResult> newGeometryTask (OperationType
operationType, String layerId, java.util.List <CLE2Geometry> geometryData,
StorageType storageType)
Creates a task for modifying CLE data. The nature of the modification is determined by the operationType
and can be creation of new data items, updating of existing ones or deleting.
For local storage, running CREATE on a layer that does not exist will create it. For remote storage it will fail if
the layer does not already exist in the service. To create a new remote layer, use newUploadLayerTask(String,
List).
Parameters:
operationType
type of operation to perform
layerId
id of layer to perform the operation on
geometryData
the data to be used for the operation
storageType
determines whether to modify locally stored data or remote ones
HERE Android SDK Developer's Guide
API Reference
585
Returns:
a CLE2 task for modifying data
Throws:
IllegalArgumentException
if @{code layerId} is null or empty or @{code geometryData} is null or empty or contains @{code null}
elements
public CLE2Task<String, CLE2LayerMetadata> newListLayersTask (StorageType
storageType)
Creates a CLE2 task for getting a list of available layers. You can specify whether to retrieve it from the CLE2
service or from local storage. In case of local storage, only layers downloaded using downloadLayer(String,
CLE2DataManager.CLE2DownloadListener) will be listed.
The result of this task is a map where the key is a layer ID and the value is a metadata object for this layer.
Parameters:
storageType
LOCAL to list layers only from local storage, REMOTE to list layers only from remote CLE2 service
Returns:
a CLE2 task for getting a list of available layers.
public CLE2Task<CLE2OperationResult> newPurgeLocalStorageTask ()
Creates a task for removing all data from local storage.
Returns:
a CLE2 task for purging all data from local storage
public CLE2Task<CLE2OperationResult> newUploadLayerTask (String layerId,
java.util.List <CLE2Geometry> geometryData)
Creates a task for uploading a new layer into CLE service, creating a new layer with specified ID. Provided
layer ID will be converted to all upper-case by CLE service. If a layer with the same ID already exist, it will be
replaced by this one. This operation does not impact locally stored data. Note that layer data needs to be
uniform, meaning all geometries be of the same type and have the same set of attributes.
Parameters:
layerId
the id of layer to upload
geometryData
geometry data to upload
HERE Android SDK Developer's Guide
API Reference
586
Returns:
a CLE2 task for uploading the layer
Throws:
IllegalArgumentException
if @{code layerId} is null or empty or @{code geometryData} is null or empty or contains @{code null}
elements
CLE2DownloadListener
The interface CLE2DownloadListener is a member of
com.here.android.mpa.customlocation2.CLE2DataManager.
Interface Summary
public static abstract interface CLE2DataManager.CLE2DownloadListener
Represents a listener that reports information about the completion of layer download.
[For complete information, see the section Interface Details]
Method Summary
Table 210: Methods in CLE2DownloadListener
Methods
public abstract void onLayerDownloaded (String layerId, CLE2Error error)
A callback indicating the completion of layer download request.
Interface Details
Represents a listener that reports information about the completion of layer download.
Method Details
public abstract void onLayerDownloaded (String layerId, CLE2Error error)
A callback indicating the completion of layer download request.
Parameters:
layerId
Name of downloaded layer
error
CLE2Error to get the status of request.
HERE Android SDK Developer's Guide
API Reference
587
OperationType
The enumeration OperationType is a member of com.here.android.mpa.customlocation2.CLE2DataManager.
Enumeration Summary
public static final enumeration CLE2DataManager.OperationType
extends java.lang.Enum, java.lang.Object
Indicated type of operation performed on CLE2 data.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 211: Enum Constants in OperationType
Fields
public static final OperationType CREATE
Indicates creation of new data.
public static final OperationType UPDATE
Indicates modification of existing data.
public static final OperationType DELETE
Indicates removal of existing data.
Method Summary
Table 212: Methods in OperationType
Methods
public static OperationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CLE2DataManager.OperationType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Indicated type of operation performed on CLE2 data.
Enum Constant Details
public static final OperationType CREATE
Indicates creation of new data.
HERE Android SDK Developer's Guide
API Reference
588
public static final OperationType UPDATE
Indicates modification of existing data.
public static final OperationType DELETE
Indicates removal of existing data.
Method Details
public static OperationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CLE2DataManager.OperationType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StorageType
The enumeration StorageType is a member of com.here.android.mpa.customlocation2.CLE2DataManager.
Enumeration Summary
public static final enumeration CLE2DataManager.StorageType
extends java.lang.Enum, java.lang.Object
Indicates which class of storage was affected by the data operation.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 213: Enum Constants in StorageType
Fields
public static final StorageType REMOTE
Indicates that a data operation was applied only to data on the remote CLE2 service.
public static final StorageType LOCAL
Indicates that a data operation was applied only to data stored locally.
HERE Android SDK Developer's Guide
API Reference
589
Method Summary
Table 214: Methods in StorageType
Methods
public static StorageType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CLE2DataManager.StorageType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Indicates which class of storage was affected by the data operation.
Enum Constant Details
public static final StorageType REMOTE
Indicates that a data operation was applied only to data on the remote CLE2 service.
public static final StorageType LOCAL
Indicates that a data operation was applied only to data stored locally.
Method Details
public static StorageType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CLE2DataManager.StorageType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CLE2Geometry
The class CLE2Geometry is a member of com.here.android.mpa.customlocation2 .
HERE Android SDK Developer's Guide
API Reference
590
Class Summary
public class CLE2Geometry
extends java.lang.Object
Specifies a user-defined geometry.
[For complete information, see the section Class Details]
Method Summary
Table 215: Methods in CLE2Geometry
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Map getAttributes ()
Returns the Map of attributes containing a copy of the custom attributes of this CLE2Geometry
public double getDistance ()
Returns the minimum distance to the geometry from the point used in a search query.
public String getGeometryId ()
Identifier of a geometry object.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isLocal ()
Checks if this geometry is local to the device or if it came from remote CLE service.
public void setAttribute (String name, String value)
Set a value of an attribute for this geometry.
public void setAttributes (Map attributes)
Sets attributes of this geometry to the ones provided.
Class Details
Specifies a user-defined geometry. This geometry can be a PointGeometry , MultiPointGeometry,
PolylineGeometry, MultiPolylineGeometry, PolygonGeometry or MultiPolygonGeometry.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
591
public Map getAttributes ()
Returns the Map of attributes containing a copy of the custom attributes of this CLE2Geometry
Returns:
Map of attributes
public double getDistance ()
Returns the minimum distance to the geometry from the point used in a search query.
Returns:
A float representing distance of this geometry to the point used in the query or 0 if it is unknown or search
query was performed offline.
public String getGeometryId ()
Identifier of a geometry object. This identifier is guaranteed to be unique only within a single layer, meaning
that two geometry object belonging to different layers might have the same geometry ID. Only geometries
that were once stored locally or remotely have an ID. Meaning that a newly created geometry object does not
have an ID.
Returns:
identifier unique within a single layer or null if this geometry does not have an ID.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isLocal ()
Checks if this geometry is local to the device or if it came from remote CLE service. Geometry that is stored
locally but was initially retrieved from the server (for example, by downloading a whole layer or caching of
search results) is not considered local.
Returns:
false if source of this geometry is a remote CLE2 service, true otherwise
public void setAttribute (String name, String value)
Set a value of an attribute for this geometry.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
592
name of the attribute to set
value
value of the attribute to set
Throws:
IllegalArgumentException
if the name or value are null or name is an empty string.
public void setAttributes (Map attributes)
Sets attributes of this geometry to the ones provided. The content of the provided map is copied and any
changes made to it or the values within it afterwards have no effect on the attributes of this geometry object.
attributes can be null or empty and in both cases it will cause removal of all the attributes from this
geometry.
Parameters:
attributes
map of attributes to set for this geometry.
CLE2LayerMetadata
The class CLE2LayerMetadata is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2LayerMetadata
extends java.lang.Object
Encapsulates metadata describing a CLE2 layer.
[For complete information, see the section Class Details]
See also:
newListLayersTask(StorageType)
Method Summary
Table 216: Methods in CLE2LayerMetadata
Methods
public String getLayerId ()
Gets id (name) of the layer
public long getTimestamp ()
Gets the timestamp of a CLE2 layer.
HERE Android SDK Developer's Guide
API Reference
593
Class Details
Encapsulates metadata describing a CLE2 layer.
See also:
newListLayersTask(StorageType)
Method Details
public String getLayerId ()
Gets id (name) of the layer
Returns:
an id of the layer
public long getTimestamp ()
Gets the timestamp of a CLE2 layer. For layers on remote CLE2 service, this indicates time of last modification
of any data contained within the layer. For layers stored locally, this is a timestamp of a CLE2 layer as it was
at the time it was downloaded from remote CLE2 service. Layers that were created and stored locally do not
have a timestamp.
Returns:
a timestamp - number of milliseconds since Unix epoch or 0 for layers that did not originate from remote
CLE2 service
CLE2MultiPointGeometry
The class CLE2MultiPointGeometry is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2MultiPointGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined multi point geometry.
[For complete information, see the section Class Details]
Method Summary
Table 217: Methods in CLE2MultiPointGeometry
Methods
public java.util.List <GeoCoordinate> getMultiPoint ()
Gets a list of GeoCoordinate of this geometry.
HERE Android SDK Developer's Guide
API Reference
594
Methods
public void setMultiPoint (java.util.List <GeoCoordinate> points)
Sets the list of GeoCoordinate for this geometry.
Class Details
Specifies a user-defined multi point geometry. A multi point geometry represent a list of GeoCoordinate
Method Details
public java.util.List <GeoCoordinate> getMultiPoint ()
Gets a list of GeoCoordinate of this geometry.
Returns:
List of GeoCoordinate.
public void setMultiPoint (java.util.List <GeoCoordinate> points)
Sets the list of GeoCoordinate for this geometry.
Parameters:
points
List of GeoCoordinate.
Throws:
IllegalArgumentException
if points is empty or null.
CLE2MultiPolygonGeometry
The class CLE2MultiPolygonGeometry is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2MultiPolygonGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined multi-polygon geometry.
[For complete information, see the section Class Details]
See also:
CLE2PolygonGeometry
HERE Android SDK Developer's Guide
API Reference
595
Method Summary
Table 218: Methods in CLE2MultiPolygonGeometry
Methods
public java.util.List <CLE2PolygonGeometry> getPolygons ()
Gets all CLE2PolygonGeometry of this geometry.
public void setPolygons (java.util.List <CLE2PolygonGeometry> polygons)
Sets polygon geometries that make up this multi polygon geometry.
Class Details
Specifies a user-defined multi-polygon geometry. A multi-polygon geometry represent a list of
CLE2PolygonGeometry and each polygon can have outer and inner rings.
See also:
CLE2PolygonGeometry
Method Details
public java.util.List <CLE2PolygonGeometry> getPolygons ()
Gets all CLE2PolygonGeometry of this geometry.
Returns:
A list of all CLE2PolygonGeometry of this geometry.
public void setPolygons (java.util.List <CLE2PolygonGeometry> polygons)
Sets polygon geometries that make up this multi polygon geometry.
Parameters:
polygons
list of polygons to define this multi polygon geometry
Throws:
IllegalArgumentException
if the list of polygons is null, empty or contains null elements
CLE2MultiPolylineGeometry
The class CLE2MultiPolylineGeometry is a member of com.here.android.mpa.customlocation2 .
HERE Android SDK Developer's Guide
API Reference
596
Class Summary
public final class CLE2MultiPolylineGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined multi polyline geometry.
[For complete information, see the section Class Details]
Method Summary
Table 219: Methods in CLE2MultiPolylineGeometry
Methods
public java.util.List <MapPolyline> getMapPolylines ()
Gets the list of MapPolyline that are created from GeoPolyline to be added onto the map.
public java.util.List <GeoPolyline> getPolylines ()
Gets the list of GeoPolyline of this geometry.
public void setPolylines (java.util.List <GeoPolyline> polylines)
Sets a lists of polylines to define the shape of this CLE2MultiPolylineGeometry .
Class Details
Specifies a user-defined multi polyline geometry. A multi polyline geometry represent a list of GeoPolyline.
Method Details
public java.util.List <MapPolyline> getMapPolylines ()
Gets the list of MapPolyline that are created from GeoPolyline to be added onto the map.
Returns:
List of MapPolyline OR null if creating map polylines is not possible with GeoPolylines.
See also:
MapPolyline(GeoPolyline)
public java.util.List <GeoPolyline> getPolylines ()
Gets the list of GeoPolyline of this geometry.
Returns:
List of GeoPolyline.
public void setPolylines (java.util.List <GeoPolyline> polylines)
Sets a lists of polylines to define the shape of this CLE2MultiPolylineGeometry .
HERE Android SDK Developer's Guide
API Reference
597
Parameters:
polylines
list of polylines defining the shape of this CLE2MultiPolylineGeometry
Throws:
IllegalArgumentException
if polylines is null, empty or contains null or invalid (ie. containing less than two points) elements
CLE2OperationResult
The class CLE2OperationResult is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2OperationResult
extends java.lang.Object
Encapsulates information about CLE2 data change that was a result of a local or remote data operation.
[For complete information, see the section Class Details]
Constructor Summary
Table 220: Constructors in CLE2OperationResult
Constructors
CLE2OperationResult ()
Field Summary
Table 221: Fields in CLE2OperationResult
Fields
public static final long UNKNOWN_ITEM_COUNT
Method Summary
Table 222: Methods in CLE2OperationResult
Methods
public long getAffectedItemCount ()
Gets number of data items affected by the operation.
public List getAffectedLayerIds ()
Gets list of IDs of layers affected by the operation.
HERE Android SDK Developer's Guide
API Reference
598
Methods
public OperationType getOperationType ()
Class Details
Encapsulates information about CLE2 data change that was a result of a local or remote data operation.
Constructor Details
CLE2OperationResult ()
Field Details
public static final long UNKNOWN_ITEM_COUNT
Method Details
public long getAffectedItemCount ()
Gets number of data items affected by the operation.
Returns:
number of affected items or UNKNOWN_ITEM_COUNT if undetermined
public List getAffectedLayerIds ()
Gets list of IDs of layers affected by the operation.
Returns:
list of layer IDs or null if unknown
public OperationType getOperationType ()
Returns:
type of data operation
CLE2PointGeometry
The class CLE2PointGeometry is a member of com.here.android.mpa.customlocation2 .
HERE Android SDK Developer's Guide
API Reference
599
Class Summary
public final class CLE2PointGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined point geometry.
[For complete information, see the section Class Details]
Method Summary
Table 223: Methods in CLE2PointGeometry
Methods
public GeoCoordinate getPoint ()
Gets GeoCoordinate of this point geometry.
public void setPoint (GeoCoordinate point)
Set GeoCoordinate for this geometry.
Class Details
Specifies a user-defined point geometry. A point geometry represent a single GeoCoordinate
Method Details
public GeoCoordinate getPoint ()
Gets GeoCoordinate of this point geometry.
Returns:
GeoCoordinate of this geometry.
public void setPoint (GeoCoordinate point)
Set GeoCoordinate for this geometry.
Parameters:
point
GeoCoordinate.
Throws:
IllegalArgumentException
if point is null.
HERE Android SDK Developer's Guide
API Reference
600
CLE2PolygonGeometry
The class CLE2PolygonGeometry is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2PolygonGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined polygon geometry.
[For complete information, see the section Class Details]
Constructor Summary
Table 224: Constructors in CLE2PolygonGeometry
Constructors
CLE2PolygonGeometry (GeoPolygon outerRing, java.util.List <GeoPolygon> innerRings)
Creates a new polygon geometry with outer ring (shape) and inner rings (holes).
Method Summary
Table 225: Methods in CLE2PolygonGeometry
Methods
public java.util.List <GeoPolygon> getInnerRings ()
Gets the all inner ring of this geometry.
public GeoPolygon getOuterRing ()
Gets the outer ring GeoPolygon of this geometry.
public void setPolygon (GeoPolygon outerRing)
Sets the shape of this polygon to a solid one without any holes.
public void setPolygon (GeoPolygon outerRing, java.util.List <GeoPolygon> innerRings)
Sets the geometry of this polygon with outer ring (shape) and inner rings (holes).
Class Details
Specifies a user-defined polygon geometry. The polygon geometry represent a list of GeoPolygon
Note: The concept of polygon in WKT (Well Known Text) format consists of one outer ring/polygon, plus zero
or more inner rings/polygons. We map the WKT concept here with a GeoPolygon outer ring object, and a list
of GeoPolygon as the inner rings (if any).
HERE Android SDK Developer's Guide
API Reference
601
Constructor Details
CLE2PolygonGeometry (GeoPolygon outerRing, java.util.List <GeoPolygon>
innerRings)
Creates a new polygon geometry with outer ring (shape) and inner rings (holes). Input polygons can be
"closed" (ie. having the same first and last vertex) or not, both options are valid.
Parameters:
outerRing
the outer boundary of the polygon, defining its shape
innerRings
list if inner rings of the polygon, defining holes in the main shape, will be ignored if null or empty
Throws:
IllegalArgumentException
when outerRing is null or invalid, meaning it is not a polygon with an area greater than 0, or when
innerRings contains null or invalid elements
Method Details
public java.util.List <GeoPolygon> getInnerRings ()
Gets the all inner ring of this geometry. The polygons returned by this method are always "closed", meaning
that its last vertex is the same as the first one.
Returns:
a list of GeoPolygon defining holes in the polygon
public GeoPolygon getOuterRing ()
Gets the outer ring GeoPolygon of this geometry. The polygon returned by this method is always "closed",
meaning that its last vertex is the same as the first one.
Returns:
GeoPolygon defining the shape of this polygon
public void setPolygon (GeoPolygon outerRing)
Sets the shape of this polygon to a solid one without any holes.
Parameters:
outerRing
the outer boundary of the polygon, defining its shape
Throws:
HERE Android SDK Developer's Guide
API Reference
602
IllegalArgumentException
when outerRing is null or invalid, meaning it is not a polygon with an area greater than 0
public void setPolygon (GeoPolygon outerRing, java.util.List <GeoPolygon>
innerRings)
Sets the geometry of this polygon with outer ring (shape) and inner rings (holes). Input polygons can be
"closed" (ie. having the same first and last vertex) or not, both options are valid.
Parameters:
outerRing
the outer boundary of the polygon, defining its shape
innerRings
list if inner rings of the polygon, defining holes in the main shape, will be ignored if null or empty
Throws:
IllegalArgumentException
when outerRing is null or invalid, meaning it is not a polygon with an area greater than 0, or when
innerRings contains null or invalid elements
CLE2PolylineGeometry
The class CLE2PolylineGeometry is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2PolylineGeometry
extends com.here.android.mpa.customlocation2.CLE2Geometry, java.lang.Object
Specifies a user-defined polyline geometry.
[For complete information, see the section Class Details]
Method Summary
Table 226: Methods in CLE2PolylineGeometry
Methods
public MapPolyline getMapPolyline ()
Gets the MapPolyline that are created from GeoPolyline to be added onto the map.
public GeoPolyline getPolyline ()
Gets the GeoPolyline in this geometry.
HERE Android SDK Developer's Guide
API Reference
603
Methods
public void setPolyline (GeoPolyline polyline)
Sets the shape of this polyline to the one supplied.
Class Details
Specifies a user-defined polyline geometry. A polyline geometry represent a single GeoPolyline
Method Details
public MapPolyline getMapPolyline ()
Gets the MapPolyline that are created from GeoPolyline to be added onto the map.
Returns:
MapPolyline OR null if creating map polyline is not possible with GeoPolyline.
public GeoPolyline getPolyline ()
Gets the GeoPolyline in this geometry.
Returns:
GeoPolyline.
public void setPolyline (GeoPolyline polyline)
Sets the shape of this polyline to the one supplied.
Parameters:
polyline
polyline defining the shape of this CLE2PolylineGeometry
CLE2ProximityRequest
The class CLE2ProximityRequest is a member of com.here.android.mpa.customlocation2 .
Class Summary
public class CLE2ProximityRequest
extends com.here.android.mpa.customlocation2.CLE2Request, java.lang.Object
Represents a custom geometry search request that uses the area around a location to retrieve user-defined
geometries.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
604
Constructor Summary
Table 227: Constructors in CLE2ProximityRequest
Constructors
CLE2ProximityRequest (String layerId, GeoCoordinate center, int radius)
Creates a Proximity Request
CLE2ProximityRequest (List layerIds, GeoCoordinate center, int radius)
Creates a Proximity Request that searches through multiple layers.
Class Details
Represents a custom geometry search request that uses the area around a location to retrieve user-defined
geometries.
This type of search request is used for user-defined geometries around a specified point.
A new CLE2ProximityRequest should be created for each search.
Constructor Details
CLE2ProximityRequest (String layerId, GeoCoordinate center, int radius)
Creates a Proximity Request
Parameters:
layerId
Name of layer specifying the layer to search.
center
A GeoCoordinate specifying the search center.
radius
An int specifying the search radius in meters.
Throws:
IllegalArgumentException
if center is invalid.
IllegalArgumentException
if radius is smaller than or equal to zero.
CLE2ProximityRequest (List layerIds, GeoCoordinate center, int radius)
Creates a Proximity Request that searches through multiple layers.
Parameters:
layerIds
List of layers name specifying the layer to search.
HERE Android SDK Developer's Guide
API Reference
605
center
A GeoCoordinate specifying the search center.
radius
An int specifying the search radius in meters.
Throws:
IllegalArgumentException
if center is invalid.
IllegalArgumentException
if radius is smaller than or equal to zero.
CLE2QuadkeyRequest
The class CLE2QuadkeyRequest is a member of com.here.android.mpa.customlocation2 .
Class Summary
public class CLE2QuadkeyRequest
extends com.here.android.mpa.customlocation2.CLE2Request, java.lang.Object
Represents a custom location search request that uses quadkey.
[For complete information, see the section Class Details]
Constructor Summary
Table 228: Constructors in CLE2QuadkeyRequest
Constructors
CLE2QuadkeyRequest (String layerId, String quadKey)
Creates a quadkey request.
Class Details
Represents a custom location search request that uses quadkey. A quadkey is a string containing a numeric
value. The value is obtained by interleaving the bits of the row and column coordinates of a tile in the grid
at the given zoom level, then converting the result to a base-4 number (the leading zeros are retained). The
length of a quadkey string (the number of digits/characters) equals the zoom level of the tile. Use this search
to retrieve the geometries that overlap exact certain tiles of a quadkey-tile based bitmap display.
Constructor Details
CLE2QuadkeyRequest (String layerId, String quadKey)
Creates a quadkey request.
HERE Android SDK Developer's Guide
API Reference
606
Parameters:
layerId
Name of layer specifying the layer to search.
quadKey
The quad key number of the map tile area to search from.
Throws:
IllegalArgumentException
if layerId is invalid.
CLE2Request
The class CLE2Request is a member of com.here.android.mpa.customlocation2 .
Class Summary
public class CLE2Request
extends java.lang.Object
Represents a custom location search request.
[For complete information, see the section Class Details]
Nested Class Summary
Table 229: Nested Classes in CLE2Request
Nested Classes
public static final enumeration CLE2Request.CLE2ConnectivityMode
Specifies the connectivity mode for a request.
public static class CLE2Request.CLE2Error
Represents values describing possible search request errors.
public static final enumeration CLE2Request.CLE2GeometryType
Specifies the geometry representation in the result.
public static abstract interface CLE2Request.CLE2ResultListener
Represents a listener that reports information about the completion of a custom location search CLE2Request.
HERE Android SDK Developer's Guide
API Reference
607
Method Summary
Table 230: Methods in CLE2Request
Methods
public void cancel ()
Cancels a search request in progress.
public boolean equals (Object other)
For documentation, see java.lang.Object
public String execute (CLE2ResultListener listener)
Executes the asynchronous custom location request.
public CLE2ConnectivityMode getConnectivityMode ()
Get request mode for this CLE2Request.
public int hashCode ()
For documentation, see java.lang.Object
public CLE2Request setCachingEnabled (boolean cache)
Set if request output geometries should be stored locally.
public CLE2Request setConnectivityMode (CLE2ConnectivityMode mode)
Sets the connectivity mode for this CLE2Request.
public CLE2Request setGeometry (CLE2GeometryType geometry)
Sets the geometry representation in request.
public CLE2Request setQuery (String query)
Specifies the filter(s) to be used for a custom location request.
Class Details
Represents a custom location search request.
Method Details
public void cancel ()
Cancels a search request in progress. Otherwise, nothing happens.
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public String execute (CLE2ResultListener listener)
HERE Android SDK Developer's Guide
API Reference
608
Executes the asynchronous custom location request.
Parameters:
listener
A CLE2Request.CLE2ResultListener to be notified when the search request is completed.
Returns:
NONE if request is sent successfully, otherwise, error message.
Throws:
IllegalArgumentException
if listener is {code null}.
public CLE2ConnectivityMode getConnectivityMode ()
Get request mode for this CLE2Request.
Returns:
CLE2Request.CLE2ConnectivityMode object.
public int hashCode ()
For documentation, see java.lang.Object
public CLE2Request setCachingEnabled (boolean cache)
Set if request output geometries should be stored locally. Default is false.
Please note that, if enabled, only FULL response will be stored. Other CLE2Request.CLE2GeometryType
response will not be stored.
Parameters:
cache
boolean indicating store response or not.
Returns:
updated CLE2Request for chaining operation.
public CLE2Request setConnectivityMode (CLE2ConnectivityMode mode)
Sets the connectivity mode for this CLE2Request. Default mode is ONLINE.
Please note that CLE2AttributeRequest only supports ONLINE mode.
Parameters:
mode
HERE Android SDK Developer's Guide
API Reference
609
CLE2Request.CLE2ConnectivityMode connectivity mode
Returns:
updated CLE2Request for chaining operation.
Throws:
IllegalArgumentException
When CLE2RequestMode is not ONLINE for CLE2AttributeRequest.
public CLE2Request setGeometry (CLE2GeometryType geometry)
Sets the geometry representation in request.
Default value for all request is FULL.
When using OFFLINE or AUTO, only FULL is supported. Also, CLE2AttributeRequest only supports FULL.
Parameters:
geometry
The geometry representation.
Returns:
current instance for chaining operation.
Throws:
IllegalArgumentException
if request is CLE2AttributeRequest and CLE2Request.CLE2GeometryType is not FULL.
public CLE2Request setQuery (String query)
Specifies the filter(s) to be used for a custom location request. When specified, only geometries where
expression evaluates to true will be returned. An example query can be like this "RATING $gt; 3 &&
NAME != 'MyPlace23'" where RATING and NAME are column names.
Please note that this method is only supported in ONLINE.
Parameters:
query
A JavaScript expression as a string being evaluated for each geometry.
Returns:
current instance for chaining operation.
Throws:
IllegalArgumentException
if query is empty.
HERE Android SDK Developer's Guide
API Reference
610
CLE2ConnectivityMode
The enumeration CLE2ConnectivityMode is a member of com.here.android.mpa.customlocation2.CLE2Request.
Enumeration Summary
public static final enumeration CLE2Request.CLE2ConnectivityMode
extends java.lang.Enum, java.lang.Object
Specifies the connectivity mode for a request.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 231: Enum Constants in CLE2ConnectivityMode
Fields
public static final CLE2ConnectivityMode ONLINE
Indicates online connectivity mode.
public static final CLE2ConnectivityMode OFFLINE
Indicates offline connectivity mode.
public static final CLE2ConnectivityMode AUTO
Set the auto mode for request.
Method Summary
Table 232: Methods in CLE2ConnectivityMode
Methods
public static CLE2ConnectivityMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CLE2Request.CLE2ConnectivityMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies the connectivity mode for a request.
Enum Constant Details
public static final CLE2ConnectivityMode ONLINE
Indicates online connectivity mode. If no connection is present, request will fail. Offline request will not be
attempted.
HERE Android SDK Developer's Guide
API Reference
611
public static final CLE2ConnectivityMode OFFLINE
Indicates offline connectivity mode. If no data is present, request will fail. Online request will not be
attempted.
public static final CLE2ConnectivityMode AUTO
Set the auto mode for request. If connection is present, request will be online, otherwise offline.
Method Details
public static CLE2ConnectivityMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CLE2Request.CLE2ConnectivityMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CLE2Error
The class CLE2Error is a member of com.here.android.mpa.customlocation2.CLE2Request.
Class Summary
public static class CLE2Request.CLE2Error
extends java.lang.Object
Represents values describing possible search request errors.
[For complete information, see the section Class Details]
Nested Class Summary
Table 233: Nested Classes in CLE2Error
Nested Classes
public static final enumeration CLE2Request.CLE2Error.CLE2ErrorCode
Error codes
HERE Android SDK Developer's Guide
API Reference
612
Constructor Summary
Table 234: Constructors in CLE2Error
Constructors
CLE2Error (CLE2ErrorCode code, String message)
Constructor to create a CLE2Error .
Field Summary
Table 235: Fields in CLE2Error
Fields
public static final String BUSY
The search service was busy with another request.
public static final String CANCELLED
Network request was cancelled.
public static final String INVALID_PARAMETER
A query request parameter was invalid.
public static final String NETWORK_COMMUNICATION
There was a network communications error.
public static final String NONE
No error was encountered.
public static final String OPERATION_NOT_ALLOWED
Access to this operation is denied.
public static final String UNKNOWN
Some other unexpected error occurred.
Method Summary
Table 236: Methods in CLE2Error
Methods
public CLE2ErrorCode getErrorCode ()
Get error code.
public String getErrorMessage ()
Get error description.
Class Details
Represents values describing possible search request errors.
HERE Android SDK Developer's Guide
API Reference
613
Constructor Details
CLE2Error (CLE2ErrorCode code, String message)
Constructor to create a CLE2Error .
Parameters:
code
- error code.
message
- error message.
Field Details
public static final String BUSY
The search service was busy with another request.
public static final String CANCELLED
Network request was cancelled.
public static final String INVALID_PARAMETER
A query request parameter was invalid.
public static final String NETWORK_COMMUNICATION
There was a network communications error.
public static final String NONE
No error was encountered.
public static final String OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final String UNKNOWN
Some other unexpected error occurred.
HERE Android SDK Developer's Guide
API Reference
614
Method Details
public CLE2ErrorCode getErrorCode ()
Get error code.
Returns:
error code
public String getErrorMessage ()
Get error description.
Returns:
error message
CLE2ErrorCode
The enumeration CLE2ErrorCode is a member of
com.here.android.mpa.customlocation2.CLE2Request.CLE2Error.
Enumeration Summary
public static final enumeration CLE2Request.CLE2Error.CLE2ErrorCode
extends java.lang.Enum, java.lang.Object
Error codes
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 237: Enum Constants in CLE2ErrorCode
Fields
public static final CLE2ErrorCode NONE
No error code.
public static final CLE2ErrorCode INVALID_PARAMETER
Invalid parameter.
public static final CLE2ErrorCode NETWORK_COMMUNICATION
Network communication.
public static final CLE2ErrorCode OPERATION_NOT_ALLOWED
Operation not allowed.
public static final CLE2ErrorCode DATA_MANAGER_FAILED
Storage Error.
HERE Android SDK Developer's Guide
API Reference
615
Fields
public static final CLE2ErrorCode SERVER_FAILED
Server error.
public static final CLE2ErrorCode PARTIAL_SUCCESS
Partial success.
public static final CLE2ErrorCode BUSY
Busy
public static final CLE2ErrorCode CANCELLED
Cancelled
public static final CLE2ErrorCode UNKNOWN
Unknown error code.
Method Summary
Table 238: Methods in CLE2ErrorCode
Methods
public int getValue ()
public static CLE2ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CLE2Request.CLE2Error.CLE2ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Error codes
Enum Constant Details
public static final CLE2ErrorCode NONE
No error code.
public static final CLE2ErrorCode INVALID_PARAMETER
Invalid parameter.
public static final CLE2ErrorCode NETWORK_COMMUNICATION
Network communication.
HERE Android SDK Developer's Guide
API Reference
616
public static final CLE2ErrorCode OPERATION_NOT_ALLOWED
Operation not allowed.
public static final CLE2ErrorCode DATA_MANAGER_FAILED
Storage Error.
public static final CLE2ErrorCode SERVER_FAILED
Server error.
public static final CLE2ErrorCode PARTIAL_SUCCESS
Partial success.
public static final CLE2ErrorCode BUSY
Busy
public static final CLE2ErrorCode CANCELLED
Cancelled
public static final CLE2ErrorCode UNKNOWN
Unknown error code.
Method Details
public int getValue ()
public static CLE2ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CLE2Request.CLE2Error.CLE2ErrorCode[] values ()
HERE Android SDK Developer's Guide
API Reference
617
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CLE2GeometryType
The enumeration CLE2GeometryType is a member of com.here.android.mpa.customlocation2.CLE2Request.
Enumeration Summary
public static final enumeration CLE2Request.CLE2GeometryType
extends java.lang.Enum, java.lang.Object
Specifies the geometry representation in the result.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 239: Enum Constants in CLE2GeometryType
Fields
public static final CLE2GeometryType LOCAL
Local geometry is used for map display purposes, returning geometry pieces that cover the given search radius, bounding
box or corridor polygon.
public static final CLE2GeometryType FULL
Full geometry is mostly used for interactive editing, where the original geometry is required.
public static final CLE2GeometryType NONE
None is used for applications like geofencing, which most of the time want to know only the ids of the geofence points/
lines and the polygons they are in or near.
Method Summary
Table 240: Methods in CLE2GeometryType
Methods
public String value ()
public static CLE2GeometryType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CLE2Request.CLE2GeometryType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies the geometry representation in the result.
HERE Android SDK Developer's Guide
API Reference
618
Enum Constant Details
public static final CLE2GeometryType LOCAL
Local geometry is used for map display purposes, returning geometry pieces that cover the given search
radius, bounding box or corridor polygon.
public static final CLE2GeometryType FULL
Full geometry is mostly used for interactive editing, where the original geometry is required.
public static final CLE2GeometryType NONE
None is used for applications like geofencing, which most of the time want to know only the ids of the
geofence points/lines and the polygons they are in or near.
Method Details
public String value ()
public static CLE2GeometryType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CLE2Request.CLE2GeometryType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CLE2ResultListener
The interface CLE2ResultListener is a member of com.here.android.mpa.customlocation2.CLE2Request.
Interface Summary
public static abstract interface CLE2Request.CLE2ResultListener
Represents a listener that reports information about the completion of a custom location search
CLE2Request.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
619
Method Summary
Table 241: Methods in CLE2ResultListener
Methods
public abstract void onCompleted (CLE2Result result, String error)
A callback indicating the completion of a custom location request
Interface Details
Represents a listener that reports information about the completion of a custom location search
CLE2Request.
Method Details
public abstract void onCompleted (CLE2Result result, String error)
A callback indicating the completion of a custom location request
Parameters:
result
Represents the data result of location request. If request failed, result should be ignored.
error
Represents the status of the location request. If None, the request was processed successfully,
otherwise, one of the other error codes will be returned.
CLE2Result
The class CLE2Result is a member of com.here.android.mpa.customlocation2 .
Class Summary
public final class CLE2Result
extends java.lang.Object
Stores the user-defined locations or geometries retrieved from a CLE2Request.
[For complete information, see the section Class Details]
Method Summary
Table 242: Methods in CLE2Result
Methods
public CLE2ConnectivityMode getConnectivityModeUsed ()
Gets ONLINE or OFFLINE mode for received response.
HERE Android SDK Developer's Guide
API Reference
620
Methods
public java.util.List <CLE2Geometry> getGeometries ()
Returns a List of user-defined CLE2Geometry(s).
Class Details
Stores the user-defined locations or geometries retrieved from a CLE2Request.
Method Details
public CLE2ConnectivityMode getConnectivityModeUsed ()
Gets ONLINE or OFFLINE mode for received response. This method can be useful to know whether the
response comes from server or from local storage in case of AUTO.
Returns:
CLE2Request.CLE2ConnectivityMode for received response.
public java.util.List <CLE2Geometry> getGeometries ()
Returns a List of user-defined CLE2Geometry(s).
Returns:
A List of user-defined CLE2Geometry(s) retrieved from a CLE2Request.
CLE2Task<ResultType>
The class CLE2Task<ResultType> is a member of com.here.android.mpa.customlocation2 .
Type Parameters:
ResultType
type of data the task retrieves from the service
Class Summary
public class CLE2Task
extends java.lang.Object
Encapsulates an asynchronous CLE2 task (that usually involves network communication and/or database
operations) and provides some common operations like observing, waiting for the result, cancelling or
getting the result.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
621
Nested Class Summary
Table 243: Nested Classes in CLE2Task<ResultType>
Nested Classes
public static abstract interface CLE2Task.Callback
Used to notify the client of the result of the operation.
Method Summary
Table 244: Methods in CLE2Task<ResultType>
Methods
public CLE2Task<ResultType> cancel ()
Attempts to cancel this task if it is running.
public CLE2Error getError ()
Gets the status of a finished task.
public ResultType getResult ()
Gets result of the operation represented by this task.
public boolean isFinished ()
Checks if the task has finished.
public boolean isStarted ()
Checks if the task has been started.
public CLE2Task<ResultType> start ()
Starts this task.
public CLE2Task<ResultType> start (Callback<ResultType> callback)
Starts this task and subscribes the supplied callback for result.
public CLE2Task<ResultType> subscribe (Callback<ResultType> callback)
Add a listener to be notified when this task finishes.
public CLE2Task<ResultType> unsubscribe (Callback<ResultType> callback)
Removes a listener from the list of subscribers to this task.
public CLE2Task<ResultType> waitForResult (long timeout, TimeUnit unit)
Waits for task's completion or until specified time passes.
public CLE2Task<ResultType> waitForResult ()
Waits for task's completion.
Class Details
Encapsulates an asynchronous CLE2 task (that usually involves network communication and/or database
operations) and provides some common operations like observing, waiting for the result, cancelling or
getting the result.
HERE Android SDK Developer's Guide
API Reference
622
A typical use for a CLE2Task involves creating a task, subscribing to it and starting its execution.
The factory methods usually looks something like newActionTask(parameters) where
Action is a descriptive name of what the task will do. For example, if you don't care about
holding onto the task for later use or having more than one subscriber, you might write
CLE2DataManager.getInstance().newListLayersTask(StorageType.LOCAL).start(myListener)
to create and start a task that will get the list of locally stored layers.
CLE2Task also provides some more advanced features. For example, if you are performing a background
operation that involves interacting with CLE2, a CLE2Task can be used in a synchronous manner by means of
calling waitForResult() method and then getting the result and error from the the finished task.
Having multiple subscribers to the task is also possible.
And finally, since CLE2Task object represents a unit of work, it can be held onto for later use, passed around,
run repeatedly multiple times (for example, retrying a failed operation) and canceled.
Method Details
public CLE2Task<ResultType> cancel ()
Attempts to cancel this task if it is running. There is no guarantee that the task will get
cancelled, it might happen that it might be too late in the process to abort. Regardless of the
outcome, all subscribers will get called. Refer to the error status in the subscriber callback
CLE2Task.Callback#onTaskFinished(Object, CLE2Request.CLE2Error) to determine if the task
was actually cancelled or not.
Returns:
this task, for method chaining
public CLE2Error getError ()
Gets the status of a finished task. This is how to check if the operation finished successfully or learn of the
reason for failure.
Only tasks that finished and are not currently in progress give a guarantee of returning a meaningful value.
Returns:
error status
public ResultType getResult ()
Gets result of the operation represented by this task. Only tasks that finished successfully and are not
currently in progress give a guarantee of returning a meaningful value.
Returns:
result of the task if finished, undefined otherwise (refer to the documentation of the task creator)
public boolean isFinished ()
HERE Android SDK Developer's Guide
API Reference
623
Checks if the task has finished.
NOTE: a task that is not started is always not finished.
Returns:
true if this task finished, false otherwise
public boolean isStarted ()
Checks if the task has been started.
NOTE: a finished task is also started. A task that is running is one that is started but not finished.
Returns:
true if this task was already started, false otherwise
public CLE2Task<ResultType> start ()
Starts this task. It will be run asynchronously. Attempting to start a task that is already running has no effect.
Starting the task that has already finished will make it run again.
To be notified about the task's result you need to subscribe to it using subscribe(CLE2Task.Callback) or if
synchronous operation is required waitForResult() and use getResult() and getError().
Returns:
this task, for method chaining
public CLE2Task<ResultType> start (Callback<ResultType> callback)
Starts this task and subscribes the supplied callback for result. All subscribers are called on the main
thread when the task finishes. Attempting to start a task that is already running is equivalent to calling
subscribe(CLE2Task.Callback) on it with the callback . Starting the task that has already finished will make
it run again.
Parameters:
callback
a subscriber to be notified of the result of this task
Returns:
this task, for method chaining
public CLE2Task<ResultType> subscribe (Callback<ResultType> callback)
Add a listener to be notified when this task finishes. They will be called in the same order as they were
added.
Subscribing on a task that already finished will result in callback being invoked immediately with the result.
HERE Android SDK Developer's Guide
API Reference
624
All subscribers are called on the main thread.
Parameters:
callback
Listener to be notified when this task finishes.
Returns:
this task, for method chaining
public CLE2Task<ResultType> unsubscribe (Callback<ResultType> callback)
Removes a listener from the list of subscribers to this task. This method has no effect if the callback is not
already a subscriber.
Parameters:
callback
a callback/listener to subscribe on this task
Returns:
this task, for method chaining
public CLE2Task<ResultType> waitForResult (long timeout, TimeUnit unit)
Waits for task's completion or until specified time passes. Returns immediately if the task has already
finished or is not started.
Important: never call this method from the main thread, that will result in RuntimeException . It is
meant to be used in situations where you run a non-trivial sequence of operations on your own background
thread.
Parameters:
timeout
the maximum time to wait
unit
the time unit of the timeout argument
Returns:
this task, for method chaining
public CLE2Task<ResultType> waitForResult ()
Waits for task's completion. Returns immediately if the task has already finished or is not started.
Important: never call this method from the main thread, that will result in RuntimeException . It is
meant to be used in situations where you run a non-trivial sequence of operations on your own background
thread.
HERE Android SDK Developer's Guide
API Reference
625
Returns:
this task, for method chaining
Callback<ResultType>
The interface Callback<ResultType> is a member of com.here.android.mpa.customlocation2.CLE2Task.
Type Parameters:
ResultType
data type of result
Interface Summary
public static abstract interface CLE2Task.Callback
Used to notify the client of the result of the operation.
[For complete information, see the section Interface Details]
Method Summary
Table 245: Methods in Callback<ResultType>
Methods
public abstract void onTaskFinished (ResultType result, CLE2Error error)
Called on main thread once CLE2Task finishes with a result and an error status.
Interface Details
Used to notify the client of the result of the operation.
Method Details
public abstract void onTaskFinished (ResultType result, CLE2Error error)
Called on main thread once CLE2Task finishes with a result and an error status.
Parameters:
result
result of the operation if finished successfully, this value is meaningless on operation's failure
error
error status carrying information on how the operation finished
HERE Android SDK Developer's Guide
API Reference
626
electronic_horizon
The package electronic_horizon is a member of com.here.android.mpa.
Package Summary
electronic_horizon
Package Details
AdasisV2Engine
The class AdasisV2Engine is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class AdasisV2Engine
extends java.lang.Object
AdasisV2Engine uses Electronic Horizon to predict upcoming streets and generates ADASIS v2 messages.
[For complete information, see the section Class Details]
Nested Class Summary
Table 246: Nested Classes in AdasisV2Engine
Nested Classes
public static abstract interface AdasisV2Engine.Listener
Constructor Summary
Table 247: Constructors in AdasisV2Engine
Constructors
AdasisV2Engine (AdasisV2MessageConfiguration adasisMessageConfig)
Constructor.
Method Summary
Table 248: Methods in AdasisV2Engine
Methods
public void setListener (Listener listener)
Sets the Listener that listens to the messages generated by the AdasisV2Engine.
HERE Android SDK Developer's Guide
API Reference
627
Methods
public void update ()
Updates ADASIS engine with new position.
Class Details
AdasisV2Engine uses Electronic Horizon to predict upcoming streets and generates ADASIS v2 messages.
Constructor Details
AdasisV2Engine (AdasisV2MessageConfiguration adasisMessageConfig)
Constructor.
Parameters:
adasisMessageConfig
Instance of AdasisV2MessageConfiguration which switches ON or OFF necessary ADASIS messages
Method Details
public void setListener (Listener listener)
Sets the Listener that listens to the messages generated by the AdasisV2Engine.
Parameters:
listener
Listener that listens to the messages generated by the AdasisV2Engine.
public void update ()
Updates ADASIS engine with new position. After calling update function, ADASIS version 2 protocol messages
will be received via Listener.
Listener
The interface Listener is a member of com.here.android.mpa.electronic_horizon.AdasisV2Engine.
Interface Summary
public static abstract interface AdasisV2Engine.Listener
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
628
Field Summary
Table 249: Fields in Listener
Fields
public static final int ADASIS_V2_MESSAGE_LENGTH
Constant length of each binary encoded ADASIS v2 message
Method Summary
Table 250: Methods in Listener
Methods
public abstract void onAdasisMessageReceived (byte[] bytes)
Called every time when new message is generated by ADASIS engine.
Interface Details
Field Details
public static final int ADASIS_V2_MESSAGE_LENGTH
Constant length of each binary encoded ADASIS v2 message
Method Details
public abstract void onAdasisMessageReceived (byte[] bytes)
Called every time when new message is generated by ADASIS engine.
Parameters:
bytes
binary encoded ADASIS v2 message. It always not null and contain exactly ADASIS_V2_MESSAGE_LENGTH
bytes
Note: The slope information will not be received if the shared disk cache is used. Use isolated disk cache
instead. To use isolated disk cache, check the documentation of function
AdasisV2MessageConfiguration
The class AdasisV2MessageConfiguration is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class AdasisV2MessageConfiguration
HERE Android SDK Developer's Guide
API Reference
629
extends java.lang.Object
AdasisV2MessageConfiguration enables or disables generation of specific ADASIS v2 messages.
[For complete information, see the section Class Details]
Method Summary
Table 251: Methods in AdasisV2MessageConfiguration
Methods
public static AdasisV2MessageConfiguration createAllEnabled ()
Creates AdasisV2MessageConfiguration with all possible ADASIS messages enabled.
public static AdasisV2MessageConfiguration createDefaultsEnabled ()
Creates AdasisV2MessageConfiguration with default ADASIS messages enabled.
public boolean isLatitudeLongitudeEnabled ()
public boolean isMetaDataEnabled ()
public boolean isPVIDEnabled ()
public boolean isPositionEnabled ()
public boolean isRoadAccessibilityEnabled ()
public boolean isSegmentEnabled ()
public boolean isSlopeEnabled ()
public boolean isStubEnabled ()
public void setLatitudeLongitudeEnabled (boolean enabled)
Set long profile LATITUDE and LONGITUDE messages enabled
public void setMetaDataEnabled (boolean enabled)
Set META-DATA message enabled
public void setPVIDEnabled (boolean enabled)
Set long profile PVID message enabled
public void setPositionEnabled (boolean enabled)
Set POSITION message enabled
public void setRoadAccessibilityEnabled (boolean enabled)
Set short profile ROAD_ACCESSIBILITY message enabled
public void setSegmentEnabled (boolean enabled)
Set SEGMENT message enabled
public void setSlopeEnabled (boolean enabled)
Set short profile SLOPE message enabled
public void setStubEnabled (boolean enabled)
Set STUB message enabled
HERE Android SDK Developer's Guide
API Reference
630
Class Details
AdasisV2MessageConfiguration enables or disables generation of specific ADASIS v2 messages.
Method Details
public static AdasisV2MessageConfiguration createAllEnabled ()
Creates AdasisV2MessageConfiguration with all possible ADASIS messages enabled.
Returns:
Instance of AdasisV2MessageConfiguration
public static AdasisV2MessageConfiguration createDefaultsEnabled ()
Creates AdasisV2MessageConfiguration with default ADASIS messages enabled. It's POSITION, STUB, SEGMENT
and META-DATA
Returns:
Instance of AdasisV2MessageConfiguration
public boolean isLatitudeLongitudeEnabled ()
Returns:
True if long profile LATITUDE and LONGITUDE messages are enabled
public boolean isMetaDataEnabled ()
Returns:
True if META-DATA message is enabled
public boolean isPVIDEnabled ()
Returns:
True if long profile PVID message is enabled
public boolean isPositionEnabled ()
Returns:
True if POSITION message is enabled
public boolean isRoadAccessibilityEnabled ()
Returns:
HERE Android SDK Developer's Guide
API Reference
631
True if short profile ROAD_ACCESSIBILITY message is enabled
public boolean isSegmentEnabled ()
Returns:
True if SEGMENT message is enabled
public boolean isSlopeEnabled ()
Returns:
True if short profile SLOPE message is enabled
public boolean isStubEnabled ()
Returns:
True if STUB message is enabled
public void setLatitudeLongitudeEnabled (boolean enabled)
Set long profile LATITUDE and LONGITUDE messages enabled
Parameters:
enabled
Are messages enabled
public void setMetaDataEnabled (boolean enabled)
Set META-DATA message enabled
Parameters:
enabled
Is message enabled
public void setPVIDEnabled (boolean enabled)
Set long profile PVID message enabled
Parameters:
enabled
Is message enabled
public void setPositionEnabled (boolean enabled)
HERE Android SDK Developer's Guide
API Reference
632
Set POSITION message enabled
Parameters:
enabled
Is message enabled
public void setRoadAccessibilityEnabled (boolean enabled)
Set short profile ROAD_ACCESSIBILITY message enabled
Parameters:
enabled
Is message enabled
public void setSegmentEnabled (boolean enabled)
Set SEGMENT message enabled
Parameters:
enabled
Is message enabled
public void setSlopeEnabled (boolean enabled)
Set short profile SLOPE message enabled
Parameters:
enabled
Is message enabled
public void setStubEnabled (boolean enabled)
Set STUB message enabled
Parameters:
enabled
Is message enabled
DataNotReadyException
The class DataNotReadyException is a member of com.here.android.mpa.electronic_horizon .
HERE Android SDK Developer's Guide
API Reference
633
Class Summary
public class DataNotReadyException
extends java.lang.Exception, java.lang.Throwable, java.lang.Object
Exception is thrown in case when data is not ready yet.
[For complete information, see the section Class Details]
Constructor Summary
Table 252: Constructors in DataNotReadyException
Constructors
DataNotReadyException (String message)
Class Details
Exception is thrown in case when data is not ready yet. Probably you need to try access it later.
Constructor Details
DataNotReadyException (String message)
Parameters:
message
ElectronicHorizon
The class ElectronicHorizon is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class ElectronicHorizon
extends java.lang.Object
ElectronicHorizon is a class that predicts upcoming streets and provides information about them.
[For complete information, see the section Class Details]
Nested Class Summary
Table 253: Nested Classes in ElectronicHorizon
Nested Classes
public static abstract interface ElectronicHorizon.Listener
Represents an interface for responding to electronic horizon events sent by the ElectronicHorizon.
HERE Android SDK Developer's Guide
API Reference
634
Constructor Summary
Table 254: Constructors in ElectronicHorizon
Constructors
ElectronicHorizon ()
Constructor.
Method Summary
Table 255: Methods in ElectronicHorizon
Methods
public MapAccessor getMapAccessor ()
public void setListener (Listener listener)
Sets the Listener that listens to the events of the ElectronicHorizon.
public void setLookAheadDistancesInCentimeters (int... distancesInCentimeters)
Sets look ahead distances.
public void setRoute (Route route)
Sets route to follow.
public void setTrailingDistanceInCentimeters (int distanceInCentimeters)
Sets trailing distance.
public void update ()
Updates electronic horizon with new position.
Class Details
ElectronicHorizon is a class that predicts upcoming streets and provides information about them.
Constructor Details
ElectronicHorizon ()
Constructor.
Method Details
public MapAccessor getMapAccessor ()
Returns:
An instance of MapAccessor class, which can be used to access the information about any link.
HERE Android SDK Developer's Guide
API Reference
635
public void setListener (Listener listener)
Sets the Listener that listens to the events of the ElectronicHorizon.
Parameters:
listener
Listener that listens to the events of the ElectronicHorizon.
public void setLookAheadDistancesInCentimeters (int...
distancesInCentimeters)
Sets look ahead distances. New links and children will be added if distance between them and current
position is less than distance on appropriate level.
Parameters:
distancesInCentimeters
Distances in centimeters where distance at index 0 means distance for main path and distance
at N index means N level of children Examples: Only main path with length of 7 kilometers
from current position: setLookAheadDistancesInCentimeters(new int[] {700000}) Main path with
length of 7 kilometers from current position and children with length of 1 kilometer from current
position (i.e. children have 1 kilometer length only if it starts at the same point as current position,
otherwise it have 1 kilometer minus offset between current position and child's offset at main path):
setLookAheadDistancesInCentimeters(new int[] {700000, 100000})
public void setRoute (Route route)
Sets route to follow. Electronic horizon will take route into account to build path tree.
Parameters:
route
Route to follow Note: Only the routes with transport mode RouteOptions.TransportMode#CAR or
RouteOptions.TransportMode#TRACK are supported.
Throws:
IllegalArgumentException
if route is null or mode doesn't match.
public void setTrailingDistanceInCentimeters (int distanceInCentimeters)
Sets trailing distance. Old links and children are removed only when they far at this trailing distance from
current position.
Parameters:
distanceInCentimeters
Distance in centimeters
HERE Android SDK Developer's Guide
API Reference
636
public void update ()
Updates electronic horizon with new position. After calling update function the path tree of electronic
horizon might be changed.
Listener
The interface Listener is a member of com.here.android.mpa.electronic_horizon.ElectronicHorizon.
Interface Summary
public static abstract interface ElectronicHorizon.Listener
Represents an interface for responding to electronic horizon events sent by the ElectronicHorizon.
[For complete information, see the section Interface Details]
Method Summary
Table 256: Methods in Listener
Methods
public abstract void onChildDetached (PathTree parent, PathTree child)
Called every time a path is detached from its parent.
public abstract void onLinkAdded (PathTree path, Link link)
Called every time a new link is added to the tree.
public abstract void onLinkRemoved (PathTree path, Link link)
Called every time a link is removed from the tree.
public abstract void onNewPosition (Position position)
Called when new position on most probable path or offroad position is computed.
public abstract void onPathAdded (PathTree path)
Called every time a new path is added to the tree.
public abstract void onPathRemoved (PathTree path)
Called every time a path is removed from the tree.
public abstract void onTreeReset ()
Called every time when the tree is reset.
Interface Details
Represents an interface for responding to electronic horizon events sent by the ElectronicHorizon.
HERE Android SDK Developer's Guide
API Reference
637
Method Details
public abstract void onChildDetached (PathTree parent, PathTree child)
Called every time a path is detached from its parent.
Parameters:
parent
The parent path tree element.
child
The child path tree element.
public abstract void onLinkAdded (PathTree path, Link link)
Called every time a new link is added to the tree.
Parameters:
path
The path to which the link was added.
link
The link which was added.
public abstract void onLinkRemoved (PathTree path, Link link)
Called every time a link is removed from the tree.
Parameters:
path
The path from which the link will be removed.
link
The link which will be removed.
public abstract void onNewPosition (Position position)
Called when new position on most probable path or offroad position is computed.
Parameters:
position
Updated position which contains the the most probable path which we are currently on and offset from
its origin.
public abstract void onPathAdded (PathTree path)
Called every time a new path is added to the tree.
HERE Android SDK Developer's Guide
API Reference
638
Parameters:
path
The path which was added.
public abstract void onPathRemoved (PathTree path)
Called every time a path is removed from the tree.
Parameters:
path
The path which will be removed. Note: No additional events about removing will be fired for children and
links of this path.
public abstract void onTreeReset ()
Called every time when the tree is reset. Note: Tree reset occurs when the new position cannot be matched
to the horizon. The tree will be rebuilt based on the new position.
Link
The class Link is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class Link
extends java.lang.Object
Represents a link for electronic horizon.
[For complete information, see the section Class Details]
Nested Class Summary
Table 257: Nested Classes in Link
Nested Classes
public static final enumeration Link.Direction
Defines the direction of movement.
HERE Android SDK Developer's Guide
API Reference
639
Constructor Summary
Table 258: Constructors in Link
Constructors
Link (long id, Direction direction, int startOffsetCentimeters, int endOffsetCentimeters)
Constructor
Method Summary
Table 259: Methods in Link
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Direction getDirection ()
public int getEndOffsetCentimeters ()
public long getId ()
public int getStartOffsetCentimeters ()
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a link for electronic horizon.
Constructor Details
Link (long id, Direction direction, int startOffsetCentimeters, int
endOffsetCentimeters)
Constructor
Parameters:
id
direction
startOffsetCentimeters
endOffsetCentimeters
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
640
Parameters:
obj
public Direction getDirection ()
Returns:
The direction of movement.
public int getEndOffsetCentimeters ()
Returns:
The distance from beginning of path to end of link in centimeters.
public long getId ()
Returns:
The identifier of the link.
public int getStartOffsetCentimeters ()
Returns:
The distance in centimeters from the logical beginning of the path.
public int hashCode ()
For documentation, see java.lang.Object
Direction
The enumeration Direction is a member of com.here.android.mpa.electronic_horizon.Link.
Enumeration Summary
public static final enumeration Link.Direction
extends java.lang.Enum, java.lang.Object
Defines the direction of movement.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
641
Enum Constant Summary
Table 260: Enum Constants in Direction
Fields
public static final Direction FORWARD
Forward
public static final Direction BACKWARD
Backward
Method Summary
Table 261: Methods in Direction
Methods
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Link.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines the direction of movement.
Enum Constant Details
public static final Direction FORWARD
Forward
public static final Direction BACKWARD
Backward
Method Details
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
642
public static Link.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
LinkInformation
The class LinkInformation is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class LinkInformation
extends java.lang.Object
Represents a link for electronic horizon.
[For complete information, see the section Class Details]
Nested Class Summary
Table 262: Nested Classes in LinkInformation
Nested Classes
public static final enumeration LinkInformation.AllowedDirection
Determines the allowed direction for the Link.
public static final enumeration LinkInformation.FormOfWay
Determines the form of the road for the Link
public static final enumeration LinkInformation.FunctionalRoadClass
Determines the priority of the road for the Link.
Constructor Summary
Table 263: Constructors in LinkInformation
Constructors
LinkInformation (boolean isBridge, boolean isDividedRoad, boolean isTunnel, boolean
isUrban, boolean isPedestrianOpen, double speedLimitMetersPerSecond, double lengthMeters,
AllowedDirection openForCars, AllowedDirection carThroughOpen, FunctionalRoadClass functionalRoadClass,
FormOfWay formOfWay)
Constructor
HERE Android SDK Developer's Guide
API Reference
643
Method Summary
Table 264: Methods in LinkInformation
Methods
public FormOfWay getFormOfWay ()
public FunctionalRoadClass getFunctionalRoadClass ()
public double getLengthMeters ()
public double getSpeedLimitMetersPerSecond ()
public boolean isBridge ()
public boolean isCarThroughOpen (AllowedDirection direction)
Checks whether the link is allowed to pass through with the cars on certain direction.
public boolean isDividedRoad ()
public boolean isOpenForCars (AllowedDirection direction)
Checks whether the link is allowed for the cars with certain direction.
public boolean isPedestrianOpen ()
public boolean isTunnel ()
public boolean isUrban ()
Class Details
Represents a link for electronic horizon.
Constructor Details
LinkInformation (boolean isBridge, boolean isDividedRoad, boolean
isTunnel, boolean isUrban, boolean isPedestrianOpen, double
speedLimitMetersPerSecond, double lengthMeters, AllowedDirection openForCars,
AllowedDirection carThroughOpen, FunctionalRoadClass functionalRoadClass,
FormOfWay formOfWay)
Constructor
Parameters:
isBridge
isDividedRoad
isTunnel
isUrban
isPedestrianOpen
speedLimitMetersPerSecond
lengthMeters
openForCars
HERE Android SDK Developer's Guide
API Reference
644
carThroughOpen
functionalRoadClass
formOfWay
Method Details
public FormOfWay getFormOfWay ()
Returns:
The FormOfWay which determines the form of way for the link.
public FunctionalRoadClass getFunctionalRoadClass ()
Returns:
The FunctionalRoadClass which determines the priority of the road.
public double getLengthMeters ()
Returns:
The length of the link in meters.
public double getSpeedLimitMetersPerSecond ()
Returns:
The speed limitation for the current link in meters per seconds.
public boolean isBridge ()
Returns:
true if current link is bridge, false otherwise.
public boolean isCarThroughOpen (AllowedDirection direction)
Checks whether the link is allowed to pass through with the cars on certain direction.
Parameters:
direction
The direction from which the link will be checked.
Returns:
true if link is allowed to pass with the cars, false otherwise.
HERE Android SDK Developer's Guide
API Reference
645
public boolean isDividedRoad ()
Returns:
true if current link is divided road, false otherwise.
public boolean isOpenForCars (AllowedDirection direction)
Checks whether the link is allowed for the cars with certain direction.
Parameters:
direction
The direction from which the link will be checked.
Returns:
true if link is allowed for cars, false otherwise.
public boolean isPedestrianOpen ()
Returns:
true if current link is allowed for the pedestrian, false otherwise.
public boolean isTunnel ()
Returns:
true if current link is tunnel, false otherwise.
public boolean isUrban ()
Returns:
true if current link is urban, false otherwise.
AllowedDirection
The enumeration AllowedDirection is a member of com.here.android.mpa.electronic_horizon.LinkInformation.
Enumeration Summary
public static final enumeration LinkInformation.AllowedDirection
extends java.lang.Enum, java.lang.Object
Determines the allowed direction for the Link.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
646
Enum Constant Summary
Table 265: Enum Constants in AllowedDirection
Fields
public static final AllowedDirection FORWARD
Forward
public static final AllowedDirection BACKWARD
Backward
public static final AllowedDirection BOTH
Both
public static final AllowedDirection NONE
None
Method Summary
Table 266: Methods in AllowedDirection
Methods
public static AllowedDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LinkInformation.AllowedDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Determines the allowed direction for the Link.
Enum Constant Details
public static final AllowedDirection FORWARD
Forward
public static final AllowedDirection BACKWARD
Backward
public static final AllowedDirection BOTH
Both
public static final AllowedDirection NONE
HERE Android SDK Developer's Guide
API Reference
647
None
Method Details
public static AllowedDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LinkInformation.AllowedDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FormOfWay
The enumeration FormOfWay is a member of com.here.android.mpa.electronic_horizon.LinkInformation.
Enumeration Summary
public static final enumeration LinkInformation.FormOfWay
extends java.lang.Enum, java.lang.Object
Determines the form of the road for the Link
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 267: Enum Constants in FormOfWay
Fields
public static final FormOfWay MULTIDIGITIZED
Multidigitized
public static final FormOfWay SINGLE_CARRIAGE
Single carriage
public static final FormOfWay SLIPROAD
Sliproad
public static final FormOfWay ROUNDABOUT_CIRCLE
Roundabout circle
HERE Android SDK Developer's Guide
API Reference
648
Fields
public static final FormOfWay SPECIAL_TRAFFIC_FIGURE
Special traffic figure
public static final FormOfWay PEDESTRIAN_ZONE
Pedestrian zone
public static final FormOfWay SERVICE_ROAD
Service road
Method Summary
Table 268: Methods in FormOfWay
Methods
public static FormOfWay valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LinkInformation.FormOfWay[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Determines the form of the road for the Link
Enum Constant Details
public static final FormOfWay MULTIDIGITIZED
Multidigitized
public static final FormOfWay SINGLE_CARRIAGE
Single carriage
public static final FormOfWay SLIPROAD
Sliproad
public static final FormOfWay ROUNDABOUT_CIRCLE
Roundabout circle
public static final FormOfWay SPECIAL_TRAFFIC_FIGURE
Special traffic figure
HERE Android SDK Developer's Guide
API Reference
649
public static final FormOfWay PEDESTRIAN_ZONE
Pedestrian zone
public static final FormOfWay SERVICE_ROAD
Service road
Method Details
public static FormOfWay valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LinkInformation.FormOfWay[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FunctionalRoadClass
The enumeration FunctionalRoadClass is a member of
com.here.android.mpa.electronic_horizon.LinkInformation.
Enumeration Summary
public static final enumeration LinkInformation.FunctionalRoadClass
extends java.lang.Enum, java.lang.Object
Determines the priority of the road for the Link.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 269: Enum Constants in FunctionalRoadClass
Fields
public static final FunctionalRoadClass FRC1
Functional road class 1
HERE Android SDK Developer's Guide
API Reference
650
Fields
public static final FunctionalRoadClass FRC2
Functional road class 2
public static final FunctionalRoadClass FRC3
Functional road class 3
public static final FunctionalRoadClass FRC4
Functional road class 4
public static final FunctionalRoadClass FRC5
Functional road class 5
Method Summary
Table 270: Methods in FunctionalRoadClass
Methods
public static FunctionalRoadClass valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LinkInformation.FunctionalRoadClass[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Determines the priority of the road for the Link. FRC1 is the highest priority road and the FRC5 is lowest
priority road.
Enum Constant Details
public static final FunctionalRoadClass FRC1
Functional road class 1
public static final FunctionalRoadClass FRC2
Functional road class 2
public static final FunctionalRoadClass FRC3
Functional road class 3
public static final FunctionalRoadClass FRC4
Functional road class 4
HERE Android SDK Developer's Guide
API Reference
651
public static final FunctionalRoadClass FRC5
Functional road class 5
Method Details
public static FunctionalRoadClass valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LinkInformation.FunctionalRoadClass[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
LinkRange
The class LinkRange is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class LinkRange
implements java.lang.Iterable
extends java.lang.Object
Represents an enumerable for iterating through PathTree elements.
[For complete information, see the section Class Details]
Method Summary
Table 271: Methods in LinkRange
Methods
public int getSize ()
public java.util.Iterator <electronic_horizon.Link> iterator ()
public void reset ()
Resets the iterator to point to the beginning of the range.
HERE Android SDK Developer's Guide
API Reference
652
Class Details
Represents an enumerable for iterating through PathTree elements.
Method Details
public int getSize ()
Returns:
The number of PathTree objects in the range.
public java.util.Iterator <electronic_horizon.Link> iterator ()
Returns:
The iterator that can be used to traverse through the elements in the range.
public void reset ()
Resets the iterator to point to the beginning of the range.
MapAccessor
The class MapAccessor is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class MapAccessor
extends java.lang.Object
Represents a class that provides information about any link.
[For complete information, see the section Class Details]
Constructor Summary
Table 272: Constructors in MapAccessor
Constructors
MapAccessor ()
Constructor.
HERE Android SDK Developer's Guide
API Reference
653
Method Summary
Table 273: Methods in MapAccessor
Methods
public java.util.List <electronic_horizon.Link> getConnectedLinks (Link link)
Retrieves the list of connected links of the link.
public LinkInformation getLinkInformation (Link link)
Retrieves the information of the link.
public GeoPolyline getLinkPolyline (Link link)
Retrieves the geometry of the link.
public MetaData getMetaData (Link link)
Retrieves the meta data of the link.
public String getPVID (Link link)
Retrieves the PVID of the link.
public java.util.List <electronic_horizon.SlopeDataPoint> getSlopeDataPoints (Link link)
Retrieves the list of slope data points of the link.
Class Details
Represents a class that provides information about any link.
Constructor Details
MapAccessor ()
Constructor.
Method Details
public java.util.List <electronic_horizon.Link> getConnectedLinks (Link link)
Retrieves the list of connected links of the link.
Parameters:
link
The link from which the connected links will be retrieved.
Returns:
The list of connected links if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
HERE Android SDK Developer's Guide
API Reference
654
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
public LinkInformation getLinkInformation (Link link)
Retrieves the information of the link.
Parameters:
link
The link from which the information will be retrieved.
Returns:
The linkInformation if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
public GeoPolyline getLinkPolyline (Link link)
Retrieves the geometry of the link.
Parameters:
link
The link from which the geometry will be retrieved.
Returns:
The geometry if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
HERE Android SDK Developer's Guide
API Reference
655
public MetaData getMetaData (Link link)
Retrieves the meta data of the link.
Parameters:
link
The link from which the meta data will be retrieved.
Returns:
The meta data if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
public String getPVID (Link link)
Retrieves the PVID of the link.
Parameters:
link
The link from which the PVID will be retrieved.
Returns:
The PVID if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
public java.util.List <electronic_horizon.SlopeDataPoint> getSlopeDataPoints (Link
link)
Retrieves the list of slope data points of the link.
HERE Android SDK Developer's Guide
API Reference
656
Note: The slope information will not be available if the shared disk cache is used. In this case
RuntimeException will be thrown. To avoid this use isolated disk cache instead. To use isolated disk cache,
check the documentation of setIsolatedDiskCacheRootPath function
Parameters:
link
The link from which the slope data points will be retrieved.
Returns:
The list of slope data points if the operation was successful, otherwise the exception is thrown.
Throws:
IllegalArgumentException
The link parameter is Invalid.
DataNotReadyException
The map data is not loaded yet.
RuntimeException
Unexpected error.
MetaData
The class MetaData is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class MetaData
extends java.lang.Object
Represents a meta data which is unique for the region where the link is located for electronic horizon.
[For complete information, see the section Class Details]
Nested Class Summary
Table 274: Nested Classes in MetaData
Nested Classes
public static final enumeration MetaData.SideOfDriving
Defines the side of driving of the specific region where the Link is located.
public static final enumeration MetaData.UnitSystem
Defines the unit system of the specific region where the Link is located.
HERE Android SDK Developer's Guide
API Reference
657
Constructor Summary
Table 275: Constructors in MetaData
Constructors
MetaData (SideOfDriving sideOfDriving, UnitSystem unitSystem, int countryCode, int regionCode)
Constructor
Method Summary
Table 276: Methods in MetaData
Methods
public int getCountryCode ()
public int getRegionCode ()
public SideOfDriving getSideOfDriving ()
public UnitSystem getUnitSystem ()
Class Details
Represents a meta data which is unique for the region where the link is located for electronic horizon.
Constructor Details
MetaData (SideOfDriving sideOfDriving, UnitSystem unitSystem, int countryCode,
int regionCode)
Constructor
Parameters:
sideOfDriving
unitSystem
countryCode
regionCode
Method Details
public int getCountryCode ()
Returns:
The ISO 3166-1 numeric country code where the link is located.
public int getRegionCode ()
Returns:
HERE Android SDK Developer's Guide
API Reference
658
The ISO 3166-1 numeric region code where the link is located.
public SideOfDriving getSideOfDriving ()
Returns:
The side of driving where the link is located.
public UnitSystem getUnitSystem ()
Returns:
The unit system where the link is located.
SideOfDriving
The enumeration SideOfDriving is a member of com.here.android.mpa.electronic_horizon.MetaData.
Enumeration Summary
public static final enumeration MetaData.SideOfDriving
extends java.lang.Enum, java.lang.Object
Defines the side of driving of the specific region where the Link is located.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 277: Enum Constants in SideOfDriving
Fields
public static final SideOfDriving RIGHT
Right
public static final SideOfDriving LEFT
Left
public static final SideOfDriving UNKNOWN
Unknown
HERE Android SDK Developer's Guide
API Reference
659
Method Summary
Table 278: Methods in SideOfDriving
Methods
public static SideOfDriving valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MetaData.SideOfDriving[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines the side of driving of the specific region where the Link is located.
Enum Constant Details
public static final SideOfDriving RIGHT
Right
public static final SideOfDriving LEFT
Left
public static final SideOfDriving UNKNOWN
Unknown
Method Details
public static SideOfDriving valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MetaData.SideOfDriving[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
660
UnitSystem
The enumeration UnitSystem is a member of com.here.android.mpa.electronic_horizon.MetaData.
Enumeration Summary
public static final enumeration MetaData.UnitSystem
extends java.lang.Enum, java.lang.Object
Defines the unit system of the specific region where the Link is located.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 279: Enum Constants in UnitSystem
Fields
public static final UnitSystem METRIC
Metric
public static final UnitSystem IMPERIAL
Imperial
public static final UnitSystem UNKNOWN
Unknown
Method Summary
Table 280: Methods in UnitSystem
Methods
public static UnitSystem valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MetaData.UnitSystem[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines the unit system of the specific region where the Link is located.
Enum Constant Details
public static final UnitSystem METRIC
Metric
HERE Android SDK Developer's Guide
API Reference
661
public static final UnitSystem IMPERIAL
Imperial
public static final UnitSystem UNKNOWN
Unknown
Method Details
public static UnitSystem valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MetaData.UnitSystem[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
PathTree
The class PathTree is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class PathTree
extends java.lang.Object
Represents a tree like structure where each PathTree contains multiple children and links.
[For complete information, see the section Class Details]
Method Summary
Table 281: Methods in PathTree
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public PathTreeRange getChildren ()
public LinkRange getLinks ()
HERE Android SDK Developer's Guide
API Reference
662
Methods
public int getOffsetCentimeters ()
public PathTree getParent ()
Note: The parent property of the root path tree is null.
public float getProbability ()
Note: The value of the property can be in range from 0 to 1.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a tree like structure where each PathTree contains multiple children and links.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public PathTreeRange getChildren ()
Returns:
Enumerator of type PathTreeRange, which allows to iterate through all the child path trees.
public LinkRange getLinks ()
Returns:
Enumerator of type LinkRange, which allows to iterate through all the links of the path tree.
public int getOffsetCentimeters ()
Returns:
The distance from the logical beginning of parent path to the start of the path tree in centimeters.
public PathTree getParent ()
Note: The parent property of the root path tree is null.
Returns:
The parent path tree in the hierarchy.
HERE Android SDK Developer's Guide
API Reference
663
public float getProbability ()
Note: The value of the property can be in range from 0 to 1.
Returns:
The probability of taking this path.
public int hashCode ()
For documentation, see java.lang.Object
PathTreeRange
The class PathTreeRange is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class PathTreeRange
implements java.lang.Iterable
extends java.lang.Object
Represents an enumerable for iterating through PathTree elements.
[For complete information, see the section Class Details]
Method Summary
Table 282: Methods in PathTreeRange
Methods
public int getSize ()
public java.util.Iterator <electronic_horizon.PathTree> iterator ()
public void reset ()
Resets the iterator to point to the beginning of the range.
Class Details
Represents an enumerable for iterating through PathTree elements.
Method Details
public int getSize ()
Returns:
HERE Android SDK Developer's Guide
API Reference
664
The number of PathTree objects in the range.
public java.util.Iterator <electronic_horizon.PathTree> iterator ()
Returns:
The iterator that can be used to traverse through the elements in the range.
public void reset ()
Resets the iterator to point to the beginning of the range.
Position
The class Position is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class Position
extends java.lang.Object
Represents a link for electronic horizon.
[For complete information, see the section Class Details]
Method Summary
Table 283: Methods in Position
Methods
public int getOffsetCentimeters ()
public PathTree getPathTree ()
public double getSpeedMetersPerSecond ()
public Date getTimestamp ()
Class Details
Represents a link for electronic horizon.
Method Details
public int getOffsetCentimeters ()
Returns:
The identifier of the link.
HERE Android SDK Developer's Guide
API Reference
665
public PathTree getPathTree ()
Returns:
The distance from beginning of path to end of link in centimeters.
public double getSpeedMetersPerSecond ()
Returns:
The direction of movement.
public Date getTimestamp ()
Returns:
The distance in centimeters from the logical beginning of the path.
SlopeDataPoint
The class SlopeDataPoint is a member of com.here.android.mpa.electronic_horizon .
Class Summary
public final class SlopeDataPoint
extends java.lang.Object
Represents a slope data points for specific link in electronic horizon.
[For complete information, see the section Class Details]
Constructor Summary
Table 284: Constructors in SlopeDataPoint
Constructors
SlopeDataPoint (double relativePositionOnLink, double slopePercent)
Constructor
Method Summary
Table 285: Methods in SlopeDataPoint
Methods
public double getRelativePositionOnLink ()
HERE Android SDK Developer's Guide
API Reference
666
Methods
public double getSlopePercent ()
Class Details
Represents a slope data points for specific link in electronic horizon.
Constructor Details
SlopeDataPoint (double relativePositionOnLink, double slopePercent)
Constructor
Parameters:
relativePositionOnLink
slopePercent
Method Details
public double getRelativePositionOnLink ()
Returns:
The relative position along the link, where 0.0 represents the start of the link and 1.0 represents the end of
the link.
public double getSlopePercent ()
Returns:
The slope value. It can also be positive or negative infinity in case of a steep incline.
fce
The package fce is a member of com.here.android.mpa.
Package Summary
fce
The package fce (Fleet Connectivity Extensions) provides classes, interfaces, and enumerations that allow
your application to support fleet management.
Package Details
HERE Android SDK Developer's Guide
API Reference
667
The package fce (Fleet Connectivity Extensions) provides classes, interfaces, and enumerations that allow
your application to support fleet management.
FleetConnectivityCustomEvent
The class FleetConnectivityCustomEvent is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityCustomEvent
extends com.here.android.mpa.fce.FleetConnectivityEvent, java.lang.Object
Represents event used for relaying custom data to the operator.
[For complete information, see the section Class Details]
Constructor Summary
Table 286: Constructors in FleetConnectivityCustomEvent
Constructors
FleetConnectivityCustomEvent ()
Method Summary
Table 287: Methods in FleetConnectivityCustomEvent
Methods
protected boolean dispatch (FleetConnectivityService service)
Internal method.
public void setJobId (String jobId)
Sets the job ID to which this event relates.
Class Details
Represents event used for relaying custom data to the operator.
Constructor Details
FleetConnectivityCustomEvent ()
Method Details
protected boolean dispatch (FleetConnectivityService service)
Internal method.
HERE Android SDK Developer's Guide
API Reference
668
Parameters:
service
public void setJobId (String jobId)
Sets the job ID to which this event relates. Specifying this property is optional.
Parameters:
jobId
Optional job ID.
FleetConnectivityCustomMessage
The class FleetConnectivityCustomMessage is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityCustomMessage
extends com.here.android.mpa.fce.FleetConnectivityMessage, java.lang.Object
Represents incoming message with generic information from the operator.
[For complete information, see the section Class Details]
Constructor Summary
Table 288: Constructors in FleetConnectivityCustomMessage
Constructors
FleetConnectivityCustomMessage ()
Class Details
Represents incoming message with generic information from the operator. The details of this message
should be specified in the content map.
Constructor Details
FleetConnectivityCustomMessage ()
FleetConnectivityError
The class FleetConnectivityError is a member of com.here.android.mpa.fce .
HERE Android SDK Developer's Guide
API Reference
669
Class Summary
public class FleetConnectivityError
extends java.lang.Object
Represents error reported by the server or the %NMAFleetConnectivityService.
[For complete information, see the section Class Details]
Nested Class Summary
Table 289: Nested Classes in FleetConnectivityError
Nested Classes
public static class FleetConnectivityError.Issue
Represents issue reported by the server.
public static final enumeration FleetConnectivityError.Type
Defines types of errors codes that can be reported by the @{link FleetConnectivityService.
Method Summary
Table 290: Methods in FleetConnectivityError
Methods
public String getErrorId ()
public java.util.List <Issue> getIssues ()
public int getResponseCode ()
public Type getType ()
Class Details
Represents error reported by the server or the %NMAFleetConnectivityService.
Method Details
public String getErrorId ()
Returns:
Error ID that can be used for tracking the problem in case of server error.
public java.util.List <Issue> getIssues ()
Returns:
List of issues reported by the server.
HERE Android SDK Developer's Guide
API Reference
670
public int getResponseCode ()
Returns:
HTTP response code of the server.
public Type getType ()
Returns:
Type of this error.
Issue
The class Issue is a member of com.here.android.mpa.fce.FleetConnectivityError.
Class Summary
public static class FleetConnectivityError.Issue
extends java.lang.Object
Represents issue reported by the server.
[For complete information, see the section Class Details]
Method Summary
Table 291: Methods in Issue
Methods
public String getCode ()
public String getMessage ()
Class Details
Represents issue reported by the server.
Method Details
public String getCode ()
Returns:
Code of the issue.
public String getMessage ()
Returns:
HERE Android SDK Developer's Guide
API Reference
671
Details of the issue.
Type
The enumeration Type is a member of com.here.android.mpa.fce.FleetConnectivityError.
Enumeration Summary
public static final enumeration FleetConnectivityError.Type
extends java.lang.Enum, java.lang.Object
Defines types of errors codes that can be reported by the @{link FleetConnectivityService.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 292: Enum Constants in Type
Fields
public static final Type SERVER_ERROR
Server reported error, for example due to incorrect data.
public static final Type CONNECTION_ERROR
Connection problem occurred.
Method Summary
Table 293: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static FleetConnectivityError.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines types of errors codes that can be reported by the @{link FleetConnectivityService.
Enum Constant Details
public static final Type SERVER_ERROR
Server reported error, for example due to incorrect data.
HERE Android SDK Developer's Guide
API Reference
672
public static final Type CONNECTION_ERROR
Connection problem occurred.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static FleetConnectivityError.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FleetConnectivityEvent
The class FleetConnectivityEvent is a member of com.here.android.mpa.fce .
Class Summary
public abstract class FleetConnectivityEvent
extends java.lang.Object
Abstract class common for all outgoing events.
[For complete information, see the section Class Details]
Constructor Summary
Table 294: Constructors in FleetConnectivityEvent
Constructors
FleetConnectivityEvent ()
Field Summary
Table 295: Fields in FleetConnectivityEvent
Fields
protected String m_jobId
HERE Android SDK Developer's Guide
API Reference
673
Method Summary
Table 296: Methods in FleetConnectivityEvent
Methods
protected abstract boolean dispatch (FleetConnectivityService service)
public Map getContent ()
public String getJobId ()
public void setContent (Map content)
Generic map of strings.
Class Details
Abstract class common for all outgoing events. It can be used to inform the operator about specific
event, for example job start, or job cancellation etc. The event can be sent out by using @{link
sendEvent(FleetConnectivityEvent) method. The event is sent out asynchronously. To check the result of the
dispatch, a listener should be set in FleetConnectivityService.
Constructor Details
FleetConnectivityEvent ()
Field Details
protected String m_jobId
Method Details
protected abstract boolean dispatch (FleetConnectivityService service)
Parameters:
service
public Map getContent ()
Returns:
Generic map of strings. Can be used for any purpose.
public String getJobId ()
Returns:
Job ID to which this event relates.
HERE Android SDK Developer's Guide
API Reference
674
public void setContent (Map content)
Generic map of strings. Can be used for any purpose.
Parameters:
content
Generic map of strings.
Throws:
IllegalArgumentException
if the content is null.
FleetConnectivityJobCancelledEvent
The class FleetConnectivityJobCancelledEvent is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityJobCancelledEvent
extends com.here.android.mpa.fce.FleetConnectivityEvent, java.lang.Object
Represents event used to inform the operator that the ongoing job was cancelled.
[For complete information, see the section Class Details]
Constructor Summary
Table 297: Constructors in FleetConnectivityJobCancelledEvent
Constructors
FleetConnectivityJobCancelledEvent ()
Method Summary
Table 298: Methods in FleetConnectivityJobCancelledEvent
Methods
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Class Details
Represents event used to inform the operator that the ongoing job was cancelled.
HERE Android SDK Developer's Guide
API Reference
675
Constructor Details
FleetConnectivityJobCancelledEvent ()
Method Details
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Parameters:
service
FleetConnectivityJobFinishedEvent
The class FleetConnectivityJobFinishedEvent is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityJobFinishedEvent
extends com.here.android.mpa.fce.FleetConnectivityEvent, java.lang.Object
Represents event used to inform the operator that the ongoing job was finished.
[For complete information, see the section Class Details]
Constructor Summary
Table 299: Constructors in FleetConnectivityJobFinishedEvent
Constructors
FleetConnectivityJobFinishedEvent ()
Method Summary
Table 300: Methods in FleetConnectivityJobFinishedEvent
Methods
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Class Details
Represents event used to inform the operator that the ongoing job was finished.
HERE Android SDK Developer's Guide
API Reference
676
Constructor Details
FleetConnectivityJobFinishedEvent ()
Method Details
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Parameters:
service
FleetConnectivityJobMessage
The class FleetConnectivityJobMessage is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityJobMessage
extends com.here.android.mpa.fce.FleetConnectivityMessage, java.lang.Object
Represents incoming message with a job request.
[For complete information, see the section Class Details]
Constructor Summary
Table 301: Constructors in FleetConnectivityJobMessage
Constructors
FleetConnectivityJobMessage ()
Method Summary
Table 302: Methods in FleetConnectivityJobMessage
Methods
public long getEtaThreshold ()
Optional ETA threshold proposed by the operator.
Class Details
Represents incoming message with a job request. The job can be accepted or rejected, see
FleetConnectivityJobStartedEvent and FleetConnectivityJobRejectedEvent. The details of the job (like
destination) should be specified in the content dictionary in this message.
HERE Android SDK Developer's Guide
API Reference
677
Constructor Details
FleetConnectivityJobMessage ()
Method Details
public long getEtaThreshold ()
Optional ETA threshold proposed by the operator. See FleetConnectivityJobStartedEvent for more details.
Returns:
ETA threshold proposed by the operator.
FleetConnectivityJobRejectedEvent
The class FleetConnectivityJobRejectedEvent is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityJobRejectedEvent
extends com.here.android.mpa.fce.FleetConnectivityEvent, java.lang.Object
Represents event used to inform the operator that the incoming job was rejected.
[For complete information, see the section Class Details]
Constructor Summary
Table 303: Constructors in FleetConnectivityJobRejectedEvent
Constructors
FleetConnectivityJobRejectedEvent ()
Method Summary
Table 304: Methods in FleetConnectivityJobRejectedEvent
Methods
protected boolean dispatch (FleetConnectivityService service)
Internal method.
public void setJobId (String jobId)
Job ID to which this event relates.
HERE Android SDK Developer's Guide
API Reference
678
Class Details
Represents event used to inform the operator that the incoming job was rejected.
Constructor Details
FleetConnectivityJobRejectedEvent ()
Method Details
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Parameters:
service
public void setJobId (String jobId)
Job ID to which this event relates. Should be set before sending out.
Parameters:
jobId
Job ID to which this event relates.
FleetConnectivityJobStartedEvent
The class FleetConnectivityJobStartedEvent is a member of com.here.android.mpa.fce .
Class Summary
public class FleetConnectivityJobStartedEvent
extends com.here.android.mpa.fce.FleetConnectivityEvent, java.lang.Object
Represents event used to inform the operator that the incoming job was accepted.
[For complete information, see the section Class Details]
Constructor Summary
Table 305: Constructors in FleetConnectivityJobStartedEvent
Constructors
FleetConnectivityJobStartedEvent ()
HERE Android SDK Developer's Guide
API Reference
679
Method Summary
Table 306: Methods in FleetConnectivityJobStartedEvent
Methods
protected boolean dispatch (FleetConnectivityService service)
Internal method.
public long getEtaThreshold ()
Estimated time of arrival change threshold, which will trigger the dispatch of ETA update event.
public void setEtaThreshold (long etaThreshold)
Estimated time of arrival change threshold, which will trigger the dispatch of ETA update event.
public void setJobId (String jobId)
Job ID to which this event relates.
Class Details
Represents event used to inform the operator that the incoming job was accepted.
Constructor Details
FleetConnectivityJobStartedEvent ()
Method Details
protected boolean dispatch (FleetConnectivityService service)
Internal method.
Parameters:
service
public long getEtaThreshold ()
Estimated time of arrival change threshold, which will trigger the dispatch of ETA update event. If not set or
greater than 100, then default threshold of 10% will be used.
Returns:
ETA update threshold.
public void setEtaThreshold (long etaThreshold)
Estimated time of arrival change threshold, which will trigger the dispatch of ETA update event. If not set or
greater than 100, then default threshold of 10% will be used.
Parameters:
HERE Android SDK Developer's Guide
API Reference
680
etaThreshold
ETA update threshold.
public void setJobId (String jobId)
Job ID to which this event relates. Should be set before sending out.
Parameters:
jobId
Job ID to which this event relates.
FleetConnectivityMessage
The class FleetConnectivityMessage is a member of com.here.android.mpa.fce .
Class Summary
public abstract class FleetConnectivityMessage
extends java.lang.Object
Abstract class representing incoming messages.
[For complete information, see the section Class Details]
Constructor Summary
Table 307: Constructors in FleetConnectivityMessage
Constructors
FleetConnectivityMessage ()
Method Summary
Table 308: Methods in FleetConnectivityMessage
Methods
public String getAssetId ()
public Map getContent ()
public long getCreationTimeMilliseconds ()
public String getDispatcherId ()
public String getJobId ()
public String getMessage ()
HERE Android SDK Developer's Guide
API Reference
681
Class Details
Abstract class representing incoming messages.
Constructor Details
FleetConnectivityMessage ()
Method Details
public String getAssetId ()
Returns:
Asset ID of the device for which this message was intended (the local device).
public Map getContent ()
Returns:
Map of strings with custom content sent by the dispatcher.
public long getCreationTimeMilliseconds ()
Returns:
Creation time of this message in milliseconds (Unix timestamp).
public String getDispatcherId ()
Returns:
ID of the dispatcher of this message.
public String getJobId ()
Returns:
Job id related to this message, can be null.
public String getMessage ()
Returns:
Optional message from the dispatcher.
HERE Android SDK Developer's Guide
API Reference
682
FleetConnectivityService
The class FleetConnectivityService is a member of com.here.android.mpa.fce .
Class Summary
public final class FleetConnectivityService
extends java.lang.Object
Main component of Fleet Connectivity Extension responsible for communication.
[For complete information, see the section Class Details]
Nested Class Summary
Table 309: Nested Classes in FleetConnectivityService
Nested Classes
public static abstract interface FleetConnectivityService.Listener
Represents a listener to handle FleetConnectivityService incoming messages.
Method Summary
Table 310: Methods in FleetConnectivityService
Methods
public boolean forcePoll ()
Forces poll of new events, if the service is running.
public String getAssetId ()
Sets the asset ID that identifies this device.
public String getDispatcherId ()
Dispatcher ID that identifies the user of this device.
public static FleetConnectivityService getInstance ()
Returns the FleetConnectivityService singleton instance.
public long getPollingInterval ()
Polling interval specified in seconds.
public String getRunningJobId ()
Retrieves the ID of currently running job.
public boolean sendEvent (FleetConnectivityEvent event)
Dispatches the provided event.
public void setAssetId (String assetId)
Asset ID that identifies this device.
HERE Android SDK Developer's Guide
API Reference
683
Methods
public void setDispatcherId (String dispatcherId)
Sets the dispatcher ID that identifies the user of this device.
public void setListener (Listener listener)
Sets the Listener that listens for messages from the FleetConnectivityService.
public void setPollingInterval (long interval)
Sets the polling interval specified in seconds.
public boolean start ()
Starts the service if it is not already started.
public boolean stop ()
Stops the service if it is running.
Class Details
Main component of Fleet Connectivity Extension responsible for communication.
Method Details
public boolean forcePoll ()
Forces poll of new events, if the service is running.
Returns:
false if service is not running.
public String getAssetId ()
Sets the asset ID that identifies this device. Will be reported in every event dispatched to the server. Server
provides new messages based on this ID. Service won't start if it is not specified.
Returns:
Specified assetId.
public String getDispatcherId ()
Dispatcher ID that identifies the user of this device. Service won't start if it is not specified.
Returns:
Specified dispatcherId.
public static FleetConnectivityService getInstance ()
Returns the FleetConnectivityService singleton instance.
HERE Android SDK Developer's Guide
API Reference
684
Returns:
FleetConnectivityService instance.
public long getPollingInterval ()
Polling interval specified in seconds. Default value is 10 seconds.
Returns:
Specified polling interval.
public String getRunningJobId ()
Retrieves the ID of currently running job.
Returns:
ID of the currently running job. Null if no job is in progress.
public boolean sendEvent (FleetConnectivityEvent event)
Dispatches the provided event.
Parameters:
event
The FleetConnectivityEvent instance. See FleetConnectivityJobStartedEvent,
FleetConnectivityJobRejectedEvent, FleetConnectivityJobFinishedEvent, FleetConnectivityJobCancelledEvent
and FleetConnectivityCustomEvent.
Returns:
false if service is not running or conditions for given event are not met.
public void setAssetId (String assetId)
Asset ID that identifies this device. Will be reported in every event dispatched to the server. Server provides
new messages based on this ID. Service won't start if it is not specified.
Parameters:
assetId
Specified assetId.
public void setDispatcherId (String dispatcherId)
Sets the dispatcher ID that identifies the user of this device. Service won't start if it is not specified.
Parameters:
dispatcherId
HERE Android SDK Developer's Guide
API Reference
685
Specified dispatcherId.
public void setListener (Listener listener)
Sets the Listener that listens for messages from the FleetConnectivityService.
Parameters:
listener
Listener that listens for messages from the FleetConnectivityService.
public void setPollingInterval (long interval)
Sets the polling interval specified in seconds. Default value is 10 seconds. Can be set to values greater than 0,
otherwise exception is thrown.
Parameters:
interval
Specified polling interval.
Throws:
IllegalArgumentException
if interval is equal or less than 0.
public boolean start ()
Starts the service if it is not already started. Fails if assetId or dispatcherId is not set.
Returns:
false if assetId or dispatcherId is not set or service is already started.
public boolean stop ()
Stops the service if it is running.
Returns:
false if service is not running.
Listener
The interface Listener is a member of com.here.android.mpa.fce.FleetConnectivityService.
HERE Android SDK Developer's Guide
API Reference
686
Interface Summary
public static abstract interface FleetConnectivityService.Listener
Represents a listener to handle FleetConnectivityService incoming messages.
[For complete information, see the section Interface Details]
Method Summary
Table 311: Methods in Listener
Methods
public abstract void onEventAcknowledged (FleetConnectivityEvent event, FleetConnectivityError error)
Called when server acknowledges dispatched event.
public abstract void onMessageReceived (FleetConnectivityMessage message)
Called when incoming message arrives.
Interface Details
Represents a listener to handle FleetConnectivityService incoming messages.
Methods of this listener are called on the main thread.
Method Details
public abstract void onEventAcknowledged (FleetConnectivityEvent event,
FleetConnectivityError error)
Called when server acknowledges dispatched event.
Parameters:
event
The FleetConnectivityEvent instance. Note that it won't be the same instance of event that was passed to
the sendEvent(FleetConnectivityEvent) call.
error
The FleetConnectivityError instance in case of network failure or server error.
public abstract void onMessageReceived (FleetConnectivityMessage message)
Called when incoming message arrives.
Parameters:
message
The FleetConnectivityMessage instance. See FleetConnectivityJobMessage and
FleetConnectivityCustomMessage .
HERE Android SDK Developer's Guide
API Reference
687
guidance
The package guidance is a member of com.here.android.mpa.
Package Summary
guidance
This package includes classes, interfaces, and enumerations related to guidance and turn-by-turn navigation,
used by other packages in the APIs for Android SDK.
Package Details
This package includes classes, interfaces, and enumerations related to guidance and turn-by-turn navigation,
used by other packages in the APIs for Android SDK.
The key classes to this package is NavigationManager. For more information on how to use this class, please
consult the Developer Guide or the class Javadoc.
Important: The Turn-by-turn Guidance APIs are in beta. Application developers using these APIs are
required to thoroughly test their applications in all expected usage scenarios to ensure safe and correct
behavior. Application developers are responsible for warning their users of the following obligations:
Do not follow instructions which may lead to an unsafe or illegal situation
Obey all local laws.
Be aware that using a mobile phone or some of its features while driving may be prohibited.
Always keep hands free to operate the vehicle while driving.
First consideration while driving should be road safety.
The following permission is required in each Android application that uses the guidance features of the HERE
SDK for Android:
<uses-permission android:name="android.permission.VIBRATE" />
AudioPlayerDelegate
The interface AudioPlayerDelegate is a member of com.here.android.mpa.guidance .
Interface Summary
public abstract interface AudioPlayerDelegate
Interface for notifying NavigationManager.AudioPlayer functions used by NavigationManager.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
688
Method Summary
Table 312: Methods in AudioPlayerDelegate
Methods
public abstract boolean playFiles (String[] files)
Delegate function for NavigationManager.AudioPlayer used by NavigationManager.
public abstract boolean playText (String text)
Delegate function for NavigationManager.AudioPlayer used by NavigationManager.
Interface Details
Interface for notifying NavigationManager.AudioPlayer functions used by NavigationManager. Clients can
take over playback of audio files and TTS text strings by implementing this interface and submitting to
setDelegate(AudioPlayerDelegate).
Method Details
public abstract boolean playFiles (String[] files)
Delegate function for NavigationManager.AudioPlayer used by NavigationManager. Clients will receive an
array of audio file paths that be submitted to media players for playback.
Parameters:
files
a string array of audio file paths to be sequentially played.
Returns:
true if client is handling the audio playback, false will allow the SDK to handle it.
public abstract boolean playText (String text)
Delegate function for NavigationManager.AudioPlayer used by NavigationManager. Clients will receive a text
string that can be submitted to TTS engines for playback.
Parameters:
text
TTS text to be played.
Returns:
true if client is handling the TTS playback, false will allow the SDK to handle it.
LaneInformation
The class LaneInformation is a member of com.here.android.mpa.guidance .
HERE Android SDK Developer's Guide
API Reference
689
Class Summary
public final class LaneInformation
extends java.lang.Object
Gives information about a lane, e.g.
[For complete information, see the section Class Details]
Nested Class Summary
Table 313: Nested Classes in LaneInformation
Nested Classes
public static final enumeration LaneInformation.CrossingRestriction
Crossing restriction to enter or exit a HOV lane.
public static final enumeration LaneInformation.Direction
All possible directions the lane leads.
public static final enumeration LaneInformation.MarkingType
Marking types for the divider and center marking.
public static final enumeration LaneInformation.RecommendationState
Recommendation for taking the lane according to the lane connectivity.
Method Summary
Table 314: Methods in LaneInformation
Methods
public MarkingType getCenterMarking ()
Gets the divider marking type for the center mark.
public CrossingRestriction getCrossingRestriction ()
Gets the crossing restriction of the lane.
public java.util.EnumSet <Direction> getDirections ()
Gets the directions of the lane as an EnumSet.
public MarkingType getDividerMarking ()
Gets the divider marking type for side marks.
public int getHeightRestriction ()
Gets the height restriction in cm.
public RecommendationState getRecommendationState ()
Gets the recommendation state of the lane according to the current route.
public int getSpeedLimit ()
Gets the speed limit on this lane in the positive lane direction in km/h.
HERE Android SDK Developer's Guide
API Reference
690
Methods
public int getWidth ()
Gets the lane width in cm.
public boolean isAcceleration ()
Returns whether this is an acceleration lane.
public boolean isAuxLane ()
Returns whether this is an auxiliary lane.
public boolean isCenterTurn ()
Returns whether this is a center turn lane.
public boolean isDeceleration ()
Returns whether this is a deceleration lane.
public boolean isDriveableShoulder ()
Returns whether this is a drivable shoulder lane.
public boolean isExpress ()
Returns whether this is an express lane.
public boolean isHOV ()
Returns whether this is a high occupancy vehicle (HOV) lane.
public boolean isPassing ()
Returns whether this is a passing lane.
public boolean isRegular ()
Returns whether this is a regular lane (i.e.
public boolean isRegulatedAccess ()
Returns whether this is a regulated access lane.
public boolean isReversible ()
Returns whether this is a reversible lane.
public boolean isSlow ()
Returns whether this is a slow lane.
public boolean isSyntheticDirection ()
Gets whether the direction of the lane is synthetic.
public boolean isTruckParking ()
Returns whether this is a truck parking lane.
public boolean isTurn ()
Returns whether this is a turn lane.
Class Details
Gives information about a lane, e.g. its type, direction and recommendation state.
HERE Android SDK Developer's Guide
API Reference
691
Method Details
public MarkingType getCenterMarking ()
Gets the divider marking type for the center mark.
Center markings are markings between lanes in opposite direction.
Returns:
The divider marking type for the center mark.
public CrossingRestriction getCrossingRestriction ()
Gets the crossing restriction of the lane. This indicates if it is illegal to enter or exit a lane.
Returns:
The crossing restriction of the lane.
public java.util.EnumSet <Direction> getDirections ()
Gets the directions of the lane as an EnumSet. The EnumSet holds all the directions the lane leads to.
The LaneInformation.Direction values are stored in bitmask form, so it is possible to convert them to a
bitmask if needed using the following code (e.g. for indexing image resources):
private long
convertDirectionToBitMask(EnumSet<Direction> directions) {
long bitmask = 0;
for (Direction dir : directions) {
bitmask |= dir.value();
}
return bitmask;
}
Returns:
An EnumSet that has each direction the lane leads to.
See also:
LaneInformation.Direction
public MarkingType getDividerMarking ()
Gets the divider marking type for side marks.
Divider markings are markings between lanes of same direction
Returns:
The divider marking type for side marks.
public int getHeightRestriction ()
HERE Android SDK Developer's Guide
API Reference
692
Gets the height restriction in cm.
Returns:
The height restriction in cm or zero if there is no restriction or it is unknown.
public RecommendationState getRecommendationState ()
Gets the recommendation state of the lane according to the current route.
If the map data does not provide connectivity information for this lane, then the RecommendationState is
set to NOT_AVAILABLE.
Returns:
The recommendation state of the lane according to the current route.
public int getSpeedLimit ()
Gets the speed limit on this lane in the positive lane direction in km/h. Zero if the speed limit is not
available. In the case of zero, the speed limit is the speed limit of the whole road (see RoadElement
Returns:
The speed limit on this lane in the positive lane direction in km/h (zero if not available).
public int getWidth ()
Gets the lane width in cm.
Returns:
The lane width in cm or zero if the lane width is not available.
public boolean isAcceleration ()
Returns whether this is an acceleration lane.
An acceleration lane (or merge lane) allows traffic entering a highway to accelerate to the speed of through
traffic before merging with it.
Returns:
True if this lane is an acceleration lane. False otherwise.
public boolean isAuxLane ()
Returns whether this is an auxiliary lane.
An auxiliary lane is a lane other than a through lane, used to separate entering, exiting or turning traffic from
the through traffic.
Returns:
HERE Android SDK Developer's Guide
API Reference
693
True if this lane is an auxiliary lane. False otherwise.
public boolean isCenterTurn ()
Returns whether this is a center turn lane.
Center turn lane is a bidirectional turn lane located in the middle of a road that allows traffic in both
directions to turn left (right for left side driving countries).
Returns:
True if this lane is a center turn lane. False otherwise.
public boolean isDeceleration ()
Returns whether this is a deceleration lane.
A deceleration lane is a lane adjacent to the primary road or street allowing drivers to pull out of the through
lane and decelerate safely before turning off a surface street or exiting a freeway.
Returns:
True if this lane is a deceleration lane. False otherwise.
public boolean isDriveableShoulder ()
Returns whether this is a drivable shoulder lane.
A shoulder lane is reserved paved area on the side of the road (one or both sides) that are not generally
used for driving, although it is possible under certain circumstances. Only shoulder lanes designated as a
part-time driving lanes are included.
Returns:
True if this lane is a drivable shoulder lane. False otherwise.
public boolean isExpress ()
Returns whether this is an express lane.
Returns:
True if this lane is an express lane. False otherwise.
public boolean isHOV ()
Returns whether this is a high occupancy vehicle (HOV) lane.
A HOV lane (or carpool lane) is reserved for carpool usage. Carpool lane requires a minimum number
of passengers in order for the car to use the carpool lane. HOV lanes may also be reserved for hybrids,
motorcycles, alternate fuel, etc. HOV Lane may require a fee
HERE Android SDK Developer's Guide
API Reference
694
Returns:
True if this lane is an HOV lane. False otherwise.
public boolean isPassing ()
Returns whether this is a passing lane.
Returns:
True if this lane is a passing lane. False otherwise.
public boolean isRegular ()
Returns whether this is a regular lane (i.e. the lane has no other type).
Regular lanes are lanes which have no specific use (i.e. they are not a special type such as HOV, reversible,
etc.)
Returns:
True if this lane is a regular lane. False otherwise.
public boolean isRegulatedAccess ()
Returns whether this is a regulated access lane.
(Trucks only) A regulated access lane is a lane designated as a holding zone, used to regulate traffic using
time intervals.
Returns:
True if this lane is a regulated access lane. False otherwise.
public boolean isReversible ()
Returns whether this is a reversible lane.
A reversible lane is a lane in which traffic may travel in either direction, depending on certain conditions
(also known as a tidal flow lane).
Returns:
True if this lane is a reversible lane. False otherwise.
public boolean isSlow ()
Returns whether this is a slow lane.
Returns:
True if this lane is a slow lane. False otherwise.
HERE Android SDK Developer's Guide
API Reference
695
public boolean isSyntheticDirection ()
Gets whether the direction of the lane is synthetic.
Synthetic directions are derived from the connectivity of the lane. Non-synthetic directions represent actual
physical arrows printed on the lane.
Returns:
True if the direction is synthetic. False otherwise.
public boolean isTruckParking ()
Returns whether this is a truck parking lane.
Truck parking lanes are wide shoulder lane that maybe used for truck parking as well as for emergency.
Returns:
True if this lane is a truck parking lane. False otherwise.
public boolean isTurn ()
Returns whether this is a turn lane.
Turn lane is an extra lane that is used for making a turn in order not to disrupt ongoing traffic.
Returns:
True if this lane is a turn lane. False otherwise.
CrossingRestriction
The enumeration CrossingRestriction is a member of com.here.android.mpa.guidance.LaneInformation.
Enumeration Summary
public static final enumeration LaneInformation.CrossingRestriction
extends java.lang.Enum, java.lang.Object
Crossing restriction to enter or exit a HOV lane.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
696
Enum Constant Summary
Table 315: Enum Constants in CrossingRestriction
Fields
public static final CrossingRestriction NO_RESTRICTION
No restriction
public static final CrossingRestriction LEFT
Left restricted
public static final CrossingRestriction RIGHT
Right restricted
public static final CrossingRestriction BOTH
Both directions restricted
Method Summary
Table 316: Methods in CrossingRestriction
Methods
public int getValue ()
public static CrossingRestriction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LaneInformation.CrossingRestriction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Crossing restriction to enter or exit a HOV lane.
Enum Constant Details
public static final CrossingRestriction NO_RESTRICTION
No restriction
public static final CrossingRestriction LEFT
Left restricted
public static final CrossingRestriction RIGHT
Right restricted
HERE Android SDK Developer's Guide
API Reference
697
public static final CrossingRestriction BOTH
Both directions restricted
Method Details
public int getValue ()
public static CrossingRestriction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LaneInformation.CrossingRestriction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Direction
The enumeration Direction is a member of com.here.android.mpa.guidance.LaneInformation.
Enumeration Summary
public static final enumeration LaneInformation.Direction
extends java.lang.Enum, java.lang.Object
All possible directions the lane leads.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 317: Enum Constants in Direction
Fields
public static final Direction UNDEFINED
Undefined.
public static final Direction STRAIGHT
Straight.
HERE Android SDK Developer's Guide
API Reference
698
Fields
public static final Direction SLIGHTLY_RIGHT
Slightly right.
public static final Direction RIGHT
Right.
public static final Direction SHARP_RIGHT
Sharp right.
public static final Direction U_TURN_LEFT
Left U-turn.
public static final Direction SHARP_LEFT
Sharp left.
public static final Direction LEFT
Left.
public static final Direction SLIGHTLY_LEFT
Slightly left.
public static final Direction MERGE_RIGHT
Merge right.
public static final Direction MERGE_LEFT
Merge left.
public static final Direction MERGE_LANES
Merge lanes.
public static final Direction U_TURN_RIGHT
Right U-turn.
public static final Direction SECOND_RIGHT
Second right.
public static final Direction SECOND_LEFT
Second left.
Method Summary
Table 318: Methods in Direction
Methods
public int value ()
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
699
Methods
public static LaneInformation.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
All possible directions the lane leads.
Enum Constant Details
public static final Direction UNDEFINED
Undefined. This indicates there are no markings on this lane and the direction is unknown.
public static final Direction STRAIGHT
Straight.
public static final Direction SLIGHTLY_RIGHT
Slightly right.
public static final Direction RIGHT
Right.
public static final Direction SHARP_RIGHT
Sharp right.
public static final Direction U_TURN_LEFT
Left U-turn.
public static final Direction SHARP_LEFT
Sharp left.
public static final Direction LEFT
Left.
public static final Direction SLIGHTLY_LEFT
HERE Android SDK Developer's Guide
API Reference
700
Slightly left.
public static final Direction MERGE_RIGHT
Merge right.
public static final Direction MERGE_LEFT
Merge left.
public static final Direction MERGE_LANES
Merge lanes.
public static final Direction U_TURN_RIGHT
Right U-turn.
public static final Direction SECOND_RIGHT
Second right.
public static final Direction SECOND_LEFT
Second left.
Method Details
public int value ()
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LaneInformation.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
701
MarkingType
The enumeration MarkingType is a member of com.here.android.mpa.guidance.LaneInformation.
Enumeration Summary
public static final enumeration LaneInformation.MarkingType
extends java.lang.Enum, java.lang.Object
Marking types for the divider and center marking.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 319: Enum Constants in MarkingType
Fields
public static final MarkingType NOT_AVAILABLE
Not available
public static final MarkingType LONG_DASHED
Long dashed
public static final MarkingType DOUBLE_SOLID_LINE
Double solid line
public static final MarkingType SINGLE_SOLID_LINE
Single solid line
public static final MarkingType DOUBLE_INNER_SINGLE_OUTER_DASHED
Double inner single outer dashed
public static final MarkingType DOUBLE_INNER_DASHED_OUTER_SINGLE
Double inner dashed outer single
public static final MarkingType SHORT_DASHED
Short dashed
public static final MarkingType SHARED_AREA
Shared area
public static final MarkingType DASHED_BLOCKS
Dashed blocks
public static final MarkingType PHYSICAL_DIVIDER
Physical divider
HERE Android SDK Developer's Guide
API Reference
702
Fields
public static final MarkingType DOUBLE_DASHED
Double dashed
public static final MarkingType NO_DIVIDER
No divider
public static final MarkingType CROSSING_ALERT
Crossing alert
Method Summary
Table 320: Methods in MarkingType
Methods
public int getValue ()
public static MarkingType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LaneInformation.MarkingType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Marking types for the divider and center marking.
Enum Constant Details
public static final MarkingType NOT_AVAILABLE
Not available
public static final MarkingType LONG_DASHED
Long dashed
public static final MarkingType DOUBLE_SOLID_LINE
Double solid line
public static final MarkingType SINGLE_SOLID_LINE
Single solid line
public static final MarkingType DOUBLE_INNER_SINGLE_OUTER_DASHED
HERE Android SDK Developer's Guide
API Reference
703
Double inner single outer dashed
public static final MarkingType DOUBLE_INNER_DASHED_OUTER_SINGLE
Double inner dashed outer single
public static final MarkingType SHORT_DASHED
Short dashed
public static final MarkingType SHARED_AREA
Shared area
public static final MarkingType DASHED_BLOCKS
Dashed blocks
public static final MarkingType PHYSICAL_DIVIDER
Physical divider
public static final MarkingType DOUBLE_DASHED
Double dashed
public static final MarkingType NO_DIVIDER
No divider
public static final MarkingType CROSSING_ALERT
Crossing alert
Method Details
public int getValue ()
public static MarkingType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
704
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static LaneInformation.MarkingType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RecommendationState
The enumeration RecommendationState is a member of com.here.android.mpa.guidance.LaneInformation.
Enumeration Summary
public static final enumeration LaneInformation.RecommendationState
extends java.lang.Enum, java.lang.Object
Recommendation for taking the lane according to the lane connectivity.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 321: Enum Constants in RecommendationState
Fields
public static final RecommendationState NOT_RECOMMENDED
The lane is not on the current route.
public static final RecommendationState RECOMMENDED
The lane is on the route at least up to the next decision point, but not for the whole part of the route for which connectivity
information is available.
public static final RecommendationState HIGHLY_RECOMMENDED
The lane is on the current route for the whole part of the route for which connectivity information is available.
public static final RecommendationState NOT_AVAILABLE
Recommendation information is not available.
Method Summary
Table 322: Methods in RecommendationState
Methods
public int value ()
HERE Android SDK Developer's Guide
API Reference
705
Methods
public static RecommendationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LaneInformation.RecommendationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Recommendation for taking the lane according to the lane connectivity.
Enum Constant Details
public static final RecommendationState NOT_RECOMMENDED
The lane is not on the current route.
public static final RecommendationState RECOMMENDED
The lane is on the route at least up to the next decision point, but not for the whole part of the route for
which connectivity information is available.
public static final RecommendationState HIGHLY_RECOMMENDED
The lane is on the current route for the whole part of the route for which connectivity information is
available.
public static final RecommendationState NOT_AVAILABLE
Recommendation information is not available.
Method Details
public int value ()
public static RecommendationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
706
public static LaneInformation.RecommendationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
NavigationManager
The class NavigationManager is a member of com.here.android.mpa.guidance .
Class Summary
public final class NavigationManager
extends java.lang.Object
This class controls turn by turn navigation.
[For complete information, see the section Class Details]
Nested Class Summary
Table 323: Nested Classes in NavigationManager
Nested Classes
public static final enumeration NavigationManager.AspectRatio
A measure of an image's aspect ratio which is w x h.
public static final enumeration NavigationManager.AudioEvent
Used for enabling/disabling audio events during navigation.
public static abstract class NavigationManager.AudioFeedbackListener
AudioFeedbackListener provides callback of audio related events from NavigationManager .
public class NavigationManager.AudioPlayer
public static final enumeration NavigationManager.Error
Navigation Manager Error
public static abstract class NavigationManager.GpsSignalListener
GpsSignalListener provides callback of GPS signal related events from NavigationManager .
public static abstract class NavigationManager.LaneInformationListener
LaneInformationListener provides callback of LaneInformation related events from NavigationManager .
public static abstract class NavigationManager.ManeuverEventListener
ManeuverEventListener provides callback of maneuver events from NavigationManager .
public static final enumeration NavigationManager.MapUpdateMode
Map Update Mode
public static final enumeration NavigationManager.NaturalGuidanceMode
Enum used to turn on/off features within natural guidance.
HERE Android SDK Developer's Guide
API Reference
707
Nested Classes
public static abstract class NavigationManager.NavigationManagerEventListener
NavigationManagerEventListener provides callback of general navigation manager related events from
NavigationManager .
public static final enumeration NavigationManager.NavigationMode
Possible Navigation Modes
public static final enumeration NavigationManager.NavigationState
Possible states of navigation
public static abstract class NavigationManager.NewInstructionEventListener
NewInstructionEventListener provides callback of new instruction events from NavigationManager .
public static abstract class NavigationManager.PositionListener
PositionListener provides callback of position events from NavigationManager .
public static abstract class NavigationManager.RealisticViewListener
RealisticViewListenerAdapter provides callback of realistic view related events from NavigationManager .
public static final enumeration NavigationManager.RealisticViewMode
Enum used to turn on/off realistic view (junction view and 2D signs).
public static abstract class NavigationManager.RerouteListener
RerouteListener provides callback of route re-calculation related events from NavigationManager .
public static class NavigationManager.RoadView
This static class controls road view of turn by turn navigation.
public static abstract class NavigationManager.SafetySpotListener
SafetySpotListener provides callback of safety spot related events from NavigationManager .
public static abstract class NavigationManager.SpeedWarningListener
SpeedListener provides callback of speed warning related events from NavigationManager .
public static final enumeration NavigationManager.TrafficAvoidanceMode
Specifies if traffic should be automatically avoided or not during navigation
public static abstract class NavigationManager.TrafficRerouteListener
This adapter class receives notifications from NavigationManager that indicates traffic re-routing events due to the use
of different NavigationManager.TrafficAvoidanceModes.
public static final enumeration NavigationManager.TtsOutputFormat
Used for specifying TTS output format in which the text should be generated.
public static final enumeration NavigationManager.UnitSystem
Supported unit system types
HERE Android SDK Developer's Guide
API Reference
708
Field Summary
Table 324: Fields in NavigationManager
Fields
public static final Date INVALID_ETA_DATE
Represents an invalid time of arrival.
Method Summary
Table 325: Methods in NavigationManager
Methods
public void addAudioFeedbackListener (java.lang.ref.WeakReference <AudioFeedbackListener> listener)
Add a NavigationManager.AudioFeedbackListener to NavigationManager as a WeakReference .
public void addGpsSignalListener (java.lang.ref.WeakReference <GpsSignalListener> listener)
Add a NavigationManager.GpsSignalListener to NavigationManager to subscribe to route re-calculation events.
public void addLaneInformationListener (java.lang.ref.WeakReference <LaneInformationListener>
listener)
Add a NavigationManager.LaneInformationListener to NavigationManager to subscribe to lane information related
events.
public void addManeuverEventListener (java.lang.ref.WeakReference <ManeuverEventListener> listener)
Add a NavigationManager.ManeuverEventListener to NavigationManager to subscribe to new instruction event(s).
public void addNavigationManagerEventListener (java.lang.ref.WeakReference
<NavigationManagerEventListener> listener)
Add a NavigationManager.NavigationManagerEventListener to NavigationManager to subscribe to general info events.
public void addNewInstructionEventListener (java.lang.ref.WeakReference <NewInstructionEventListener>
listener)
Add a NavigationManager.NewInstructionEventListener to NavigationManager to subscribe to new instruction event(s).
public void addPositionListener (java.lang.ref.WeakReference <PositionListener> listener)
Add a NavigationManager.PositionListener to NavigationManager to subscribe to position event(s).
public void addRealisticViewAspectRatio (AspectRatio ratio)
Adds an aspect ratio to the realistic view engine.
public void addRealisticViewListener (java.lang.ref.WeakReference <RealisticViewListener> listener)
Add a NavigationManager.RealisticViewListener to NavigationManager as a WeakReference .
public void addRerouteListener (java.lang.ref.WeakReference <RerouteListener> listener)
Add a NavigationManager.RerouteListener to NavigationManager to subscribe to route re-calculation events.
public void addSafetySpotListener (java.lang.ref.WeakReference <SafetySpotListener> listener)
Add a NavigationManager.SafetySpotListener to NavigationManager to subscribe to safety spot event(s).
HERE Android SDK Developer's Guide
API Reference
709
Methods
public void addSpeedWarningListener (java.lang.ref.WeakReference <SpeedWarningListener> listener)
Add a NavigationManager.SpeedWarningListener to NavigationManager to subscribe to speed warning event(s).
public void addTrafficRerouteListener (java.lang.ref.WeakReference <TrafficRerouteListener> listener)
Add a traffic re-route listener as a WeakReference .
public void clearRealisticViewAspectRatios ()
Clear all aspect ratios from the realistic view engine.
public Maneuver getAfterNextManeuver ()
Returns the Maneuver after the next Maneuver
public long getAfterNextManeuverDistance ()
Returns the distance to the Maneuver after the next Maneuver
public AudioPlayer getAudioPlayer ()
Retrieve the Audio Player instance associated with the NavigationManager
public double getAverageSpeed ()
Returns the current average speed.
public String getCountryCode ()
Gets the three-letter country code (defined in ISO 3166-1) from current location.
public long getDestinationDistance ()
Returns the current distance to destination.
public UnitSystem getDistanceUnit ()
Gets the Distance Unit.
public long getElapsedDistance ()
Returns the elapsed distance from start of navigation, tracking or simulation.
public java.util.EnumSet <AudioEvent> getEnabledAudioEvents ()
Gets the set of all NavigationManager.AudioEvents that are currently enabled.
public Date getEta (boolean wholeRoute, TrafficPenaltyMode mode)
Returns the estimated time of arrival (ETA) of the route.
public float getHighSpeedWarningBoundary ()
The current speed boundary in meters/second.
public float getHighSpeedWarningOffset ()
The current high speed warning offset in meters/second.
public static NavigationManager getInstance ()
public float getLowSpeedWarningOffset ()
The current low speed warning offset in meters/second.
public MapUpdateMode getMapUpdateMode ()
Retrieves currently set MapUpdateMode
HERE Android SDK Developer's Guide
API Reference
710
Methods
public java.util.EnumSet <NaturalGuidanceMode> getNaturalGuidanceMode ()
Get the natural guidance modes enabled.
public NavigationMode getNavigationMode ()
Retrieves the current Navigation Mode
public Maneuver getNextManeuver ()
Returns the next maneuver on the route, or null if no next maneuver.
public long getNextManeuverDistance ()
Returns the distance to the next Maneuver
public java.util.EnumSet <AspectRatio> getRealisticViewAspectRatios ()
Gets the aspect ratios currently being returned.
public RealisticViewMode getRealisticViewMode ()
Returns the currently set NavigationManager.RealisticViewMode.
public RoadView getRoadView ()
Retrieve the Road View instance associated with the NavigationManager
public NavigationState getRunningState ()
Retrieves the current Navigation Running State
public TrafficAvoidanceMode getTrafficAvoidanceMode ()
Get the way in which traffic should be handled during navigation.
public TrafficWarner getTrafficWarner ()
Retrieve the traffic warner instance for the navigation manager
public RouteTta getTta (TrafficPenaltyMode mode, boolean wholeRoute)
Returns the Time To Arrival (TTA).
public TtsOutputFormat getTtsOutputFormat ()
Gets the TTS text output format currently in use.
public VoiceSkin getVoiceSkin ()
Gets the voice skin currently in use.
public static boolean isManeuverVoiceoverEnabled (Action action)
Checks if guidance voice prompts are enabled for the given type of maneuver actions.
public boolean isSpeedWarningEnabled ()
Get the speed warning status.
public int isTtsLanguageAvailable (Locale locale)
Get the availability of the specified language as represented by the Locale .
public void pause ()
Suspend Navigation temporarily.
HERE Android SDK Developer's Guide
API Reference
711
Methods
public void removeAudioFeedbackListener (AudioFeedbackListener listener)
Remove a NavigationManager.AudioFeedbackListener previously added to NavigationManager .
public void removeGpsSignalListener (GpsSignalListener listener)
Remove a NavigationManager.GpsSignalListener previously added to NavigationManager .
public void removeLaneInformationListener (LaneInformationListener listener)
Remove a NavigationManager.LaneInformationListener previously added to NavigationManager .
public void removeManeuverEventListener (ManeuverEventListener listener)
Remove a NavigationManager.NewInstructionEventListener previously added to NavigationManager
public void removeNavigationManagerEventListener (NavigationManagerEventListener listener)
Remove a NavigationManager.NavigationManagerEventListener previously added to NavigationManager
public void removeNewInstructionEventListener (NewInstructionEventListener listener)
Remove a NavigationManager.NewInstructionEventListener previously added to NavigationManager
public void removePositionListener (PositionListener listener)
Remove a NavigationManager.PositionListener previously added to NavigationManager .
public void removeRealisticViewListener (RealisticViewListener listener)
Remove a NavigationManager.RealisticViewListener previously added to NavigationManager .
public void removeRerouteListener (RerouteListener listener)
Remove a NavigationManager.RerouteListener previously added to NavigationManager .
public void removeSafetySpotListener (SafetySpotListener listener)
Remove a NavigationManager.SafetySpotListener previously added to NavigationManager .
public void removeSpeedWarningListener (SpeedWarningListener listener)
Remove a NavigationManager.SpeedWarningListener previously added to NavigationManager .
public void removeTrafficRerouteListener (TrafficRerouteListener listener)
Remove a traffic re-route listener.
public void repeatVoiceCommand ()
Repeat last voice command.
public Error resume ()
Resume paused Navigation.
public Error setDistanceUnit (UnitSystem us)
Sets the measuring unit system that is used by voice guidance.
public void setEnabledAudioEvents (java.util.EnumSet <AudioEvent> events)
Used to enable/disable the playback of audio events during navigation.
public static boolean setManeuverVoiceoverEnabled (Action action, boolean enabled)
Enables or disables guidance voice prompts for a given type of maneuver action.
HERE Android SDK Developer's Guide
API Reference
712
Methods
public void setMap (Map map)
Set Map to this Navigation Manager object and show the Navigation on Map .
public Error setMapUpdateMode (MapUpdateMode mode)
Sets the Map Update Mode, different modes changes the way position is updated.
public boolean setNaturalGuidanceMode (java.util.EnumSet <NaturalGuidanceMode> mode)
Set the natural guidance modes to be enabled.
public void setRealisticViewMode (RealisticViewMode mode)
Change realistic view mode.
public Error setRoute (Route route)
Sets the route navigation manager should use.
public Error setRouteRequestInterval (int value)
Set the time period between two re-routing.
public boolean setSpeedWarningEnabled (boolean value)
Set the speed warning state.
public Error setSpeedWarningOptions (float lowSpeedOffset, float highSpeedOffset, float
highSpeedBoundary)
Set speed warning options.
public Error setTrafficAvoidanceMode (TrafficAvoidanceMode mode)
Set the way in which traffic should be handled during navigation.
public void setTtsOutputFormat (TtsOutputFormat format)
Sets the TTS text output format.
public Error setVoiceSkin (VoiceSkin skin)
sets the voice skin id for voice Navigation
public Error simulate (Route route, long speed)
Start route simulation.
public Error startNavigation (Route route)
Start navigation along the route.
public Error startTracking ()
Start tracking mode.
public void stop ()
Abort the current operation, which can be route navigation, route simulation or tracking.
public void stopSpeedWarning ()
Stop speed warning notifications for the current navigation session.
HERE Android SDK Developer's Guide
API Reference
713
Class Details
This class controls turn by turn navigation.
If the user of the application revokes the ACCESS_FINE_LOCATION permission at runtime while
NavigationManager is active, navigation will stop functioning. Navigation must be restarted once the
ACCESS_FINE_LOCATION permission is restored.
Field Details
public static final Date INVALID_ETA_DATE
Represents an invalid time of arrival.
See also:
getEta(boolean, TrafficPenaltyMode)
Method Details
public void addAudioFeedbackListener (java.lang.ref.WeakReference
<AudioFeedbackListener> listener)
Add a NavigationManager.AudioFeedbackListener to NavigationManager as a WeakReference .
Parameters:
listener
The WeakReference of NavigationManager.AudioFeedbackListener to be added.
public void addGpsSignalListener (java.lang.ref.WeakReference
<GpsSignalListener> listener)
Add a NavigationManager.GpsSignalListener to NavigationManager to subscribe to route re-calculation
events.
Parameters:
listener
The WeakReference of the GpsSignalListener to be added.
public void addLaneInformationListener (java.lang.ref.WeakReference
<LaneInformationListener> listener)
Add a NavigationManager.LaneInformationListener to NavigationManager to subscribe to lane
information related events.
Parameters:
listener
HERE Android SDK Developer's Guide
API Reference
714
The WeakReference of the LaneInformationListener to be added.
public void addManeuverEventListener (java.lang.ref.WeakReference
<ManeuverEventListener> listener)
Add a NavigationManager.ManeuverEventListener to NavigationManager to subscribe to new instruction
event(s).
Parameters:
listener
The WeakReference of the ManeuverEventListener to be added.
public void addNavigationManagerEventListener (java.lang.ref.WeakReference
<NavigationManagerEventListener> listener)
Add a NavigationManager.NavigationManagerEventListener to NavigationManager to subscribe to general
info events.
Parameters:
listener
The WeakReference of the NavigationManagerEventListener to be added.
public void addNewInstructionEventListener (java.lang.ref.WeakReference
<NewInstructionEventListener> listener)
Add a NavigationManager.NewInstructionEventListener to NavigationManager to subscribe to new
instruction event(s).
Parameters:
listener
The WeakReference of the NewInstructionEventListener to be added.
public void addPositionListener (java.lang.ref.WeakReference
<PositionListener> listener)
Add a NavigationManager.PositionListener to NavigationManager to subscribe to position event(s).
Parameters:
listener
The WeakReference of the PositionListener to be added.
public void addRealisticViewAspectRatio (AspectRatio ratio)
HERE Android SDK Developer's Guide
API Reference
715
Adds an aspect ratio to the realistic view engine. By default all aspect ratios are off. Realistic view images are
only generated for the requested aspect ratios.
Parameters:
ratio
The aspect ratio to be added.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public void addRealisticViewListener (java.lang.ref.WeakReference
<RealisticViewListener> listener)
Add a NavigationManager.RealisticViewListener to NavigationManager as a WeakReference .
Parameters:
listener
The WeakReference of NavigationManager.RealisticViewListener to be added.
public void addRerouteListener (java.lang.ref.WeakReference <RerouteListener>
listener)
Add a NavigationManager.RerouteListener to NavigationManager to subscribe to route re-calculation
events.
Parameters:
listener
The WeakReference of the RerouteListener to be added.
public void addSafetySpotListener (java.lang.ref.WeakReference
<SafetySpotListener> listener)
Add a NavigationManager.SafetySpotListener to NavigationManager to subscribe to safety spot event(s).
Parameters:
listener
The WeakReference of the SafetySpotListener to be added.
public void addSpeedWarningListener (java.lang.ref.WeakReference
<SpeedWarningListener> listener)
Add a NavigationManager.SpeedWarningListener to NavigationManager to subscribe to speed warning
event(s).
HERE Android SDK Developer's Guide
API Reference
716
Parameters:
listener
The WeakReference of the SpeedWarningListener to be added.
public void addTrafficRerouteListener (java.lang.ref.WeakReference
<TrafficRerouteListener> listener)
Add a traffic re-route listener as a WeakReference .
Parameters:
listener
A WeakReference of the NavigationManager.TrafficRerouteListener to be added.
See also:
NavigationManager.TrafficAvoidanceMode
setTrafficAvoidanceMode(TrafficAvoidanceMode)
public void clearRealisticViewAspectRatios ()
Clear all aspect ratios from the realistic view engine. After this no images will be generated unless new
aspect ratios are added with addRealisticViewAspectRatio(AspectRatio)).
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public Maneuver getAfterNextManeuver ()
Returns the Maneuver after the next Maneuver
Returns:
The Maneuver after the next Maneuver.
public long getAfterNextManeuverDistance ()
Returns the distance to the Maneuver after the next Maneuver
Returns:
distance to the Maneuver after the next Maneuver in meters. Returns -1 if an error occured or if the
maneuver after the next maneuver is not available yet.
public AudioPlayer getAudioPlayer ()
Retrieve the Audio Player instance associated with the NavigationManager
HERE Android SDK Developer's Guide
API Reference
717
Returns:
AudioPlayer instance
public double getAverageSpeed ()
Returns the current average speed.
Returns:
average speed in m/s.
public String getCountryCode ()
Gets the three-letter country code (defined in ISO 3166-1) from current location. Navigation session should be
started for this method to work.
Returns:
The country code from current location. null if the information is not available.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public long getDestinationDistance ()
Returns the current distance to destination.
Returns:
the distance to destination in meters.
public UnitSystem getDistanceUnit ()
Gets the Distance Unit. This is the measure unit used for voice guidance
Returns:
The NavigationManager.UnitSystem currently in use.
public long getElapsedDistance ()
Returns the elapsed distance from start of navigation, tracking or simulation.
Returns:
elapsed distance in meters.
public java.util.EnumSet <AudioEvent> getEnabledAudioEvents ()
HERE Android SDK Developer's Guide
API Reference
718
Gets the set of all NavigationManager.AudioEvents that are currently enabled. Safety spot ( SAFETY_SPOT)
and re-routing ( ROUTE) audio events are disabled by default.
Returns:
The set of all enabled events.
public Date getEta (boolean wholeRoute, TrafficPenaltyMode mode)
Returns the estimated time of arrival (ETA) of the route.
Parameters:
wholeRoute
Calculate ETA for the whole route if true or for the current leg if false.
mode
The TrafficPenaltyMode to use.
Returns:
A valid ETA date is returned when actively navigating on a route (when the navigation mode is NAVIGATION
or SIMULATION). Note that when a navigation event is being handled (for example, during a route
recalculation), a INVALID_ETA_DATE can be returned. A INVALID_ETA_DATE will also be returned if not actively
navigating on a route.
public float getHighSpeedWarningBoundary ()
The current speed boundary in meters/second.
Returns:
Boundary for high speed.
See also:
setSpeedWarningOptions(float, float, float)
public float getHighSpeedWarningOffset ()
The current high speed warning offset in meters/second.
Returns:
Offset in high speeds.
See also:
setSpeedWarningOptions(float, float, float)
public static NavigationManager getInstance ()
Returns:
HERE Android SDK Developer's Guide
API Reference
719
NavigationManager instance.
public float getLowSpeedWarningOffset ()
The current low speed warning offset in meters/second.
Returns:
Offset in low speeds in m/s.
See also:
setSpeedWarningOptions(float, float, float)
public MapUpdateMode getMapUpdateMode ()
Retrieves currently set MapUpdateMode
Returns:
MapUpdateMode enum value
See also:
NavigationManager.MapUpdateMode
public java.util.EnumSet <NaturalGuidanceMode> getNaturalGuidanceMode ()
Get the natural guidance modes enabled.
Returns:
All enabled natural guidance modes.
public NavigationMode getNavigationMode ()
Retrieves the current Navigation Mode
Returns:
The current NavigationManager.NavigationMode
public Maneuver getNextManeuver ()
Returns the next maneuver on the route, or null if no next maneuver.
Returns:
next Maneuver.
public long getNextManeuverDistance ()
HERE Android SDK Developer's Guide
API Reference
720
Returns the distance to the next Maneuver
Returns:
distance to the next Maneuver in meters. Returns Integer.MAX_VALUE if an error occured or if the next
maneuver is not available yet.
public java.util.EnumSet <AspectRatio> getRealisticViewAspectRatios ()
Gets the aspect ratios currently being returned.
Returns:
The EnumSet of aspect ratios.
public RealisticViewMode getRealisticViewMode ()
Returns the currently set NavigationManager.RealisticViewMode.
Returns:
The RealisticViewMode.
public RoadView getRoadView ()
Retrieve the Road View instance associated with the NavigationManager
Returns:
RoadView instance, null if RoadView is not used.
public NavigationState getRunningState ()
Retrieves the current Navigation Running State
Returns:
The current NavigationManager.NavigationState
public TrafficAvoidanceMode getTrafficAvoidanceMode ()
Get the way in which traffic should be handled during navigation.
Returns:
The current NavigationManager.TrafficAvoidanceMode.
public TrafficWarner getTrafficWarner ()
Retrieve the traffic warner instance for the navigation manager
Returns:
HERE Android SDK Developer's Guide
API Reference
721
The TrafficWarner instance currently in use.
public RouteTta getTta (TrafficPenaltyMode mode, boolean wholeRoute)
Returns the Time To Arrival (TTA).
Parameters:
mode
The Route.TrafficPenaltyMode to use for the calculation.
wholeRoute
True to return the TTA for the whole route, false to return the TTA for the next stopover waypoint.
Returns:
The current RouteTta. Can be null if not currently in guidance.
public TtsOutputFormat getTtsOutputFormat ()
Gets the TTS text output format currently in use.
Returns:
The NavigationManager.TtsOutputFormat used.
public VoiceSkin getVoiceSkin ()
Gets the voice skin currently in use.
Returns:
The voice skin.
public static boolean isManeuverVoiceoverEnabled (Action action)
Checks if guidance voice prompts are enabled for the given type of maneuver actions.
Parameters:
action
Maneuver action type to be checked.
Returns:
True if voice prompts for this maneuver action type is enabled, false otherwise.
public boolean isSpeedWarningEnabled ()
Get the speed warning status.
Returns:
HERE Android SDK Developer's Guide
API Reference
722
true speed warning is enabled, false otherwise.
public int isTtsLanguageAvailable (Locale locale)
Get the availability of the specified language as represented by the Locale .
Parameters:
locale
The Locale describing the language to be used.
Returns:
Return one of the values below:
android.speech.tts.TextToSpeech#LANG_AVAILABLE
android.speech.tts.TextToSpeech#LANG_COUNTRY_AVAILABLE
android.speech.tts.TextToSpeech#LANG_COUNTRY_VAR_AVAILABLE
android.speech.tts.TextToSpeech#LANG_MISSING_DATA
android.speech.tts.TextToSpeech#LANG_NOT_SUPPORTED
See also:
android.speech.tts.TextToSpeech
public void pause ()
Suspend Navigation temporarily.
public void removeAudioFeedbackListener (AudioFeedbackListener listener)
Remove a NavigationManager.AudioFeedbackListener previously added to NavigationManager .
Parameters:
listener
The NavigationManager.AudioFeedbackListener to be removed.
public void removeGpsSignalListener (GpsSignalListener listener)
Remove a NavigationManager.GpsSignalListener previously added to NavigationManager .
Parameters:
listener
The GpsSignalListener to be removed.
public void removeLaneInformationListener (LaneInformationListener listener)
Remove a NavigationManager.LaneInformationListener previously added to NavigationManager .
HERE Android SDK Developer's Guide
API Reference
723
Parameters:
listener
The LaneInformationListener to be removed.
public void removeManeuverEventListener (ManeuverEventListener listener)
Remove a NavigationManager.NewInstructionEventListener previously added to NavigationManager
Parameters:
listener
The NewInstructionEventListener to be removed.
public void removeNavigationManagerEventListener (NavigationManagerEventListener
listener)
Remove a NavigationManager.NavigationManagerEventListener previously added to NavigationManager
Parameters:
listener
The NavigationManagerEventListener to be removed.
public void removeNewInstructionEventListener (NewInstructionEventListener
listener)
Remove a NavigationManager.NewInstructionEventListener previously added to NavigationManager
Parameters:
listener
The NewInstructionEventListener to be removed.
public void removePositionListener (PositionListener listener)
Remove a NavigationManager.PositionListener previously added to NavigationManager .
Parameters:
listener
The PositionListener to be removed.
public void removeRealisticViewListener (RealisticViewListener listener)
Remove a NavigationManager.RealisticViewListener previously added to NavigationManager .
Parameters:
listener
HERE Android SDK Developer's Guide
API Reference
724
The NavigationManager.RealisticViewListener to be removed.
public void removeRerouteListener (RerouteListener listener)
Remove a NavigationManager.RerouteListener previously added to NavigationManager .
Parameters:
listener
The RerouteListener to be removed.
public void removeSafetySpotListener (SafetySpotListener listener)
Remove a NavigationManager.SafetySpotListener previously added to NavigationManager .
Parameters:
listener
The SafetySpotListener to be removed.
public void removeSpeedWarningListener (SpeedWarningListener listener)
Remove a NavigationManager.SpeedWarningListener previously added to NavigationManager .
Parameters:
listener
The SpeedWarningListener to be removed.
public void removeTrafficRerouteListener (TrafficRerouteListener listener)
Remove a traffic re-route listener.
Parameters:
listener
A NavigationManager.TrafficRerouteListener to be removed.
See also:
addTrafficRerouteListener(WeakReference<TrafficRerouteListener>)
public void repeatVoiceCommand ()
Repeat last voice command.
public Error resume ()
Resume paused Navigation.
HERE Android SDK Developer's Guide
API Reference
725
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
public Error setDistanceUnit (UnitSystem us)
Sets the measuring unit system that is used by voice guidance. The default UnitSystem is METRIC.
Note: If a new VoiceSkin is selected and it does not support the currently selected UnitSystem then
NavigationManager will default to METRIC. It is recommended that after calling setVoiceSkin(VoiceSkin) then
setDistanceUnit(NavigationManager.UnitSystem) be also called to setup the appropriate UnitSystem .
Parameters:
us
The desired NavigationManager.UnitSystem to be used.
Returns:
NONE if operation was successful, INVALID_OPERATION if the selected VoiceSkin does not support the
desired unit system. otherwise one of the other error codes in Error.
See also:
setVoiceSkin(VoiceSkin)
public void setEnabledAudioEvents (java.util.EnumSet <AudioEvent> events)
Used to enable/disable the playback of audio events during navigation. As the presence of an enum will
enable the desired event, likewise the absence of an enum will disable the missing event.
Parameters:
events
The set of all NavigationManager.AudioEvents to be enabled.
public static boolean setManeuverVoiceoverEnabled (Action action, boolean
enabled)
Enables or disables guidance voice prompts for a given type of maneuver action.
Parameters:
action
Maneuver voice prompt to be enabled/disabled.
enabled
State for maneuver voice prompt.
Returns:
true if operation was successful, false otherwise
HERE Android SDK Developer's Guide
API Reference
726
public void setMap (Map map)
Set Map to this Navigation Manager object and show the Navigation on Map . Passing null will remove
Navigation from the Map . Setting a new Map instance (e.g. setMap(Map1) => setMap(Map2) ) will cause
Navigation to be removed from Map1 and added to Map2 .
Note: Setting the map while Navigation is ongoing is not supported.
Parameters:
map
The Map to show the Navigation on.
public Error setMapUpdateMode (MapUpdateMode mode)
Sets the Map Update Mode, different modes changes the way position is updated. The default Map Update
Mode is NONE.
Parameters:
mode
The desired NavigationManager.MapUpdateMode to be used.
Returns:
Any NavigationManager.Error that resulted from the update
public boolean setNaturalGuidanceMode (java.util.EnumSet
<NaturalGuidanceMode> mode)
Set the natural guidance modes to be enabled. By default, all of the natural guidance modes are disabled.
Parameters:
mode
One or more natural guidance modes to be enabled
Returns:
True if all modes were set successfully. False otherwise.
public void setRealisticViewMode (RealisticViewMode mode)
Change realistic view mode. By default the feature is off. By selecting day or night (and adding an aspect
ratio with addRealisticViewAspectRatio(AspectRatio)) the feature is activated.
Parameters:
mode
The mode to set.
Throws:
AccessControlException
HERE Android SDK Developer's Guide
API Reference
727
Access to this operation is denied. Contact your HERE representative for more information.
public Error setRoute (Route route)
Sets the route navigation manager should use.
Parameters:
route
the new route navigation manager should use
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error. INVALID_PARAMETERS
if route is null or is an online public transit, bicycle or online urban mobility route (route with
TransportMode set to PUBLIC_TRANSPORT, BICYCLE or calculated using UMRouter). INVALID_OPERATION if
LocationDataSourceAutomotive is provided as position source but a non-automotive route is used ( route
with TransportMode NOT set to CAR). OPERATION_NOT_ALLOWED if access to this operation is denied.
public Error setRouteRequestInterval (int value)
Set the time period between two re-routing. Default interval is 5 minutes. This time period is applicable when
DYNAMIC or MANUAL is in use.
Parameters:
value
The new route request interval in seconds
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
See also:
setTrafficAvoidanceMode(TrafficAvoidanceMode)
public boolean setSpeedWarningEnabled (boolean value)
Set the speed warning state. The method makes it easy to turn on/off speed warning notifications during the
same navigation session. The speed warning is automatically turned on when setSpeedWarningOptions(float,
float, float) is called. Operation fails if called before starting navigation, tracking or simulation. Operation
also fails when speed warner is not available or is not initialized, (for example, in pedestrian mode).
Operation fails if stopSpeedWarning() has already been called for the current navigation session.
Parameters:
value
speed warning state. The boolean value true indicates that the speed warning is going to be turned on.
The boolean value false indicates that the speed warning is going to be turned off.
Returns:
HERE Android SDK Developer's Guide
API Reference
728
true if operation was successful , false otherwise.
public Error setSpeedWarningOptions (float lowSpeedOffset, float
highSpeedOffset, float highSpeedBoundary)
Set speed warning options. Speed warning is triggered by comparing current speed to speed limit with
offset. i.e. if you exceed the speed limit beyond the given offset a warning will be issued Speed unit is is m/s.
Operation fails if called before starting navigation, tracking or simulation. Operation fails when speed warner
is not available or is not initialized (eg:in pedestrian mode).
Parameters:
lowSpeedOffset
Offset in low speeds.
highSpeedOffset
Offset in high speeds.
highSpeedBoundary
Boundary for high speed. Above this speed high speed offset is used and below low speed offset.
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
public Error setTrafficAvoidanceMode (TrafficAvoidanceMode mode)
Set the way in which traffic should be handled during navigation. Default
NavigationManager.TrafficAvoidanceMode is DISABLE.
Parameters:
mode
The desired TrafficAvoidanceMode
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
public void setTtsOutputFormat (TtsOutputFormat format)
Sets the TTS text output format. Default format is RAW (pure text without phonemes and escape sequences).
Parameters:
format
The NavigationManager.TtsOutputFormat to use.
public Error setVoiceSkin (VoiceSkin skin)
sets the voice skin id for voice Navigation
HERE Android SDK Developer's Guide
API Reference
729
Parameters:
skin
The VoiceSkin to use.
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
public Error simulate (Route route, long speed)
Start route simulation.
Route simulation should only be used for testing purposes. Do not use this feature in a production
application.
Parameters:
route
The route to use.
speed
simulation speed in meter per second. Valid range is 0 - 4294967295.
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error. INVALID_PARAMETERS
if route is null or is an online public transit, bicycle or online urban mobility route (route with
TransportMode set to PUBLIC_TRANSPORT, BICYCLE or calculated using UMRouter). INVALID_OPERATION if
LocationDataSourceAutomotive is provided as position source but a non-automotive route is used ( route
with TransportMode NOT set to CAR). OPERATION_NOT_ALLOWED if access to this operation is denied.
public Error startNavigation (Route route)
Start navigation along the route.
Parameters:
route
The Route to use.
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error. INVALID_PARAMETERS
if route is null or is an online public transit, bicycle or online urban mobility route (route with
TransportMode set to PUBLIC_TRANSPORT, BICYCLE or calculated using UMRouter). INVALID_OPERATION if
LocationDataSourceAutomotive is provided as position source but a non-automotive route is used ( route
with TransportMode NOT set to CAR). OPERATION_NOT_ALLOWED if access to this operation is denied.
public Error startTracking ()
Start tracking mode.
HERE Android SDK Developer's Guide
API Reference
730
Returns:
NONE if operation was successful, otherwise one of the other error codes in Error.
public void stop ()
Abort the current operation, which can be route navigation, route simulation or tracking.
public void stopSpeedWarning ()
Stop speed warning notifications for the current navigation session. After this method call, changing the
speed warning state will have no effect during the current navigation session.
AspectRatio
The enumeration AspectRatio is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.AspectRatio
extends java.lang.Enum, java.lang.Object
A measure of an image's aspect ratio which is w x h.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 326: Enum Constants in AspectRatio
Fields
public static final AspectRatio AR_16x9
16 x 9
public static final AspectRatio AR_3x5
3 x 5
public static final AspectRatio AR_5x3
5 x 3
public static final AspectRatio AR_4x3
4 x 3
HERE Android SDK Developer's Guide
API Reference
731
Method Summary
Table 327: Methods in AspectRatio
Methods
public int value ()
public static AspectRatio valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.AspectRatio[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
A measure of an image's aspect ratio which is w x h.
Enum Constant Details
public static final AspectRatio AR_16x9
16 x 9
public static final AspectRatio AR_3x5
3 x 5
public static final AspectRatio AR_5x3
5 x 3
public static final AspectRatio AR_4x3
4 x 3
Method Details
public int value ()
public static AspectRatio valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
732
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.AspectRatio[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
AudioEvent
The enumeration AudioEvent is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.AudioEvent
extends java.lang.Enum, java.lang.Object
Used for enabling/disabling audio events during navigation.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 328: Enum Constants in AudioEvent
Fields
public static final AudioEvent MANEUVER
Maneuver output (maneuvers, stop-overs reached, destination reached).
public static final AudioEvent ROUTE
Route output (re-routing, route recalculated).
public static final AudioEvent GPS
GPS output (GPS lost, GPS restored).
public static final AudioEvent SPEED_LIMIT
Speed limit audio output (exceeded limit start, exceeded limit end).
public static final AudioEvent SAFETY_SPOT
Safety spot audio output (approaching safety spot).
public static final AudioEvent VIBRATION
Vibration (during walk navigation only).
HERE Android SDK Developer's Guide
API Reference
733
Method Summary
Table 329: Methods in AudioEvent
Methods
public static AudioEvent valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.AudioEvent[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Used for enabling/disabling audio events during navigation. See setEnabledAudioEvents(EnumSet).
Enum Constant Details
public static final AudioEvent MANEUVER
Maneuver output (maneuvers, stop-overs reached, destination reached).
public static final AudioEvent ROUTE
Route output (re-routing, route recalculated).
public static final AudioEvent GPS
GPS output (GPS lost, GPS restored).
public static final AudioEvent SPEED_LIMIT
Speed limit audio output (exceeded limit start, exceeded limit end).
public static final AudioEvent SAFETY_SPOT
Safety spot audio output (approaching safety spot).
public static final AudioEvent VIBRATION
Vibration (during walk navigation only). To enable, the app must also have android.permission.VIBRATE in
AndroidManifest.xml.
HERE Android SDK Developer's Guide
API Reference
734
Method Details
public static AudioEvent valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.AudioEvent[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
AudioFeedbackListener
The class AudioFeedbackListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.AudioFeedbackListener
extends java.lang.Object
AudioFeedbackListener provides callback of audio related events from NavigationManager .
[For complete information, see the section Class Details]
See also:
setVoiceSkin(VoiceSkin)
Constructor Summary
Table 330: Constructors in AudioFeedbackListener
Constructors
AudioFeedbackListener ()
Method Summary
Table 331: Methods in AudioFeedbackListener
Methods
public void onAudioEnd ()
Callback after the playing of any voice navigation command ends.
public void onAudioStart ()
Callback before the playing of any voice navigation command starts.
HERE Android SDK Developer's Guide
API Reference
735
Methods
public void onVibrationEnd ()
Callback for when vibration has finished.
public void onVibrationStart ()
Callback for when vibration is about to start.
Class Details
AudioFeedbackListener provides callback of audio related events from NavigationManager . By
default, empty implementations are provided for all callbacks, users may selectively overload specific
methods that are of interest.
See also:
setVoiceSkin(VoiceSkin)
Constructor Details
AudioFeedbackListener ()
Method Details
public void onAudioEnd ()
Callback after the playing of any voice navigation command ends.
public void onAudioStart ()
Callback before the playing of any voice navigation command starts.
public void onVibrationEnd ()
Callback for when vibration has finished. This is just an estimation as Android's Vibrator does not notify
when complete.
public void onVibrationStart ()
Callback for when vibration is about to start.
AudioPlayer
The class AudioPlayer is a member of com.here.android.mpa.guidance.NavigationManager.
HERE Android SDK Developer's Guide
API Reference
736
Class Summary
public class NavigationManager.AudioPlayer
extends java.lang.Object
[For complete information, see the section Class Details]
Field Summary
Table 332: Fields in AudioPlayer
Fields
public static final float DEFAULT_AUDIO_VOLUME
Default audio player volume
public static final float DEFAULT_SPEECH_RATE
Default speech rate
Method Summary
Table 333: Methods in AudioPlayer
Methods
public int getStreamId ()
Get the current Audio stream used by NavigationManager
public float getTtsSpeechRate ()
Gets the TTS speech rate used by NavigationManager
public float getVolume ()
Get the Audio Volume used by NavigationManager
public void setDelegate (AudioPlayerDelegate delegate)
Sets NavigationManager.AudioPlayer delegate.
public AudioPlayer setStreamId (int audioStream)
Set the Audio Stream used by NavigationManager .
public void setTtsSpeechRate (float rate)
Set the TTS speech rate used by NavigationManager when a TTS voice skin is chosen through setVoiceSkin(VoiceSkin).
public AudioPlayer setVolume (float audioVolume)
Set the Audio Volume used by NavigationManager
public void stop ()
Stop the navigation instruction currently being played.
HERE Android SDK Developer's Guide
API Reference
737
Class Details
Field Details
public static final float DEFAULT_AUDIO_VOLUME
Default audio player volume
public static final float DEFAULT_SPEECH_RATE
Default speech rate
Method Details
public int getStreamId ()
Get the current Audio stream used by NavigationManager
Returns:
the current audio stream id. One of the possible values from {code android.media.AudioManager} stream Id
constants.
See also:
android.media.AudioManager
public float getTtsSpeechRate ()
Gets the TTS speech rate used by NavigationManager
Returns:
The TTS speech rate in the range of (0.0f, 2.0f] or DEFAULT_SPEECH_RATE if a custom value is not set.
public float getVolume ()
Get the Audio Volume used by NavigationManager
Returns:
float A float percentage value in the range of [0.0f, 1.0f] or DEFAULT_AUDIO_VOLUME if a custom value is not
set
public void setDelegate (AudioPlayerDelegate delegate)
Sets NavigationManager.AudioPlayer delegate. Clients can implement AudioPlayerDelegate to take over
playback of audio files and TTS strings. Note: by delegating NavigationManager.AudioPlayer it immediately
stops all current audio and TTS playbacks by the SDK.
HERE Android SDK Developer's Guide
API Reference
738
Parameters:
delegate
The NavigationManager.AudioPlayer delegate.
public AudioPlayer setStreamId (int audioStream)
Set the Audio Stream used by NavigationManager . By default,
android.media.AudioManager.STREAM_MUSIC is used.
Parameters:
audioStream
int android.media.AudioManager for the set of system streams.
Returns:
The updated AudioPlayer object itself.
See also:
android.media.AudioManager
public void setTtsSpeechRate (float rate)
Set the TTS speech rate used by NavigationManager when a TTS voice skin is chosen through
setVoiceSkin(VoiceSkin). The specified TTS speech rate is applied immediately if a TTS voice skin is chosen
when this is called; otherwise, it will not be applied until a TTS voice skin is chosen.
Parameters:
rate
A value in the range of (0.0f, 2.0f]. Default value is DEFAULT_SPEECH_RATE. Normal speech rate is 1.0.
Smaller value results in slower speech.
See also:
DEFAULT_SPEECH_RATE
public AudioPlayer setVolume (float audioVolume)
Set the Audio Volume used by NavigationManager
The volume change will not take effect until the next navigation instruction is played. stop() can be used to
stop the currently playing instruction.
Parameters:
audioVolume
float A float percentage value in the range of [0.0f, 1.0f]. A value of DEFAULT_AUDIO_VOLUME can be set
to use the system default volume.
Returns:
HERE Android SDK Developer's Guide
API Reference
739
The updated AudioPlayer object itself.
See also:
stop()
public void stop ()
Stop the navigation instruction currently being played. Future instructions will continue to be played.
This can be used in conjunction with setVolume(float) to mute the navigation audio immediately.
See also:
setVolume(float)
Error
The enumeration Error is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.Error
extends java.lang.Enum, java.lang.Object
Navigation Manager Error
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 334: Enum Constants in Error
Fields
public static final Error NONE
There is no error
public static final Error GUIDANCE_NOT_READY
Guidance is not ready for use
public static final Error POSITIONING_FAILED
Positioning Manager failed to start for navigation use.
public static final Error NOT_READY
Guidance polling must be continued.
public static final Error OUT_OF_MEMORY
Out of memory
HERE Android SDK Developer's Guide
API Reference
740
Fields
public static final Error INVALID_PARAMETERS
Invalid parameters
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call
public static final Error NOT_FOUND
When something was not found (e.g.
public static final Error ABORTED
Operation aborted.
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied.
public static final Error INVALID_CREDENTIALS
HERE Developer credentials are invalid or were not provided
public static final Error UNKNOWN
Generic error
Method Summary
Table 335: Methods in Error
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Navigation Manager Error
Enum Constant Details
public static final Error NONE
There is no error
public static final Error GUIDANCE_NOT_READY
Guidance is not ready for use
public static final Error POSITIONING_FAILED
HERE Android SDK Developer's Guide
API Reference
741
Positioning Manager failed to start for navigation use. This could be becasue the application has not been
granted the ACCESS_FINE_LOCATION android permission at the time of the call to NavigationManager .
public static final Error NOT_READY
Guidance polling must be continued.
public static final Error OUT_OF_MEMORY
Out of memory
public static final Error INVALID_PARAMETERS
Invalid parameters
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call
public static final Error NOT_FOUND
When something was not found (e.g. voice skins)
public static final Error ABORTED
Operation aborted.
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final Error INVALID_CREDENTIALS
HERE Developer credentials are invalid or were not provided
public static final Error UNKNOWN
Generic error
Method Details
public static Error valueOf (String name)
HERE Android SDK Developer's Guide
API Reference
742
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
GpsSignalListener
The class GpsSignalListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.GpsSignalListener
extends java.lang.Object
GpsSignalListener provides callback of GPS signal related events from NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 336: Constructors in GpsSignalListener
Constructors
GpsSignalListener ()
Method Summary
Table 337: Methods in GpsSignalListener
Methods
public void onGpsLost ()
Callback for GPS signal lost event.
public void onGpsRestored ()
Callback for GPS signal restored event.
Class Details
GpsSignalListener provides callback of GPS signal related events from NavigationManager . By
default, empty implementations are provided for each callback method, users may selectively overload
specific methods that are of interest.
HERE Android SDK Developer's Guide
API Reference
743
Constructor Details
GpsSignalListener ()
Method Details
public void onGpsLost ()
Callback for GPS signal lost event.
public void onGpsRestored ()
Callback for GPS signal restored event.
LaneInformationListener
The class LaneInformationListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.LaneInformationListener
extends java.lang.Object
LaneInformationListener provides callback of LaneInformation related events from
NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 338: Constructors in LaneInformationListener
Constructors
LaneInformationListener ()
Method Summary
Table 339: Methods in LaneInformationListener
Methods
public void onLaneInformation (java.util.List <LaneInformation> lanes, RoadElement road)
Called when new information about lanes is available.
HERE Android SDK Developer's Guide
API Reference
744
Class Details
LaneInformationListener provides callback of LaneInformation related events from
NavigationManager . Used to retrieve information about the lane configuration while navigating.
No callback will be triggered if the HERE license key is invalid.
Constructor Details
LaneInformationListener ()
Method Details
public void onLaneInformation (java.util.List <LaneInformation> lanes,
RoadElement road)
Called when new information about lanes is available. This method is called whenever the current available
lane information changes. No available lane information is indicated by an empty List (e.g. lane information
should stop being displayed).
The lanes are ordered from left (index = 0) to right (index = lanes.size( ) - 1).
Parameters:
lanes
A List of LaneInformation objects. An empty List indicates that no lane information is available and
lane information should stop being shown. The lanes are ordered from left (index = 0) to right (index =
lanes.size( ) - 1).
road
The RoadElement that the LaneInformation is associated with. null if not available or if lanes is
empty.
ManeuverEventListener
The class ManeuverEventListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.ManeuverEventListener
extends java.lang.Object
ManeuverEventListener provides callback of maneuver events from NavigationManager .
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
745
Constructor Summary
Table 340: Constructors in ManeuverEventListener
Constructors
ManeuverEventListener ()
Method Summary
Table 341: Methods in ManeuverEventListener
Methods
public void onManeuverEvent ()
Callback for new maneuver event.
Class Details
ManeuverEventListener provides callback of maneuver events from NavigationManager . By default,
an empty implementation is provided for the callback method.
Constructor Details
ManeuverEventListener ()
Method Details
public void onManeuverEvent ()
Callback for new maneuver event. This callback is in sync with the playback of audio maneuver commands
Note that if this new maneuver event is a Maneuver.Action#STOPOVER, you will receive an additional
callback, onStopoverReached(int).
See also:
getNextManeuver()
getNextManeuverDistance()
getAfterNextManeuver()
getAfterNextManeuverDistance()
MapUpdateMode
The enumeration MapUpdateMode is a member of com.here.android.mpa.guidance.NavigationManager.
HERE Android SDK Developer's Guide
API Reference
746
Enumeration Summary
public static final enumeration NavigationManager.MapUpdateMode
extends java.lang.Enum, java.lang.Object
Map Update Mode
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 342: Enum Constants in MapUpdateMode
Fields
public static final MapUpdateMode NONE
No automatic map movement (only PositionIndicator would move to reflect current location)
public static final MapUpdateMode POSITION
Map updated with new position and direction
public static final MapUpdateMode POSITION_ANIMATION
Map updated with new position and direction with animated movement
public static final MapUpdateMode ROADVIEW
Map updated using NavigationManager.RoadView, with zoom level automatically adjusted according to the approaching
maneuver, road type and speed.
public static final MapUpdateMode ROADVIEW_NOZOOM
Map updated using NavigationManager.RoadView
Method Summary
Table 343: Methods in MapUpdateMode
Methods
public int value ()
public static MapUpdateMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.MapUpdateMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Map Update Mode
Enum Constant Details
public static final MapUpdateMode NONE
HERE Android SDK Developer's Guide
API Reference
747
No automatic map movement (only PositionIndicator would move to reflect current location)
public static final MapUpdateMode POSITION
Map updated with new position and direction
public static final MapUpdateMode POSITION_ANIMATION
Map updated with new position and direction with animated movement
public static final MapUpdateMode ROADVIEW
Map updated using NavigationManager.RoadView, with zoom level automatically adjusted according to the
approaching maneuver, road type and speed.
public static final MapUpdateMode ROADVIEW_NOZOOM
Map updated using NavigationManager.RoadView
Method Details
public int value ()
public static MapUpdateMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.MapUpdateMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
NaturalGuidanceMode
The enumeration NaturalGuidanceMode is a member of com.here.android.mpa.guidance.NavigationManager.
HERE Android SDK Developer's Guide
API Reference
748
Enumeration Summary
public static final enumeration NavigationManager.NaturalGuidanceMode
extends java.lang.Enum, java.lang.Object
Enum used to turn on/off features within natural guidance.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 344: Enum Constants in NaturalGuidanceMode
Fields
public static final NaturalGuidanceMode TRAFFIC_LIGHT
Natural guidance for traffic lights.
public static final NaturalGuidanceMode STOP_SIGN
Natural guidance for stop signs.
public static final NaturalGuidanceMode JUNCTION
Natural guidance for junctions.
Method Summary
Table 345: Methods in NaturalGuidanceMode
Methods
public int value ()
public static NaturalGuidanceMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.NaturalGuidanceMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum used to turn on/off features within natural guidance.
Enum Constant Details
public static final NaturalGuidanceMode TRAFFIC_LIGHT
Natural guidance for traffic lights.
public static final NaturalGuidanceMode STOP_SIGN
Natural guidance for stop signs.
HERE Android SDK Developer's Guide
API Reference
749
public static final NaturalGuidanceMode JUNCTION
Natural guidance for junctions.
Method Details
public int value ()
public static NaturalGuidanceMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.NaturalGuidanceMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
NavigationManagerEventListener
The class NavigationManagerEventListener is a member of
com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.NavigationManagerEventListener
extends java.lang.Object
NavigationManagerEventListener provides callback of general navigation manager related events from
NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 346: Constructors in NavigationManagerEventListener
Constructors
NavigationManagerEventListener ()
HERE Android SDK Developer's Guide
API Reference
750
Method Summary
Table 347: Methods in NavigationManagerEventListener
Methods
public void onCountryInfo (String currentCountry, String nextCountry)
Callback when country changes.
public void onEnded (NavigationMode mode)
Callback when navigation, simulation or tracking has just been ended.
public void onMapDataAvailable ()
Called when navigation manager resumes after previously suspending due to a lack of map data.
public void onMapDataInsufficient ()
Called when navigation manager suspends due to insufficient map data.
public void onMapUpdateModeChanged (MapUpdateMode mode)
Callback when the map update mode has been changed
public void onNavigationModeChanged ()
Callback for Navigation Mode changed event.
public void onRouteUpdated (Route newRoute)
Callback to notify that setRoute(Route) has taken effect.
public void onRunningStateChanged ()
Callback for Navigation Manager state changed event.
public void onStopoverReached (int index)
Callback indicating that a route stopover has been reached.
Class Details
NavigationManagerEventListener provides callback of general navigation manager related events
from NavigationManager . By default, empty implementations are provided for each callback, users may
selectively overload specific methods that are of interest.
Constructor Details
NavigationManagerEventListener ()
Method Details
public void onCountryInfo (String currentCountry, String nextCountry)
Callback when country changes.
No callback will be triggered if the HERE license key is invalid.
Parameters:
HERE Android SDK Developer's Guide
API Reference
751
currentCountry
The 3-letter country code related to current position
nextCountry
The 3-letter country code you are entering
public void onEnded (NavigationMode mode)
Callback when navigation, simulation or tracking has just been ended.
Parameters:
mode
The NavigationManager.NavigationMode indication which action (navigation, simulation or tracking) that
has been ended.
public void onMapDataAvailable ()
Called when navigation manager resumes after previously suspending due to a lack of map data.
This may be used as a notification that the map data for guidance is available again after previously being
unavailable for the current location. This callback is only made if onMapDataInsufficient() was previously
called. This callback will not be made if guidance is stopped before map data becomes available again.
public void onMapDataInsufficient ()
Called when navigation manager suspends due to insufficient map data.
In order to operate NavigationManager relies on a constant stream of map matched positions from
PositioningManager. One reason that map matching can fail is if map data for the current location is
not available. If this situation arises then this callback will be made. If Map has never been used to view
a particular location since your app was installed (note that map data is cached across app launches),
MapLoader has not been used to download an MapPackage for this location, no network connection is
available and navigation progresses to this location then the scenario described above will occur. To
guarantee that navigation never encounters problems in poor network conditions use MapLoader to
download map data for the region being navigated. Once map data is available again, onMapDataAvailable()
will be called.
public void onMapUpdateModeChanged (MapUpdateMode mode)
Callback when the map update mode has been changed
Parameters:
mode
The new NavigationManager.MapUpdateMode.
HERE Android SDK Developer's Guide
API Reference
752
public void onNavigationModeChanged ()
Callback for Navigation Mode changed event.
public void onRouteUpdated (Route newRoute)
Callback to notify that setRoute(Route) has taken effect.
Parameters:
newRoute
The new Route used by the NavigationManager.
public void onRunningStateChanged ()
Callback for Navigation Manager state changed event.
public void onStopoverReached (int index)
Callback indicating that a route stopover has been reached.
Note that in addition to this, onManeuverEvent() callback will also be received. Furthermore, note that a
RouteWaypoint of type RouteWaypoint.Type#VIA_WAYPOINT is not considered to be a route stopover.
Parameters:
index
The index of the stopover that was reached, starting from 0. Stopovers can be retrieved by index from
the RoutePlan.
See also:
getWaypoint(int)
NavigationMode
The enumeration NavigationMode is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.NavigationMode
extends java.lang.Enum, java.lang.Object
Possible Navigation Modes
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
753
Enum Constant Summary
Table 348: Enum Constants in NavigationMode
Fields
public static final NavigationMode NONE
Navigation is inactive.
public static final NavigationMode SIMULATION
Navigation is running in simulation mode (following a calculated route without using real GPS data)
public static final NavigationMode NAVIGATION
Navigation is running in navigation mode (following a route using GPS data, recalculation will occur if position deviates
from route)
public static final NavigationMode TRACKING
Navigation is running in tracking mode (Not following a route, real GPS data drives map movement)
Method Summary
Table 349: Methods in NavigationMode
Methods
public static NavigationMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.NavigationMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Possible Navigation Modes
Enum Constant Details
public static final NavigationMode NONE
Navigation is inactive.
public static final NavigationMode SIMULATION
Navigation is running in simulation mode (following a calculated route without using real GPS data)
public static final NavigationMode NAVIGATION
Navigation is running in navigation mode (following a route using GPS data, recalculation will occur if
position deviates from route)
HERE Android SDK Developer's Guide
API Reference
754
public static final NavigationMode TRACKING
Navigation is running in tracking mode (Not following a route, real GPS data drives map movement)
Method Details
public static NavigationMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.NavigationMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
NavigationState
The enumeration NavigationState is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.NavigationState
extends java.lang.Enum, java.lang.Object
Possible states of navigation
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 350: Enum Constants in NavigationState
Fields
public static final NavigationState IDLE
Navigation has not been started, or is finished
public static final NavigationState RUNNING
Navigation is currently running
public static final NavigationState PAUSED
Navigation has been paused mid-route
HERE Android SDK Developer's Guide
API Reference
755
Method Summary
Table 351: Methods in NavigationState
Methods
public static NavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.NavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Possible states of navigation
Enum Constant Details
public static final NavigationState IDLE
Navigation has not been started, or is finished
public static final NavigationState RUNNING
Navigation is currently running
public static final NavigationState PAUSED
Navigation has been paused mid-route
Method Details
public static NavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.NavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
756
NewInstructionEventListener
The class NewInstructionEventListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.NewInstructionEventListener
extends java.lang.Object
NewInstructionEventListener provides callback of new instruction events from NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 352: Constructors in NewInstructionEventListener
Constructors
NewInstructionEventListener ()
Method Summary
Table 353: Methods in NewInstructionEventListener
Methods
public void onNewInstructionEvent ()
Callback for New Instruction event.
Class Details
NewInstructionEventListener provides callback of new instruction events from NavigationManager .
By default, an empty implementation is provided for the callback method.
Constructor Details
NewInstructionEventListener ()
Method Details
public void onNewInstructionEvent ()
Callback for New Instruction event.
See also:
getNextManeuver()
getNextManeuverDistance()
HERE Android SDK Developer's Guide
API Reference
757
getAfterNextManeuver()
getAfterNextManeuverDistance()
PositionListener
The class PositionListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.PositionListener
extends java.lang.Object
PositionListener provides callback of position events from NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 354: Constructors in PositionListener
Constructors
PositionListener ()
Method Summary
Table 355: Methods in PositionListener
Methods
public void onPositionUpdated (GeoPosition loc)
Callback for Position Updated event.
Class Details
PositionListener provides callback of position events from NavigationManager . By default, an empty
implementation is provided for the callback method.
Constructor Details
PositionListener ()
Method Details
public void onPositionUpdated (GeoPosition loc)
Callback for Position Updated event.
HERE Android SDK Developer's Guide
API Reference
758
Parameters:
loc
the updated position.
RealisticViewListener
The class RealisticViewListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.RealisticViewListener
extends java.lang.Object
RealisticViewListenerAdapter provides callback of realistic view related events from
NavigationManager .
[For complete information, see the section Class Details]
See also:
setRealisticViewMode(RealisticViewMode)
Constructor Summary
Table 356: Constructors in RealisticViewListener
Constructors
RealisticViewListener ()
Method Summary
Table 357: Methods in RealisticViewListener
Methods
public void onRealisticViewHide ()
Callback for hiding the realistic view.
public void onRealisticViewNextManeuver (AspectRatio ratio, Image junctionImage, Image
signImageIn2D)
Callback for notifying the junction view and 2D sign image for the next maneuver.
public void onRealisticViewShow (AspectRatio ratio, Image junctionImage, Image signImageIn2D)
Callback for showing a junction view and 2D sign image.
HERE Android SDK Developer's Guide
API Reference
759
Class Details
RealisticViewListenerAdapter provides callback of realistic view related events from
NavigationManager . By default, empty implementations are provided for all callbacks, users may
selectively overload specific methods that are of interest.
No callback will be triggered if the HERE license key is invalid.
See also:
setRealisticViewMode(RealisticViewMode)
Constructor Details
RealisticViewListener ()
Method Details
public void onRealisticViewHide ()
Callback for hiding the realistic view.
public void onRealisticViewNextManeuver (AspectRatio ratio, Image
junctionImage, Image signImageIn2D)
Callback for notifying the junction view and 2D sign image for the next maneuver.
Parameters:
ratio
The aspect ratio of the returned images.
junctionImage
The junction view image.
signImageIn2D
The 2D sign image.
public void onRealisticViewShow (AspectRatio ratio, Image junctionImage,
Image signImageIn2D)
Callback for showing a junction view and 2D sign image.
Parameters:
ratio
The aspect ratio of the returned images.
junctionImage
The junction view image.
signImageIn2D
HERE Android SDK Developer's Guide
API Reference
760
A 2D sign image.
RealisticViewMode
The enumeration RealisticViewMode is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.RealisticViewMode
extends java.lang.Enum, java.lang.Object
Enum used to turn on/off realistic view (junction view and 2D signs).
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 358: Enum Constants in RealisticViewMode
Fields
public static final RealisticViewMode OFF
Off.
public static final RealisticViewMode DAY
Day.
public static final RealisticViewMode NIGHT
Night.
Method Summary
Table 359: Methods in RealisticViewMode
Methods
public int value ()
public static RealisticViewMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.RealisticViewMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum used to turn on/off realistic view (junction view and 2D signs).
HERE Android SDK Developer's Guide
API Reference
761
Enum Constant Details
public static final RealisticViewMode OFF
Off.
public static final RealisticViewMode DAY
Day.
public static final RealisticViewMode NIGHT
Night.
Method Details
public int value ()
public static RealisticViewMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.RealisticViewMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RerouteListener
The class RerouteListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.RerouteListener
extends java.lang.Object
RerouteListener provides callback of route re-calculation related events from NavigationManager .
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
762
Constructor Summary
Table 360: Constructors in RerouteListener
Constructors
RerouteListener ()
Method Summary
Table 361: Methods in RerouteListener
Methods
public void onRerouteBegin ()
Callback for Re-route begin event.
public void onRerouteEnd (Route route)
Deprecated: As of SDK 3.4.
Callback for Re-route end event
public void onRerouteEnd (RouteResult routeResult)
Callback for Re-route end event.
public void onRerouteFailed ()
Callback for Re-route failure event.
Class Details
RerouteListener provides callback of route re-calculation related events from NavigationManager .
By default, empty implementations are provided for each callback method, users may selectively overload
specific methods that are of interest.
Note that this is different from route re-calculation due to traffic avoidance, instead, this normally triggered
when user strays away from course. See NavigationManager.TrafficAvoidanceMode.
Constructor Details
RerouteListener ()
Method Details
public void onRerouteBegin ()
Callback for Re-route begin event.
public void onRerouteEnd (Route route)
Deprecated: As of SDK 3.4.
HERE Android SDK Developer's Guide
API Reference
763
Instead use onRerouteEnd(RouteResult).
Callback for Re-route end event
Parameters:
route
The newly calculated Route.
public void onRerouteEnd (RouteResult routeResult)
Callback for Re-route end event.
Parameters:
routeResult
The RouteResult object.
See also:
getViolatedOptions()
public void onRerouteFailed ()
Callback for Re-route failure event.
RoadView
The class RoadView is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static class NavigationManager.RoadView
extends java.lang.Object
This static class controls road view of turn by turn navigation.
[For complete information, see the section Class Details]
Nested Class Summary
Table 362: Nested Classes in RoadView
Nested Classes
public static abstract interface NavigationManager.RoadView.Listener
Interface to report RoadView events.
public static abstract class NavigationManager.RoadView.ListenerAdapter
class and overload specific methods to have a smaller code footprint.
HERE Android SDK Developer's Guide
API Reference
764
Nested Classes
public static final enumeration NavigationManager.RoadView.Orientation
Used for setting the orientation when ROADVIEW or ROADVIEW_NOZOOM is used.
Method Summary
Table 363: Methods in RoadView
Methods
public void addListener (java.lang.ref.WeakReference <RoadView.Listener> listener)
Adds a Road View event listener as a WeakReference.
public boolean getAnimationEnabled ()
Deprecated: As of SDK 3.5.
checks if animation between map movements is enabled.
public Orientation getOrientation ()
Gets the current orientation used by ROADVIEW and ROADVIEW_NOZOOM.
public void removeListener (Listener listener)
Remove Road View event listener.
public void setAnimationEnabled (boolean enabled)
Deprecated: As of SDK 3.5.
set usage of animation between map movements.
public void setOrientation (Orientation orientation)
Sets the orientation for ROADVIEW and ROADVIEW_NOZOOM.
public Error zoomIn ()
Zooms in the map.
public Error zoomOut ()
Zooms out the map.
Class Details
This static class controls road view of turn by turn navigation.
Method Details
public void addListener (java.lang.ref.WeakReference <RoadView.Listener>
listener)
Adds a Road View event listener as a WeakReference.
Parameters:
listener
the Road View event listener to add.
HERE Android SDK Developer's Guide
API Reference
765
public boolean getAnimationEnabled ()
Deprecated: As of SDK 3.5.
This feature is no longer supported.
checks if animation between map movements is enabled.
Returns:
true if smooth animation is enabled between map movements in road view, false if no animation is used
public Orientation getOrientation ()
Gets the current orientation used by ROADVIEW and ROADVIEW_NOZOOM.
Returns:
The NavigationManager.RoadView.Orientation currently in use.
public void removeListener (Listener listener)
Remove Road View event listener.
Parameters:
listener
the Road View event listener to remove.
public void setAnimationEnabled (boolean enabled)
Deprecated: As of SDK 3.5.
This feature is no longer supported.
set usage of animation between map movements.
Parameters:
enabled
true if smooth animation is enabled between map movements in road view, false if no animation is used.
Note: Use of animation is disabled by default and should only be enabled when ROADVIEW_NOZOOM is
used.
public void setOrientation (Orientation orientation)
Sets the orientation for ROADVIEW and ROADVIEW_NOZOOM. This method is only effective after the
navigation has started running, otherwise DYNAMIC is used by default.
HERE Android SDK Developer's Guide
API Reference
766
Parameters:
orientation
The NavigationManager.RoadView.Orientation to use.
public Error zoomIn ()
Zooms in the map.
Returns:
NONE on success.
public Error zoomOut ()
Zooms out the map.
Returns:
NONE on success.
Listener
The interface Listener is a member of com.here.android.mpa.guidance.NavigationManager.RoadView.
Interface Summary
public static abstract interface NavigationManager.RoadView.Listener
Interface to report RoadView events.
[For complete information, see the section Interface Details]
Method Summary
Table 364: Methods in Listener
Methods
public abstract void onPositionChanged (GeoCoordinate geoCoordinate)
Callback when the position used by Road View has been changed.
Interface Details
Interface to report RoadView events.
Method Details
public abstract void onPositionChanged (GeoCoordinate geoCoordinate)
HERE Android SDK Developer's Guide
API Reference
767
Callback when the position used by Road View has been changed. The main use case of this callback is
for position indicator updates if client decides to implement their own for navigation with RoadView. This
ensures a smooth tranistion of the indicator along with map movements as the operation is synchronized.
Note:: please do not perform a synchronized map redraw with this position update as this callback is within
the scope of navigation manager's poll which is already doing a synchronized redraw. Any additional blocking
operation will cause a deadlock.
Parameters:
geoCoordinate
GeoCoordinate
ListenerAdapter
The class ListenerAdapter is a member of com.here.android.mpa.guidance.NavigationManager.RoadView.
Class Summary
public static abstract class NavigationManager.RoadView.ListenerAdapter
implements com.here.android.mpa.guidance.NavigationManager.RoadView.Listener
extends java.lang.Object
class and overload specific methods to have a smaller code footprint.
[For complete information, see the section Class Details]
See also:
NavigationManager.RoadView.Listener
Constructor Summary
Table 365: Constructors in ListenerAdapter
Constructors
ListenerAdapter ()
Method Summary
Table 366: Methods in ListenerAdapter
Methods
public void onPositionChanged (GeoCoordinate geoCoordinate)
Callback when the position used by Road View has been changed
Class Details
class and overload specific methods to have a smaller code footprint.
HERE Android SDK Developer's Guide
API Reference
768
See also:
NavigationManager.RoadView.Listener
Constructor Details
ListenerAdapter ()
Method Details
public void onPositionChanged (GeoCoordinate geoCoordinate)
Callback when the position used by Road View has been changed
Parameters:
geoCoordinate
GeoCoordinate
Orientation
The enumeration Orientation is a member of com.here.android.mpa.guidance.NavigationManager.RoadView.
Enumeration Summary
public static final enumeration NavigationManager.RoadView.Orientation
extends java.lang.Enum, java.lang.Object
Used for setting the orientation when ROADVIEW or ROADVIEW_NOZOOM is used.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 367: Enum Constants in Orientation
Fields
public static final Orientation DYNAMIC
Heading is at the top of the screen.
public static final Orientation NORTH_UP
North is at the top of the screen.
HERE Android SDK Developer's Guide
API Reference
769
Method Summary
Table 368: Methods in Orientation
Methods
public int value ()
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.RoadView.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Used for setting the orientation when ROADVIEW or ROADVIEW_NOZOOM is used.
Enum Constant Details
public static final Orientation DYNAMIC
Heading is at the top of the screen.
public static final Orientation NORTH_UP
North is at the top of the screen.
Method Details
public int value ()
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.RoadView.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
770
SafetySpotListener
The class SafetySpotListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.SafetySpotListener
extends java.lang.Object
SafetySpotListener provides callback of safety spot related events from NavigationManager .
[For complete information, see the section Class Details]
Constructor Summary
Table 369: Constructors in SafetySpotListener
Constructors
SafetySpotListener ()
Method Summary
Table 370: Methods in SafetySpotListener
Methods
public void onSafetySpot (SafetySpotNotification notification)
Callback to signal when safety spot notifications are available.
Class Details
SafetySpotListener provides callback of safety spot related events from NavigationManager . By
default, an empty implementation for the callback method is provided.
No callback will be triggered if the HERE license key is invalid.
Constructor Details
SafetySpotListener ()
Method Details
public void onSafetySpot (SafetySpotNotification notification)
Callback to signal when safety spot notifications are available.
Parameters:
notification
HERE Android SDK Developer's Guide
API Reference
771
the safety spot notification.
SpeedWarningListener
The class SpeedWarningListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.SpeedWarningListener
extends java.lang.Object
SpeedListener provides callback of speed warning related events from NavigationManager .
[For complete information, see the section Class Details]
See also:
setSpeedWarningEnabled(boolean)
setSpeedWarningOptions(float, float, float)
Constructor Summary
Table 371: Constructors in SpeedWarningListener
Constructors
SpeedWarningListener ()
Method Summary
Table 372: Methods in SpeedWarningListener
Methods
public void onSpeedExceeded (String roadName, float speedLimit)
Callback for Speed limit exceeded event.
public void onSpeedExceededEnd (String roadName, float speedLimit)
Callback for Speed limit no longer exceeded event.
Class Details
SpeedListener provides callback of speed warning related events from NavigationManager . By default,
empty implementations are provided for each callback method, users may selectively overload specific
methods that are of interest.
See also:
setSpeedWarningEnabled(boolean)
HERE Android SDK Developer's Guide
API Reference
772
setSpeedWarningOptions(float, float, float)
Constructor Details
SpeedWarningListener ()
Method Details
public void onSpeedExceeded (String roadName, float speedLimit)
Callback for Speed limit exceeded event.
Parameters:
roadName
Road name.
speedLimit
Current speed limit in meters per second.
public void onSpeedExceededEnd (String roadName, float speedLimit)
Callback for Speed limit no longer exceeded event.
Parameters:
roadName
Road name.
speedLimit
Current speed limit in meters per second.
TrafficAvoidanceMode
The enumeration TrafficAvoidanceMode is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.TrafficAvoidanceMode
extends java.lang.Enum, java.lang.Object
Specifies if traffic should be automatically avoided or not during navigation
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
773
Enum Constant Summary
Table 373: Enum Constants in TrafficAvoidanceMode
Fields
public static final TrafficAvoidanceMode DYNAMIC
Route recalculated periodically taking traffic data into account.
public static final TrafficAvoidanceMode MANUAL
Traffic on route avoidance must be confirmed by the user
public static final TrafficAvoidanceMode DISABLE
Disable use of traffic for rerouting purpose
Method Summary
Table 374: Methods in TrafficAvoidanceMode
Methods
public int value ()
public static TrafficAvoidanceMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.TrafficAvoidanceMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies if traffic should be automatically avoided or not during navigation
Enum Constant Details
public static final TrafficAvoidanceMode DYNAMIC
Route recalculated periodically taking traffic data into account. Updates automatically if the new route is
better than existing one.
public static final TrafficAvoidanceMode MANUAL
Traffic on route avoidance must be confirmed by the user
public static final TrafficAvoidanceMode DISABLE
Disable use of traffic for rerouting purpose
HERE Android SDK Developer's Guide
API Reference
774
Method Details
public int value ()
public static TrafficAvoidanceMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.TrafficAvoidanceMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficRerouteListener
The class TrafficRerouteListener is a member of com.here.android.mpa.guidance.NavigationManager.
Class Summary
public static abstract class NavigationManager.TrafficRerouteListener
extends java.lang.Object
This adapter class receives notifications from NavigationManager that indicates traffic re-routing events
due to the use of different NavigationManager.TrafficAvoidanceModes.
[For complete information, see the section Class Details]
See also:
setTrafficAvoidanceMode(TrafficAvoidanceMode)
Nested Class Summary
Table 375: Nested Classes in TrafficRerouteListener
Nested Classes
public static final enumeration NavigationManager.TrafficRerouteListener.TrafficEnabledRoutingState
Enum used to describes the current route re-calculation due to traffic's status.
HERE Android SDK Developer's Guide
API Reference
775
Constructor Summary
Table 376: Constructors in TrafficRerouteListener
Constructors
TrafficRerouteListener ()
Method Summary
Table 377: Methods in TrafficRerouteListener
Methods
public void onTrafficRerouteBegin (TrafficNotification notification)
Callback that is triggered when traffic-based route re-calculation has begun as a result of of a TrafficNotification.
public void onTrafficRerouteFailed (TrafficNotification notification)
Callback that is triggered when traffic-based route re-calculation has failed.
public void onTrafficRerouteState (TrafficEnabledRoutingState state)
Callback to inform the user about current state of traffic enabled routing feature.
public void onTrafficRerouted (Route newRoute)
Deprecated: As of SDK 3.4.
Callback to indicate a new Route that has been calculated as a result of MANUAL being in use.
public void onTrafficRerouted (RouteResult newRouteResult)
Callback to indicate a new Route that has been calculated as a result of MANUAL being in use.
Class Details
This adapter class receives notifications from NavigationManager that indicates traffic re-routing events
due to the use of different NavigationManager.TrafficAvoidanceModes.
It provides an empty implementation by default. Sub-class of this adapter can selectively override methods
that are of interest.
See also:
setTrafficAvoidanceMode(TrafficAvoidanceMode)
Constructor Details
TrafficRerouteListener ()
Method Details
public void onTrafficRerouteBegin (TrafficNotification notification)
HERE Android SDK Developer's Guide
API Reference
776
Callback that is triggered when traffic-based route re-calculation has begun as a result of of a
TrafficNotification.
Parameters:
notification
The TrafficNotification contains the avoided traffic events.
public void onTrafficRerouteFailed (TrafficNotification notification)
Callback that is triggered when traffic-based route re-calculation has failed.
Parameters:
notification
The TrafficNotification associated with the callback.
public void onTrafficRerouteState (TrafficEnabledRoutingState state)
Callback to inform the user about current state of traffic enabled routing feature. Note that this callback will
be triggered repeatedly during navigation.
Parameters:
state
An enum TrafficEnabledRoutingState representing the current traffic enabled routing state.
See also:
setTrafficAvoidanceMode(TrafficAvoidanceMode)
public void onTrafficRerouted (Route newRoute)
Deprecated: As of SDK 3.4.
Instead use onTrafficRerouted(RouteResult).
Callback to indicate a new Route that has been calculated as a result of MANUAL being in use. The new
Route is the fastest available at the time of the route calculation. Note: Clients can call setRoute(Route) to
start using this new route.
Parameters:
newRoute
The newly calculated Route.
public void onTrafficRerouted (RouteResult newRouteResult)
Callback to indicate a new Route that has been calculated as a result of MANUAL being in use. The new
Route is the fastest available at the time of the route calculation. Note: Clients can call setRoute(Route) from
RouteResult.getRoute() to start using this new route.
HERE Android SDK Developer's Guide
API Reference
777
Parameters:
newRouteResult
The result indicating the new route.
See also:
getViolatedOptions()
TrafficEnabledRoutingState
The enumeration TrafficEnabledRoutingState is a member of
com.here.android.mpa.guidance.NavigationManager.TrafficRerouteListener.
Enumeration Summary
public static final enumeration NavigationManager.TrafficRerouteListener.TrafficEnabledRoutingState
extends java.lang.Enum, java.lang.Object
Enum used to describes the current route re-calculation due to traffic's status.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 378: Enum Constants in TrafficEnabledRoutingState
Fields
public static final TrafficEnabledRoutingState OFF
Route re-calculation due to traffic is disabled, when traffic avoidance mode is set to DISABLE.
public static final TrafficEnabledRoutingState ON
Route re-calculation due to traffic is enabled and not currently in use.
public static final TrafficEnabledRoutingState ONGOING_REQUEST
Deprecated: As of SDK 3.4.
Route re-calculation is enabled and it currently handling the on-going re-routing.
public static final TrafficEnabledRoutingState NOT_AVAILABLE
Route re-calculation is enabled but re-routing cannot be processed.
Method Summary
Table 379: Methods in TrafficEnabledRoutingState
Methods
public static TrafficEnabledRoutingState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
778
Methods
public static NavigationManager.TrafficRerouteListener.TrafficEnabledRoutingState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum used to describes the current route re-calculation due to traffic's status.
Enum Constant Details
public static final TrafficEnabledRoutingState OFF
Route re-calculation due to traffic is disabled, when traffic avoidance mode is set to DISABLE.
public static final TrafficEnabledRoutingState ON
Route re-calculation due to traffic is enabled and not currently in use.
public static final TrafficEnabledRoutingState ONGOING_REQUEST
Deprecated: As of SDK 3.4.
Will not occur.
Route re-calculation is enabled and it currently handling the on-going re-routing.
public static final TrafficEnabledRoutingState NOT_AVAILABLE
Route re-calculation is enabled but re-routing cannot be processed. For example, the application is currently
offline.
Method Details
public static TrafficEnabledRoutingState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.TrafficRerouteListener.TrafficEnabledRoutingState[] values
()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
779
TtsOutputFormat
The enumeration TtsOutputFormat is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.TtsOutputFormat
extends java.lang.Enum, java.lang.Object
Used for specifying TTS output format in which the text should be generated.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 380: Enum Constants in TtsOutputFormat
Fields
public static final TtsOutputFormat RAW
The text won't include any phonemes and escape sequences.
public static final TtsOutputFormat NUANCE
The text will include phonemes in a format supported by Nuance TTS.
Method Summary
Table 381: Methods in TtsOutputFormat
Methods
public static TtsOutputFormat valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.TtsOutputFormat[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Used for specifying TTS output format in which the text should be generated. See
setTtsOutputFormat(NavigationManager.TtsOutputFormat).
Enum Constant Details
public static final TtsOutputFormat RAW
The text won't include any phonemes and escape sequences.
HERE Android SDK Developer's Guide
API Reference
780
public static final TtsOutputFormat NUANCE
The text will include phonemes in a format supported by Nuance TTS.
Method Details
public static TtsOutputFormat valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.TtsOutputFormat[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UnitSystem
The enumeration UnitSystem is a member of com.here.android.mpa.guidance.NavigationManager.
Enumeration Summary
public static final enumeration NavigationManager.UnitSystem
extends java.lang.Enum, java.lang.Object
Supported unit system types
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 382: Enum Constants in UnitSystem
Fields
public static final UnitSystem METRIC
Meter and kilometer
public static final UnitSystem IMPERIAL
Miles and yards
public static final UnitSystem IMPERIAL_US
Miles and feet
HERE Android SDK Developer's Guide
API Reference
781
Method Summary
Table 383: Methods in UnitSystem
Methods
public int value ()
public static UnitSystem valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static NavigationManager.UnitSystem[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Supported unit system types
Enum Constant Details
public static final UnitSystem METRIC
Meter and kilometer
public static final UnitSystem IMPERIAL
Miles and yards
public static final UnitSystem IMPERIAL_US
Miles and feet
Method Details
public int value ()
public static UnitSystem valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static NavigationManager.UnitSystem[] values ()
HERE Android SDK Developer's Guide
API Reference
782
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SafetySpotNotification
The class SafetySpotNotification is a member of com.here.android.mpa.guidance .
Class Summary
public final class SafetySpotNotification
extends java.lang.Object
Notification of incoming safety spots during navigation/tracking.
[For complete information, see the section Class Details]
Method Summary
Table 384: Methods in SafetySpotNotification
Methods
public java.util.List <SafetySpotNotificationInfo> getSafetySpotNotificationInfos ()
Gets the list of SafetySpotNotificationInfo associated with this notification.
public double getSpeed ()
Gets the speed at which the safety spots are approached in m/s.
Class Details
Notification of incoming safety spots during navigation/tracking.
Method Details
public java.util.List <SafetySpotNotificationInfo> getSafetySpotNotificationInfos
()
Gets the list of SafetySpotNotificationInfo associated with this notification.
Returns:
The list of SafetySpotNotificationInfo.
public double getSpeed ()
Gets the speed at which the safety spots are approached in m/s.
Returns:
The speed.
HERE Android SDK Developer's Guide
API Reference
783
SafetySpotNotificationInfo
The class SafetySpotNotificationInfo is a member of com.here.android.mpa.guidance .
Class Summary
public final class SafetySpotNotificationInfo
extends java.lang.Object
Notification information for this safety spot.
[For complete information, see the section Class Details]
Method Summary
Table 385: Methods in SafetySpotNotificationInfo
Methods
public long getDistance ()
Gets the distance to this safety spot.
public SafetySpotInfo getSafetySpot ()
Gets the safety spot associated with this notification info.
public String toString ()
For documentation, see java.lang.Object
Class Details
Notification information for this safety spot.
Method Details
public long getDistance ()
Gets the distance to this safety spot.
Returns:
The distance in meters.
public SafetySpotInfo getSafetySpot ()
Gets the safety spot associated with this notification info.
Returns:
The safety spot.
HERE Android SDK Developer's Guide
API Reference
784
public String toString ()
For documentation, see java.lang.Object
TrafficNotification
The class TrafficNotification is a member of com.here.android.mpa.guidance .
Class Summary
public final class TrafficNotification
extends java.lang.Object
Represents the traffic notification for the current navigation session.
[For complete information, see the section Class Details]
Method Summary
Table 386: Methods in TrafficNotification
Methods
public java.util.List <TrafficNotificationInfo> getInfoList ()
Retrieves the list of traffic notification infos TrafficNotificationInfo associated with the traffic notification TrafficNotification
public String toString ()
For documentation, see java.lang.Object
Class Details
Represents the traffic notification for the current navigation session.
Method Details
public java.util.List <TrafficNotificationInfo> getInfoList ()
Retrieves the list of traffic notification infos TrafficNotificationInfo associated with the traffic notification
TrafficNotification
Returns:
a list of traffic notification info
public String toString ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
785
TrafficNotificationInfo
The class TrafficNotificationInfo is a member of com.here.android.mpa.guidance .
Class Summary
public final class TrafficNotificationInfo
extends java.lang.Object
Represents the details information for the traffic notification.
[For complete information, see the section Class Details]
Nested Class Summary
Table 387: Nested Classes in TrafficNotificationInfo
Nested Classes
public static final enumeration TrafficNotificationInfo.Type
Type for a traffic notification, with regards to the current route
Method Summary
Table 388: Methods in TrafficNotificationInfo
Methods
public GeoBoundingBox getAffectedArea ()
Return the bounding box affecting this TrafficNotificationInfo .
public long getAffectedLength ()
Returns the full length of the traffic event during tracking or the portion of the route affected by the traffic event during
navigation.
public long getDistanceInMeters ()
The distance from the last callback position to the traffic notification
public Severity getSeverity ()
Gets the TrafficEvent.Severity of this traffic notification.
public long getTravelTime ()
Returns the free flow travel time for the road segments covered by the location of the traffic notification.
public long getTravelTimeWithTraffic ()
Returns the traffic travel time for the road segments covered by the location of the traffic notification.
public Type getType ()
The type of the traffic notification info TrafficNotificationInfo
HERE Android SDK Developer's Guide
API Reference
786
Methods
public String toString ()
For documentation, see java.lang.Object
Class Details
Represents the details information for the traffic notification.
Method Details
public GeoBoundingBox getAffectedArea ()
Return the bounding box affecting this TrafficNotificationInfo .
Returns:
The GeoBoundingBox representing the area affected.
public long getAffectedLength ()
Returns the full length of the traffic event during tracking or the portion of the route affected by the traffic
event during navigation.
Returns:
The affected length (in meters).
public long getDistanceInMeters ()
The distance from the last callback position to the traffic notification
Returns:
true if the traffic notification info is valid
public Severity getSeverity ()
Gets the TrafficEvent.Severity of this traffic notification.
Returns:
The TrafficEvent.Severity of this traffic notification.
public long getTravelTime ()
Returns the free flow travel time for the road segments covered by the location of the traffic notification.
Returns:
The travel time in seconds.
HERE Android SDK Developer's Guide
API Reference
787
public long getTravelTimeWithTraffic ()
Returns the traffic travel time for the road segments covered by the location of the traffic notification.
Returns:
The traffic travel time in seconds.
public Type getType ()
The type of the traffic notification info TrafficNotificationInfo
Returns:
type of the traffic notification info
public String toString ()
For documentation, see java.lang.Object
Type
The enumeration Type is a member of com.here.android.mpa.guidance.TrafficNotificationInfo.
Enumeration Summary
public static final enumeration TrafficNotificationInfo.Type
extends java.lang.Enum, java.lang.Object
Type for a traffic notification, with regards to the current route
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 389: Enum Constants in Type
Fields
public static final Type UNDEFINED
Undefined.
public static final Type ON_ROUTE
On route.
public static final Type ON_HIGHWAY
On highway.
HERE Android SDK Developer's Guide
API Reference
788
Fields
public static final Type NEAR_START
Near start.
public static final Type NEAR_STOPOVER
Near stopover.
public static final Type NEAR_DESTINATION
Near Destination.
Method Summary
Table 390: Methods in Type
Methods
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TrafficNotificationInfo.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Type for a traffic notification, with regards to the current route
Enum Constant Details
public static final Type UNDEFINED
Undefined.
public static final Type ON_ROUTE
On route.
public static final Type ON_HIGHWAY
On highway.
public static final Type NEAR_START
Near start.
public static final Type NEAR_STOPOVER
HERE Android SDK Developer's Guide
API Reference
789
Near stopover.
public static final Type NEAR_DESTINATION
Near Destination.
Method Details
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TrafficNotificationInfo.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficUpdater
The class TrafficUpdater is a member of com.here.android.mpa.guidance .
Class Summary
public final class TrafficUpdater
extends java.lang.Object
Handles traffic update requests.
[For complete information, see the section Class Details]
Nested Class Summary
Table 391: Nested Classes in TrafficUpdater
Nested Classes
public static final enumeration TrafficUpdater.Error
Traffic status errors
HERE Android SDK Developer's Guide
API Reference
790
Nested Classes
public static abstract interface TrafficUpdater.GetEventsListener
Interface for report TrafficUpdaters events.
public static abstract interface TrafficUpdater.Listener
Interface to report traffic status changes.
public static final class TrafficUpdater.RequestInfo
Holds the error code and request id from a request for traffic.
public static final enumeration TrafficUpdater.RequestState
Traffic status enumeration
Method Summary
Table 392: Methods in TrafficUpdater
Methods
public void cancelRequest (long requestId)
Cancels a currently pending request.
public void clear ()
Clear current traffic events.
public void enableUpdate (boolean update)
Enable traffic updates.
public void getEvents (Route route, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given route.
public void getEvents (RouteElement element, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given route element.
public void getEvents (java.util.List <RouteElement> elements, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given route elements.
public void getEvents (RouteElements elements, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given RouteElements.
public static TrafficUpdater getInstance ()
Gets the TrafficUpdater instance.
public boolean isUpdateEnabled ()
Check to see if traffic updating is enabled.
public RequestInfo request (GeoCoordinate center, Listener listener)
Request traffic with given center coordinates and the default radius (10km).
public RequestInfo request (GeoCoordinate center, int radius, Listener listener)
Request traffic with given center coordinates and radius.
HERE Android SDK Developer's Guide
API Reference
791
Methods
public RequestInfo request (Route route, Listener listener)
Request traffic for given route with a default radius (10km) around each waypoint.
public RequestInfo request (Route route, int radius, Listener listener)
Request traffic for given route and radius around each waypoint.
public RequestInfo request (RouteElements elements, Listener listener)
Request traffic for a RouteElements object.
public boolean setRefreshInterval (int refreshInterval)
Sets the interval at which traffic data is refreshed.
Class Details
Handles traffic update requests.
Method Details
public void cancelRequest (long requestId)
Cancels a currently pending request.
Parameters:
requestId
The request ID to cancel. Can be obtained from the getRequestId() returned in the original request.
public void clear ()
Clear current traffic events.
public void enableUpdate (boolean update)
Enable traffic updates.
Parameters:
update
True if traffic updates requested. False otherwise.
public void getEvents (Route route, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given route. It's a good idea to call request(Route,
TrafficUpdater.Listener) prior to making this call.
NOTE: Truck routes and public transit timetable routes are unsupported. TrafficUpdater.GetEventsListener will
return with error UNSUPPORTED_ROUTE_MODE.
Parameters:
HERE Android SDK Developer's Guide
API Reference
792
route
The Route to check for traffic events.
listener
The listener which will receive the list of TrafficEvents.
public void getEvents (RouteElement element, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given route element. It's a good idea to call request(Route,
TrafficUpdater.Listener) prior to making this call.
NOTE: Truck routes and public transit timetable routes are unsupported. TrafficUpdater.GetEventsListener will
return with error UNSUPPORTED_ROUTE_MODE.
Parameters:
element
The RouteElement to check for traffic events.
listener
The listener which will receive the list of TrafficEvents.
public void getEvents (java.util.List <RouteElement> elements, GetEventsListener
listener)
Gets a list of TrafficEvent objects that affect the given route elements. It's a good idea to call
request(RouteElements, TrafficUpdater.Listener) prior to making this call.
NOTE: Truck routes and public transport timetable routes are unsupported. TrafficUpdater.GetEventsListener
will return with error UNSUPPORTED_ROUTE_MODE.
Parameters:
elements
The list of RouteElement objects to check for traffic events.
listener
The listener which will receive the list of TrafficEvents.
public void getEvents (RouteElements elements, GetEventsListener listener)
Gets a list of TrafficEvent objects that affect the given RouteElements. It's a good idea to call
request(RouteElements, TrafficUpdater.Listener) prior to making this call.
NOTE: Truck routes and public transport timetable routes are unsupported. TrafficUpdater.GetEventsListener
will return with error UNSUPPORTED_ROUTE_MODE.
Parameters:
elements
The RouteElements to check for traffic events.
HERE Android SDK Developer's Guide
API Reference
793
listener
The listener which will receive the list of TrafficEvents.
public static TrafficUpdater getInstance ()
Gets the TrafficUpdater instance.
Returns:
The TrafficUpdater instance.
public boolean isUpdateEnabled ()
Check to see if traffic updating is enabled. If it is not, no calls to any request traffic functions will have any
effect.
Returns:
true if traffic updating is enabled. false otherwise.
public RequestInfo request (GeoCoordinate center, Listener listener)
Request traffic with given center coordinates and the default radius (10km).
Parameters:
center
Center coordinate where traffic updates are requested.
listener
Listener that will notified when request completes.
Returns:
A TrafficUpdater.RequestInfo containing the error code of the request and a request id if the error is NONE.
public RequestInfo request (GeoCoordinate center, int radius, Listener listener)
Request traffic with given center coordinates and radius. Using a radius greater than the default (10km) can
impact performance.
Parameters:
center
Center coordinate where traffic updates are requested.
radius
Distance (in km) of the request radius.
listener
Listener that will notified when request completes.
HERE Android SDK Developer's Guide
API Reference
794
Returns:
A TrafficUpdater.RequestInfo containing the error code of the request and a request id if the error is NONE.
public RequestInfo request (Route route, Listener listener)
Request traffic for given route with a default radius (10km) around each waypoint.
NOTE: Truck routes and public transport timetable routes are unsupported. TrafficUpdater.RequestInfo will
return UNSUPPORTED_ROUTE_MODE.
Parameters:
route
Route used to query traffic events.
listener
Listener that will notified when request completes.
Returns:
A TrafficUpdater.RequestInfo containing the error code of the request and a request id if the error is NONE.
public RequestInfo request (Route route, int radius, Listener listener)
Request traffic for given route and radius around each waypoint.
NOTE: Truck routes and public transport timetable routes are unsupported. TrafficUpdater.RequestInfo will
return UNSUPPORTED_ROUTE_MODE.
Parameters:
route
Route used to query traffic events.
radius
Distance (in km) of the request radius.
listener
Listener that will notified when request completes.
Returns:
A TrafficUpdater.RequestInfo containing the error code of the request and a request id if the error is NONE.
public RequestInfo request (RouteElements elements, Listener listener)
Request traffic for a RouteElements object.
NOTE: Truck route elements and public transport timetable route elements are unsupported.
TrafficUpdater.RequestInfo will return UNSUPPORTED_ROUTE_MODE.
Parameters:
elements
HERE Android SDK Developer's Guide
API Reference
795
The RouteElements object to request traffic on.
listener
Listener that will notified when request completes.
Returns:
A TrafficUpdater.RequestInfo containing the error code of the request and a request id if the error is NONE.
public boolean setRefreshInterval (int refreshInterval)
Sets the interval at which traffic data is refreshed. This method MUST be called before the HERE SDK uses
any traffic in the current app session - e.g. before any other TrafficUpdater methods are called, before traffic
is enabled on a Map View and before routing with traffic is performed. If this method is called too late then
false will be returned. Traffic refresh interval defaults to a value determined by the HERE traffic servers.
Parameters:
refreshInterval
Refresh interval in seconds. Must be within the range 60..300.
Returns:
refreshInterval True the interval was set successfully, NO if traffic is already initialized or if refreshInterval is
outside the valid range.
Error
The enumeration Error is a member of com.here.android.mpa.guidance.TrafficUpdater.
Enumeration Summary
public static final enumeration TrafficUpdater.Error
extends java.lang.Enum, java.lang.Object
Traffic status errors
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 393: Enum Constants in Error
Fields
public static final Error NONE
No error.
public static final Error INVALID_PARAMETERS
Invalid parameters
HERE Android SDK Developer's Guide
API Reference
796
Fields
public static final Error OUT_OF_MEMORY
Out of memory
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call because another request is already in progress
public static final Error REQUEST_FAILED
Operation failed.Usually happens when traffic request is initiated when map is moving,panning or when network connection
is not available
public static final Error INVALID_CREDENTIALS
HERE Developer credentials are invalid or were not provided
public static final Error UNKNOWN
Generic error
public static final Error UNSUPPORTED_ROUTE_MODE
The route mode is not supported by TrafficUpdater
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied.
Method Summary
Table 394: Methods in Error
Methods
public int value ()
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TrafficUpdater.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Traffic status errors
Enum Constant Details
public static final Error NONE
No error.
public static final Error INVALID_PARAMETERS
Invalid parameters
HERE Android SDK Developer's Guide
API Reference
797
public static final Error OUT_OF_MEMORY
Out of memory
public static final Error INVALID_OPERATION
Operation not allowed at the time of the call because another request is already in progress
public static final Error REQUEST_FAILED
Operation failed.Usually happens when traffic request is initiated when map is moving,panning or when
network connection is not available
public static final Error INVALID_CREDENTIALS
HERE Developer credentials are invalid or were not provided
public static final Error UNKNOWN
Generic error
public static final Error UNSUPPORTED_ROUTE_MODE
The route mode is not supported by TrafficUpdater
public static final Error OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
Method Details
public int value ()
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
798
public static TrafficUpdater.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
GetEventsListener
The interface GetEventsListener is a member of com.here.android.mpa.guidance.TrafficUpdater.
Interface Summary
public static abstract interface TrafficUpdater.GetEventsListener
Interface for report TrafficUpdaters events.
[For complete information, see the section Interface Details]
Method Summary
Table 395: Methods in GetEventsListener
Methods
public abstract void onComplete (java.util.List <TrafficEvent> events, Error error)
Interface Details
Interface for report TrafficUpdaters events.
Method Details
public abstract void onComplete (java.util.List <TrafficEvent> events, Error
error)
Parameters:
events
error
Listener
The interface Listener is a member of com.here.android.mpa.guidance.TrafficUpdater.
Interface Summary
public static abstract interface TrafficUpdater.Listener
Interface to report traffic status changes.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
799
Method Summary
Table 396: Methods in Listener
Methods
public abstract void onStatusChanged (RequestState state)
Callback for Traffic status changes.
Interface Details
Interface to report traffic status changes.
Method Details
public abstract void onStatusChanged (RequestState state)
Callback for Traffic status changes.
Parameters:
state
representing the traffic request status.
RequestInfo
The class RequestInfo is a member of com.here.android.mpa.guidance.TrafficUpdater.
Class Summary
public static final class TrafficUpdater.RequestInfo
extends java.lang.Object
Holds the error code and request id from a request for traffic.
[For complete information, see the section Class Details]
Method Summary
Table 397: Methods in RequestInfo
Methods
public Error getError ()
The error code for the request.
public long getRequestId ()
The request id of the request.
HERE Android SDK Developer's Guide
API Reference
800
Class Details
Holds the error code and request id from a request for traffic.
Method Details
public Error getError ()
The error code for the request.
Returns:
The error code.
public long getRequestId ()
The request id of the request. Can be used to cancel a request. Note that this is only valid if error is NONE.
Returns:
The request id.
See also:
cancelRequest(long)
RequestState
The enumeration RequestState is a member of com.here.android.mpa.guidance.TrafficUpdater.
Enumeration Summary
public static final enumeration TrafficUpdater.RequestState
extends java.lang.Enum, java.lang.Object
Traffic status enumeration
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 398: Enum Constants in RequestState
Fields
public static final RequestState ERROR
public static final RequestState DONE
HERE Android SDK Developer's Guide
API Reference
801
Method Summary
Table 399: Methods in RequestState
Methods
public int value ()
public static RequestState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TrafficUpdater.RequestState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Traffic status enumeration
Enum Constant Details
public static final RequestState ERROR
public static final RequestState DONE
Method Details
public int value ()
public static RequestState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TrafficUpdater.RequestState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficWarner
The class TrafficWarner is a member of com.here.android.mpa.guidance .
HERE Android SDK Developer's Guide
API Reference
802
Class Summary
public final class TrafficWarner
extends java.lang.Object
Represents the traffic warning information for the current navigation session.
[For complete information, see the section Class Details]
Nested Class Summary
Table 400: Nested Classes in TrafficWarner
Nested Classes
public static abstract class TrafficWarner.Listener
A listener for traffic notifications which should be added to a traffic warner
Method Summary
Table 401: Methods in TrafficWarner
Methods
public void addListener (java.lang.ref.WeakReference <Listener> listener)
Adds a listener for the traffic warner
public void clear ()
Clears the traffic warner
public static TrafficNotification getNotificationOnRoute ()
Gets the traffic notification for the route currently in use by NavigationManager.
public static TrafficNotification getNotificationOnRoute (Route route)
Gets the traffic notification for a given Route.
public boolean init ()
Initializes the traffic warner, and starts it automatically.
public boolean isAhead (TrafficNotification notification)
Determines whether or not a traffic notification TrafficNotification is ahead of the last callback position
public boolean isOnRoute (Route route, TrafficNotification notification)
Determines whether or not a traffic notification TrafficNotification is on a given route Route
public boolean isValid ()
Determines whether or not the traffic warner is valid
public void removeListener (Listener listener)
Removes a listener from the traffic warner
public void start ()
Starts the traffic warner
HERE Android SDK Developer's Guide
API Reference
803
Methods
public void stop ()
Stops the traffic warner
Class Details
Represents the traffic warning information for the current navigation session.
Method Details
public void addListener (java.lang.ref.WeakReference <Listener> listener)
Adds a listener for the traffic warner
Parameters:
listener
to be added
public void clear ()
Clears the traffic warner
public static TrafficNotification getNotificationOnRoute ()
Gets the traffic notification for the route currently in use by NavigationManager.
Returns:
The notification for the route currently in use by NavigationManager or null if navigation is not active.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public static TrafficNotification getNotificationOnRoute (Route route)
Gets the traffic notification for a given Route.
Parameters:
route
The route to query for a traffic notification.
Returns:
The traffic notification object.
Throws:
AccessControlException
HERE Android SDK Developer's Guide
API Reference
804
Access to this operation is denied. Contact your HERE representative for more information.
public boolean init ()
Initializes the traffic warner, and starts it automatically. This method should be called only after
NavigationManager is running with tracking, simulation, or navigation, or false will be returned.
Returns:
true if the initialization succeeded without errors.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public boolean isAhead (TrafficNotification notification)
Determines whether or not a traffic notification TrafficNotification is ahead of the last callback position
Parameters:
notification
TrafficNotification to be checked
Returns:
true if the notification is ahead of last callback position
public boolean isOnRoute (Route route, TrafficNotification notification)
Determines whether or not a traffic notification TrafficNotification is on a given route Route
Parameters:
route
Route to be used
notification
Notification to be checked
Returns:
true if the notification is on the route
public boolean isValid ()
Determines whether or not the traffic warner is valid
Returns:
true if traffic warner is valid
HERE Android SDK Developer's Guide
API Reference
805
public void removeListener (Listener listener)
Removes a listener from the traffic warner
Parameters:
listener
to be removed
public void start ()
Starts the traffic warner
public void stop ()
Stops the traffic warner
Listener
The class Listener is a member of com.here.android.mpa.guidance.TrafficWarner.
Class Summary
public static abstract class TrafficWarner.Listener
extends java.lang.Object
A listener for traffic notifications which should be added to a traffic warner
[For complete information, see the section Class Details]
Constructor Summary
Table 402: Constructors in Listener
Constructors
Listener ()
Method Summary
Table 403: Methods in Listener
Methods
public abstract void onTraffic (TrafficNotification notification)
Callback for the traffic warner
HERE Android SDK Developer's Guide
API Reference
806
Class Details
A listener for traffic notifications which should be added to a traffic warner
Constructor Details
Listener ()
Method Details
public abstract void onTraffic (TrafficNotification notification)
Callback for the traffic warner
Parameters:
notification
associated with the callback
VoiceCatalog
The class VoiceCatalog is a member of com.here.android.mpa.guidance .
Class Summary
public final class VoiceCatalog
extends java.lang.Object
Manages the voice catalog used to download new voice skins.
[For complete information, see the section Class Details]
Nested Class Summary
Table 404: Nested Classes in VoiceCatalog
Nested Classes
public static final enumeration VoiceCatalog.Error
Error codes for VoiceCatalog.OnDownloadDoneListener.
public static abstract interface VoiceCatalog.OnDownloadDoneListener
Callback from report that the voice catalog/package download is done
public static abstract interface VoiceCatalog.OnProgressListener
Callback to report the catalog/package download progress.
HERE Android SDK Developer's Guide
API Reference
807
Field Summary
Table 405: Fields in VoiceCatalog
Fields
public static final int ID_BEEPS_VIBRATE
Pass this to getLocalVoiceSkin(long) to get the locally deployed skin for beeps and vibration.
Method Summary
Table 406: Methods in VoiceCatalog
Methods
public void cancel ()
Cancels any current downloads
public boolean deleteVoiceSkin (long id)
Deletes a voice skin by voice skin id from the file system Once deletion is complete the voice catalog is refreshed
public boolean deleteVoiceSkin (VoiceSkin skin)
Deletes a voice skin from the file system.
public boolean downloadCatalog (OnDownloadDoneListener listener)
Start downloading the catalog for the current device locale language.
public boolean downloadVoice (long id, OnDownloadDoneListener listener)
Start downloading voice package with given identifier.
public java.util.List <VoicePackage> getCatalogList ()
Get the voice package description from the local catalog.
public static VoiceCatalog getInstance ()
Get access to the VoiceCatalog Singleton.
public VoiceSkin getLocalVoiceSkin (long id)
Get the voice using a specific identifier from the local storage.
public java.util.List <VoiceSkin> getLocalVoiceSkins ()
Get the voice list from the local storage.
public boolean isDownloading ()
Checks if the VoiceCatalog is downloading
public boolean isLocalCatalogAvailable ()
Check if the voice catalog for the current device locale is available in local storage.
public boolean isLocalVoiceSkin (long id)
Check if voice skin with given id is locally stored.
HERE Android SDK Developer's Guide
API Reference
808
Methods
public void refreshVoiceSkins ()
Method to refresh the list of voice skins on the file system Note: If there are any pending downloads, it will be cancelled
before the list is refreshed.
public void setOnProgressEventListener (OnProgressListener listener)
Register VoiceCatalog download progress listener.
Class Details
Manages the voice catalog used to download new voice skins.
Field Details
public static final int ID_BEEPS_VIBRATE
Pass this to getLocalVoiceSkin(long) to get the locally deployed skin for beeps and vibration. The beeps and
vibration skin is not part of the online catalog.
Method Details
public void cancel ()
Cancels any current downloads
public boolean deleteVoiceSkin (long id)
Deletes a voice skin by voice skin id from the file system Once deletion is complete the voice catalog is
refreshed
Parameters:
id
The Id of the Voice Skin to be deleted
Returns:
true if voice skin is successfully deleted, false otherwise.
public boolean deleteVoiceSkin (VoiceSkin skin)
Deletes a voice skin from the file system. Once deletion is complete the voice catalog is refreshed
Parameters:
skin
VoiceSkin to delete
Returns:
HERE Android SDK Developer's Guide
API Reference
809
true if successful, false otherwise
public boolean downloadCatalog (OnDownloadDoneListener listener)
Start downloading the catalog for the current device locale language. Catalog file is then stored locally for
future access.
Parameters:
listener
Download completion listener.
Returns:
true if download initialization is successful, otherwise false is returned. Use isDownloading() to check if
there is already an outstanding voice catalog download request that causes false to be returned.
See also:
isDownloading()
public boolean downloadVoice (long id, OnDownloadDoneListener listener)
Start downloading voice package with given identifier. Note: only one voice package download at time is
possible.
Parameters:
id
Voice package identifier.
listener
Download completion listener.
Returns:
true if download is initialized successfully. false otherwise.
public java.util.List <VoicePackage> getCatalogList ()
Get the voice package description from the local catalog. If no catalog matching the device's current locale is
present, the list of voice package(s) in the most recently used local voice catalog will be returned instead. In
the event this last known local voice catalog is not available, an empty list will be returned.
When device locale is changed, user must call refreshVoiceSkins() to reload the voice catalog that adheres to
the new locale language. If the voice catalog associated with the new locale language is not available locally,
this method will default back to the most recently used local catalog. Therefore, users are recommended to
check if there is a local catalog available of the device's current locale by calling isLocalCatalogAvailable().
If the local catalog is unavailable, call downloadCatalog(OnDownloadDoneListener) to download of the voice
catalog for the new locale language.
HERE Android SDK Developer's Guide
API Reference
810
Occasionally, an existing catalog can also become obsolete and returns an empty voice package List . This
will require the download of the voice catalog again.
Returns:
A List of VoicePackage objects. An empty List can be returned.
See also:
downloadCatalog(OnDownloadDoneListener)
setMapDisplayLanguage(Locale)
public static VoiceCatalog getInstance ()
Get access to the VoiceCatalog Singleton.
Returns:
VoiceCatalog instance
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public VoiceSkin getLocalVoiceSkin (long id)
Get the voice using a specific identifier from the local storage. If no voice with the identifier is present, an
null reference is returned.
Parameters:
id
VoiceSkin identifier.
Returns:
VoiceSkin if found. Null otherwise.
public java.util.List <VoiceSkin> getLocalVoiceSkins ()
Get the voice list from the local storage. If no voice is present an empty array is returned
Returns:
Array of VoiceSkin objects (can be empty).
public boolean isDownloading ()
Checks if the VoiceCatalog is downloading
Returns:
HERE Android SDK Developer's Guide
API Reference
811
True if downloading, false otherwise.
public boolean isLocalCatalogAvailable ()
Check if the voice catalog for the current device locale is available in local storage. If not, user can download
it using downloadCatalog(OnDownloadDoneListener).
Returns:
true if the voice catalog is available in local storage. false otherwise.
public boolean isLocalVoiceSkin (long id)
Check if voice skin with given id is locally stored.
Parameters:
id
Voice skin identifier.
Returns:
True if voice skin with given id is locally stored.
public void refreshVoiceSkins ()
Method to refresh the list of voice skins on the file system Note: If there are any pending downloads, it will
be cancelled before the list is refreshed. After calling this function, clients can get the updated catalog list by
calling getCatalogList()
public void setOnProgressEventListener (OnProgressListener listener)
Register VoiceCatalog download progress listener.
Parameters:
listener
Download progress listener.
Error
The enumeration Error is a member of com.here.android.mpa.guidance.VoiceCatalog.
Enumeration Summary
public static final enumeration VoiceCatalog.Error
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
812
Error codes for VoiceCatalog.OnDownloadDoneListener.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 407: Enum Constants in Error
Fields
public static final Error NONE
No error.
public static final Error UNKNOWN
Unknown error.
public static final Error NOT_ENOUGH_DISK_SPACE
The disk does not have the space required to perform the requested VoiceCatalog operation.
Method Summary
Table 408: Methods in Error
Methods
public int value ()
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VoiceCatalog.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Error codes for VoiceCatalog.OnDownloadDoneListener.
Enum Constant Details
public static final Error NONE
No error.
public static final Error UNKNOWN
Unknown error.
public static final Error NOT_ENOUGH_DISK_SPACE
The disk does not have the space required to perform the requested VoiceCatalog operation.
HERE Android SDK Developer's Guide
API Reference
813
Method Details
public int value ()
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VoiceCatalog.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnDownloadDoneListener
The interface OnDownloadDoneListener is a member of com.here.android.mpa.guidance.VoiceCatalog.
Interface Summary
public static abstract interface VoiceCatalog.OnDownloadDoneListener
Callback from report that the voice catalog/package download is done
[For complete information, see the section Interface Details]
Method Summary
Table 409: Methods in OnDownloadDoneListener
Methods
public abstract void onDownloadDone (Error error)
Report download completion.
Interface Details
Callback from report that the voice catalog/package download is done
Method Details
public abstract void onDownloadDone (Error error)
HERE Android SDK Developer's Guide
API Reference
814
Report download completion.
Parameters:
error
Download completion error code. NONE is returned if successful. Otherwise error. Note: It will return
NOT_ENOUGH_DISK_SPACE if the device storage with the requested voice package installed would reach
the critical level of 500MB. Below this level the device's file system may reject file operations which will
result in installation failures.
OnProgressListener
The interface OnProgressListener is a member of com.here.android.mpa.guidance.VoiceCatalog.
Interface Summary
public static abstract interface VoiceCatalog.OnProgressListener
Callback to report the catalog/package download progress.
[For complete information, see the section Interface Details]
Method Summary
Table 410: Methods in OnProgressListener
Methods
public abstract void onProgress (int percentage)
Report download progress.
Interface Details
Callback to report the catalog/package download progress.
Method Details
public abstract void onProgress (int percentage)
Report download progress.
Parameters:
percentage
Percentage of download completion.
VoicePackage
The class VoicePackage is a member of com.here.android.mpa.guidance .
HERE Android SDK Developer's Guide
API Reference
815
Class Summary
public final class VoicePackage
extends java.lang.Object
Return information about downloaded voice packages.
[For complete information, see the section Class Details]
Nested Class Summary
Table 411: Nested Classes in VoicePackage
Nested Classes
public static final enumeration VoicePackage.Gender
Gender for a VoicePackage .
public static final enumeration VoicePackage.TravelMode
Travel Mode of voice package.
Method Summary
Table 412: Methods in VoicePackage
Methods
public String getBCP47Code ()
Get the international BCP-47 code describing the language of the voice skin (see http://tools.ietf.org/rfc/bcp/bcp47.txt).
public float getContentSize ()
Size of the package after unzipping to the device
public Hashtable getCustomAttributes ()
Gets the custom attributes from the Voice package.
public float getDownloadSize ()
Size of the download required for this package
public Gender getGender ()
Gets the gender of the voice skin.
public long getId ()
Get the package identifier.
public String getLocalizedGender ()
Gets the localized description of the gender for this voice skin.
public String getLocalizedLanguage ()
Get the localized description of the language of this voice skin.
public String getLocalizedQuality ()
Get the localized description of the voice skin quality
HERE Android SDK Developer's Guide
API Reference
816
Methods
public String getLocalizedType ()
Get the localized description for the type of voice package.
public String getMarcCode ()
Get the international MARC code describing the language of the voice skin (see http://www.loc.gov/marc/languages).
public String getName ()
Get the package name.
public String getQuality ()
Get the text description of the voice skin quality
public TravelMode getTravelMode ()
Get the VoicePackage.TravelMode of voice package.
public String getVersion ()
Get the package version.
public boolean isLocal ()
Check if the voice is locally installed.
public boolean isTts ()
Get voice TextToSpeech capability.
public boolean isTtsLanguageAvailable ()
Gets whether this voice package language is supported by this TTS engine.
Class Details
Return information about downloaded voice packages. Used in VoiceCatalog.
Method Details
public String getBCP47Code ()
Get the international BCP-47 code describing the language of the voice skin (see http://tools.ietf.org/rfc/
bcp/bcp47.txt).
Returns:
The BCP-47 code, e.g. "en".
public float getContentSize ()
Size of the package after unzipping to the device
Returns:
float, number of megabytes
HERE Android SDK Developer's Guide
API Reference
817
public Hashtable getCustomAttributes ()
Gets the custom attributes from the Voice package.
Returns:
a hashtable containing key values pairs representing the Attributes
public float getDownloadSize ()
Size of the download required for this package
Returns:
float, number of megabytes
public Gender getGender ()
Gets the gender of the voice skin.
Note: if the voice package is a TTS package, then the gender is only a suggestion. The current Android TTS
engine does not support switching voice genders. Clients that use third-party engines that support genders
may use this API as a suggestion.
Returns:
The VoicePackage.Gender of the voice skin.
public long getId ()
Get the package identifier.
Returns:
Package identifier.
public String getLocalizedGender ()
Gets the localized description of the gender for this voice skin.
Note: if the voice package is a TTS package, then the gender is only a suggestion. The current Android TTS
engine does not support switching voice genders. Clients that use third-party engines that support genders
may use this API as a suggestion.
Returns:
A localized String representing the gender of the voice skin.
public String getLocalizedLanguage ()
Get the localized description of the language of this voice skin.
HERE Android SDK Developer's Guide
API Reference
818
Returns:
A localized String representing the language of this voice skin.
public String getLocalizedQuality ()
Get the localized description of the voice skin quality
Returns:
localized description of the voice skin quality, this field can be empty if no quality information is available.
public String getLocalizedType ()
Get the localized description for the type of voice package.
Returns:
A localized String representing the type of the voice package.
public String getMarcCode ()
Get the international MARC code describing the language of the voice skin (see http://www.loc.gov/marc/
languages).
Returns:
The MARC code, e.g. "eng".
public String getName ()
Get the package name.
Returns:
Package name.
public String getQuality ()
Get the text description of the voice skin quality
Returns:
text description of the voice skin quality, this field can be empty if no quality information is available.
public TravelMode getTravelMode ()
Get the VoicePackage.TravelMode of voice package.
Returns:
The VoicePackage.TravelMode of voice package.
HERE Android SDK Developer's Guide
API Reference
819
public String getVersion ()
Get the package version.
Returns:
Package version.
public boolean isLocal ()
Check if the voice is locally installed.
Returns:
True if locally installed. False otherwise.
public boolean isTts ()
Get voice TextToSpeech capability.
Returns:
True if the voice is TTS capable.
public boolean isTtsLanguageAvailable ()
Gets whether this voice package language is supported by this TTS engine.
Returns:
true if the currently installed TextToSpeech engine supports the language of this voice package, false
otherwise.
Gender
The enumeration Gender is a member of com.here.android.mpa.guidance.VoicePackage.
Enumeration Summary
public static final enumeration VoicePackage.Gender
extends java.lang.Enum, java.lang.Object
Gender for a VoicePackage .
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
820
Enum Constant Summary
Table 413: Enum Constants in Gender
Fields
public static final Gender FEMALE
Female.
public static final Gender MALE
Male.
Method Summary
Table 414: Methods in Gender
Methods
public static Gender valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VoicePackage.Gender[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Gender for a VoicePackage .
Enum Constant Details
public static final Gender FEMALE
Female.
public static final Gender MALE
Male.
Method Details
public static Gender valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
821
public static VoicePackage.Gender[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TravelMode
The enumeration TravelMode is a member of com.here.android.mpa.guidance.VoicePackage.
Enumeration Summary
public static final enumeration VoicePackage.TravelMode
extends java.lang.Enum, java.lang.Object
Travel Mode of voice package.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 415: Enum Constants in TravelMode
Fields
public static final TravelMode WALK_DRIVE
Pedestrian and car navigation.
public static final TravelMode DRIVE
Car navigation only.
public static final TravelMode WALK
Pedestrian navigation only.
public static final TravelMode UNKNOWN
Unknown navigation type.
Method Summary
Table 416: Methods in TravelMode
Methods
public static TravelMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VoicePackage.TravelMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
822
Enumeration Details
Travel Mode of voice package. If a voice package's skin is used during navigation and the type of navigation is
not supported by the selected skin, NavigationManager will use a default skin instead. See getTravelMode().
Enum Constant Details
public static final TravelMode WALK_DRIVE
Pedestrian and car navigation.
Note: Pedestrian voice guidance is offered as a beta. It may be modified or removed at any time.
public static final TravelMode DRIVE
Car navigation only.
public static final TravelMode WALK
Pedestrian navigation only.
Note: Pedestrian voice guidance is offered as a beta. It may be modified or removed at any time.
public static final TravelMode UNKNOWN
Unknown navigation type.
Method Details
public static TravelMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VoicePackage.TravelMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VoiceSkin
The class VoiceSkin is a member of com.here.android.mpa.guidance .
HERE Android SDK Developer's Guide
API Reference
823
Class Summary
public final class VoiceSkin
extends java.lang.Object
Defines a voice skin used for guidance.
[For complete information, see the section Class Details]
Nested Class Summary
Table 417: Nested Classes in VoiceSkin
Nested Classes
public static final enumeration VoiceSkin.OutputType
Voice Skin Output Types
Method Summary
Table 418: Methods in VoiceSkin
Methods
public boolean delete ()
Delete the voice skin from the device
public String getDescription ()
Get the human readable description of the voice skin.
public String getGender ()
Gets the gender of the voice skin: "f" female, "m" male.
public long getId ()
Get the voice skin identifier.
public String getLanguage ()
Get the human readable language name of the voice skin.
public String getLanguageCode ()
Returns language code in BCP-47 format: language-COUNTRY
public String getMarcCode ()
Get the international MARC code describing the language of the voice skin (see http://www.loc.gov/marc/languages).
public OutputType getOutputType ()
Get the voice skin output voice type.
public String getQuality ()
Get the text description of the voice skin quality
public String getSpeaker ()
Get the speaker of the voice skin.
HERE Android SDK Developer's Guide
API Reference
824
Methods
public String getVersion ()
Get the version number string of the voice skin.
Class Details
Defines a voice skin used for guidance.
Method Details
public boolean delete ()
Delete the voice skin from the device
Returns:
true if deletion was successful, false otherwise
public String getDescription ()
Get the human readable description of the voice skin.
Returns:
The description, e.g. "English Female".
public String getGender ()
Gets the gender of the voice skin: "f" female, "m" male.
Note: if the voice skin is a TTS voice skin, then the gender is only a suggestion. The current Android TTS
engine does not support switching voice genders. Clients that use third-party engines that support genders
may use this API as a suggestion.
Returns:
"f" if female, "m" if male.
public long getId ()
Get the voice skin identifier.
Returns:
The voice skin identifier.
public String getLanguage ()
Get the human readable language name of the voice skin.
Returns:
HERE Android SDK Developer's Guide
API Reference
825
The language name, e.g. "English".
public String getLanguageCode ()
Returns language code in BCP-47 format: language-COUNTRY
Returns:
language code in BCP-47 format
public String getMarcCode ()
Get the international MARC code describing the language of the voice skin (see http://www.loc.gov/marc/
languages).
Returns:
The MARC code, e.g. "eng".
public OutputType getOutputType ()
Get the voice skin output voice type.
Returns:
The voice skin output voice type.
public String getQuality ()
Get the text description of the voice skin quality
Returns:
text description of the voice skin quality, this field can be empty if no quality information is available.
public String getSpeaker ()
Get the speaker of the voice skin.
Returns:
The name of the speaker.
public String getVersion ()
Get the version number string of the voice skin.
Returns:
The version number, e.g. "0.2.0.0".
HERE Android SDK Developer's Guide
API Reference
826
OutputType
The enumeration OutputType is a member of com.here.android.mpa.guidance.VoiceSkin.
Enumeration Summary
public static final enumeration VoiceSkin.OutputType
extends java.lang.Enum, java.lang.Object
Voice Skin Output Types
[For complete information, see the section Enumeration Details]
See also:
getOutputType()
Enum Constant Summary
Table 419: Enum Constants in OutputType
Fields
public static final OutputType AUDIO
Audio output (wav files).
public static final OutputType TEXT
Text output, but no text to speech associated.
public static final OutputType TTS
Text to speech output.
public static final OutputType NONE
Invalid skin.
Method Summary
Table 420: Methods in OutputType
Methods
public int value ()
public static OutputType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VoiceSkin.OutputType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Voice Skin Output Types
HERE Android SDK Developer's Guide
API Reference
827
See also:
getOutputType()
Enum Constant Details
public static final OutputType AUDIO
Audio output (wav files).
public static final OutputType TEXT
Text output, but no text to speech associated.
public static final OutputType TTS
Text to speech output.
public static final OutputType NONE
Invalid skin.
Method Details
public int value ()
public static OutputType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VoiceSkin.OutputType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
mapping
The package mapping is a member of com.here.android.mpa.
HERE Android SDK Developer's Guide
API Reference
828
Package Summary
mapping
The mapping package provides classes, interfaces, and enumerations that display an interactive map, and
related functionality that allows your application to create and add map content.
Package Details
The mapping package provides classes, interfaces, and enumerations that display an interactive map, and
related functionality that allows your application to create and add map content.
Some key classes and interfaces in this package are:
Map
MapGesture
MapFragment
MapObject
MapTransitLayer
Map
The Map interface represents the interactive map itself.
Map schemes (e.g. Satellite, Terrain, etc.) can be changed as follows:
map.setMapScheme ( Map.Scheme.NORMAL_DAY );
Refer to the Map.Scheme class for a description of supported schemes.
A Map can contain visual objects, which are instantiated from the children of the MapObject class, such as:
MapCircle
MapMarker
MapPolygon
MapPolyline
MapRoute
A polygon, for example, can be drawn on the map as follows:
...
MapPolygon polygon = new MapPolygon();
map.addMapObject( polygon );
Notice that the parent map object class, MapContainer , does not itself represent a visual object. A
MapContainer determines the stacking order (z-index ordering) of objects on a map.
MapObjects and z-index ordering
The z-index of a MapObject specifies its stacking order within a Map. In general, an object with a higher z-
index appears closer to the viewer than an object with a lower z-index.
The stack order of a Map is defined hierarchically, according to the following specifications:
HERE Android SDK Developer's Guide
API Reference
829
The MapObject with the highest z-index is drawn on top of any other instances of MapObject.
Within a MapContainer, the MapObject with highest z-index is drawn on top of any other instances of
MapObject.
Colors
Color values in this package are defined in terms of ARGB integer values, where the 24 least significant
bits define red, green, and blue components while the eight most significant bits define the alpha value
(0xAARRGGBB) of opacity, for which 0xFFRRGGBB is fully opaque and 0x00RRGGBB is fully transparent.
Note: if the target platform does not support transparency, the alpha value is ignored and the color is
displayed as fully opaque.
GeoMesh
The class GeoMesh is a member of com.here.android.mpa.mapping .
Class Summary
public final class GeoMesh
extends com.here.android.mpa.mapping.Mesh, java.lang.Object
Represents the mesh data for a MapGeoModel.
[For complete information, see the section Class Details]
Constructor Summary
Table 421: Constructors in GeoMesh
Constructors
GeoMesh ()
Creates a GeoMesh .
Method Summary
Table 422: Methods in GeoMesh
Methods
public GeoMesh setVertices (java.util.List <GeoCoordinate> vertices)
Sets a List of GeoCoordinate objects representing the vertices associated with the GeoMesh .
public GeoMesh setVertices (DoubleBuffer vertices)
Sets a DoubleBuffer representing a list of vertices associated with the GeoMesh .
Class Details
Represents the mesh data for a MapGeoModel.
HERE Android SDK Developer's Guide
API Reference
830
The properties of a GeoMesh include vertices, specified as either GeoCoordinate objects or an array of
double values representing the latitude, longitude and altitude of each vertex sequentially.
Constructor Details
GeoMesh ()
Creates a GeoMesh .
Method Details
public GeoMesh setVertices (java.util.List <GeoCoordinate> vertices)
Sets a List of GeoCoordinate objects representing the vertices associated with the GeoMesh .
Parameters:
vertices
A List of GeoCoordinate representing the vertices used to form the GeoMesh.
Returns:
The updated GeoMesh.
Throws:
IllegalArgumentException
if vertices is empty.
IllegalArgumentException
if vertices contains more than 65536 GeoCoordinate.
public GeoMesh setVertices (DoubleBuffer vertices)
Sets a DoubleBuffer representing a list of vertices associated with the GeoMesh .
Each vertex is specified as triplets of latitude, longitude and altitude. All triplets are then placed into a
DoubleBuffer sequentially to represent the list of vertices.
Parameters:
vertices
Desired DoubleBuffer list of GeoCoordinate, i.e. vertex, in multiples of three.
Returns:
The updated GeoMesh.
Throws:
IllegalArgumentException
if vertices is empty.
IllegalArgumentException
HERE Android SDK Developer's Guide
API Reference
831
if vertices does not contain triplets of double, representing the latitude, longitude and altitude values
of a vertex.
IllegalArgumentException
if vertices contains more than 65536 triplets, each representing a GeoCoordinate.
See also:
java.nio.DoubleBuffer
HistoricalTrafficRasterTileSource
The class HistoricalTrafficRasterTileSource is a member of com.here.android.mpa.mapping .
Class Summary
public final class HistoricalTrafficRasterTileSource
extends com.here.android.mpa.mapping.UrlMapRasterTileSourceBase,
com.here.android.mpa.mapping.MapRasterTileSource, java.lang.Object
This class displays a street map tile overlay showing the typical traffic pattern for a specific time point during
the week.
[For complete information, see the section Class Details]
See also:
addRasterTileSource(MapRasterTileSource)
removeRasterTileSource(MapRasterTileSource)
Constructor Summary
Table 423: Constructors in HistoricalTrafficRasterTileSource
Constructors
HistoricalTrafficRasterTileSource (int dayOfWeek, int hourOfDay)
Public constructor to instantiate a raster tile that displays history traffic for the time requested.
HistoricalTrafficRasterTileSource (int dayOfWeek, int hourOfDay, int minOfHour)
Public constructor to instantiate a raster tile that displays history traffic for the time requested.
HERE Android SDK Developer's Guide
API Reference
832
Method Summary
Table 424: Methods in HistoricalTrafficRasterTileSource
Methods
public String getUrl (int x, int y, int zoomLevel)
Gets the URL representing the source of the specified raster tile image.
This method overrides mapping.UrlMapRasterTileSourceBase.getUrl(int, int, int)
Class Details
This class displays a street map tile overlay showing the typical traffic pattern for a specific time point during
the week.
See also:
addRasterTileSource(MapRasterTileSource)
removeRasterTileSource(MapRasterTileSource)
Constructor Details
HistoricalTrafficRasterTileSource (int dayOfWeek, int hourOfDay)
Public constructor to instantiate a raster tile that displays history traffic for the time requested.
The time specified is local to the location requesting the historic traffic. For example, regardless of what the
device's locale setting is, where the device's current location, nor what is the current time, if the target area
for the historic traffic request is for Berlin, Germany at 3:00pm Monday, then the hourOfDay used should be
15 and the dayOfWeek should be Calendar.Monday .
Parameters:
dayOfWeek
One of the values defined in Calendar class, to be used when setting Calendar.DAY_OF_WEEK. eg.
Calendar.MONDAY.
hourOfDay
An int representing the hour to request historic traffic at. It uses the 24-hour clock format. E.g., at 07:00
PM, use 19.
Throws:
IllegalArgumentException
If requested time's dayOfWeek is invalid.
IllegalArgumentException
If requested time's hourOfDay is invalid.
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
HERE Android SDK Developer's Guide
API Reference
833
HistoricalTrafficRasterTileSource (int dayOfWeek, int hourOfDay, int
minOfHour)
Public constructor to instantiate a raster tile that displays history traffic for the time requested.
The time specified is local to the location requesting the historic traffic. For example, regardless of what the
device's locale setting is, where the device's current location, nor what is the current time, if the target area
for the historic traffic request is for Berlin, Germany at 3:30pm Monday, then the hourOfDay used should be
15 , minOfHour used should be 30 , and the dayOfWeek should be Calendar.Monday .
Parameters:
dayOfWeek
One of the values defined in Calendar class, to be used when setting Calendar.DAY_OF_WEEK. eg.
Calendar.MONDAY.
hourOfDay
An int representing the hour to request historic traffic at. It uses the 24-hour clock format. E.g., at 07:04
PM, use 19.
minOfHour
An int indicating the minute within the hour to request historic traffic. E.g., at 07:04 PM use 4.
Throws:
IllegalArgumentException
If requested time's dayOfWeek is invalid.
IllegalArgumentException
If requested time's hourOfDay is invalid.
IllegalArgumentException
If requested time's minOfHour is invalid.
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
Method Details
public String getUrl (int x, int y, int zoomLevel)
Gets the URL representing the source of the specified raster tile image.
Note: implementations of raster tile sources must override this method to provide a complete URL string
pointing to the raster tile image.
This method overrides mapping.UrlMapRasterTileSourceBase.getUrl(int, int, int)
Parameters:
x
y
zoomLevel
HERE Android SDK Developer's Guide
API Reference
834
LocalMesh
The class LocalMesh is a member of com.here.android.mpa.mapping .
Class Summary
public final class LocalMesh
extends com.here.android.mpa.mapping.Mesh, java.lang.Object
Represents the mesh data for a MapLocalModel.
[For complete information, see the section Class Details]
Constructor Summary
Table 425: Constructors in LocalMesh
Constructors
LocalMesh ()
Creates a LocalMesh .
Method Summary
Table 426: Methods in LocalMesh
Methods
public FloatBuffer getVertices ()
Gets a FloatBuffer representing a list of vertices associated with the LocalMesh .
public LocalMesh setVertices (FloatBuffer vertices)
Sets a FloatBuffer representing a list of vertices associated with the LocalMesh .
Class Details
Represents the mesh data for a MapLocalModel.
The properties of a LocalMesh include vertices, specified as triplets. A unit of 1 represents 1 meter in the
real world.
Constructor Details
LocalMesh ()
Creates a LocalMesh .
HERE Android SDK Developer's Guide
API Reference
835
Method Details
public FloatBuffer getVertices ()
Gets a FloatBuffer representing a list of vertices associated with the LocalMesh .
Note: vertices for a LocalMesh are specified as triplets.
Returns:
vertices associated with the mesh
public LocalMesh setVertices (FloatBuffer vertices)
Sets a FloatBuffer representing a list of vertices associated with the LocalMesh .
Note: vertices for a LocalMesh are specified as triplets.
Parameters:
vertices
Desired FloatBuffer list of vertices, in triplets
Returns:
The updated LocalMesh
Throws:
IllegalArgumentException
if vertices is empty.
IllegalArgumentException
if vertices does not contain triplets of floats, i.e. vertices's capacity is not in multiples of 3.
IllegalArgumentException
if vertices contains more than 65536 triplets, each representing a vertex.
See also:
java.nio.FloatBuffer
Location
The class Location is a member of com.here.android.mpa.mapping .
Class Summary
public final class Location
extends java.lang.Object
Class which provides ways to retrieve certain parameters of an icon or a marker.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
836
See also:
MapCartoMarker
Method Summary
Table 427: Methods in Location
Methods
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of this location object
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of this location object
public LocationInfo getInfo ()
Gets the LocationInfo of this location object
Class Details
Class which provides ways to retrieve certain parameters of an icon or a marker.
See also:
MapCartoMarker
Method Details
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of this location object
Returns:
the GeoBoundingBox of this location object
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of this location object
Returns:
the GeoCoordinate of this location object
public LocationInfo getInfo ()
Gets the LocationInfo of this location object
Returns:
the LocationInfo of this location object
HERE Android SDK Developer's Guide
API Reference
837
LocationInfo
The class LocationInfo is a member of com.here.android.mpa.mapping .
Class Summary
public final class LocationInfo
extends java.lang.Object
Class which contains information about a particular icon/marker.
[For complete information, see the section Class Details]
See also:
Location
Nested Class Summary
Table 428: Nested Classes in LocationInfo
Nested Classes
public static final enumeration LocationInfo.Field
Fields for a LocationInfo object which can be retrieved
Method Summary
Table 429: Methods in LocationInfo
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public String getField (Field field)
Retrieves the value of the specified LocationInfo.Field for the object
public boolean hasField (Field field)
Determines whether or not the object has a particular LocationInfo.Field
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Class which contains information about a particular icon/marker.
See also:
Location
HERE Android SDK Developer's Guide
API Reference
838
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public String getField (Field field)
Retrieves the value of the specified LocationInfo.Field for the object
Parameters:
field
Field to determine
Returns:
the string value of the specified Field
public boolean hasField (Field field)
Determines whether or not the object has a particular LocationInfo.Field
Parameters:
field
Field to determine
Returns:
true if the object has the Field
public int hashCode ()
For documentation, see java.lang.Object
Field
The enumeration Field is a member of com.here.android.mpa.mapping.LocationInfo.
Enumeration Summary
public static final enumeration LocationInfo.Field
extends java.lang.Enum, java.lang.Object
Fields for a LocationInfo object which can be retrieved
HERE Android SDK Developer's Guide
API Reference
839
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 430: Enum Constants in Field
Fields
public static final Field ADDR_COUNTRY_CODE
Country code of address, named as in ISO 3166 alpha-3
public static final Field ADDR_COUNTRY_NAME
Country Name
public static final Field ADDR_STATE_NAME
Name of federal state
public static final Field ADDR_STATE_CODE
Code of federal state
public static final Field ADDR_PROVINCE_NAME
Province Name
public static final Field ADDR_COUNTY_NAME
County Name
public static final Field ADDR_CITY_NAME
City Name
public static final Field ADDR_DISTRICT_NAME
District Name
public static final Field ADDR_POSTAL_CODE
Postal Code
public static final Field ADDR_TOWNSHIP_NAME
Township Name
public static final Field ADDR_NEIGHBORHOOD_NAME
Name of the neighborhood within the city
public static final Field ADDR_STREET_NAME
Street name
public static final Field ADDR_HOUSE_NUMBER
House number of address.
public static final Field ADDR_CONTINENT_NAME
Continent name
public static final Field ADDR_TYPE_NAME
Type of address (city, street, etc.)
HERE Android SDK Developer's Guide
API Reference
840
Fields
public static final Field ADDR_POPULATION
Population living at this address
public static final Field ADDR_BUILDING_NAME
Building Name
public static final Field ADDR_BUILDING_FLOOR
Building Floor
public static final Field ADDR_BUILDING_ROOM
Building Room
public static final Field ADDR_BUILDING_ZONE
Building Zone
public static final Field PLACE_NAME
Place Name
public static final Field PLACE_PRE_NAME
Place prefix.
public static final Field PLACE_POST_NAME
Place postfix.
public static final Field PLACE_TYPE
Type of the place (premium, adplace, recommendation, etc.)
public static final Field PLACE_CATEGORY
Name of the category of the place
public static final Field PLACE_CATEGORY_ID
The identifier (number as a string) of the category.
public static final Field PLACE_DESCRIPTION
Short description of the place.
public static final Field PLACE_PHONE_NUMBER
Phone number of the place.
public static final Field PLACE_URL
URL belonging to the place.
public static final Field PLACE_PREMIUM_URL_ID
Premium POI URL Id.
public static final Field PLACE_PREMIUM_NODE_ID
Premium POI Node Id.
public static final Field PLACE_ADVERTISEMENT_STRING
Advertisement string
HERE Android SDK Developer's Guide
API Reference
841
Fields
public static final Field TZ_OFFSET_MINUTES
Time zone offset in minutes
public static final Field OTHER_DATA
Can be used to return some other information for the location.
public static final Field PLACE_ICON_ID
The place's icon identifier.
public static final Field LOCATION_TYPE
ADDRESS, POI, STRING.
public static final Field LOCATION_META
Additional flags to mark results
public static final Field LOCATION_TEXT
Formatted text of the location
public static final Field ADDR_AREA_ID
Area Id
public static final Field FOREIGN_ID
Foreign ID
public static final Field FOREIGN_ID_SOURCE
Foreign ID source.
Method Summary
Table 431: Methods in Field
Methods
public static Field valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static LocationInfo.Field[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Fields for a LocationInfo object which can be retrieved
Enum Constant Details
public static final Field ADDR_COUNTRY_CODE
Country code of address, named as in ISO 3166 alpha-3
HERE Android SDK Developer's Guide
API Reference
842
public static final Field ADDR_COUNTRY_NAME
Country Name
public static final Field ADDR_STATE_NAME
Name of federal state
public static final Field ADDR_STATE_CODE
Code of federal state
public static final Field ADDR_PROVINCE_NAME
Province Name
public static final Field ADDR_COUNTY_NAME
County Name
public static final Field ADDR_CITY_NAME
City Name
public static final Field ADDR_DISTRICT_NAME
District Name
public static final Field ADDR_POSTAL_CODE
Postal Code
public static final Field ADDR_TOWNSHIP_NAME
Township Name
public static final Field ADDR_NEIGHBORHOOD_NAME
Name of the neighborhood within the city
public static final Field ADDR_STREET_NAME
Street name
HERE Android SDK Developer's Guide
API Reference
843
public static final Field ADDR_HOUSE_NUMBER
House number of address. Can include characters.
public static final Field ADDR_CONTINENT_NAME
Continent name
public static final Field ADDR_TYPE_NAME
Type of address (city, street, etc.)
public static final Field ADDR_POPULATION
Population living at this address
public static final Field ADDR_BUILDING_NAME
Building Name
public static final Field ADDR_BUILDING_FLOOR
Building Floor
public static final Field ADDR_BUILDING_ROOM
Building Room
public static final Field ADDR_BUILDING_ZONE
Building Zone
public static final Field PLACE_NAME
Place Name
public static final Field PLACE_PRE_NAME
Place prefix.
public static final Field PLACE_POST_NAME
HERE Android SDK Developer's Guide
API Reference
844
Place postfix.
public static final Field PLACE_TYPE
Type of the place (premium, adplace, recommendation, etc.)
public static final Field PLACE_CATEGORY
Name of the category of the place
public static final Field PLACE_CATEGORY_ID
The identifier (number as a string) of the category.
public static final Field PLACE_DESCRIPTION
Short description of the place. Also used as input for place search.
public static final Field PLACE_PHONE_NUMBER
Phone number of the place.
public static final Field PLACE_URL
URL belonging to the place.
public static final Field PLACE_PREMIUM_URL_ID
Premium POI URL Id.
public static final Field PLACE_PREMIUM_NODE_ID
Premium POI Node Id.
public static final Field PLACE_ADVERTISEMENT_STRING
Advertisement string
public static final Field TZ_OFFSET_MINUTES
Time zone offset in minutes
HERE Android SDK Developer's Guide
API Reference
845
public static final Field OTHER_DATA
Can be used to return some other information for the location.
public static final Field PLACE_ICON_ID
The place's icon identifier. This is for Plug-In usage only. S60 shall make use of PlaceCategoryDataStore.
public static final Field LOCATION_TYPE
ADDRESS, POI, STRING.
public static final Field LOCATION_META
Additional flags to mark results
public static final Field LOCATION_TEXT
Formatted text of the location
public static final Field ADDR_AREA_ID
Area Id
public static final Field FOREIGN_ID
Foreign ID
public static final Field FOREIGN_ID_SOURCE
Foreign ID source. MapCartoMarker markers will have a source of "pvid"
Method Details
public static Field valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
846
public static LocationInfo.Field[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Map
The class Map is a member of com.here.android.mpa.mapping .
Class Summary
public final class Map
extends java.lang.Object
A Map object represents a virtual model of the world.
[For complete information, see the section Class Details]
Nested Class Summary
Table 432: Nested Classes in Map
Nested Classes
public static final enumeration Map.Animation
Represents values that describe animation types for on-screen map movements.
public static final enumeration Map.FleetFeature
Fleet features to be rendered on the map
public static final enumeration Map.LayerCategory
Definition for layer categories within a map.
public static abstract interface Map.OnSchemeChangedListener
Listener for Map scheme changed events.
public static abstract interface Map.OnTransformListener
Listener for Map transform events.
public static final enumeration Map.PedestrianFeature
Pedestrian features to be rendered on the map
public static class Map.PixelResult
Result class for conversion of a GeoCoordinate to screen pixel coordinates.
public static final enumeration Map.Projection
The projection scheme used to render the map.
public static final class Map.Scheme
Represents a collection of schemes that the Map class supports.
HERE Android SDK Developer's Guide
API Reference
847
Constructor Summary
Table 433: Constructors in Map
Constructors
Map ()
Default Constructor
Field Summary
Table 434: Fields in Map
Fields
public static final int ABSTRACT_CITY_MODEL
public static final int AIRPORT_AREA
public static final int AMUSEMENT_PARK
public static final int ANIMAL_PARK
public static final int BACKGROUND
public static final int BEACH
public static final int BORDER_BUILTUP
public static final int BORDER_COUNTRY
public static final int BORDER_LINE_OF_CONTROL
public static final int BORDER_REGIONAL
public static final int BORDER_STATE
public static final int BUILDING
public static final int BUILTUP
public static final int CEMETERY
public static final int CITY_PARK
public static final int DESERT
public static final int EXIT_SIGN
public static final int FERRY
public static final int GLACIER
public static final int GOLF_COURSE
public static final int HARBOR_AREA
public static final int HOSPITAL_CAMPUS
public static final int ICON_MOUNTAIN
HERE Android SDK Developer's Guide
API Reference
848
Fields
public static final int ICON_PUBLIC_TRANSIT_STATION
public static final int INDUSTRIAL_COMPLEX
public static final int LABEL_AIRPORT_AREA
public static final int LABEL_AMUSEMENT_PARK
public static final int LABEL_ANIMAL_PARK
public static final int LABEL_BEACH
public static final int LABEL_BUILDING
public static final int LABEL_CEMETERY
public static final int LABEL_CITY_CAPITAL
public static final int LABEL_CITY_OTHER
public static final int LABEL_CITY_PARK
public static final int LABEL_CITY_STATE_CAPITAL
public static final int LABEL_CONTINENT
public static final int LABEL_DESERT
public static final int LABEL_FERRY
public static final int LABEL_GLACIER
public static final int LABEL_GOLF_COURSE
public static final int LABEL_HARBOR_AREA
public static final int LABEL_HOSPITAL_CAMPUS
public static final int LABEL_INDUSTRIAL_COMPLEX
public static final int LABEL_ISLAND
public static final int LABEL_MAJOR_COUNTRY
public static final int LABEL_MILITARY_BASE
public static final int LABEL_MINOR_COUNTRY
public static final int LABEL_MOUNTAIN
public static final int LABEL_NATIONAL_PARK
public static final int LABEL_NATIVE_RESERVATION
public static final int LABEL_NEIGHBORHOOD_AREA
public static final int LABEL_OCEAN
public static final int LABEL_PEDESTRIAN_AREA
public static final int LABEL_PUBLIC_TRANSIT_LINE
HERE Android SDK Developer's Guide
API Reference
849
Fields
public static final int LABEL_PUBLIC_TRANSIT_STATION
public static final int LABEL_RAILYARD
public static final int LABEL_SEA
public static final int LABEL_SHOPPING_COMPLEX
public static final int LABEL_SPORTS_COMPLEX
public static final int LABEL_STATE
public static final int LABEL_STATE_ABBREVIATION
public static final int LABEL_STREET_CATEGORY_0
public static final int LABEL_STREET_CATEGORY_1
public static final int LABEL_STREET_CATEGORY_2
public static final int LABEL_STREET_CATEGORY_3
public static final int LABEL_STREET_CATEGORY_4
public static final int LABEL_STREET_CATEGORY_PEDESTRIAN
public static final int LABEL_STREET_CATEGORY_WALKWAY
public static final int LABEL_UNIVERSITY_CAMPUS
public static final int LABEL_WATER_OTHER
public static final int LABEL_WOODLAND
public static final int LAND
public static final int LANDMARK_3D
public static final int LAND_PARCEL
public static final int MILITARY_BASE
public static final float MOVE_PRESERVE_ORIENTATION
A valid orientation value that lies outside the minimum and maximum supported tilt range, used to indicate that the
current orientation should be preserved.
public static final float MOVE_PRESERVE_TILT
A valid tilt value that lies outside the range of getMinTilt() and getMaxTilt(), used to indicate that the current tilt should be
preserved.
public static final double MOVE_PRESERVE_ZOOM_LEVEL
A valid zoom level value that lies outside the range of getMinZoomLevel() and getMaxZoomLevel(), used to indicate that the
current zoom level should be preserved.
public static final int NATIONAL_PARK
public static final int NATIVE_RESERVATION
public static final int NEIGHBORHOOD_AREA
HERE Android SDK Developer's Guide
API Reference
850
Fields
public static final int OUTLINE_MILITARY_BASE
public static final int OUTLINE_NATIONAL_PARK
public static final int OUTLINE_NATIVE_RESERVATION
public static final int PEDESTRIAN_AREA
public static final int PEDESTRIAN_FEATURE
public static final int POINT_ADDRESS
public static final int POI_ICON
public static final int POI_LABEL
public static final int PUBLIC_TRANSIT_LINE
public static final int RAILROAD
public static final int RAILYARD
public static final int RELIEF
public static final int ROADSIGN_ICON
public static final int SHOPPING_COMPLEX
public static final int SPORTS_COMPLEX
public static final int STREET_CATEGORY_0
public static final int STREET_CATEGORY_1
public static final int STREET_CATEGORY_2
public static final int STREET_CATEGORY_3
public static final int STREET_CATEGORY_4
public static final int STREET_CATEGORY_PEDESTRIAN
public static final int STREET_CATEGORY_WALKWAY
public static final int UNIVERSITY_CAMPUS
public static final int WATER
public static final int WOODLAND
Method Summary
Table 435: Methods in Map
Methods
public void addClusterLayer (ClusterLayer layer)
Attaches cluster layer to the map.
HERE Android SDK Developer's Guide
API Reference
851
Methods
public boolean addMapObject (MapObject object)
Adds a MapObject to this Map .
public boolean addMapObjects (java.util.List <MapObject> objects)
Adds a List of multiple MapObject objects to this Map .
public boolean addMapOverlay (MapOverlay overlay)
Adds a MapOverlay to this Map .
public boolean addRasterTileSource (MapRasterTileSource source)
Adds a user-defined MapRasterTileSource to this Map .
public void addSchemeChangedListener (OnSchemeChangedListener listener)
Adds a Map.OnSchemeChangedListener to listen for map scheme change events.
public void addTransformListener (OnTransformListener listener)
Adds a Map.OnTransformListener to this Map to listen for map transform events.
public boolean areCartoMarkersVisible ()
Returns a boolean indicating whether all MapCartoMarkers of all IconCategory are visible.
public boolean areCartoMarkersVisible (IconCategory category)
Get if MapCartoMarkers of a certain POI category is shown.
public boolean areExtrudedBuildingsVisible ()
Returns a boolean indicating whether the extruded buildings layer is shown on this map.
public boolean areLandmarksVisible ()
Returns a boolean indicating whether 3D landmarks are currently visible.
public boolean areSafetySpotsVisible ()
Gets the current visibility of safety spots.
public static int convert (LayerCategory cat)
public CustomizableScheme createCustomizableScheme (String newSchemeName, String baseSchemeName)
Creates a customizable scheme based on an existing Map.Scheme.
public Map disableTrafficAutoUpdate ()
Disables automatic traffic information updates.
public static void enableMaximumFpsLimit (boolean isLimited)
Function to enable/disable the FPS draw limit.
public void executeSynchronized (Runnable task)
Execute a batched set of commands to the Map .
public GeoBoundingBox getBoundingBox ()
Returns the current visible map area as a GeoBoundingBox.
public GeoCoordinate getCenter ()
Returns the GeoCoordinate location at the current center of this Map .
HERE Android SDK Developer's Guide
API Reference
852
Methods
public String getCopyright ()
Returns the copyright notice text for this Map .
public CustomizableScheme getCustomizableScheme (String schemeName)
Retrieves a customizable scheme by using its name.
public java.util.EnumSet <FleetFeature> getFleetFeaturesVisible ()
Get the set of fleet features visible.
public int getHeight ()
Returns the current height of this Map , in number of pixels.
public MapBuildingLayer getMapBuildingLayer ()
Returns the MapBuildingLayer for this Map .
public String getMapDisplayLanguage ()
Get the language which the Map is set to render
public String getMapScheme ()
Returns the current scheme for the Map .
public List getMapSchemes ()
Returns a list containing all supported schemes for the Map .
public String getMapSecondaryDisplayLanguage ()
Get the secondary language which the Map is set to render
public MapState getMapState ()
Returns the current tilt, perspective, and zoom of the map as a MapState object.
public MapTrafficLayer getMapTrafficLayer ()
Get the MapTrafficLayer
public MapTransitLayer getMapTransitLayer ()
Returns the MapTransitLayer associated with this Map .
public float getMaxTilt ()
Returns the maximum degree allowed to be set as tilt angle for the Map .
public double getMaxZoomLevel ()
Returns the highest valid zoom level for Map , representing the closest view near the street-level
public static int getMaximumFps ()
Function to get the maximum drawing frames-per-second.
public float getMinTilt ()
Returns the minimum degree allowed to be set as tilt angle for the Map .
public double getMinZoomLevel ()
Returns the lowest valid zoom level for Map , representing the most distant view away from street-level.
HERE Android SDK Developer's Guide
API Reference
853
Methods
public float getOrientation ()
Returns the current orientation for this Map , in degrees relative to true-north, which has an orientation of 0 degrees.
public java.util.EnumSet <PedestrianFeature> getPedestrianFeaturesVisible ()
Get the set of pedestrian features visible.
public PositionIndicator getPositionIndicator ()
Deprecated: As of SDK 3.3.
Returns the PositionIndicator instance that renders the current position with a marker.
public Projection getProjectionMode ()
Gets the current map projection mode.
public double getScaleFromZoomLevel (double level)
Returns a map scale value based on the specified zoom level.
public java.util.List <ViewObject> getSelectedObjects (PointF p)
Returns the list of selectable ViewObject instances which are located at the specified screen pixel coordinates.
public java.util.List <ViewObject> getSelectedObjects (ViewRect rect)
Returns the list of selectable ViewObject objects which are within a specified ViewRect.
public java.util.List <ViewObject> getSelectedObjectsNearby (PointF p)
Returns the list of selectable ViewObject instances which are located at the specified screen pixel coordinates.
public List getSupportedMapDisplayLanguages ()
Get the list of supported display languages.
public float getTilt ()
Returns the current tilt angle for this Map , in degrees.
public PointF getTransformCenter ()
Returns the current center coordinate for Map transformations such as zooming and rotation.
public java.util.EnumSet <LayerCategory> getVisibleLayers ()
Get the set of Map layers being rendered.
public int getWidth ()
Returns the current width of this Map , in number of pixels.
public double getZoomLevel ()
Returns the current zoom level, which will be within a range between getMinZoomLevel() and getMaxZoomLevel().
public static boolean isMaximumFpsLimited ()
Function to check if the FPS draw limit is enabled or not.
public boolean isStreetLevelCoverageVisible ()
Returns a boolean indicating whether street level coverage is visible.
public boolean isTrafficAutoUpdateEnabled ()
Returns a boolean indicating whether automatic traffic updates are enabled.
HERE Android SDK Developer's Guide
API Reference
854
Methods
public boolean isTrafficInfoVisible ()
Returns a boolean indicating whether traffic information is currently visible on the Map .
public void pan (PointF from, PointF to)
Moves the map from one specified screen pixel coordinates to another in a linear motion.
public GeoCoordinate pixelToGeo (PointF point)
Converts and returns GeoCoordinate from screen pixel coordinates.
public GeoCoordinate pixelToGeo (PointF point, float altitude)
Converts and returns GeoCoordinate from screen pixel coordinates at specific altitude.
public java.util.List <GeoCoordinate> pixelToGeo (List points)
Converts and returns a list of GeoCoordinate objects from a List of screen pixel coordinates.
public PixelResult projectToPixel (GeoCoordinate coordinate)
Converts and returns a PixelResult that represents screen pixel coordinates from a GeoCoordinate.
public java.util.List <PixelResult> projectToPixel (java.util.List <GeoCoordinate> coordinates)
Converts and returns a list of Map.PixelResult elements that represent screen pixel coordinates from a List of
GeoCoordinate objects.
public void removeClusterLayer (ClusterLayer layer)
Detaches the cluster from the map.
public boolean removeCustomizableScheme (String schemeName)
Remove customizable scheme.
public boolean removeMapObject (MapObject object)
Removes a MapObject from this Map .
public boolean removeMapObjects (java.util.List <MapObject> objects)
Removes a List of multiple MapObject objects from this Map .
public boolean removeMapOverlay (MapOverlay overlay)
Removes a MapOverlay from this Map .
public boolean removeRasterTileSource (MapRasterTileSource source)
Removes a user-defined MapRasterTileSource from this Map .
public void removeSchemeChangedListener (OnSchemeChangedListener listener)
Removes an existing Map.OnSchemeChangedListener.
public void removeTransformListener (OnTransformListener listener)
Removes an existing Map.OnTransformListener from this Map .
public Map setCartoMarkersVisible (boolean visible)
Show or hide all MapCartoMarkers on Map .
public Map setCartoMarkersVisible (IconCategory category, boolean visible)
Toggles the visibility of a particular POI category's MapCartoMarkers.
HERE Android SDK Developer's Guide
API Reference
855
Methods
public void setCenter (GeoCoordinate point, Animation animation, double level, float orientation,
float tilt)
Moves the center of this Map to a specific GeoCoordinate, while simultaneously setting a zoom level (a fraction within the
range of minimum and maximum levels), orientation (from 0 degrees to 360 degrees), and tilt (within the range of minimum
and maximum tilt angles).
public void setCenter (GeoCoordinate point, Animation animation)
Moves the center of this Map to the specified GeoCoordinate using the given Map.Animation.
public void setCenter (PointF newCenter, Animation animation, double zoomLevel, float
orientation, float tilt)
Centers the map at the specified screen pixel coordinates.
public static void setCustomMapConfiguration (String pathToConfigFile, String
pathToResourceFile)
Deprecated: As of SDK 3.4.
Set a custom map style configuration.
public boolean setExtrudedBuildingsVisible (boolean visible)
Show or hide the extruded buildings layer on this map.
public Map setFadingAnimations (boolean enabled)
Enable or disable animations for labels and icons shown on the map.
public Map setFleetFeaturesVisible (java.util.EnumSet <FleetFeature> features)
Set a set of fleet features to be visible.
public Map setLandmarksVisible (boolean visible)
Sets 3D landmarks to be either visible or invisible for this Map .
public boolean setMapDisplayLanguage (Locale language)
Set the map display language using a locale.
public Map setMapScheme (String scheme)
Sets a scheme for the Map to the specified String value.
public Map setMapScheme (CustomizableScheme customizableScheme)
Sets a scheme for the Map to the specified customizable scheme.
public boolean setMapSecondaryDisplayLanguage (Locale language)
Set the map secondary display language using a locale.
public static void setMaximumFps (int fps)
Function to set the maximum drawing frames-per-second.
public void setMaximumTiltFunction (ZoomLevelToTiltFunction function)
The functional relationship between zoom and maximum tilt.
public Map setOrientation (float angle)
Sets an absolute orientation for this Map to the specified angle, in degrees, where true-north is 0 degrees.
HERE Android SDK Developer's Guide
API Reference
856
Methods
public void setOrientation (float angle, Animation animation)
Sets an absolute orientation for this Map to the specified angle, in degrees, where true-north is 0 degrees.
public Map setPedestrianFeaturesVisible (java.util.EnumSet <PedestrianFeature> features)
Set a set of pedestrian features to be visible.
public Map setProjectionMode (Projection projection)
Change the projection mode used to render the map.
public void setSafetySpotsVisible (boolean visible)
Sets safety spots visible.
public Map setStreetLevelCoverageVisible (boolean visible)
Sets street level coverage to be either visible or invisible for the Map .
public Map setTilt (float angle)
Sets a tilt angle for this Map , in degrees.
public void setTilt (float angle, Animation animation)
Sets a tilt angle for the Map , in degrees.
public Map setTrafficInfoVisible (boolean visible)
Sets traffic information to be either visible or invisible for this Map .
public Map setTransformCenter (PointF center)
Sets a center coordinate for Map transformations such as zooming and rotation.
public boolean setUseSystemLanguage ()
Set the map display language using the system default locale.
public Map setVisibleLayers (java.util.EnumSet <LayerCategory> layers, boolean enable)
Toggles the visibility of the map layer categories to be rendered.
public Map setZoomLevel (double level)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom levels.
public void setZoomLevel (double level, Animation animation)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom levels.
public void setZoomLevel (double level, PointF focus, Animation animation)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom levels while keeping the
specified screen coordinate at the same Geographical Location.
public void zoomTo (GeoBoundingBox geoRect, Animation animation, float orientation)
Moves this Map instance's map center and changes the zoom level to show the specified GeoBoundingBox at the given
orientation.
public void zoomTo (GeoBoundingBox geoRect, Animation animation, float orientation, float
perspective)
Moves this Map instance's map center and changes the zoom level to show the specified GeoBoundingBox at the given
orientation.
HERE Android SDK Developer's Guide
API Reference
857
Methods
public void zoomTo (GeoBoundingBox geoRect, ViewRect viewPort, Animation animation, float
orientation)
Moves this Map instance and changes its zoom level to show the specified GeoBoundingBox within the provided ViewRect.
public void zoomTo (GeoBoundingBox geoRect, int width, int height, Animation animation, float
orientation)
Moves this Map instance and changes its zoom level to show the specified GeoBoundingBox within the specified pixel
dimensions around the transform center.
Class Details
A Map object represents a virtual model of the world. When embedded in a MapFragment, or MapView, Map
objects can be used to show maps, add/remove map objects, and enable user interactions.
Constructor Details
Map ()
Default Constructor
Field Details
public static final int ABSTRACT_CITY_MODEL
public static final int AIRPORT_AREA
public static final int AMUSEMENT_PARK
public static final int ANIMAL_PARK
public static final int BACKGROUND
public static final int BEACH
public static final int BORDER_BUILTUP
public static final int BORDER_COUNTRY
HERE Android SDK Developer's Guide
API Reference
858
public static final int BORDER_LINE_OF_CONTROL
public static final int BORDER_REGIONAL
public static final int BORDER_STATE
public static final int BUILDING
public static final int BUILTUP
public static final int CEMETERY
public static final int CITY_PARK
public static final int DESERT
public static final int EXIT_SIGN
public static final int FERRY
public static final int GLACIER
public static final int GOLF_COURSE
public static final int HARBOR_AREA
public static final int HOSPITAL_CAMPUS
public static final int ICON_MOUNTAIN
public static final int ICON_PUBLIC_TRANSIT_STATION
HERE Android SDK Developer's Guide
API Reference
859
public static final int INDUSTRIAL_COMPLEX
public static final int LABEL_AIRPORT_AREA
public static final int LABEL_AMUSEMENT_PARK
public static final int LABEL_ANIMAL_PARK
public static final int LABEL_BEACH
public static final int LABEL_BUILDING
public static final int LABEL_CEMETERY
public static final int LABEL_CITY_CAPITAL
public static final int LABEL_CITY_OTHER
public static final int LABEL_CITY_PARK
public static final int LABEL_CITY_STATE_CAPITAL
public static final int LABEL_CONTINENT
public static final int LABEL_DESERT
public static final int LABEL_FERRY
public static final int LABEL_GLACIER
HERE Android SDK Developer's Guide
API Reference
860
public static final int LABEL_GOLF_COURSE
public static final int LABEL_HARBOR_AREA
public static final int LABEL_HOSPITAL_CAMPUS
public static final int LABEL_INDUSTRIAL_COMPLEX
public static final int LABEL_ISLAND
public static final int LABEL_MAJOR_COUNTRY
public static final int LABEL_MILITARY_BASE
public static final int LABEL_MINOR_COUNTRY
public static final int LABEL_MOUNTAIN
public static final int LABEL_NATIONAL_PARK
public static final int LABEL_NATIVE_RESERVATION
public static final int LABEL_NEIGHBORHOOD_AREA
public static final int LABEL_OCEAN
public static final int LABEL_PEDESTRIAN_AREA
public static final int LABEL_PUBLIC_TRANSIT_LINE
public static final int LABEL_PUBLIC_TRANSIT_STATION
HERE Android SDK Developer's Guide
API Reference
861
public static final int LABEL_RAILYARD
public static final int LABEL_SEA
public static final int LABEL_SHOPPING_COMPLEX
public static final int LABEL_SPORTS_COMPLEX
public static final int LABEL_STATE
public static final int LABEL_STATE_ABBREVIATION
public static final int LABEL_STREET_CATEGORY_0
public static final int LABEL_STREET_CATEGORY_1
public static final int LABEL_STREET_CATEGORY_2
public static final int LABEL_STREET_CATEGORY_3
public static final int LABEL_STREET_CATEGORY_4
public static final int LABEL_STREET_CATEGORY_PEDESTRIAN
public static final int LABEL_STREET_CATEGORY_WALKWAY
public static final int LABEL_UNIVERSITY_CAMPUS
public static final int LABEL_WATER_OTHER
HERE Android SDK Developer's Guide
API Reference
862
public static final int LABEL_WOODLAND
public static final int LAND
public static final int LANDMARK_3D
public static final int LAND_PARCEL
public static final int MILITARY_BASE
public static final float MOVE_PRESERVE_ORIENTATION
A valid orientation value that lies outside the minimum and maximum supported tilt range, used to indicate
that the current orientation should be preserved. Pass this value to preserve the orientation when calling
compound Map transform operations.
public static final float MOVE_PRESERVE_TILT
A valid tilt value that lies outside the range of getMinTilt() and getMaxTilt(), used to indicate that the
current tilt should be preserved. Pass this value to preserve the tilt when calling compound Map transform
operations.
public static final double MOVE_PRESERVE_ZOOM_LEVEL
A valid zoom level value that lies outside the range of getMinZoomLevel() and getMaxZoomLevel(), used to
indicate that the current zoom level should be preserved. Pass this value to preserve the zoom level when
calling compound Map transform operations.
public static final int NATIONAL_PARK
public static final int NATIVE_RESERVATION
public static final int NEIGHBORHOOD_AREA
public static final int OUTLINE_MILITARY_BASE
HERE Android SDK Developer's Guide
API Reference
863
public static final int OUTLINE_NATIONAL_PARK
public static final int OUTLINE_NATIVE_RESERVATION
public static final int PEDESTRIAN_AREA
public static final int PEDESTRIAN_FEATURE
public static final int POINT_ADDRESS
public static final int POI_ICON
public static final int POI_LABEL
public static final int PUBLIC_TRANSIT_LINE
public static final int RAILROAD
public static final int RAILYARD
public static final int RELIEF
public static final int ROADSIGN_ICON
public static final int SHOPPING_COMPLEX
public static final int SPORTS_COMPLEX
public static final int STREET_CATEGORY_0
public static final int STREET_CATEGORY_1
HERE Android SDK Developer's Guide
API Reference
864
public static final int STREET_CATEGORY_2
public static final int STREET_CATEGORY_3
public static final int STREET_CATEGORY_4
public static final int STREET_CATEGORY_PEDESTRIAN
public static final int STREET_CATEGORY_WALKWAY
public static final int UNIVERSITY_CAMPUS
public static final int WATER
public static final int WOODLAND
Method Details
public void addClusterLayer (ClusterLayer layer)
Attaches cluster layer to the map. From this moment on the markers added to the layer will be also added to
the map. After the layer is added clustering will happen automatically.
Parameters:
layer
layer to add
Throws:
NullPointerException
if null is passed as an argument
public boolean addMapObject (MapObject object)
Adds a MapObject to this Map .
Parameters:
object
HERE Android SDK Developer's Guide
API Reference
865
A MapObject to add
Returns:
True if the MapObject was added successfully, false otherwise (if the object has already been added, as
duplicates are not allowed).
Throws:
NullPointerException
if object is null.
See also:
addMapObjects(List<MapObject>)
removeMapObject(MapObject)
public boolean addMapObjects (java.util.List <MapObject> objects)
Adds a List of multiple MapObject objects to this Map .
Parameters:
objects
A List of MapObject objects to add
Returns:
True if all the MapObjects in the List were added successfully, false otherwise (if any of the objects have
already been added, as duplicates are not allowed).
Throws:
NullPointerException
if objects is null
See also:
addMapObject(MapObject)
removeMapObjects(List<MapObjects>)
public boolean addMapOverlay (MapOverlay overlay)
Adds a MapOverlay to this Map .
Parameters:
overlay
A MapOverlay to add.
Returns:
True if the MapOverlay was added successfully, false otherwise.
Throws:
HERE Android SDK Developer's Guide
API Reference
866
NullPointerException
if overlay is null
See also:
removeMapOverlay(MapOverlay)
public boolean addRasterTileSource (MapRasterTileSource source)
Adds a user-defined MapRasterTileSource to this Map .
Parameters:
source
A MapRasterTileSource representing a user-defined raster tile source
Returns:
True if the raster tile source was added successfully, false otherwise
See also:
removeRasterTileSource(MapRasterTileSource)
public void addSchemeChangedListener (OnSchemeChangedListener listener)
Adds a Map.OnSchemeChangedListener to listen for map scheme change events.
Parameters:
listener
A Map.OnSchemeChangedListener to add to the Map
See also:
removeTransformListener(OnTransformListener)
public void addTransformListener (OnTransformListener listener)
Adds a Map.OnTransformListener to this Map to listen for map transform events.
Parameters:
listener
A Map.OnTransformListener to add to the Map
See also:
removeTransformListener(OnTransformListener)
public boolean areCartoMarkersVisible ()
Returns a boolean indicating whether all MapCartoMarkers of all IconCategory are visible.
HERE Android SDK Developer's Guide
API Reference
867
This is equivalent to calling areCartoMarkersVisible(IconCategory) with IconCategory.ALL .
Returns:
true if MapCartoMarkers of all IconCategory are visible, false otherwise.
public boolean areCartoMarkersVisible (IconCategory category)
Get if MapCartoMarkers of a certain POI category is shown.
Parameters:
category
See IconCategory for category list.
Returns:
true if the MapCartoMarkers of the specified category is visible, false otherwise.
public boolean areExtrudedBuildingsVisible ()
Returns a boolean indicating whether the extruded buildings layer is shown on this map.
Returns:
true if shown, false otherwise.
public boolean areLandmarksVisible ()
Returns a boolean indicating whether 3D landmarks are currently visible.
Returns:
True if landmarks are visible, false otherwise
public boolean areSafetySpotsVisible ()
Gets the current visibility of safety spots.
Returns:
true if safety spot visibility has been enabled.
public static int convert (LayerCategory cat)
Parameters:
cat
public CustomizableScheme createCustomizableScheme (String newSchemeName,
String baseSchemeName)
HERE Android SDK Developer's Guide
API Reference
868
Creates a customizable scheme based on an existing Map.Scheme. Please note that created schemes are
destroyed when the application life cycle ends.
Parameters:
newSchemeName
Name of the new scheme which you want to create.
baseSchemeName
Name of base scheme. New scheme will be derived from this base scheme. Base scheme should be one
from getMapSchemes()
Returns:
A customizable Scheme Instance.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
NullPointerException
if newSchemeName OR baseSchemeName is null.
InvalidParameterException
if baseSchemeName is not valid OR newSchemeName already exist.
public Map disableTrafficAutoUpdate ()
Disables automatic traffic information updates.
To implement custom traffic updates in an app, use this method to turn off automatic updating, then call
TrafficUpdater#request(GeoCoordinate, int, TrafficUpdater.Listener) as needed to
request traffic in a radius around a given location.
This method must be called before setTrafficInfoVisible(boolean).
Returns:
The modified Map itself.
public static void enableMaximumFpsLimit (boolean isLimited)
Function to enable/disable the FPS draw limit. When enabled, the redraw of the map will be limited to the
value set using setMaximumFps(int). When disabled, the redraw rate will be hardware limited.
Parameters:
isLimited
True if FPS limiting is to be enabled. False, to disable limiting.
public void executeSynchronized (Runnable task)
HERE Android SDK Developer's Guide
API Reference
869
Execute a batched set of commands to the Map . This is useful to improve performance when multiple
operations require re-rendering of the display.
Parameters:
task
Task block to execute synchronously.
public GeoBoundingBox getBoundingBox ()
Returns the current visible map area as a GeoBoundingBox.
Note that a bounding box is always rectangular, and its sides are always parallel to latitude and longitude.
If the map is rotated when this method is called (for example, if the orientation is 10 degrees east of true-
north), the returned bounding box will be a circumscribed rectangle that is larger than the visible map
area. Similarly, when the map is tilted (for example, if the map is tilted by 45 degrees), the visible map area
represents a trapezoidal area in the world. Calling getBoundingBox() will then return a larger circumscribed
rectangle that contains this trapezoid area.
The bounding box may be invalid when this method is called at low zoom levels, as the map area does not fill
the screen.
Returns:
The GeoBoundingBox containing the visible map area.
public GeoCoordinate getCenter ()
Returns the GeoCoordinate location at the current center of this Map .
Returns:
The current map center
public String getCopyright ()
Returns the copyright notice text for this Map . This text is only available after Map completes rendering for
the first time.
Returns:
The copyright notice
public CustomizableScheme getCustomizableScheme (String schemeName)
Retrieves a customizable scheme by using its name.
Parameters:
schemeName
Name of customizable scheme name.
HERE Android SDK Developer's Guide
API Reference
870
Returns:
A customizable Scheme Instance OR null if no scheme found.
Throws:
InvalidParameterException
if scheme with this name is not configurable.
public java.util.EnumSet <FleetFeature> getFleetFeaturesVisible ()
Get the set of fleet features visible.
Returns:
The EnumSet of fleet features enabled
public int getHeight ()
Returns the current height of this Map , in number of pixels.
Returns:
The current height
public MapBuildingLayer getMapBuildingLayer ()
Returns the MapBuildingLayer for this Map . This layer enables user interactions with extruded buildings on
the map.
Returns:
A MapBuildingLayer instance for this Map.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public String getMapDisplayLanguage ()
Get the language which the Map is set to render
Returns:
String MARC code of the displayed language.
public String getMapScheme ()
Returns the current scheme for the Map .
Returns:
HERE Android SDK Developer's Guide
API Reference
871
The current scheme
See also:
Map.Scheme
getMapSchemes()
public List getMapSchemes ()
Returns a list containing all supported schemes for the Map .
Returns:
The supported schemes
See also:
Map.Scheme
getMapScheme()
setMapScheme(String)
public String getMapSecondaryDisplayLanguage ()
Get the secondary language which the Map is set to render
Returns:
String MARC code of the displayed language.
public MapState getMapState ()
Returns the current tilt, perspective, and zoom of the map as a MapState object.
Returns:
MapState object representing current state of the map.
public MapTrafficLayer getMapTrafficLayer ()
Get the MapTrafficLayer
Returns:
MapTrafficLayer
public MapTransitLayer getMapTransitLayer ()
Returns the MapTransitLayer associated with this Map .
Returns:
HERE Android SDK Developer's Guide
API Reference
872
The MapTransitLayer
public float getMaxTilt ()
Returns the maximum degree allowed to be set as tilt angle for the Map .
Returns:
float maximum tilt angle in degrees.
public double getMaxZoomLevel ()
Returns the highest valid zoom level for Map , representing the closest view near the street-level
Returns:
The maximum zoom level
public static int getMaximumFps ()
Function to get the maximum drawing frames-per-second.
Returns:
The maximum drawing frames-per-second.
public float getMinTilt ()
Returns the minimum degree allowed to be set as tilt angle for the Map .
Returns:
float minimum tilt angle in degrees.
public double getMinZoomLevel ()
Returns the lowest valid zoom level for Map , representing the most distant view away from street-level.
Returns:
The minimum zoom level
public float getOrientation ()
Returns the current orientation for this Map , in degrees relative to true-north, which has an orientation of 0
degrees.
Returns:
The current orientation angle
HERE Android SDK Developer's Guide
API Reference
873
public java.util.EnumSet <PedestrianFeature> getPedestrianFeaturesVisible ()
Get the set of pedestrian features visible.
Returns:
The EnumSet of Pedestrian features enabled
public PositionIndicator getPositionIndicator ()
Deprecated: As of SDK 3.3.
Use getPositionIndicator() or getPositionIndicator() instead.
Returns the PositionIndicator instance that renders the current position with a marker. The position indicator
should be used with PositioningManager.
Returns:
The PositionIndicator
public Projection getProjectionMode ()
Gets the current map projection mode.
Returns:
Projection current projection mode.
public double getScaleFromZoomLevel (double level)
Returns a map scale value based on the specified zoom level. Scale units are in physical geo centimeters per
screen inch.
Parameters:
level
The zoom level to be translated to a map scale.
Returns:
Scale value for the passed level. Units are in geo centimeters per screen inch
public java.util.List <ViewObject> getSelectedObjects (PointF p)
Returns the list of selectable ViewObject instances which are located at the specified screen pixel
coordinates.
Parameters:
p
Screen pixel coordinate to check for ViewObject.
Returns:
HERE Android SDK Developer's Guide
API Reference
874
The list of ViewObject objects at the pixel coordinate. If no object exists at p, returns an empty list.
public java.util.List <ViewObject> getSelectedObjects (ViewRect rect)
Returns the list of selectable ViewObject objects which are within a specified ViewRect.
Parameters:
rect
A ViewRect with selected ViewObject objects
Returns:
The list of ViewObjects within the ViewRect. If no object exists within rect, returns an empty list.
public java.util.List <ViewObject> getSelectedObjectsNearby (PointF p)
Returns the list of selectable ViewObject instances which are located at the specified screen pixel
coordinates.
Parameters:
p
Screen pixel coordinate to check for ViewObject.
Returns:
The list of ViewObject objects at the pixel coordinate. If no object exists at p, returns an empty list.
public List getSupportedMapDisplayLanguages ()
Get the list of supported display languages.
Returns:
a list of supported map display languages
public float getTilt ()
Returns the current tilt angle for this Map , in degrees.
Returns:
The current tilt angle
public PointF getTransformCenter ()
Returns the current center coordinate for Map transformations such as zooming and rotation. The transform
center may be different than the Map center.
Returns:
HERE Android SDK Developer's Guide
API Reference
875
The PointF representing the current center used for transformations
public java.util.EnumSet <LayerCategory> getVisibleLayers ()
Get the set of Map layers being rendered.
Returns:
An EnumSet identifying the rendered layers.
public int getWidth ()
Returns the current width of this Map , in number of pixels.
Returns:
The current width
public double getZoomLevel ()
Returns the current zoom level, which will be within a range between getMinZoomLevel() and
getMaxZoomLevel(). The zoom level is only precise to three decimal places due to numerical operations
performed internally when rendering the map.
Returns:
The zoom level within the fractional range
public static boolean isMaximumFpsLimited ()
Function to check if the FPS draw limit is enabled or not.
Returns:
True if FPS draw limit is enabled. False otherwise.
public boolean isStreetLevelCoverageVisible ()
Returns a boolean indicating whether street level coverage is visible.
Returns:
True if street level coverage is visible, false otherwise
public boolean isTrafficAutoUpdateEnabled ()
Returns a boolean indicating whether automatic traffic updates are enabled.
Returns:
True if traffic updates are requested automatically, false otherwise.
HERE Android SDK Developer's Guide
API Reference
876
public boolean isTrafficInfoVisible ()
Returns a boolean indicating whether traffic information is currently visible on the Map .
Returns:
True if traffic information is visible, false otherwise
public void pan (PointF from, PointF to)
Moves the map from one specified screen pixel coordinates to another in a linear motion.
Parameters:
from
A PointF representing the screen pixel coordinates to pan the map from.
to
A PointF representing the screen pixel coordinates to pan the map to.
public GeoCoordinate pixelToGeo (PointF point)
Converts and returns GeoCoordinate from screen pixel coordinates.
This method returns null if the conversion fails. (For example, if the coordinate is not a valid value.)
Parameters:
point
The screen pixel coordinates to convert
Returns:
A GeoCoordinate representing the map location. null if the conversion fails.
See also:
pixelToGeo(PointF, float)
pixelToGeo(List<PointF>)
public GeoCoordinate pixelToGeo (PointF point, float altitude)
Converts and returns GeoCoordinate from screen pixel coordinates at specific altitude.
This method returns null if the conversion fails. (For example, if the coordinate is not a valid value.)
Parameters:
point
The screen pixel coordinates to convert
altitude
A height in meters on which GeoCoordinate need to be calculated.
HERE Android SDK Developer's Guide
API Reference
877
Returns:
A GeoCoordinate representing the map location. null if the conversion fails.
See also:
pixelToGeo(PointF)
pixelToGeo(List<PointF>)
public java.util.List <GeoCoordinate> pixelToGeo (List points)
Converts and returns a list of GeoCoordinate objects from a List of screen pixel coordinates.
This method returns one or more list elements as null if the conversion of the corresponding pixel
coordinates fails.
Parameters:
points
A List of screen pixel coordinates to convert
Returns:
A list of GeoCoordinate or null elements.
See also:
pixelToGeo(PointF)
pixelToGeo(PointF, float)
public PixelResult projectToPixel (GeoCoordinate coordinate)
Converts and returns a PixelResult that represents screen pixel coordinates from a GeoCoordinate. This
method is converts a GeoCoordinate from world space to screen space.
Parameters:
coordinate
A GeoCoordinate to convert
Returns:
A PixelResult representing screen pixel coordinates and operation success code. Check
PixelResult#getError() to check the success of the conversion.
See also:
projectToPixel(List<GeoCoordinate>)
public java.util.List <PixelResult> projectToPixel (java.util.List
<GeoCoordinate> coordinates)
HERE Android SDK Developer's Guide
API Reference
878
Converts and returns a list of Map.PixelResult elements that represent screen pixel coordinates from a List
of GeoCoordinate objects.
This method returns one or more list elements as null if the conversion of the corresponding
GeoCoordinate instances fails.
Parameters:
coordinates
A List of GeoCoordinate objects to convert
Returns:
The list of PixelResult results. Check PixelResult#getError() to check the success of each
conversion.
See also:
projectToPixel(GeoCoordinate)
public void removeClusterLayer (ClusterLayer layer)
Detaches the cluster from the map. After this call completes markers on this layer will be removed from the
map.
Parameters:
layer
layer to remove
public boolean removeCustomizableScheme (String schemeName)
Remove customizable scheme. Please note that the current scheme cannot be removed.
Parameters:
schemeName
Name of the scheme which you want to remove.
Returns:
Boolean indicating scheme has been removed successfully.
Throws:
NullPointerException
if schemeName is null.
InvalidParameterException
if schemeName is not valid OR not removable.
public boolean removeMapObject (MapObject object)
Removes a MapObject from this Map .
HERE Android SDK Developer's Guide
API Reference
879
Parameters:
object
A MapObject to remove
Returns:
True if the MapObject was removed successfully, false otherwise
See also:
removeMapObjects(List<MapObject>)
public boolean removeMapObjects (java.util.List <MapObject> objects)
Removes a List of multiple MapObject objects from this Map .
Parameters:
objects
A List of MapObject objects to remove
Returns:
True if all the MapObjects in the List were removed successfully, false otherwise
See also:
removeMapObject(MapObject)
public boolean removeMapOverlay (MapOverlay overlay)
Removes a MapOverlay from this Map .
Parameters:
overlay
A MapOverlay to remove
Returns:
True if the MapOverlay was removed successfully, false otherwise.
Throws:
NullPointerException
if overlay is null
public boolean removeRasterTileSource (MapRasterTileSource source)
Removes a user-defined MapRasterTileSource from this Map .
Parameters:
source
HERE Android SDK Developer's Guide
API Reference
880
A MapRasterTileSource representing a user-defined raster tile source
Returns:
True if the raster tile source was removed successfully, false otherwise
public void removeSchemeChangedListener (OnSchemeChangedListener listener)
Removes an existing Map.OnSchemeChangedListener.
Parameters:
listener
A Map.OnSchemeChangedListener to remove from the Map
public void removeTransformListener (OnTransformListener listener)
Removes an existing Map.OnTransformListener from this Map .
Parameters:
listener
A Map.OnTransformListener to remove from the Map
public Map setCartoMarkersVisible (boolean visible)
Show or hide all MapCartoMarkers on Map .
Parameters:
visible
Whether the MapCartoMarkers should be visible.
Returns:
The updated Map.
public Map setCartoMarkersVisible (IconCategory category, boolean visible)
Toggles the visibility of a particular POI category's MapCartoMarkers. To toggle visibility for IconCategory.ALL
categories, setCartoMarkersVisible(boolean) can also be used.
Parameters:
category
See IconCategory for category list.
visible
Intended visibility for the specific POI category's MapCartoMarkers.
Returns:
HERE Android SDK Developer's Guide
API Reference
881
The updated Map itself.
public void setCenter (GeoCoordinate point, Animation animation, double level,
float orientation, float tilt)
Moves the center of this Map to a specific GeoCoordinate, while simultaneously setting a zoom level (a
fraction within the range of minimum and maximum levels), orientation (from 0 degrees to 360 degrees),
and tilt (within the range of minimum and maximum tilt angles). If you wish to keep the current zoom level,
orientation, or tilt after setting a new center, pass one or more of the following values as the relevant
parameter:
MOVE_PRESERVE_ZOOM_LEVEL to keep the current zoom level
MOVE_PRESERVE_ORIENTATION to keep the current orientation
MOVE_PRESERVE_TILT to keep the current tile
Note: it is unlikely that you would pass all three of the special MOVE_PRESERVE_ZOOM_LEVEL,
MOVE_PRESERVE_ORIENTATION and MOVE_PRESERVE_TILT parameters when calling this method (it would
make more sense to call setCenter(GeoCoordinate, Animation)). More likely, you would use one or two of
the special parameters (for example, change the orientation and tilt along with the center coordinate while
keeping the current zoom level).
Parameters:
point
A GeoCoordinate representing the new center
animation
A Map.Animation to illustrate the transformation
level
Desired zoom level of the newly-centered Map (pass MOVE_PRESERVE_ZOOM_LEVEL to keep the current
level)
orientation
Desired orientation of the newly-centered Map (pass MOVE_PRESERVE_ORIENTATION to keep the current
orientation)
tilt
Desired tilt angle of the newly-centered Map (pass MOVE_PRESERVE_TILT to keep the current tilt)
See also:
setCenter(GeoCoordinate, Animation)
getMaxZoomLevel()
getMinZoomLevel()
getMaxTilt()
getMinTilt()
public void setCenter (GeoCoordinate point, Animation animation)
HERE Android SDK Developer's Guide
API Reference
882
Moves the center of this Map to the specified GeoCoordinate using the given Map.Animation.
Parameters:
point
A GeoCoordinate representing the new center
animation
An Animation to illustrate the transformation
See also:
setCenter(GeoCoordinate, Animation, double, float, float)
public void setCenter (PointF newCenter, Animation animation, double
zoomLevel, float orientation, float tilt)
Centers the map at the specified screen pixel coordinates. The zoom level, orientation and tilt angle be
adjusted at the same time.
Parameters:
newCenter
A PointF representing the screen pixel coordinates to set as map center.
animation
An Animation to illustrate the transformation
zoomLevel
Desired zoom level of the newly-centered Map. Use MOVE_PRESERVE_ZOOM_LEVEL to keep the current
zoom level.
orientation
Desired orientation of the newly-centered Map. Use MOVE_PRESERVE_ORIENTATION to keep the current
orientation angle.
tilt
Desired tilt angle of the newly-centered Map. Use MOVE_PRESERVE_TILT to keep the current tilt angle.
Throws:
IllegalArgumentException
if unsupported zoom level or orientation angel is specified.
See also:
setCenter(GeoCoordinate, Animation, double, float, float)
public static void setCustomMapConfiguration (String pathToConfigFile,
String pathToResourceFile)
Deprecated: As of SDK 3.4.
Use set(Hashtable) instead.
HERE Android SDK Developer's Guide
API Reference
883
Set a custom map style configuration. The custom map style setting should be made before the first Map is
created. Note: This API should only be used in consultation with HERE technical support.
Parameters:
pathToConfigFile
Map Style Configuration File.
pathToResourceFile
Map Style Resource File. Can be null where default file will be used.
Throws:
FileNotFoundException
If pathToConfigFile or pathToResourceFile not exists.
public boolean setExtrudedBuildingsVisible (boolean visible)
Show or hide the extruded buildings layer on this map.
Parameters:
visible
true to show extruded building, false otherwise
Returns:
boolean True if extruded build visibility has been changed successfully. False, otherwise.
public Map setFadingAnimations (boolean enabled)
Enable or disable animations for labels and icons shown on the map. Note: the fading animations property
will take effect when the map is redrawn.
Parameters:
enabled
true to enable animations (default), false to disable animations
Returns:
The updated Map.
public Map setFleetFeaturesVisible (java.util.EnumSet <FleetFeature>
features)
Set a set of fleet features to be visible. Features not in the set will be set invisible. An empty set means no
features are visible.
Parameters:
features
A set of visible fleet features
HERE Android SDK Developer's Guide
API Reference
884
Returns:
The updated Map itself.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public Map setLandmarksVisible (boolean visible)
Sets 3D landmarks to be either visible or invisible for this Map .
If the map scheme is set to any Hybrid or Satellite map schemes (such as SATELLITE_DAY or HYBRID_DAY),
this method will have no visible effect.
Parameters:
visible
A boolean specifying whether 3D landmarks should be visible
Returns:
The updated Map.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public boolean setMapDisplayLanguage (Locale language)
Set the map display language using a locale. Causes a map redraw when language is set.
When this method is called, it will override the device's current locale until the device's locale is changed.
This language change does not affect other features like search.
Parameters:
language
The language locale as described in http://developer.android.com/reference/java/util/Locale.htm..
Returns:
true if the language is accepted by the Map, false otherwise.
public Map setMapScheme (String scheme)
Sets a scheme for the Map to the specified String value.
Parameters:
scheme
The desired scheme from getMapSchemes().
HERE Android SDK Developer's Guide
API Reference
885
Returns:
The updated Map.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
See also:
Map.Scheme
getMapSchemes()
public Map setMapScheme (CustomizableScheme customizableScheme)
Sets a scheme for the Map to the specified customizable scheme.
Parameters:
customizableScheme
CustomizableScheme instance.
Returns:
The updated Map.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
See also:
Map.Scheme
getMapSchemes()
public boolean setMapSecondaryDisplayLanguage (Locale language)
Set the map secondary display language using a locale. Causes a map redraw when language is set. Passing
null will cause the display of secondary language to be disabled.
Setting a secondary display language will cause the language to be displayed below the primary language for
some map labels (e.g. countries).
Parameters:
language
The language locale as described in http://developer.android.com/reference/java/util/Locale.htm.. or
null to disable display of secondary language.
Returns:
true if the language is accepted by the Map, false otherwise.
HERE Android SDK Developer's Guide
API Reference
886
See also:
setMapDisplayLanguage(Locale)
public static void setMaximumFps (int fps)
Function to set the maximum drawing frames-per-second. The FPS rate is used if
enableMaximumFpsLimit(boolean) is enabled.
IMPORTANT: Setting this property less than 5 fps is not recommended, as the map view's usability suffers
dramatically. For example, the position indicator may not function correctly. Tilting and zooming may also
become overly slow.
Parameters:
fps
Frames-per-second (must be greater then zero)
public void setMaximumTiltFunction (ZoomLevelToTiltFunction function)
The functional relationship between zoom and maximum tilt. Using the setMaximumTiltFunction, an
application may control the maximum tilt of a map at different zoom levels. The maximum applies to all
sources of map tilt, including gestures and animations.
Parameters:
function
- function that provides a tilt value output for a zoom level input.
public Map setOrientation (float angle)
Sets an absolute orientation for this Map to the specified angle, in degrees, where true-north is 0 degrees. No
animation will be used to illustrate the transformation.
Parameters:
angle
Desired orientation angle
Returns:
The updated Map.
See also:
setOrientation(float, Animation)
public void setOrientation (float angle, Animation animation)
Sets an absolute orientation for this Map to the specified angle, in degrees, where true-north is 0 degrees.
Note: animation is only visible for BOW. No animation is performed for LINEAR and NONE.
HERE Android SDK Developer's Guide
API Reference
887
Parameters:
angle
Desired orientation angle
animation
An Animation to illustrate the transformation
See also:
setOrientation(float)
public Map setPedestrianFeaturesVisible (java.util.EnumSet <PedestrianFeature>
features)
Set a set of pedestrian features to be visible. Features not in the set will be set invisible. An empty set means
no features are visible
Parameters:
features
A set of visible pedestrian features
Returns:
The updated Map itself.
public Map setProjectionMode (Projection projection)
Change the projection mode used to render the map.
Parameters:
projection
The new projection mode.
Returns:
Map builder pattern
Throws:
IllegalArgumentException
if deprecated Map.Projection modes are used.
public void setSafetySpotsVisible (boolean visible)
Sets safety spots visible.
Parameters:
visible
true for visible, false to hide.
HERE Android SDK Developer's Guide
API Reference
888
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public Map setStreetLevelCoverageVisible (boolean visible)
Sets street level coverage to be either visible or invisible for the Map .
Parameters:
visible
A boolean specifying whether street level coverage should be visible
Returns:
The updated Map.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public Map setTilt (float angle)
Sets a tilt angle for this Map , in degrees.
Parameters:
angle
Desired tilt angle. Acceptable values are the range between getMinTilt() and getMaxTilt() inclusive.
Returns:
The updated Map.
See also:
setTilt(float, Animation)
getMinTilt()
getMaxTilt()
public void setTilt (float angle, Animation animation)
Sets a tilt angle for the Map , in degrees.
Note: The tilt animation is not cancelled when other map operations (for example, setCenter(GeoCoordinate,
Animation)) are performed. Therefore, the tilt animation can occur concurrently with other animations.
Parameters:
angle
Desired tilt angle. Acceptable values are the range between getMinTilt() and getMaxTilt() inclusive.
HERE Android SDK Developer's Guide
API Reference
889
animation
An Animation to illustrate the transformation
See also:
setTilt(float)
getMinTilt()
getMaxTilt()
public Map setTrafficInfoVisible (boolean visible)
Sets traffic information to be either visible or invisible for this Map .
Traffic can only be displayed on one Map at a time. It is recommended that you turn off traffic display on
other Maps before enabling traffic display on a new Map otherwise the results may be unpredictable. If
multiple Maps are shown at the same time with setTrafficInfoVisible true, only one will display traffic.
Parameters:
visible
A boolean specifying whether traffic information should be visible.
Returns:
The modified Map itself.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public Map setTransformCenter (PointF center)
Sets a center coordinate for Map transformations such as zooming and rotation. Transformations performed
after calling this method will be based on this new center coordinate. The transform center may be different
than the Map center.
Parameters:
center
A PointF representing the center used for transformations
Returns:
The updated Map
public boolean setUseSystemLanguage ()
Set the map display language using the system default locale. Causes a map redraw when language is set.
Returns:
HERE Android SDK Developer's Guide
API Reference
890
true if the language update is accepted by the Map, false otherwise.
public Map setVisibleLayers (java.util.EnumSet <LayerCategory> layers,
boolean enable)
Toggles the visibility of the map layer categories to be rendered.
By default, all layer categories are enabled.
Parameters:
layers
EnumSet of layers to change visibility.
enable
true to render, false to not render
Returns:
The updated Map itself.
public Map setZoomLevel (double level)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom levels.
No animation will be used to illustrate the transformation.
Legal values are the range between getMinZoomLevel() and getMaxZoomLevel(), inclusive.
If this method is called before map animation has finished (for example, if you had called
setCenter(GeoCoordinate, Animation)), the existing animation may be stopped and the map will proceed
directly to change the zoom level. Consider using other methods that combine multiple actions to avoid
unintentionally canceling map animations. For example, use setCenter(GeoCoordinate, Animation, double,
float, float).
Note: The zoom level is only precise to three decimal places due to numerical operations performed
internally when rendering the map.
Parameters:
level
Desired fractional zoom level
Returns:
The updated Map.
See also:
setZoomLevel(double, Animation)
setZoomLevel(double, PointF, Animation)
getMinZoomLevel()
getMaxZoomLevel()
HERE Android SDK Developer's Guide
API Reference
891
public void setZoomLevel (double level, Animation animation)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom levels.
Legal values are the range between getMinZoomLevel() and getMaxZoomLevel() inclusive.
If this method is called before map animation is finished (for example, if you had called
setCenter(GeoCoordinate, Animation)), the existing animation may be stopped and the map will proceed
directly to change the zoom level. Consider using other methods that combine multiple actions to avoid
unintentionally canceling map animations. For example, use setCenter(GeoCoordinate, Animation, double,
float, float).
Note: The zoom level is only precise to three decimal places due to numerical operations performed
internally when rendering the map.
Parameters:
level
Desired fractional zoom level
animation
An Animation to illustrate the transformation
See also:
setZoomLevel(double)
setZoomLevel(double, PointF, Animation)
getMinZoomLevel()
getMaxZoomLevel()
public void setZoomLevel (double level, PointF focus, Animation animation)
Sets a zoom level for the Map to a fraction that is within the range of minimum and maximum zoom
levels while keeping the specified screen coordinate at the same Geographical Location. Concretely, the
GeoCoordinate of the specified PointF is the same before and after the transformation.
Legal values are the range between getMinZoomLevel() and getMaxZoomLevel() inclusive.
For the purposes of calculating the focus GeoCoordinate , the tilt of the map is considered to be 0. The
actual map tilt will not change.
Note: do not call this method before setting the map is initialized. If you call this method while either
getWidth() or getHeight() returns 0 it will throw a RuntimeException .
Note: The zoom level is only precise to three decimal places due to numerical operations performed
internally when rendering the map.
Parameters:
level
Desired fractional zoom level
focus
HERE Android SDK Developer's Guide
API Reference
892
A PointF to keep fixed, in pixel coordinates.
animation
An Animation to illustrate the transformation
See also:
setZoomLevel(double)
setZoomLevel(double, Animation)
getMinZoomLevel()
getMaxZoomLevel()
public void zoomTo (GeoBoundingBox geoRect, Animation animation, float
orientation)
Moves this Map instance's map center and changes the zoom level to show the specified GeoBoundingBox at
the given orientation.
Do not call this method before this map instance is initialized. If you call this method while this map is
uninitialized (either getWidth() or getHeight() returns 0), it will throw a RuntimeException . Please note the
effects of this method will apply on Map slightly after the method invocation.
Parameters:
geoRect
A GeoBoundingBox to show after the transformation
animation
An Animation to illustrate the transformation
orientation
Desired orientation of the Map (Use MOVE_PRESERVE_ORIENTATION to keep the current orientation)
See also:
zoomTo(GeoBoundingBox, ViewRect, Animation, float)
zoomTo(GeoBoundingBox, int, int, Animation, float)
public void zoomTo (GeoBoundingBox geoRect, Animation animation, float
orientation, float perspective)
Moves this Map instance's map center and changes the zoom level to show the specified GeoBoundingBox at
the given orientation.
Do not call this method before this map instance is initialized. If you call this method while this map is
uninitialized (either getWidth() or getHeight() returns 0), it will throw a RuntimeException . Please note the
effects of this method will apply on Map slightly after the method invocation.
Parameters:
geoRect
HERE Android SDK Developer's Guide
API Reference
893
A GeoBoundingBox to show after the transformation
animation
An Animation to illustrate the transformation
orientation
Desired orientation of the Map (Use MOVE_PRESERVE_ORIENTATION to keep the current orientation)
perspective
Desired perspective of the Map (Use MOVE_PRESERVE_TILT to keep the current tilt)
See also:
zoomTo(GeoBoundingBox, ViewRect, Animation, float)
zoomTo(GeoBoundingBox, int, int, Animation, float)
public void zoomTo (GeoBoundingBox geoRect, ViewRect viewPort, Animation
animation, float orientation)
Moves this Map instance and changes its zoom level to show the specified GeoBoundingBox within the
provided ViewRect.
Do not call this method before this map instance is initialized. If you call this method while this map is
uninitialized (either getWidth() or getHeight() returns 0), it will throw a RuntimeException . Please note the
effects of this method will apply on Map slightly after the method invocation.
Parameters:
geoRect
A GeoBoundingBox to show after the transformation
viewPort
A ViewRect representing the view port into which the GeoBoundingBox fits. The ViewRect is
interpreted as being in the same MapFragment as this Map instance.
animation
An Animation to illustrate the transformation
orientation
Desired orientation of the Map (pass MOVE_PRESERVE_ORIENTATION to keep the current orientation)
See also:
zoomTo(GeoBoundingBox, Animation, float)
zoomTo(GeoBoundingBox, int, int, Animation, float)
public void zoomTo (GeoBoundingBox geoRect, int width, int height, Animation
animation, float orientation)
Moves this Map instance and changes its zoom level to show the specified GeoBoundingBox within the
specified pixel dimensions around the transform center.
HERE Android SDK Developer's Guide
API Reference
894
Do not call this method before this map instance is initialized. If you call this method while this map is
uninitialized (either getWidth() or getHeight() returns 0), it will throw a RuntimeException . Please note the
effects of this method will apply on Map slightly after the method invocation.
Parameters:
geoRect
A GeoBoundingBox to show after the transformation
width
The width, in number of pixels, of the bounding area around the transform center, which the geoRect
will fit into.
height
The height, in number of pixels, of the bounding area around the transform center, which the geoRect
will fit into.
animation
An Animation to illustrate the transformation
orientation
Desired orientation of the Map (pass MOVE_PRESERVE_ORIENTATION to keep the current orientation)
Throws:
IllegalArgumentException
if width or height is less than or equal to 0
See also:
setTransformCenter(PointF)
zoomTo(GeoBoundingBox, Animation, float)
zoomTo(GeoBoundingBox, ViewRect, Animation, float)
Animation
The enumeration Animation is a member of com.here.android.mpa.mapping.Map.
Enumeration Summary
public static final enumeration Map.Animation
extends java.lang.Enum, java.lang.Object
Represents values that describe animation types for on-screen map movements.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
895
Enum Constant Summary
Table 436: Enum Constants in Animation
Fields
public static final Animation BOW
Zooms out and then in again in a bow-like manner as the map resets to a new position.
public static final Animation LINEAR
Moves in a linear manner as the map resets to a new position.
public static final Animation NONE
No animation is performed as the map resets to a new position.
Method Summary
Table 437: Methods in Animation
Methods
public static Animation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.Animation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values that describe animation types for on-screen map movements.
If the map changes size or the app comes to the foreground while Animation.LINEAR or Animation.BOW
is being used in a Map attribute setter method, then the animation will abort, and the transition will appear
as failed. To avoid this behavior, use the Animation.NONE animation type or wait until the map is stable
before performing the transition operation.
Enum Constant Details
public static final Animation BOW
Zooms out and then in again in a bow-like manner as the map resets to a new position.
public static final Animation LINEAR
Moves in a linear manner as the map resets to a new position.
public static final Animation NONE
No animation is performed as the map resets to a new position.
HERE Android SDK Developer's Guide
API Reference
896
Method Details
public static Animation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.Animation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FleetFeature
The enumeration FleetFeature is a member of com.here.android.mpa.mapping.Map.
Enumeration Summary
public static final enumeration Map.FleetFeature
extends java.lang.Enum, java.lang.Object
Fleet features to be rendered on the map
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 438: Enum Constants in FleetFeature
Fields
public static final FleetFeature TRUCK_RESTRICTIONS
Truck restrictions
public static final FleetFeature ENVIRONMENTAL_ZONES
Environmental zones
public static final FleetFeature CONGESTION_ZONES
Congestion zones
HERE Android SDK Developer's Guide
API Reference
897
Method Summary
Table 439: Methods in FleetFeature
Methods
public static FleetFeature valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.FleetFeature[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Fleet features to be rendered on the map
Enum Constant Details
public static final FleetFeature TRUCK_RESTRICTIONS
Truck restrictions
public static final FleetFeature ENVIRONMENTAL_ZONES
Environmental zones
public static final FleetFeature CONGESTION_ZONES
Congestion zones
Method Details
public static FleetFeature valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.FleetFeature[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
898
LayerCategory
The enumeration LayerCategory is a member of com.here.android.mpa.mapping.Map.
Enumeration Summary
public static final enumeration Map.LayerCategory
extends java.lang.Enum, java.lang.Object
Definition for layer categories within a map.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 440: Enum Constants in LayerCategory
Fields
public static final LayerCategory LAND
Land
public static final LayerCategory WATER
Water
public static final LayerCategory LABEL_OCEAN
Labels for oceans
public static final LayerCategory LABEL_SEA
Labels for seas
public static final LayerCategory LABEL_WATER_OTHER
Labels for lakes, rivers, canals, etc.
public static final LayerCategory BEACH
Beach
public static final LayerCategory WOODLAND
Woodland
public static final LayerCategory DESERT
Desert
public static final LayerCategory GLACIER
Glacier
public static final LayerCategory LABEL_BEACH
Labels for beaches
public static final LayerCategory LABEL_WOODLAND
Labels for woodland
HERE Android SDK Developer's Guide
API Reference
899
Fields
public static final LayerCategory LABEL_DESERT
Labels for deserts
public static final LayerCategory LABEL_GLACIER
Labels for glaciers
public static final LayerCategory AIRPORT_AREA
Airport area
public static final LayerCategory AMUSEMENT_PARK
Amusement park
public static final LayerCategory ANIMAL_PARK
Animal park
public static final LayerCategory BUILTUP
Built-up area
public static final LayerCategory CEMETERY
Cemetery
public static final LayerCategory GOLF_COURSE
Golf course
public static final LayerCategory HARBOR_AREA
Harbor area
public static final LayerCategory HOSPITAL_CAMPUS
Hospital campus
public static final LayerCategory INDUSTRIAL_COMPLEX
Industrial complex
public static final LayerCategory MILITARY_BASE
Military base
public static final LayerCategory NATIONAL_PARK
National park
public static final LayerCategory NATIVE_RESERVATION
Native reserves
public static final LayerCategory OUTLINE_MILITARY_BASE
Military base outline
public static final LayerCategory OUTLINE_NATIONAL_PARK
National park outline
public static final LayerCategory OUTLINE_NATIVE_RESERVATION
Native reserves outline
HERE Android SDK Developer's Guide
API Reference
900
Fields
public static final LayerCategory CITY_PARK
City park
public static final LayerCategory PEDESTRIAN_AREA
Pedestrian area
public static final LayerCategory RAILYARD
Rail yard
public static final LayerCategory SHOPPING_COMPLEX
Shopping complex
public static final LayerCategory SPORTS_COMPLEX
Sports complex
public static final LayerCategory UNIVERSITY_CAMPUS
University campus
public static final LayerCategory LABEL_AIRPORT_AREA
Airport area labels
public static final LayerCategory LABEL_AMUSEMENT_PARK
Amusement park labels
public static final LayerCategory LABEL_ANIMAL_PARK
Animal park labels
public static final LayerCategory LABEL_CEMETERY
Cemetery labels
public static final LayerCategory LABEL_GOLF_COURSE
Golf course labels
public static final LayerCategory LABEL_HARBOR_AREA
Harbor area labels
public static final LayerCategory LABEL_HOSPITAL_CAMPUS
Hospital campus labels
public static final LayerCategory LABEL_INDUSTRIAL_COMPLEX
Industrial complex labels
public static final LayerCategory LABEL_MILITARY_BASE
Military base labels
public static final LayerCategory LABEL_NATIONAL_PARK
National park labels
public static final LayerCategory LABEL_NATIVE_RESERVATION
Native reserve labels
HERE Android SDK Developer's Guide
API Reference
901
Fields
public static final LayerCategory LABEL_CITY_PARK
City park labels
public static final LayerCategory LABEL_PEDESTRIAN_AREA
Pedestrian area labels
public static final LayerCategory LABEL_RAILYARD
Rail yard labels
public static final LayerCategory LABEL_SHOPPING_COMPLEX
Shopping complex labels
public static final LayerCategory LABEL_SPORTS_COMPLEX
Sports complex labels
public static final LayerCategory LABEL_UNIVERSITY_CAMPUS
University campus labels
public static final LayerCategory STREET_CATEGORY_0
Street of highest importance, for example, national highways
public static final LayerCategory STREET_CATEGORY_1
Street of 2nd highest importance
public static final LayerCategory STREET_CATEGORY_2
Street of medium importance
public static final LayerCategory STREET_CATEGORY_3
Street of 2nd lowest importance
public static final LayerCategory STREET_CATEGORY_4
Street of lowest importance, for example, small local roads.
public static final LayerCategory STREET_CATEGORY_PEDESTRIAN
Pedestrian-friendly streets
public static final LayerCategory STREET_CATEGORY_WALKWAY
Pedestrian-only streets
public static final LayerCategory LABEL_STREET_CATEGORY_0
Labels for streets included in STREET_CATEGORY_0.
public static final LayerCategory LABEL_STREET_CATEGORY_1
Labels for streets included in STREET_CATEGORY_1.
public static final LayerCategory LABEL_STREET_CATEGORY_2
Labels for streets included in STREET_CATEGORY_2.
public static final LayerCategory LABEL_STREET_CATEGORY_3
Labels for streets included in STREET_CATEGORY_3.
HERE Android SDK Developer's Guide
API Reference
902
Fields
public static final LayerCategory LABEL_STREET_CATEGORY_4
Labels for streets included in STREET_CATEGORY_4.
public static final LayerCategory LABEL_STREET_CATEGORY_PEDESTRIAN
Labels for Pedestrian-friendly streets
public static final LayerCategory LABEL_STREET_CATEGORY_WALKWAY
Labels for Pedestrian-only streets
public static final LayerCategory ROADSIGN_ICON
Roadside icon
public static final LayerCategory EXIT_SIGN
Exit sign
public static final LayerCategory BORDER_COUNTRY
Country border
public static final LayerCategory BORDER_STATE
State border
public static final LayerCategory BORDER_REGIONAL
Region border
public static final LayerCategory BORDER_BUILTUP
Builtup border
public static final LayerCategory BORDER_LINE_OF_CONTROL
Line of control border
public static final LayerCategory NEIGHBORHOOD_AREA
Neighborhood area
public static final LayerCategory LAND_PARCEL
Land parcel
public static final LayerCategory LABEL_CONTINENT
Continent label
public static final LayerCategory LABEL_MAJOR_COUNTRY
Major country label
public static final LayerCategory LABEL_MINOR_COUNTRY
Minor country label
public static final LayerCategory LABEL_STATE
State label
public static final LayerCategory LABEL_STATE_ABBREVIATION
State abbreviation label
HERE Android SDK Developer's Guide
API Reference
903
Fields
public static final LayerCategory LABEL_CITY_CAPITAL
National capital city label
public static final LayerCategory LABEL_CITY_STATE_CAPITAL
Provincial/State capital city label
public static final LayerCategory LABEL_CITY_OTHER
Other cities label
public static final LayerCategory LABEL_NEIGHBORHOOD_AREA
Neighborhood area label
public static final LayerCategory PUBLIC_TRANSIT_LINE
Public transit line
public static final LayerCategory LABEL_PUBLIC_TRANSIT_LINE
Public transit line label
public static final LayerCategory ICON_PUBLIC_TRANSIT_STATION
Public transit icon
public static final LayerCategory LABEL_PUBLIC_TRANSIT_STATION
Public transit label
public static final LayerCategory RELIEF
Relief
public static final LayerCategory BACKGROUND
Background
public static final LayerCategory LABEL_MOUNTAIN
Mountain label
public static final LayerCategory ICON_MOUNTAIN
Mountain icon
public static final LayerCategory LABEL_ISLAND
Island label
public static final LayerCategory BUILDING
Building
public static final LayerCategory LABEL_BUILDING
Building label
public static final LayerCategory POINT_ADDRESS
Point addresses, alphanumeric house-numbers which are assigned to a street segment.
public static final LayerCategory PEDESTRIAN_FEATURE
Pedestrian features that includes: crosswalk, stairs, escalator, elevator, tunnel, and bridge
HERE Android SDK Developer's Guide
API Reference
904
Fields
public static final LayerCategory RAILROAD
Railroad
public static final LayerCategory FERRY
Ferry
public static final LayerCategory LABEL_FERRY
Ferry label
public static final LayerCategory POI_ICON
POI icon
public static final LayerCategory POI_LABEL
POI label
public static final LayerCategory ABSTRACT_CITY_MODEL
Abstract city model
public static final LayerCategory LANDMARK_3D
3D Landmark
Method Summary
Table 441: Methods in LayerCategory
Methods
public static LayerCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.LayerCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Definition for layer categories within a map. These layer categories can be enabled or disabled dynamically
through setVisibleLayers(EnumSet, boolean).
Enum Constant Details
public static final LayerCategory LAND
Land
public static final LayerCategory WATER
Water
HERE Android SDK Developer's Guide
API Reference
905
public static final LayerCategory LABEL_OCEAN
Labels for oceans
public static final LayerCategory LABEL_SEA
Labels for seas
public static final LayerCategory LABEL_WATER_OTHER
Labels for lakes, rivers, canals, etc.
public static final LayerCategory BEACH
Beach
public static final LayerCategory WOODLAND
Woodland
public static final LayerCategory DESERT
Desert
public static final LayerCategory GLACIER
Glacier
public static final LayerCategory LABEL_BEACH
Labels for beaches
public static final LayerCategory LABEL_WOODLAND
Labels for woodland
public static final LayerCategory LABEL_DESERT
Labels for deserts
public static final LayerCategory LABEL_GLACIER
Labels for glaciers
HERE Android SDK Developer's Guide
API Reference
906
public static final LayerCategory AIRPORT_AREA
Airport area
public static final LayerCategory AMUSEMENT_PARK
Amusement park
public static final LayerCategory ANIMAL_PARK
Animal park
public static final LayerCategory BUILTUP
Built-up area
public static final LayerCategory CEMETERY
Cemetery
public static final LayerCategory GOLF_COURSE
Golf course
public static final LayerCategory HARBOR_AREA
Harbor area
public static final LayerCategory HOSPITAL_CAMPUS
Hospital campus
public static final LayerCategory INDUSTRIAL_COMPLEX
Industrial complex
public static final LayerCategory MILITARY_BASE
Military base
public static final LayerCategory NATIONAL_PARK
HERE Android SDK Developer's Guide
API Reference
907
National park
public static final LayerCategory NATIVE_RESERVATION
Native reserves
public static final LayerCategory OUTLINE_MILITARY_BASE
Military base outline
public static final LayerCategory OUTLINE_NATIONAL_PARK
National park outline
public static final LayerCategory OUTLINE_NATIVE_RESERVATION
Native reserves outline
public static final LayerCategory CITY_PARK
City park
public static final LayerCategory PEDESTRIAN_AREA
Pedestrian area
public static final LayerCategory RAILYARD
Rail yard
public static final LayerCategory SHOPPING_COMPLEX
Shopping complex
public static final LayerCategory SPORTS_COMPLEX
Sports complex
public static final LayerCategory UNIVERSITY_CAMPUS
University campus
HERE Android SDK Developer's Guide
API Reference
908
public static final LayerCategory LABEL_AIRPORT_AREA
Airport area labels
public static final LayerCategory LABEL_AMUSEMENT_PARK
Amusement park labels
public static final LayerCategory LABEL_ANIMAL_PARK
Animal park labels
public static final LayerCategory LABEL_CEMETERY
Cemetery labels
public static final LayerCategory LABEL_GOLF_COURSE
Golf course labels
public static final LayerCategory LABEL_HARBOR_AREA
Harbor area labels
public static final LayerCategory LABEL_HOSPITAL_CAMPUS
Hospital campus labels
public static final LayerCategory LABEL_INDUSTRIAL_COMPLEX
Industrial complex labels
public static final LayerCategory LABEL_MILITARY_BASE
Military base labels
public static final LayerCategory LABEL_NATIONAL_PARK
National park labels
public static final LayerCategory LABEL_NATIVE_RESERVATION
Native reserve labels
HERE Android SDK Developer's Guide
API Reference
909
public static final LayerCategory LABEL_CITY_PARK
City park labels
public static final LayerCategory LABEL_PEDESTRIAN_AREA
Pedestrian area labels
public static final LayerCategory LABEL_RAILYARD
Rail yard labels
public static final LayerCategory LABEL_SHOPPING_COMPLEX
Shopping complex labels
public static final LayerCategory LABEL_SPORTS_COMPLEX
Sports complex labels
public static final LayerCategory LABEL_UNIVERSITY_CAMPUS
University campus labels
public static final LayerCategory STREET_CATEGORY_0
Street of highest importance, for example, national highways
public static final LayerCategory STREET_CATEGORY_1
Street of 2nd highest importance
public static final LayerCategory STREET_CATEGORY_2
Street of medium importance
public static final LayerCategory STREET_CATEGORY_3
Street of 2nd lowest importance
public static final LayerCategory STREET_CATEGORY_4
HERE Android SDK Developer's Guide
API Reference
910
Street of lowest importance, for example, small local roads.
public static final LayerCategory STREET_CATEGORY_PEDESTRIAN
Pedestrian-friendly streets
public static final LayerCategory STREET_CATEGORY_WALKWAY
Pedestrian-only streets
public static final LayerCategory LABEL_STREET_CATEGORY_0
Labels for streets included in STREET_CATEGORY_0.
public static final LayerCategory LABEL_STREET_CATEGORY_1
Labels for streets included in STREET_CATEGORY_1.
public static final LayerCategory LABEL_STREET_CATEGORY_2
Labels for streets included in STREET_CATEGORY_2.
public static final LayerCategory LABEL_STREET_CATEGORY_3
Labels for streets included in STREET_CATEGORY_3.
public static final LayerCategory LABEL_STREET_CATEGORY_4
Labels for streets included in STREET_CATEGORY_4.
public static final LayerCategory LABEL_STREET_CATEGORY_PEDESTRIAN
Labels for Pedestrian-friendly streets
public static final LayerCategory LABEL_STREET_CATEGORY_WALKWAY
Labels for Pedestrian-only streets
public static final LayerCategory ROADSIGN_ICON
Roadside icon
HERE Android SDK Developer's Guide
API Reference
911
public static final LayerCategory EXIT_SIGN
Exit sign
public static final LayerCategory BORDER_COUNTRY
Country border
public static final LayerCategory BORDER_STATE
State border
public static final LayerCategory BORDER_REGIONAL
Region border
public static final LayerCategory BORDER_BUILTUP
Builtup border
public static final LayerCategory BORDER_LINE_OF_CONTROL
Line of control border
public static final LayerCategory NEIGHBORHOOD_AREA
Neighborhood area
public static final LayerCategory LAND_PARCEL
Land parcel
public static final LayerCategory LABEL_CONTINENT
Continent label
public static final LayerCategory LABEL_MAJOR_COUNTRY
Major country label
public static final LayerCategory LABEL_MINOR_COUNTRY
Minor country label
HERE Android SDK Developer's Guide
API Reference
912
public static final LayerCategory LABEL_STATE
State label
public static final LayerCategory LABEL_STATE_ABBREVIATION
State abbreviation label
public static final LayerCategory LABEL_CITY_CAPITAL
National capital city label
public static final LayerCategory LABEL_CITY_STATE_CAPITAL
Provincial/State capital city label
public static final LayerCategory LABEL_CITY_OTHER
Other cities label
public static final LayerCategory LABEL_NEIGHBORHOOD_AREA
Neighborhood area label
public static final LayerCategory PUBLIC_TRANSIT_LINE
Public transit line
public static final LayerCategory LABEL_PUBLIC_TRANSIT_LINE
Public transit line label
public static final LayerCategory ICON_PUBLIC_TRANSIT_STATION
Public transit icon
public static final LayerCategory LABEL_PUBLIC_TRANSIT_STATION
Public transit label
public static final LayerCategory RELIEF
HERE Android SDK Developer's Guide
API Reference
913
Relief
public static final LayerCategory BACKGROUND
Background
public static final LayerCategory LABEL_MOUNTAIN
Mountain label
public static final LayerCategory ICON_MOUNTAIN
Mountain icon
public static final LayerCategory LABEL_ISLAND
Island label
public static final LayerCategory BUILDING
Building
public static final LayerCategory LABEL_BUILDING
Building label
public static final LayerCategory POINT_ADDRESS
Point addresses, alphanumeric house-numbers which are assigned to a street segment.
public static final LayerCategory PEDESTRIAN_FEATURE
Pedestrian features that includes: crosswalk, stairs, escalator, elevator, tunnel, and bridge
public static final LayerCategory RAILROAD
Railroad
public static final LayerCategory FERRY
Ferry
HERE Android SDK Developer's Guide
API Reference
914
public static final LayerCategory LABEL_FERRY
Ferry label
public static final LayerCategory POI_ICON
POI icon
public static final LayerCategory POI_LABEL
POI label
public static final LayerCategory ABSTRACT_CITY_MODEL
Abstract city model
public static final LayerCategory LANDMARK_3D
3D Landmark
Method Details
public static LayerCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.LayerCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnSchemeChangedListener
The interface OnSchemeChangedListener is a member of com.here.android.mpa.mapping.Map.
Interface Summary
public static abstract interface Map.OnSchemeChangedListener
Listener for Map scheme changed events.
HERE Android SDK Developer's Guide
API Reference
915
[For complete information, see the section Interface Details]
Method Summary
Table 442: Methods in OnSchemeChangedListener
Methods
public abstract void onMapSchemeChanged (String schemeName)
A callback indicating that the map scheme has changed.
Interface Details
Listener for Map scheme changed events.
Method Details
public abstract void onMapSchemeChanged (String schemeName)
A callback indicating that the map scheme has changed.
Parameters:
schemeName
Updated scheme name.
See also:
setMapScheme(String)
OnTransformListener
The interface OnTransformListener is a member of com.here.android.mpa.mapping.Map.
Interface Summary
public static abstract interface Map.OnTransformListener
Listener for Map transform events.
[For complete information, see the section Interface Details]
Method Summary
Table 443: Methods in OnTransformListener
Methods
public abstract void onMapTransformEnd (MapState mapState)
Called after onMapTransformStart() once the MapState returns to a steady value (such as when it has stopped moving).
HERE Android SDK Developer's Guide
API Reference
916
Methods
public abstract void onMapTransformStart ()
Called just before the MapState begins to change.
Interface Details
Listener for Map transform events. Map transform events are triggered by any operation which causes the
MapState to change. This includes user interaction (such as map gestures) as well as programmatic calls to
the map.
onMapTransformStart() is called just before the map state begins to change, while
onMapTransformEnd(MapState) is called after the map state returns to a steady value. Therefore, there can
be a significant amount of time between when the two callbacks are made in cases such as animated map
movement events and continuous user interaction.
If you need to update UI widgets as the map state changes, the recommended approach is to trigger a
Runnable object when onMapTransformStart() is called. This method periodically checks the current map
state (at no more than 30fps) and updates the UI widgets. The Runnable object can then be cancelled upon
a call to onMapTransformEnd(MapState). An android.os.Handler object can be used to implement this
elegantly.
Do not update UI widgets in onPostDraw(boolean, long) as this method is too frequently called.
Method Details
public abstract void onMapTransformEnd (MapState mapState)
Called after onMapTransformStart() once the MapState returns to a steady value (such as when it has
stopped moving).
Parameters:
mapState
The current state of the map at the time of this callback
public abstract void onMapTransformStart ()
Called just before the MapState begins to change. This can be triggered by user interaction (such as
map gestures) as well as programmatic calls to the map. This method will not be called again until an
onMapTransformEnd(MapState) call has been made.
PedestrianFeature
The enumeration PedestrianFeature is a member of com.here.android.mpa.mapping.Map.
HERE Android SDK Developer's Guide
API Reference
917
Enumeration Summary
public static final enumeration Map.PedestrianFeature
extends java.lang.Enum, java.lang.Object
Pedestrian features to be rendered on the map
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 444: Enum Constants in PedestrianFeature
Fields
public static final PedestrianFeature CROSSWALK
Crosswalk
public static final PedestrianFeature STAIRS
Stairs
public static final PedestrianFeature ESCALATOR
Escalator
public static final PedestrianFeature ELEVATOR
Elevator
public static final PedestrianFeature TUNNEL
Tunnel
public static final PedestrianFeature BRIDGE
Bridge
Method Summary
Table 445: Methods in PedestrianFeature
Methods
public static PedestrianFeature valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.PedestrianFeature[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Pedestrian features to be rendered on the map
Enum Constant Details
public static final PedestrianFeature CROSSWALK
HERE Android SDK Developer's Guide
API Reference
918
Crosswalk
public static final PedestrianFeature STAIRS
Stairs
public static final PedestrianFeature ESCALATOR
Escalator
public static final PedestrianFeature ELEVATOR
Elevator
public static final PedestrianFeature TUNNEL
Tunnel
public static final PedestrianFeature BRIDGE
Bridge
Method Details
public static PedestrianFeature valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.PedestrianFeature[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
PixelResult
The class PixelResult is a member of com.here.android.mpa.mapping.Map.
HERE Android SDK Developer's Guide
API Reference
919
Class Summary
public static class Map.PixelResult
extends java.lang.Object
Result class for conversion of a GeoCoordinate to screen pixel coordinates.
[For complete information, see the section Class Details]
See also:
projectToPixel(GeoCoordinate)
Nested Class Summary
Table 446: Nested Classes in PixelResult
Nested Classes
public static final enumeration Map.PixelResult.Error
Error code for the computation of GeoCoordinate to screen pixel coordinate projection
Method Summary
Table 447: Methods in PixelResult
Methods
public Error getError ()
Get the Map.PixelResult.Error of the GeoCoordinate to screen Pixel conversion.
public PointF getResult ()
Get the result of the GeoCoordinate to screen Pixel conversion.
Class Details
Result class for conversion of a GeoCoordinate to screen pixel coordinates.
See also:
projectToPixel(GeoCoordinate)
Method Details
public Error getError ()
Get the Map.PixelResult.Error of the GeoCoordinate to screen Pixel conversion.
Returns:
Error screen space in pixels.
public PointF getResult ()
HERE Android SDK Developer's Guide
API Reference
920
Get the result of the GeoCoordinate to screen Pixel conversion.
Returns:
PointF screen space in pixels.
Error
The enumeration Error is a member of com.here.android.mpa.mapping.Map.PixelResult.
Enumeration Summary
public static final enumeration Map.PixelResult.Error
extends java.lang.Enum, java.lang.Object
Error code for the computation of GeoCoordinate to screen pixel coordinate projection
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 448: Enum Constants in Error
Fields
public static final Error NONE
public static final Error NOT_IN_VIEW
public static final Error OVERFLOW
public static final Error UNKNOWN
Method Summary
Table 449: Methods in Error
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.PixelResult.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Error code for the computation of GeoCoordinate to screen pixel coordinate projection
Enum Constant Details
public static final Error NONE
HERE Android SDK Developer's Guide
API Reference
921
public static final Error NOT_IN_VIEW
public static final Error OVERFLOW
public static final Error UNKNOWN
Method Details
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.PixelResult.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Projection
The enumeration Projection is a member of com.here.android.mpa.mapping.Map.
Enumeration Summary
public static final enumeration Map.Projection
extends java.lang.Enum, java.lang.Object
The projection scheme used to render the map.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 450: Enum Constants in Projection
Fields
public static final Projection MERCATOR
A mercator projection.
HERE Android SDK Developer's Guide
API Reference
922
Fields
public static final Projection GLOBE
A globe.
Method Summary
Table 451: Methods in Projection
Methods
public static Projection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Map.Projection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The projection scheme used to render the map.
Enum Constant Details
public static final Projection MERCATOR
A mercator projection.
public static final Projection GLOBE
A globe.
Method Details
public static Projection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Map.Projection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
923
Scheme
The class Scheme is a member of com.here.android.mpa.mapping.Map.
Class Summary
public static final class Map.Scheme
extends java.lang.Object
Represents a collection of schemes that the Map class supports.
[For complete information, see the section Class Details]
Field Summary
Table 452: Fields in Scheme
Fields
public static final String CARNAV_DAY
Normal scheme presented in "day" colors that is suitable for car guidance.
public static final String CARNAV_DAY_GREY
Normal scheme presented in "day" colors that is suitable for car guidance use cases in which map still has a high relevance
but is used as background for overlays.
public static final String CARNAV_HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for car guidance.
public static final String CARNAV_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for car guidance.
public static final String CARNAV_NIGHT
Normal scheme presented in "night" colors that is suitable for car guidance.
public static final String CARNAV_NIGHT_GREY
Normal scheme presented in "night" colors that is suitable for car guidance use cases in which map still has a high
relevance but is used as background for overlays.
public static final String CARNAV_TRAFFIC_DAY
Normal scheme presented in "day" colors that is suitable for displaying traffic in car guidance.
public static final String CARNAV_TRAFFIC_HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for displaying traffic in car guidance.
public static final String CARNAV_TRAFFIC_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for displaying traffic in car guidance.
public static final String CARNAV_TRAFFIC_NIGHT
Normal scheme presented in "night" colors that is suitable for displaying traffic in car guidance.
HERE Android SDK Developer's Guide
API Reference
924
Fields
public static final String HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads.
public static final String HYBRID_DAY_TRANSIT
Satellite tile scheme presented in "night" colors, with visible roads and highlighted transit lines.
public static final String HYBRID_GREY_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for use cases in which map still has a high
relevance but is used as background for overlays (like venue maps).
public static final String HYBRID_GREY_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for use cases in which map still has a
high relevance but is used as background for overlays (like venue maps).
public static final String HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads.
public static final String HYBRID_NIGHT_TRANSIT
Satellite tile scheme presented in "night" colors, with visible roads and highlighted transit lines.In all hybrid night schemes
the only difference to the hybrid day schemes is the sky.
public static final String HYBRID_REDUCED_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for use cases in which map has a low
relevance and it is used as background for overlays.
public static final String HYBRID_REDUCED_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for use cases in which map has a low
relevance and it is used as used as background for overlays.
public static final String HYBRID_TRAFFIC_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for traffic.
public static final String HYBRID_TRAFFIC_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for traffic.
public static final String MANEUVER_DAY
Normal scheme suitable for single maneuver overview.
public static final String NORMAL_DAY
Normal scheme presented in "day" colors.
public static final String NORMAL_DAY_GREY
Normal scheme presented in "day" colors that is suitable for use cases in which map still has a high relevance but is used
as background for overlays (like venue maps).
public static final String NORMAL_DAY_TRANSIT
Normal scheme presented in "day" colors that is suitable for transit.
public static final String NORMAL_NIGHT
Normal scheme presented in "night" colors.
HERE Android SDK Developer's Guide
API Reference
925
Fields
public static final String NORMAL_NIGHT_GREY
Normal scheme presented in "night" colors that is suitable for use cases in which map still has a high relevance but is used
as background for overlays (like venue maps).
public static final String NORMAL_NIGHT_TRANSIT
Normal scheme presented in "night" colors that is suitable for transit.
public static final String NORMAL_TRAFFIC_DAY
Normal scheme presented in "day" colors that is suitable for traffic.
public static final String NORMAL_TRAFFIC_NIGHT
Normal scheme presented in "night" colors that is suitable for traffic.
public static final String PEDESTRIAN_DAY
Normal scheme presented in "day" colors that is suitable for pedestrian use cases.
public static final String PEDESTRIAN_DAY_HYBRID
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for pedestrian use cases.
public static final String PEDESTRIAN_NIGHT
Normal scheme presented in "night" colors that is suitable for pedestrian use cases.
public static final String PEDESTRIAN_NIGHT_HYBRID
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for pedestrian use cases.To show/hide
pedestrian features see setPedestrianFeaturesVisible(EnumSet)
public static final String REDUCED_DAY
Normal scheme presented in "day" colors that is suitable for use cases in which map has a low relevance and it is used as
background for overlays.
public static final String REDUCED_NIGHT
Normal scheme presented in "night" colors that is suitable for use cases in which map has a low relevance and it is used as
background for overlays.
public static final String SATELLITE_DAY
Satellite tile scheme presented in "day" colors.
public static final String SATELLITE_NIGHT
Satellite tile scheme presented in "night" colors.
public static final String TERRAIN_DAY
Terrain bitmap scheme presented in "day" colors.
public static final String TRUCKNAV_DAY
Normal scheme presented in "day" colors that is suitable for truck guidance.
public static final String TRUCKNAV_HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for truck guidance.
public static final String TRUCKNAV_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for truck guidance.
HERE Android SDK Developer's Guide
API Reference
926
Fields
public static final String TRUCKNAV_NIGHT
Normal scheme presented in "night" colors that is suitable for truck guidance.
public static final String TRUCK_DAY
Truck scheme presented in "day" colors.
public static final String TRUCK_HYBRID_DAY
Satellite tile scheme presented in "day" colors with truck related attributes.
public static final String TRUCK_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors with truck related attributes.
public static final String TRUCK_NIGHT
Truck scheme presented in "night" colors.
Class Details
Represents a collection of schemes that the Map class supports. Each of the schemes in this class can be set
by way of the setMapScheme(String) method.
Field Details
public static final String CARNAV_DAY
Normal scheme presented in "day" colors that is suitable for car guidance.
public static final String CARNAV_DAY_GREY
Normal scheme presented in "day" colors that is suitable for car guidance use cases in which map still has a
high relevance but is used as background for overlays.
public static final String CARNAV_HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for car guidance.
public static final String CARNAV_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for car guidance. In all
hybrid night schemes the only difference to the hybrid day schemes is the sky. A night sky is being used
instead of a day sky. This is only visible in 3D.
public static final String CARNAV_NIGHT
Normal scheme presented in "night" colors that is suitable for car guidance.
HERE Android SDK Developer's Guide
API Reference
927
public static final String CARNAV_NIGHT_GREY
Normal scheme presented in "night" colors that is suitable for car guidance use cases in which map still has
a high relevance but is used as background for overlays.
public static final String CARNAV_TRAFFIC_DAY
Normal scheme presented in "day" colors that is suitable for displaying traffic in car guidance. To show/hide
traffic see setTrafficInfoVisible(boolean).
public static final String CARNAV_TRAFFIC_HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for displaying traffic in
car guidance.
public static final String CARNAV_TRAFFIC_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for displaying traffic in
car guidance. In all hybrid night schemes the only difference to the hybrid day schemes is the sky. A night sky
is being used instead of a day sky. This is only visible in 3D.
public static final String CARNAV_TRAFFIC_NIGHT
Normal scheme presented in "night" colors that is suitable for displaying traffic in car guidance. To show/
hide traffic see setTrafficInfoVisible(boolean).
public static final String HYBRID_DAY
Satellite tile scheme presented in "day" colors, with visible roads.
public static final String HYBRID_DAY_TRANSIT
Satellite tile scheme presented in "night" colors, with visible roads and highlighted transit lines. To show/
hide transit lines see MapTransitLayer.setMode(Mode).
public static final String HYBRID_GREY_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for use cases in which map
still has a high relevance but is used as background for overlays (like venue maps).
public static final String HYBRID_GREY_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for use cases in which
map still has a high relevance but is used as background for overlays (like venue maps). In all hybrid night
HERE Android SDK Developer's Guide
API Reference
928
schemes the only difference to the hybrid day schemes is the sky. A night sky is being used instead of a day
sky. This is only visible in 3D.
public static final String HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads. In all hybrid night schemes the only
difference to the hybrid day schemes is the sky. A night sky is being used instead of a day sky. This is only
visible in 3D.
public static final String HYBRID_NIGHT_TRANSIT
Satellite tile scheme presented in "night" colors, with visible roads and highlighted transit lines.In all hybrid
night schemes the only difference to the hybrid day schemes is the sky. A night sky is being used instead of a
day sky. This is only visible in 3D. To show/hide transit lines see MapTransitLayer.setMode(Mode).
public static final String HYBRID_REDUCED_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for use cases in which map
has a low relevance and it is used as background for overlays.
public static final String HYBRID_REDUCED_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for use cases in which
map has a low relevance and it is used as used as background for overlays. In all hybrid night schemes the
only difference to the hybrid day schemes is the sky. A night sky is being used instead of a day sky. This is
only visible in 3D.
public static final String HYBRID_TRAFFIC_DAY
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for traffic. To show/hide
traffic see setTrafficInfoVisible(boolean).
public static final String HYBRID_TRAFFIC_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for traffic. In all hybrid
night schemes the only difference to the hybrid day schemes is the sky. A night sky is being used instead of a
day sky. To show/hide traffic see setTrafficInfoVisible(boolean).
public static final String MANEUVER_DAY
Normal scheme suitable for single maneuver overview. This scheme is useful for guidance and routing use
cases. This scheme can be used for day and night since it has a strong contrast.
HERE Android SDK Developer's Guide
API Reference
929
public static final String NORMAL_DAY
Normal scheme presented in "day" colors.
public static final String NORMAL_DAY_GREY
Normal scheme presented in "day" colors that is suitable for use cases in which map still has a high
relevance but is used as background for overlays (like venue maps).
public static final String NORMAL_DAY_TRANSIT
Normal scheme presented in "day" colors that is suitable for transit. To show/hide transit lines see
MapTransitLayer.setMode(Mode).
public static final String NORMAL_NIGHT
Normal scheme presented in "night" colors.
public static final String NORMAL_NIGHT_GREY
Normal scheme presented in "night" colors that is suitable for use cases in which map still has a high
relevance but is used as background for overlays (like venue maps).
public static final String NORMAL_NIGHT_TRANSIT
Normal scheme presented in "night" colors that is suitable for transit. To show/hide transit lines see
MapTransitLayer.setMode(Mode).
public static final String NORMAL_TRAFFIC_DAY
Normal scheme presented in "day" colors that is suitable for traffic. To show/hide traffic see
setTrafficInfoVisible(boolean).
public static final String NORMAL_TRAFFIC_NIGHT
Normal scheme presented in "night" colors that is suitable for traffic. To show/hide traffic see
setTrafficInfoVisible(boolean).
public static final String PEDESTRIAN_DAY
Normal scheme presented in "day" colors that is suitable for pedestrian use cases. To show/hide pedestrian
features see setPedestrianFeaturesVisible(EnumSet)
HERE Android SDK Developer's Guide
API Reference
930
public static final String PEDESTRIAN_DAY_HYBRID
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for pedestrian use cases.
To show/hide pedestrian features see setPedestrianFeaturesVisible(EnumSet)
public static final String PEDESTRIAN_NIGHT
Normal scheme presented in "night" colors that is suitable for pedestrian use cases. To show/hide
pedestrian features see setPedestrianFeaturesVisible(EnumSet)
public static final String PEDESTRIAN_NIGHT_HYBRID
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for pedestrian use
cases.To show/hide pedestrian features see setPedestrianFeaturesVisible(EnumSet)
public static final String REDUCED_DAY
Normal scheme presented in "day" colors that is suitable for use cases in which map has a low relevance and
it is used as background for overlays.
public static final String REDUCED_NIGHT
Normal scheme presented in "night" colors that is suitable for use cases in which map has a low relevance
and it is used as background for overlays.
public static final String SATELLITE_DAY
Satellite tile scheme presented in "day" colors. No roads are shown in this scheme.
public static final String SATELLITE_NIGHT
Satellite tile scheme presented in "night" colors. No roads are shown in this scheme.
public static final String TERRAIN_DAY
Terrain bitmap scheme presented in "day" colors.
public static final String TRUCKNAV_DAY
Normal scheme presented in "day" colors that is suitable for truck guidance.
public static final String TRUCKNAV_HYBRID_DAY
HERE Android SDK Developer's Guide
API Reference
931
Satellite tile scheme presented in "day" colors, with visible roads, that is suitable for for truck guidance.
public static final String TRUCKNAV_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors, with visible roads, that is suitable for truck guidance. In
all hybrid night schemes the only difference to the hybrid day schemes is the sky. A night sky is being used
instead of a day sky. This is only visible in 3D.
public static final String TRUCKNAV_NIGHT
Normal scheme presented in "night" colors that is suitable for truck guidance.
public static final String TRUCK_DAY
Truck scheme presented in "day" colors. To show/hide fleet features see setFleetFeaturesVisible(EnumSet)
public static final String TRUCK_HYBRID_DAY
Satellite tile scheme presented in "day" colors with truck related attributes. To show/hide fleet features see
setFleetFeaturesVisible(EnumSet)
public static final String TRUCK_HYBRID_NIGHT
Satellite tile scheme presented in "night" colors with truck related attributes. To show/hide fleet features see
setFleetFeaturesVisible(EnumSet)
public static final String TRUCK_NIGHT
Truck scheme presented in "night" colors. To show/hide fleet features see setFleetFeaturesVisible(EnumSet)
MapBuildingGroup
The class MapBuildingGroup is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapBuildingGroup
extends java.lang.Object
Represents a group of extruded buildings.
[For complete information, see the section Class Details]
See also:
HERE Android SDK Developer's Guide
API Reference
932
MapBuildingLayer
MapBuildingObject
Nested Class Summary
Table 453: Nested Classes in MapBuildingGroup
Nested Classes
public static final enumeration MapBuildingGroup.BuildingFace
Addressable building faces for the MapBuildingObject instances in this building group.
Method Summary
Table 454: Methods in MapBuildingGroup
Methods
public boolean addBuilding (Identifier identifier)
Adds a building to this MapBuildingGroup.
public boolean addBuildings (java.util.List <Identifier> identifiers)
Adds a List of buildings to this MapBuildingGroup
public Identifier convertStringToIdentifier (String id)
Convert a String building identifier to a concrete building Identifier.
public int getBuildingCount ()
Gets the number of buildings in this MapBuildingGroup
public int getColor (BuildingFace face)
Gets the color for this MapBuildingGroup's specified building face.
public float getVerticalScale ()
Gets the MapBuildingGroup's height scaling factor.
public boolean removeAllBuildings ()
Removes all MapBuildingObject from this MapBuildingGroup
public boolean removeBuilding (Identifier identifier)
Removes a building from this MapBuildingGroup
public boolean removeBuildings (java.util.List <Identifier> identifiers)
Removes a List of buildings from this MapBuildingGroup
public void setColor (int color, java.util.EnumSet <BuildingFace> faces)
Sets the color for the specified building faces.
public void setVerticalScale (float scale)
Sets the MapBuildingGroup's height scaling factor.
HERE Android SDK Developer's Guide
API Reference
933
Class Details
Represents a group of extruded buildings.
See also:
MapBuildingLayer
MapBuildingObject
Method Details
public boolean addBuilding (Identifier identifier)
Adds a building to this MapBuildingGroup.
Parameters:
identifier
Identifier of the building to be added. The Identifier can be retrieved from PlaceLink.
Returns:
true if added, false otherwise.
public boolean addBuildings (java.util.List <Identifier> identifiers)
Adds a List of buildings to this MapBuildingGroup
Parameters:
identifiers
List of building Identifiers of buildings to be added.
Returns:
true if added, false otherwise.
public Identifier convertStringToIdentifier (String id)
Convert a String building identifier to a concrete building Identifier.
Parameters:
id
String building id retrieved from BUILDING_ID_REFERENCE_NAME
Returns:
An Identifier that can be used to highlight or query buildings.
public int getBuildingCount ()
Gets the number of buildings in this MapBuildingGroup
HERE Android SDK Developer's Guide
API Reference
934
Returns:
number of buildings in the MapBuildingGroup
public int getColor (BuildingFace face)
Gets the color for this MapBuildingGroup's specified building face.
Parameters:
face
MapBuildingGroup.BuildingFace
Returns:
An integer representing android.graphics.Color
public float getVerticalScale ()
Gets the MapBuildingGroup's height scaling factor.
Returns:
float scaling factor [0,1]
public boolean removeAllBuildings ()
Removes all MapBuildingObject from this MapBuildingGroup
Returns:
true if removed, false otherwise
public boolean removeBuilding (Identifier identifier)
Removes a building from this MapBuildingGroup
Parameters:
identifier
Building Identifier
Returns:
true if removed, false otherwise.
public boolean removeBuildings (java.util.List <Identifier> identifiers)
Removes a List of buildings from this MapBuildingGroup
Parameters:
identifiers
HERE Android SDK Developer's Guide
API Reference
935
List of building Identifiers
Returns:
true if removed, false otherwise.
public void setColor (int color, java.util.EnumSet <BuildingFace> faces)
Sets the color for the specified building faces. All MapBuildingObject in this building group will be affected.
Parameters:
color
An integer representing android.graphics.Color. The format is #AARRGGBB.
faces
EnumSet of MapBuildingGroup.BuildingFaces.
public void setVerticalScale (float scale)
Sets the MapBuildingGroup's height scaling factor. All MapBuildingObject in this building group will be
affected.
Parameters:
scale
Scale factor
BuildingFace
The enumeration BuildingFace is a member of com.here.android.mpa.mapping.MapBuildingGroup.
Enumeration Summary
public static final enumeration MapBuildingGroup.BuildingFace
extends java.lang.Enum, java.lang.Object
Addressable building faces for the MapBuildingObject instances in this building group.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 455: Enum Constants in BuildingFace
Fields
public static final BuildingFace ROOF
The top of a building
HERE Android SDK Developer's Guide
API Reference
936
Fields
public static final BuildingFace WALLTOP
The upper portion of a building's side walls
public static final BuildingFace WALLBOTTOM
The bottom portion of a building's side walls
public static final BuildingFace OUTLINE
The seams between each face of the building
public static final BuildingFace LANDMARKS
Only applicable for landmarks.
Method Summary
Table 456: Methods in BuildingFace
Methods
public int mask ()
Retrieve the declared enumeration value
public static BuildingFace valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapBuildingGroup.BuildingFace[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Addressable building faces for the MapBuildingObject instances in this building group.
Enum Constant Details
public static final BuildingFace ROOF
The top of a building
public static final BuildingFace WALLTOP
The upper portion of a building's side walls
public static final BuildingFace WALLBOTTOM
The bottom portion of a building's side walls
public static final BuildingFace OUTLINE
HERE Android SDK Developer's Guide
API Reference
937
The seams between each face of the building
public static final BuildingFace LANDMARKS
Only applicable for landmarks. When this value is used, the entire landmark is shaded.
Method Details
public int mask ()
Retrieve the declared enumeration value
Returns:
the declared enumeration value
public static BuildingFace valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapBuildingGroup.BuildingFace[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapBuildingLayer
The class MapBuildingLayer is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapBuildingLayer
extends java.lang.Object
Represents a map layer that enables interactions with extruded buildings.
[For complete information, see the section Class Details]
See also:
getMapBuildingLayer()
HERE Android SDK Developer's Guide
API Reference
938
Nested Class Summary
Table 457: Nested Classes in MapBuildingLayer
Nested Classes
public static final class MapBuildingLayer.BuildingSearchResult
Represents search results information for a building search
public static final enumeration MapBuildingLayer.DefaultBuildingColor
A set of pre-defined colors to change a MapBuildingGroup's color property
public static final enumeration MapBuildingLayer.DefaultBuildingGroups
Default groups of buildings on the Map.
Method Summary
Table 458: Methods in MapBuildingLayer
Methods
public MapBuildingGroup createNewBuildingGroup ()
Create a new MapBuildingGroup for custom building selection.
public MapBuildingGroup createNewBuildingGroup (DefaultBuildingColor color)
Create a new MapBuildingGroup with the given color for custom building selection.
public MapBuildingObject getBuilding (Identifier buildingId, GeoCoordinate positionHint)
Find a particular building on the Map around the given position.
public MapBuildingObject getBuilding (Identifier buildingId)
Find a particular building on the Map
public BuildingSearchResult getBuildingsInside (GeoBoundingBox boundingBox)
Find all buildings located inside a GeoBoundingBox.
public MapBuildingGroup getDefaultBuildingGroup (DefaultBuildingGroups group)
Get a building group of a MapBuildingLayer.DefaultBuildingGroups type.
public java.util.HashMap <Identifier, java.lang.Float> getTransparency (java.util.List <Identifier>
buildingIds)
Retrieve the transparency (alpha) [0,1] factor of a list of buildings.
public java.util.HashMap <Identifier, java.lang.Float> getVerticalScale (java.util.List <Identifier>
buildingIds)
Retrieve the vertical scale [0,1] factor of a list of buildings.
public void releaseBuildingGroup (MapBuildingGroup group)
Release the MapBuildingGroup created for custom building selection.
Class Details
Represents a map layer that enables interactions with extruded buildings.
HERE Android SDK Developer's Guide
API Reference
939
This class can be used to find MapBuildingObject and create MapBuildingGroup instances.
See also:
getMapBuildingLayer()
Method Details
public MapBuildingGroup createNewBuildingGroup ()
Create a new MapBuildingGroup for custom building selection.
At run time, there can only be a maximum number of MapBuildingGroup s, when the limit is
reached, no new MapBuildingGroup can be created unless some are being freed up by calling
releaseBuildingGroup(MapBuildingGroup).
Returns:
MapBuildingGroup. By default, a new MapBuildingGroup has the MapBuildingGroup with color
SELECTED.
See also:
releaseBuildingGroup(MapBuildingGroup)
public MapBuildingGroup createNewBuildingGroup (DefaultBuildingColor color)
Create a new MapBuildingGroup with the given color for custom building selection.
At run time, there can only be a maximum number of MapBuildingGroup s, when the limit is
reached, no new MapBuildingGroup can be created unless some are being freed up by calling
releaseBuildingGroup(MapBuildingGroup).
Parameters:
color
Color of buildings in the new MapBuildingGroup
Returns:
MapBuildingGroup. Returns null if no more new MapBuildingGroup can be created. At
run time, there is a maximum number of MapBuildingGroups created. When the limit is
reached, no new MapBuildingGroup can be created unless some are being freed up by calling
releaseBuildingGroup(MapBuildingGroup).
See also:
releaseBuildingGroup(MapBuildingGroup)
public MapBuildingObject getBuilding (Identifier buildingId, GeoCoordinate
positionHint)
Find a particular building on the Map around the given position.
Parameters:
HERE Android SDK Developer's Guide
API Reference
940
buildingId
Identifier of the building. Obtainable from PlaceLink. This parameter can be null, if it is null it will try
to find the building located at positionHint.
positionHint
A GeoCoordinate of the approximate location of the building.
Returns:
MapBuildingObject
public MapBuildingObject getBuilding (Identifier buildingId)
Find a particular building on the Map
Parameters:
buildingId
Identifier of the building. Obtainable from PlaceLink
Returns:
MapBuildingObject
public BuildingSearchResult getBuildingsInside (GeoBoundingBox boundingBox)
Find all buildings located inside a GeoBoundingBox. This API will return all buildings located inside a
bounding box area. Map data for this area must be downloaded. If the search result returns NEEDS_DATA,
retry the request after some delay. Map data download request will be triggered.
Parameters:
boundingBox
A GeoBoundingBox representing the bounding box area.
Returns:
MapBuildingLayer.BuildingSearchResult. Use the method getResultCode() to determine success of the
operation. Building results can be retrieved via getResults()
public MapBuildingGroup getDefaultBuildingGroup (DefaultBuildingGroups group)
Get a building group of a MapBuildingLayer.DefaultBuildingGroups type. The default building group is a
generic group that represents all possible buildings of that type in the entire world.
Parameters:
group
One of the values in the enum DefaultBuildingGroups
Returns:
MapBuildingGroup
HERE Android SDK Developer's Guide
API Reference
941
public java.util.HashMap <Identifier, java.lang.Float> getTransparency
(java.util.List <Identifier> buildingIds)
Retrieve the transparency (alpha) [0,1] factor of a list of buildings. This is useful to animate any markers that
are anchored to specific buildings.
This API can be used in conjunction with getVerticalScale(List) to perform custom animations of MapMarker.
This API should be called from onPostDraw(boolean, long) to synchronize with rendering.
Parameters:
buildingIds
A List of identifiers for the buildings of which the current transparency are to be retrieved
Returns:
A HashMap of Identifier-to-transparency mappings.
public java.util.HashMap <Identifier, java.lang.Float> getVerticalScale
(java.util.List <Identifier> buildingIds)
Retrieve the vertical scale [0,1] factor of a list of buildings. This is useful to animate any markers that are
anchored to specific buildings.
This API can be used in conjunction with getTransparency(List) to perform custom animations of MapMarker.
This API should be called from onPostDraw(boolean, long) to synchronize with rendering.
Parameters:
buildingIds
A List of identifiers identifiers for the buildings of which the current vertical scale are to be retrieved.
Returns:
A HashMap of the Identifier-to-scaling factor mappings.
public void releaseBuildingGroup (MapBuildingGroup group)
Release the MapBuildingGroup created for custom building selection.
Parameters:
group
The MapBuildingGroup to be released. The MapBuildingGroup instance becomes invalid and
unusable again. To create a new MapBuildingGroup, use createNewBuildingGroup().
Throws:
IllegalArgumentException
if group is a default MapBuildingGroup retrieved from
getDefaultBuildingGroup(DefaultBuildingGroups).
HERE Android SDK Developer's Guide
API Reference
942
BuildingSearchResult
The class BuildingSearchResult is a member of com.here.android.mpa.mapping.MapBuildingLayer.
Class Summary
public static final class MapBuildingLayer.BuildingSearchResult
extends java.lang.Object
Represents search results information for a building search
[For complete information, see the section Class Details]
Nested Class Summary
Table 459: Nested Classes in BuildingSearchResult
Nested Classes
public static final enumeration MapBuildingLayer.BuildingSearchResult.ErrorCode
Error codes for building search result
Method Summary
Table 460: Methods in BuildingSearchResult
Methods
public ErrorCode getResultCode ()
Get the error code.
public java.util.List <MapBuildingObject> getResults ()
Get the list of buildings
Class Details
Represents search results information for a building search
Method Details
public ErrorCode getResultCode ()
Get the error code.
Returns:
MapBuildingLayer.BuildingSearchResult.ErrorCode The completion code for the building search.
public java.util.List <MapBuildingObject> getResults ()
HERE Android SDK Developer's Guide
API Reference
943
Get the list of buildings
Returns:
A list of buildings
ErrorCode
The enumeration ErrorCode is a member of
com.here.android.mpa.mapping.MapBuildingLayer.BuildingSearchResult.
Enumeration Summary
public static final enumeration MapBuildingLayer.BuildingSearchResult.ErrorCode
extends java.lang.Enum, java.lang.Object
Error codes for building search result
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 461: Enum Constants in ErrorCode
Fields
public static final ErrorCode NONE
No error.
public static final ErrorCode NEEDS_DATA
Map Data is not available at the requested area.
public static final ErrorCode AREA_TOO_LARGE
Search area is too large.
public static final ErrorCode UNKNOWN
Unknown error.
Method Summary
Table 462: Methods in ErrorCode
Methods
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapBuildingLayer.BuildingSearchResult.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
944
Enumeration Details
Error codes for building search result
Enum Constant Details
public static final ErrorCode NONE
No error.
public static final ErrorCode NEEDS_DATA
Map Data is not available at the requested area. Requires download.
public static final ErrorCode AREA_TOO_LARGE
Search area is too large. Search with a smaller boundingbox.
public static final ErrorCode UNKNOWN
Unknown error.
Method Details
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapBuildingLayer.BuildingSearchResult.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
DefaultBuildingColor
The enumeration DefaultBuildingColor is a member of com.here.android.mpa.mapping.MapBuildingLayer.
Enumeration Summary
public static final enumeration MapBuildingLayer.DefaultBuildingColor
HERE Android SDK Developer's Guide
API Reference
945
extends java.lang.Enum, java.lang.Object
A set of pre-defined colors to change a MapBuildingGroup's color property
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 463: Enum Constants in DefaultBuildingColor
Fields
public static final DefaultBuildingColor SELECTED
public static final DefaultBuildingColor HIGHLIGHT
public static final DefaultBuildingColor HIGHLIGHT2
public static final DefaultBuildingColor HIGHLIGHT3
public static final DefaultBuildingColor HIGHLIGHT4
public static final DefaultBuildingColor HIGHLIGHT5
Method Summary
Table 464: Methods in DefaultBuildingColor
Methods
public static DefaultBuildingColor valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapBuildingLayer.DefaultBuildingColor[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
A set of pre-defined colors to change a MapBuildingGroup's color property
Enum Constant Details
public static final DefaultBuildingColor SELECTED
public static final DefaultBuildingColor HIGHLIGHT
public static final DefaultBuildingColor HIGHLIGHT2
public static final DefaultBuildingColor HIGHLIGHT3
HERE Android SDK Developer's Guide
API Reference
946
public static final DefaultBuildingColor HIGHLIGHT4
public static final DefaultBuildingColor HIGHLIGHT5
Method Details
public static DefaultBuildingColor valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapBuildingLayer.DefaultBuildingColor[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
DefaultBuildingGroups
The enumeration DefaultBuildingGroups is a member of com.here.android.mpa.mapping.MapBuildingLayer.
Enumeration Summary
public static final enumeration MapBuildingLayer.DefaultBuildingGroups
extends java.lang.Enum, java.lang.Object
Default groups of buildings on the Map.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 465: Enum Constants in DefaultBuildingGroups
Fields
public static final DefaultBuildingGroups NORMAL_BUILDINGS
Basic buildings.
public static final DefaultBuildingGroups IMPORTANT_BUILDINGS
Special buildings, such as landmarks.
HERE Android SDK Developer's Guide
API Reference
947
Method Summary
Table 466: Methods in DefaultBuildingGroups
Methods
public static DefaultBuildingGroups valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapBuildingLayer.DefaultBuildingGroups[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Default groups of buildings on the Map.
Enum Constant Details
public static final DefaultBuildingGroups NORMAL_BUILDINGS
Basic buildings.
public static final DefaultBuildingGroups IMPORTANT_BUILDINGS
Special buildings, such as landmarks.
Method Details
public static DefaultBuildingGroups valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapBuildingLayer.DefaultBuildingGroups[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapBuildingObject
The class MapBuildingObject is a member of com.here.android.mpa.mapping .
HERE Android SDK Developer's Guide
API Reference
948
Class Summary
public final class MapBuildingObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
This class represents a specific building on the map.
[For complete information, see the section Class Details]
Method Summary
Table 467: Methods in MapBuildingObject
Methods
public float getHeight ()
Gets the height of the MapBuildingObject
public Identifier getIdentifier ()
Gets the Identifier of the building.
public String getPlaceName ()
Gets the name of the MapBuildingObject.
public GeoCoordinate getPosition ()
Gets the position of the MapBuildingObject
Class Details
This class represents a specific building on the map. Using the Identifier, the MapBuildingObject can be
attached to MapBuildingGroup groups to manipulate color and height properties.
Method Details
public float getHeight ()
Gets the height of the MapBuildingObject
Returns:
height in meters relative to ground level.
public Identifier getIdentifier ()
Gets the Identifier of the building. The identifier can be matched against results in PlaceLink
Returns:
Identifier id of the building
public String getPlaceName ()
HERE Android SDK Developer's Guide
API Reference
949
Gets the name of the MapBuildingObject. This information is only available in 3D Landmarks.
Returns:
Name of the landmark
public GeoCoordinate getPosition ()
Gets the position of the MapBuildingObject
Returns:
GeoCoordinate position of the building
MapCartoMarker
The class MapCartoMarker is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapCartoMarker
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a selectable cartography icon displayed at a geographical position on a map.
[For complete information, see the section Class Details]
Method Summary
Table 468: Methods in MapCartoMarker
Methods
public Location getLocation ()
Returns the Location object for the MapCartoMarker
Class Details
Represents a selectable cartography icon displayed at a geographical position on a map. It cannot be added,
removed or modified by users.
Method Details
public Location getLocation ()
Returns the Location object for the MapCartoMarker
Returns:
The Location object for the MapCartoMarker.
HERE Android SDK Developer's Guide
API Reference
950
MapCircle
The class MapCircle is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapCircle
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a MapObject in the shape of a circle.
[For complete information, see the section Class Details]
Constructor Summary
Table 469: Constructors in MapCircle
Constructors
MapCircle ()
Constructs a MapCircle , which is a MapObject in the shape of a circle.
MapCircle (double radius, GeoCoordinate center)
Constructs a MapCircle , which is a MapObject in the shape of a circle.
Method Summary
Table 470: Methods in MapCircle
Methods
public GeoCoordinate getCenter ()
Returns the GeoCoordinate representing the current center of the MapCircle .
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapCircle is rendered with depth test.
public int getFillColor ()
Returns the current fill color for this MapCircle , returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getLineColor ()
Returns the current border line color for this MapCircle , as an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getLineWidth ()
Returns the current border line width for this MapCircle , in pixels.
public double getRadius ()
Returns the current radius of the MapCircle , in meters.
HERE Android SDK Developer's Guide
API Reference
951
Methods
public MapCircle setCenter (GeoCoordinate center)
Sets the center for this MapCircle to a specified GeoCoordinate.
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapCircle with depth test.
public MapCircle setFillColor (int argbColor)
Sets a fill color for this MapCircle using an ARGB (Alpha/Red/Green/Blue) integer color value.
public MapCircle setLineColor (int argbColor)
Sets a border line color for this MapCircle , using an ARGB (Alpha/Red/Green/Blue) integer color value.
public MapCircle setLineWidth (int width)
Sets a border line width, in pixels, for this MapCircle , an int value within the [0..100] range.
public MapCircle setRadius (double radius)
Sets a radius for this MapCircle , in meters.
Class Details
Represents a MapObject in the shape of a circle.
Constructor Details
MapCircle ()
Constructs a MapCircle , which is a MapObject in the shape of a circle.
MapCircle (double radius, GeoCoordinate center)
Constructs a MapCircle , which is a MapObject in the shape of a circle.
Parameters:
radius
Desired radius of the MapCircle, in meters
center
A GeoCoordinate representing the center of the MapCircle.
Throws:
IllegalArgumentException
if center is invalid.
Method Details
public GeoCoordinate getCenter ()
HERE Android SDK Developer's Guide
API Reference
952
Returns the GeoCoordinate representing the current center of the MapCircle .
Returns:
The current MapCircle center
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapCircle is rendered with depth test. By default, depth test is
disabled.
Returns:
True if the MapCircle is rendered with depth test, false otherwise
public int getFillColor ()
Returns the current fill color for this MapCircle , returning an ARGB (Alpha/Red/Green/Blue) integer color
value. Default fill color is solid blue or in ARGB color, 0xFF0000FF.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
android.graphics.Color
public int getLineColor ()
Returns the current border line color for this MapCircle , as an ARGB (Alpha/Red/Green/Blue) integer color
value. Default line color is solid blue, or in ARGB color, 0xFF0000FF.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
android.graphics.Color
public int getLineWidth ()
Returns the current border line width for this MapCircle , in pixels. The default width is 0 pixels.
Returns:
The current width of the line defining the border of the MapCircle.
HERE Android SDK Developer's Guide
API Reference
953
public double getRadius ()
Returns the current radius of the MapCircle , in meters. The default radius of a MapCircle instance is 1.
Returns:
The current radius of this MapCircle.
public MapCircle setCenter (GeoCoordinate center)
Sets the center for this MapCircle to a specified GeoCoordinate.
Parameters:
center
Desired GeoCoordinate for this MapCircle center.
Returns:
The updated MapCircle itself.
Throws:
IllegalArgumentException
if center is invalid.
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapCircle with depth test.
Rendering with depth test should be used if map object altitude is relevant in your application. Rendering
objects with different heights while disabling depth test may cause object occlusion.
Parameters:
enabled
true if MapCircle is rendered with depth test
public MapCircle setFillColor (int argbColor)
Sets a fill color for this MapCircle using an ARGB (Alpha/Red/Green/Blue) integer color value.
Parameters:
argbColor
Desired ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated MapCircle itself.
See also:
HERE Android SDK Developer's Guide
API Reference
954
android.graphics.Color
public MapCircle setLineColor (int argbColor)
Sets a border line color for this MapCircle , using an ARGB (Alpha/Red/Green/Blue) integer color value.
Parameters:
argbColor
Desired ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated MapCircle itself.
See also:
android.graphics.Color
public MapCircle setLineWidth (int width)
Sets a border line width, in pixels, for this MapCircle , an int value within the [0..100] range.
Parameters:
width
Desired width of the line defining the border of the MapCircle
Returns:
The updated MapCircle itself.
Throws:
IllegalArgumentException
is width is out of range.
public MapCircle setRadius (double radius)
Sets a radius for this MapCircle , in meters.
Parameters:
radius
Desired radius of the MapCircle.
Returns:
The updated MapCircle itself.
Throws:
IllegalArgumentException
HERE Android SDK Developer's Guide
API Reference
955
if radius supplied is less than or equal to 0.0.
MapContainer
The class MapContainer is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapContainer
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a container that determines the stacking order of objects on a Map.
[For complete information, see the section Class Details]
See also:
setVisible(boolean)
setVisibleMask(int)
setVisibleMask(int, int)
Constructor Summary
Table 471: Constructors in MapContainer
Constructors
MapContainer ()
Creates an empty MapContainer .
Method Summary
Table 472: Methods in MapContainer
Methods
public boolean addMapObject (MapObject object)
Adds a MapObject to this MapContainer .
public java.util.List <MapObject> getAllMapObjects ()
Returns the list of all MapObject objects within this MapContainer.
public boolean removeAllMapObjects ()
Removes all MapObject objects currently within this MapContainer.
public boolean removeMapObject (MapObject object)
Removes the specified MapObject from this MapContainer.
HERE Android SDK Developer's Guide
API Reference
956
Class Details
Represents a container that determines the stacking order of objects on a Map. Applications can add certain
types of MapObject objects into a MapContainer. For more details, refer to addMapObject(MapObject).
You can use MapContainer.setVisible(boolean) to control whether the objects in the container are visible. If
MapContainer.setVisible(true) , then the visibility settings of each map object in the container are
used.
Unlike other map objects, MapContainer does not support the use of visibility masks, so you cannot set
container visibility on a zoom level basis.
See also:
setVisible(boolean)
setVisibleMask(int)
setVisibleMask(int, int)
Constructor Details
MapContainer ()
Creates an empty MapContainer .
Method Details
public boolean addMapObject (MapObject object)
Adds a MapObject to this MapContainer . Only the following types of MapObject can be added:
MapMarker objects
MapLabeledMarker objects
MapScreenMarker objects
MapCircle objects
MapPolyline objects
MapPolygon objects
For a complete enumeration of available MapObject types, refer to MapObject.Type.
Parameters:
object
A MapObject to add to this MapContainer
Returns:
True if the MapObject was added successfully to this MapContainer, false otherwise
See also:
removeMapObject(MapObject)
HERE Android SDK Developer's Guide
API Reference
957
public java.util.List <MapObject> getAllMapObjects ()
Returns the list of all MapObject objects within this MapContainer. Modifications to objects returned from the
array are not guaranteed to be reflected properly in the MapContainer. Use addMapObject(MapObject) and
removeMapObject(MapObject) to modify individual array elements.
Note: the order of the MapObjects returned in the List is arbitrary. There is no guarantee the list is sorted in
the order the MapObjects were added to the MapContainer.
Returns:
A list containing all MapObject objects within the MapContainer. If the MapContainer contains no map object,
an empty array will be returned.
public boolean removeAllMapObjects ()
Removes all MapObject objects currently within this MapContainer.
Returns:
True if all MapObject objects were removed successfully from this MapContainer, false otherwise
See also:
removeMapObject(MapObject)
public boolean removeMapObject (MapObject object)
Removes the specified MapObject from this MapContainer. If the specified MapObject is not contained within
the MapContainer, the container will be unchanged.
Parameters:
object
A MapObject to remove from this MapContainer
Returns:
True if the MapObject was removed successfully from this MapContainer , false otherwise
See also:
removeAllMapObjects()
MapFragment
The class MapFragment is a member of com.here.android.mpa.mapping .
Class Summary
public class MapFragment
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
958
A fragment class that automatically creates a Map and handles map UI interactions such as panning and
zooming.
[For complete information, see the section Class Details]
See also:
android.app.Fragment
Constructor Summary
Table 473: Constructors in MapFragment
Constructors
MapFragment ()
Constructor
Method Summary
Table 474: Methods in MapFragment
Methods
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
public ViewRect getClipRect ()
Returns the ViewRect representing the clip rectangle for this MapFragment.
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle.
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
public CopyrightLogoPosition getCopyrightLogoPosition ()
Returns the on-screen position of the HERE copyright logo as a CopyrightLogoPosition value.
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map
area to the edge of the logo.
public Map getMap ()
Returns the instance of Map associated with this map fragment
public MapGesture getMapGesture ()
Returns the MapGesture object representing the current gesture handler for the MapFragment.
public PositionIndicator getPositionIndicator ()
Returns the PositionIndicator instance that renders the current position with a marker.
HERE Android SDK Developer's Guide
API Reference
959
Methods
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the MapFragment.
public void init (OnEngineInitListener listener)
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle.
public void init (Context context, MapVariant variant, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle.
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle.
public void init (ApplicationContext context, OnEngineInitListener listener)
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle.
public View onCreateView (LayoutInflater inflater, ViewGroup container, Bundle
savedInstanceState)
Called when this fragment is first attached to its Activity .
public void onDestroyView ()
Called when the view previously created by onCreateView(LayoutInflater, ViewGroup, Bundle) has been detached from this
fragment.
public void onInflate (Activity activity, AttributeSet attrs, Bundle savedInstanceState)
Deprecated: Deprecated as of release 3.5.
Called when this fragment is being created as part of a view layout inflation, typically from setting the content view of an
activity.
public void onInflate (Context context, AttributeSet attrs, Bundle savedInstanceState)
Called when this fragment is being created as part of a view layout inflation, typically from setting the content view of an
activity.
public void onPause ()
Called when this fragment is no longer resumed.
public void onResume ()
Called when this fragment is visible to the user and actively running.
public void onSaveInstanceState (Bundle outState)
Called when this fragment has been asked to save its current dynamic state.
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the MapFragment.
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to this MapFragment.
HERE Android SDK Developer's Guide
API Reference
960
Methods
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the MapFragment's boundary, for the placement of the HERE
copyright logo.
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
Sets a position for the HERE copyright logo.
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map area to the
edge of the logo (depending on the placement).
public void setMapMarkerDragListener (OnDragListener listener)
Sets a MapMarker.OnDragListener to be invoked whenever any MapMarker on a Map that is attached to this fragment is
dragged.
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the MapFragment.
Class Details
A fragment class that automatically creates a Map and handles map UI interactions such as panning and
zooming. MapFragment extends the Android Fragment class and retains its lifecycle behaviors.
Upon the initialization of MapFragment , a Map object is automatically created and bound to the fragment.
This Map object is then persisted throughout the MapFragment 's lifetime. Since MapFragment internally
calls Fragment.setRetainInstance(true) , the Map will retain any properties applied to it during an
application's lifetime.
MapFragment objects have their own lifecycle, state, and back stack, thus it is unsafe to assume objects
returned by a MapFragment instance (with the exception of Map ) will be available throughout the lifetime of
its attached activity.
A MapFragment is defined in an Android layout XML file. For example:
<fragment
class="com.here.android.mpa.mapping.MapFragment"
android:id="@+id/map_fragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
Note: MapFragment automatically handles MapEngine pausing and resuming during activity state changes,
thus it is not necessary for the activity that owns MapFragment instances to manually call onPause() or
onResume() during the activity's onPause() and onResume(). However, considerations should be made in how
much processing is done during the onResume() method. Performing significant amounts of processing may
delay view rendering in cases such as device orientation changes. In these cases, it is recommended to use a
specifically designated handler to organize the amount of processing to be done.
See also:
android.app.Fragment
HERE Android SDK Developer's Guide
API Reference
961
Constructor Details
MapFragment ()
Constructor
Method Details
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
Parameters:
listener
A OnMapRenderListener to add to the MapFragment
See also:
removeOnMapRenderListener(OnMapRenderListener)
public ViewRect getClipRect ()
Returns the ViewRect representing the clip rectangle for this MapFragment.
Returns:
The clip rectangle for rendering MapObject objects and similar map-related screen elements. Null if the
view's layout process has yet to be completed.
If the process is not yet complete, users can either retry later or subscribe as a OnMapRenderListener and
call this method upon the callback onSizeChanged(int, int).
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle. Returns null if a boundary rect has not been set
previously.
Returns:
The copyright logo's boundary rect. null if a boundary rect has not been set previously.
See also:
setCopyrightBoundaryRect(Rect)
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
This method only returns a valid value once fragment initialization has taken completed.
Returns:
HERE Android SDK Developer's Guide
API Reference
962
The height of the copyright logo, in number of pixels
public CopyrightLogoPosition getCopyrightLogoPosition ()
Returns the on-screen position of the HERE copyright logo as a CopyrightLogoPosition value.
Returns:
The position of the logo.
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
This method only returns a valid value once fragment initialization has completed.
Returns:
The width of the copyright logo, in number of pixels
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the
visible map area to the edge of the logo.
This method only returns a valid value once fragment initialization has taken place.
Returns:
The current offset from the edge of the MapFragment, in number of pixels
public Map getMap ()
Returns the instance of Map associated with this map fragment
Returns:
The Map object currently displayed in this fragment.
public MapGesture getMapGesture ()
Returns the MapGesture object representing the current gesture handler for the MapFragment. Applications
can intercept this object and override the default event behaviors.
Returns:
The MapGesture
public PositionIndicator getPositionIndicator ()
HERE Android SDK Developer's Guide
API Reference
963
Returns the PositionIndicator instance that renders the current position with a marker. The position indicator
should be used with PositioningManager.
Returns:
The PositionIndicator
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the MapFragment. This method is asynchronous and will invoke a callback
once the operation is completed through the OnScreenCaptureListener. The MapFragment must be visible to
create the screen capture.
Parameters:
listener
A OnScreenCaptureListener to listen for the callback when screen capture is complete.
public void init (OnEngineInitListener listener)
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle. Users of
MapFragment should call this method or init(ApplicationContext, OnEngineInitListener) after the fragment is
first attached to its activity. This method should only be used for fragments declared in a layout XML. Do not
use this method when MapFragment is created programmatically.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
listener
A OnEngineInitListener object that will be called when MapFragment initialization is finished. A null
object can be supplied if the caller does not expect any notification when initialization completes.
See also:
OnEngineInitListener
init(ApplicationContext, OnEngineInitListener)
init(ApplicationContext, OnEngineInitListener)
public void init (Context context, MapVariant variant, OnEngineInitListener
listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle. Users of
MapFragment should call this method after the fragment is first attached to its activity.
HERE Android SDK Developer's Guide
API Reference
964
This method can be used for MapFragment objects that are created programmatically or declared in a
layout XML file.
This method can configure map variant which will be used by MapEngine. If initialization fails -
OPERATION_NOT_ALLOWED will be reported. Currently following variants are supported: - GLOBAL - initialize
MapEngine to use international map variant; - KOREA - initialize MapEngine to use Korean map variant; -
null - initialize MapEngine to use stored map variant or international map variant for first run. This method
is used to configure MapEngine to use certain map variant. If MapEngine was already configured and
passed variant differs - error will be reported and initialization fails.
Parameters:
context
The application context of this fragment.
variant
Map data variant to use.
listener
A OnEngineInitListener object that will be called when MapFragment initialization is finished. A null
object can be supplied if the caller does not require any notification when initialization completes.
See also:
OnEngineInitListener
init(Context, OnEngineInitListener)
init(OnEngineInitListener)
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Use init(ApplicationContext, OnEngineInitListener) instead.
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle. Users of
MapFragment should call this method after the fragment is first attached to its activity.
This method can be used for MapFragment objects that are created programmatically or declared in a
layout XML file.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
context
The application context of this fragment.
listener
A OnEngineInitListener object that will be called when MapFragment initialization is finished. A null
object can be supplied if the caller does not require any notification when initialization completes.
See also:
OnEngineInitListener
HERE Android SDK Developer's Guide
API Reference
965
init(Context, OnEngineInitListener)
init(OnEngineInitListener)
public void init (ApplicationContext context, OnEngineInitListener listener)
Initializes the MapEngine and displays a map that occupies the entire MapFragment's view rectangle. Users of
MapFragment should call this method after the fragment is first attached to its activity.
This method can be used for MapFragment objects that are created programmatically or declared in a
layout XML file.
This method will initialize MapEngine with ApplicationContext to be used during initialization.
Parameters:
context
ApplicationContext to be used during initialization.
listener
A OnEngineInitListener object that will be called when MapFragment initialization is finished. A null
object can be supplied if the caller does not require any notification when initialization completes.
See also:
OnEngineInitListener
init(ApplicationContext, OnEngineInitListener)
public View onCreateView (LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
Called when this fragment is first attached to its Activity . Automatically starts to initialize the MapEngine
for later use.
Parameters:
inflater
container
savedInstanceState
Returns:
The created MapView object.
See also:
android.app.Fragment#onAttach(android.app.Activity)
public void onDestroyView ()
Called when the view previously created by onCreateView(LayoutInflater, ViewGroup, Bundle) has been
detached from this fragment. The MapView object created earlier will detach itself of its associated Map
instance.
HERE Android SDK Developer's Guide
API Reference
966
See also:
android.app.Fragment#onDestroyView()
public void onInflate (Activity activity, AttributeSet attrs, Bundle
savedInstanceState)
Deprecated: Deprecated as of release 3.5.
Use #onInflate(Context, android.util.AttributeSet, android.os.Bundle) instead.
Called when this fragment is being created as part of a view layout inflation, typically from setting the
content view of an activity. This method may be called immediately after the fragment is created from a tag
in a layout file.
Parameters:
activity
attrs
savedInstanceState
See also:
android.app.Fragment#onInflate(Activity, AttributeSet, Bundle)
public void onInflate (Context context, AttributeSet attrs, Bundle
savedInstanceState)
Called when this fragment is being created as part of a view layout inflation, typically from setting the
content view of an activity. This method may be called immediately after the fragment is created from a tag
in a layout file.
Parameters:
context
attrs
savedInstanceState
See also:
android.app.Fragment#onInflate(Activity, AttributeSet, Bundle)
public void onPause ()
Called when this fragment is no longer resumed. All MapEngine activities will be paused automatically.
See also:
android.app.Fragment#onPause()
public void onResume ()
HERE Android SDK Developer's Guide
API Reference
967
Called when this fragment is visible to the user and actively running. All MapEngine activities will be resumed
automatically.
See also:
android.app.Fragment#onResume()
public void onSaveInstanceState (Bundle outState)
Called when this fragment has been asked to save its current dynamic state. Saving its current state allows
for it to be later reconstructed in a new instance.
Parameters:
outState
See also:
android.app.Fragment#onSaveInstanceState(android.os.Bundle)
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
Parameters:
listener
A OnMapRenderListener to remove from the MapFragment
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the MapFragment. Only the area specified by the ViewRect will be used for
rendering, while the rest of the view will be masked in black. This rectangle will be reset to the full size of the
MapFragment upon screen rotation or upon recreating the screen.
Note that setting a clipping rectangle will also reset the MapFragment 's viewing rectangle to its full default
size.
If the ViewRect is not valid, this method does nothing.
Parameters:
rect
A ViewRect for rendering MapObject objects and similar map-related screen elements
transformCenter
A android.graphics.PointF representing the center coordinate for map transformations such as
zooming and rotation
See also:
setClipRect(ViewRect)
HERE Android SDK Developer's Guide
API Reference
968
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to this MapFragment. Only the area specified by the ViewRect will be used for
rendering, while the rest of the view will be masked in black. This rectangle will be reset to the full size of the
MapFragment upon screen rotation or upon recreating the screen.
If the ViewRect is not valid, this method does nothing.
Parameters:
rect
A ViewRect for rendering MapObject objects and similar map-related screen elements
See also:
setClipRect(ViewRect, PointF)
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the MapFragment's boundary, for the placement
of the HERE copyright logo.
If the specified rectangle is not contained completely within the current visible map area, their area of
intersection will be used instead of the specified rectangle's area. The copyright logo and copyright margin
must fit into the rectangle, otherwise specified rectangle will be ignored.
The rectangle is reset upon screen rotation or upon screen re-creation, or it can be done by setting a null -
Rect .
Parameters:
rect
A Rect representing the desired rectangular container to be used for positioning the copyright logo. Use
null Rect to reset the boundary container.
Throws:
IllegalArgumentException
if Rect supplied is invalid
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
Sets a position for the HERE copyright logo. The current default is to place the logo at the center-bottom of
the visible map view area.
After the logo's position is set, the position stays effective even when the screen is rotated or re-created.
Parameters:
position
A CopyrightLogoPosition value representing the desired placement of the HERE copyright logo with
respect to the visible map view area
HERE Android SDK Developer's Guide
API Reference
969
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible map
area to the edge of the logo (depending on the placement).
Parameters:
margin
Desired offset from the edge of the MapFragment
public void setMapMarkerDragListener (OnDragListener listener)
Sets a MapMarker.OnDragListener to be invoked whenever any MapMarker on a Map that is attached to this
fragment is dragged.
Parameters:
listener
An MapMarker.OnDragListener to set for this MapFragment
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the
MapFragment.
Parameters:
listener
An android.view.OnTouchListener to set for the MapFragment
See also:
android.view.View.OnTouchListener
MapGeoModel
The class MapGeoModel is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapGeoModel
extends com.here.android.mpa.mapping.MapModelObject, com.here.android.mpa.mapping.MapObject,
com.here.android.mpa.common.ViewObject, java.lang.Object
A MapGeoModel is a GeoCoordinate mesh displayed on a map.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
970
Constructor Summary
Table 475: Constructors in MapGeoModel
Constructors
MapGeoModel ()
Creates a MapGeoModel .
Method Summary
Table 476: Methods in MapGeoModel
Methods
public GeoMesh getMesh ()
Gets the GeoMesh currently associated with the MapGeoModel .
public Image getTexture ()
Gets the current texture Image of the MapGeoModel .
public MapGeoModel setMesh (GeoMesh model)
Sets a GeoMesh for the MapGeoModel .
public MapGeoModel setTexture (Image texture)
Sets a texture Image for the MapGeoModel .
Class Details
A MapGeoModel is a GeoCoordinate mesh displayed on a map. The mesh is represented by a GeoMesh object,
which internally holds an array of GeoCoordinate .
Properties of a MapGeoModel mesh include its texture, which is an Image applied to the mesh. 2D plane
objects will respect the texture's transparency, while the alpha transparency for a texture being applied to a
3D object is undefined.
Constructor Details
MapGeoModel ()
Creates a MapGeoModel .
Method Details
public GeoMesh getMesh ()
Gets the GeoMesh currently associated with the MapGeoModel .
Returns:
The GeoMesh
HERE Android SDK Developer's Guide
API Reference
971
public Image getTexture ()
Gets the current texture Image of the MapGeoModel .
Returns:
The texture Image
public MapGeoModel setMesh (GeoMesh model)
Sets a GeoMesh for the MapGeoModel .
Parameters:
model
Desired GeoMesh
Returns:
The updated MapGeoMesh itself.
public MapGeoModel setTexture (Image texture)
Sets a texture Image for the MapGeoModel .
Parameters:
texture
Desired texture Image
Returns:
The updated MapGeoMesh itself.
MapGesture
The interface MapGesture is a member of com.here.android.mpa.mapping .
Interface Summary
public abstract interface MapGesture
Encapsulates all user interactions and touch gestures.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
972
Nested Class Summary
Table 477: Nested Classes in MapGesture
Nested Classes
public static abstract interface MapGesture.OnGestureListener
Event Listener interface for gesture events.
Method Summary
Table 478: Methods in MapGesture
Methods
public abstract void addOnGestureListener (OnGestureListener listener)
Deprecated: As of SDK 3.3, use addOnGestureListener(MapGesture.OnGestureListener, int, boolean) instead.
Adds a MapGesture.OnGestureListener to listen for map gesture events.
public abstract void addOnGestureListener (OnGestureListener listener, int priority, boolean
isSync)
Adds a MapGesture.OnGestureListener to listen for map gesture events.
public abstract void cancelKineticPanning ()
Cancels all currently active motions caused by kinetic panning.
public abstract boolean isAutoSnapToNorthEnabled ()
Returns a boolean value indicating whether map automatically rotates to the north if previous rotation did not exceed
certain small amount of degrees starting from north.
public abstract boolean isDoubleTapEnabled ()
Returns a boolean value indicating whether double-tap is enabled for the MapGesture .
public abstract boolean isFixedMapCenterOnMapRotateZoom ()
Returns a boolean value indicating whether the transform center is applied on rotate and zoom interactions.
public abstract boolean isKineticFlickEnabled ()
Returns a boolean value indicating whether flick-to-scroll (with kinetic momentum) is enabled for the MapGesture .
public abstract boolean isLongPressEnabled ()
Returns a boolean value indicating whether long-press is enabled for this MapGesture .
public abstract boolean isPanningEnabled ()
Returns a boolean value indicating whether panning is enabled for this MapGesture .
public abstract boolean isPinchEnabled ()
Returns a boolean value indicating whether pinch is enabled for this MapGesture .
public abstract boolean isRotateEnabled ()
Returns a boolean value indicating whether two-finger rotation is enabled for this MapGesture .
public abstract boolean isSingleTapEnabled ()
Returns a boolean value indicating whether single-tap is enabled for this MapGesture .
HERE Android SDK Developer's Guide
API Reference
973
Methods
public abstract boolean isTiltEnabled ()
Returns a boolean value indicating whether tilt is enabled for this MapGesture .
public abstract boolean isTwoFingerPanningEnabled ()
Returns a boolean value indicating whether two-finger panning interactions are enabled for this MapGesture .
public abstract boolean isTwoFingerTapEnabled ()
Returns a boolean value indicating whether two-finger tap is enabled for this MapGesture .
public abstract void removeOnGestureListener (OnGestureListener listener)
Removes an existing MapGesture.OnGestureListener.
public abstract MapGesture setAllGesturesEnabled (boolean enabled)
Sets all possible kinds of gesture interaction to be either enabled or disabled for the MapGesture .
public abstract MapGesture setAutoSnapToNorthEnabled (boolean enabled)
Sets whether map automatically rotates to the north if previous rotation did not exceed certain small amount of degrees
starting from north.
public abstract MapGesture setDoubleTapEnabled (boolean enabled)
Sets whether double-tap interactions are enabled or disabled for this MapGesture .
public abstract MapGesture setFixedMapCenterOnMapRotateZoom (boolean lock)
Sets whether the transform center is applied during multitouch gestures.
public abstract MapGesture setKineticFlickEnabled (boolean enabled)
Sets whether flick-to-scroll (with kinetic momentum) interactions are enabled for this MapGesture .
public abstract MapGesture setLongPressEnabled (boolean enabled)
Sets whether long-press interactions are enabled or disabled for this MapGesture .
public abstract MapGesture setPanningEnabled (boolean enabled)
Sets panning interactions to be either enabled or disabled for this MapGesture .
public abstract MapGesture setPinchEnabled (boolean enabled)
Sets whether pinch interactions are enabled or disabled for this MapGesture .
public abstract MapGesture setRotateEnabled (boolean enabled)
Sets whether two-finger rotate interactions are enabled for this MapGesture .
public abstract MapGesture setSingleTapEnabled (boolean enabled)
Sets whether single-tap interactions are enabled or disabled for this MapGesture .
public abstract MapGesture setTiltEnabled (boolean enabled)
Sets whether tilt interactions are enabled or disabled for this MapGesture .
public abstract MapGesture setTwoFingerPanningEnabled (boolean enable)
Sets whether the two-finger panning interaction is enabled for this MapGesture .
public abstract MapGesture setTwoFingerTapEnabled (boolean enabled)
Sets whether two-finger tap gestures are enabled or disabled for this MapGesture .
HERE Android SDK Developer's Guide
API Reference
974
Interface Details
Encapsulates all user interactions and touch gestures.
Default gestures made available through this interface include:
Panning - allows a user to pan around a map by holding one finger on the screen and dragging to a new
geographical location
Kinetic Flick - allows a user to pan around a map by "flicking" the screen with one finger (faster than
panning but less precise)
Pinch To Zoom - allows a user to zoom out or zoom in by, respectively, pinching or spreading two fingers
being held to the screen
Double Tap - allows a user to zoom in to view closer geographical details
Two-Finger Tap - allows a user to zoom out to view a wider geographical area
Two-Finger Vertical Drag - allows a user to tilt a map to an angle between "straight down from above"
and "looking toward the horizon"
Two-Finger Rotate - allows a user to rotate a map to a desired compass orientation
Single Tap - does not encapsulate any default behavior. Developers can add application-specific
functionality to this gesture.
Long Press - does not encapsulate any default behavior. Developers can add application-specific
functionality to this gesture.
Various setter methods of this interface allow an application developer to set specific gestures as either
enabled or disabled. There is also a setAllGesturesEnabled(boolean) method which simultaneously enables
or disables all gestures.
Note: the default functionality of one or more gestures can be customized by implementing the
MapGesture.OnGestureListener class and overriding appropriate methods to define desired gesture
functionality (this must be done to make use of the long press gesture).
Method Details
public abstract void addOnGestureListener (OnGestureListener listener)
Deprecated: As of SDK 3.3, use addOnGestureListener(MapGesture.OnGestureListener, int, boolean) instead.
Adds a MapGesture.OnGestureListener to listen for map gesture events. When there are multiple listeners
subscribed to the MapGesture events, the order when a subscriber receives a callback is determined by the
order when they are added to MapGesture .
It is important that after adding an MapGesture.OnGestureListener in an user application, remember to call
removeOnGestureListener(MapGesture.OnGestureListener) when there's no longer a need to listen for map
gesture events to free up application resources.
Parameters:
listener
A MapGesture.OnGestureListener to add to this MapGesture
See also:
addOnGestureListener(OnGestureListener, int, boolean)
removeOnGestureListener(OnGestureListener)
HERE Android SDK Developer's Guide
API Reference
975
public abstract void addOnGestureListener (OnGestureListener listener, int
priority, boolean isSync)
Adds a MapGesture.OnGestureListener to listen for map gesture events. When there are multiple listeners
subscribed to the MapGesture events, all synchronous subscriber(s) will receive the gesture event callback
first, followed by the asynchronous subscriber(s), unless the event is consumed by one of the synchronous
subscribe(s). Within the same group of synchronous or asynchronous subscriber(s), the order when a
subscriber receives a callback is then determined first by the priority, then within the same priority, it is
determined next by the order when they are added to MapGesture . Once one of the subscriber(s) consumes
a gesture event, no other subscriber(s) will receive the event.
OnGestureListeners added by way of addOnGestureListener(MapGesture.OnGestureListener, int, boolean) can
return their callbacks synchronously or asynchronously depending on the value of isSync used when calling
the method.
If a listener has previously been added as an asynchronous listener and is added again as a synchronous
listener, it will automatically be de-registered from the asynchronous to ensure the same listener can only
be an asynchronous or synchronous but not both. Similarly, the same applies for the case of synchronous
listener then switching to asynchronous.
It is important that after adding an MapGesture.OnGestureListener in an user application, remember to call
removeOnGestureListener(MapGesture.OnGestureListener) when there's no longer a need to listen for map
gesture events to free up application resources.
Parameters:
listener
A MapGesture.OnGestureListener to add to this MapGesture
priority
An int representing the priority of this listener to be added. The value Integer.MIN_VALUE is
reserved for internal use.
isSync
Use true to add this listener to receive callbacks synchronously, use false otherwise. Only
synchronous listeners can consume a gesture event.
See also:
removeOnGestureListener(OnGestureListener)
public abstract void cancelKineticPanning ()
Cancels all currently active motions caused by kinetic panning.
public abstract boolean isAutoSnapToNorthEnabled ()
Returns a boolean value indicating whether map automatically rotates to the north if previous rotation did
not exceed certain small amount of degrees starting from north. By default, this value is set to true.
Returns:
HERE Android SDK Developer's Guide
API Reference
976
True if auto snap to north is enabled, false otherwise.
public abstract boolean isDoubleTapEnabled ()
Returns a boolean value indicating whether double-tap is enabled for the MapGesture . By default, this
value is set to true.
Returns:
True if double-tap is enabled, false otherwise
public abstract boolean isFixedMapCenterOnMapRotateZoom ()
Returns a boolean value indicating whether the transform center is applied on rotate and zoom interactions.
The default value is false.
Returns:
True if transform center is fixed during zoom, False otherwise.
public abstract boolean isKineticFlickEnabled ()
Returns a boolean value indicating whether flick-to-scroll (with kinetic momentum) is enabled for the
MapGesture . By default, this value is set to true.
Returns:
True if kinetic flick is enabled, false otherwise
public abstract boolean isLongPressEnabled ()
Returns a boolean value indicating whether long-press is enabled for this MapGesture . By default, this
value is set to true.
Returns:
True if long-press is enabled, false otherwise
public abstract boolean isPanningEnabled ()
Returns a boolean value indicating whether panning is enabled for this MapGesture . By default, this value
is set to true.
Returns:
True if panning is enabled, false otherwise
public abstract boolean isPinchEnabled ()
HERE Android SDK Developer's Guide
API Reference
977
Returns a boolean value indicating whether pinch is enabled for this MapGesture . By default, this value is
set to true.
Returns:
True if pinch is enabled, false otherwise
public abstract boolean isRotateEnabled ()
Returns a boolean value indicating whether two-finger rotation is enabled for this MapGesture . By default,
this value is set to true.
Returns:
True if rotate is enabled, false otherwise
public abstract boolean isSingleTapEnabled ()
Returns a boolean value indicating whether single-tap is enabled for this MapGesture . By default, this
value is set to true.
Returns:
True if single-tap is enabled, false otherwise
public abstract boolean isTiltEnabled ()
Returns a boolean value indicating whether tilt is enabled for this MapGesture . By default, this value is set
to true.
Returns:
True if tilt is enabled, false otherwise
public abstract boolean isTwoFingerPanningEnabled ()
Returns a boolean value indicating whether two-finger panning interactions are enabled for this
MapGesture . By default, this value is set to true.
Returns:
A boolean true if enabled, false if disabled.
public abstract boolean isTwoFingerTapEnabled ()
Returns a boolean value indicating whether two-finger tap is enabled for this MapGesture . By default, this
value is set to true.
Returns:
True if two-finger tap is enabled, false otherwise
HERE Android SDK Developer's Guide
API Reference
978
public abstract void removeOnGestureListener (OnGestureListener listener)
Removes an existing MapGesture.OnGestureListener. Call this method to free up application resources when
there's no longer any need to listen for map gesture events.
Parameters:
listener
A MapGesture.OnGestureListener to remove from this MapGesture
public abstract MapGesture setAllGesturesEnabled (boolean enabled)
Sets all possible kinds of gesture interaction to be either enabled or disabled for the MapGesture .
Parameters:
enabled
A boolean specifying whether all gestures are enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setAutoSnapToNorthEnabled (boolean enabled)
Sets whether map automatically rotates to the north if previous rotation did not exceed certain small
amount of degrees starting from north. By default, this value is set to true.
Parameters:
enabled
A boolean specifying whether auto snap to north is enabled.
Returns:
The modified MapGesture itself.
public abstract MapGesture setDoubleTapEnabled (boolean enabled)
Sets whether double-tap interactions are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether double-tap is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setFixedMapCenterOnMapRotateZoom (boolean lock)
HERE Android SDK Developer's Guide
API Reference
979
Sets whether the transform center is applied during multitouch gestures. If this value is enabled, rotation
and zoom will always be applied using the transform center, instead of a point relative the touch interaction.
Parameters:
lock
A boolean specifying whether transform center is fixed . Default is false
Returns:
The modified MapGesture itself.
public abstract MapGesture setKineticFlickEnabled (boolean enabled)
Sets whether flick-to-scroll (with kinetic momentum) interactions are enabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether kinetic flick is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setLongPressEnabled (boolean enabled)
Sets whether long-press interactions are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether long-press is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setPanningEnabled (boolean enabled)
Sets panning interactions to be either enabled or disabled for this MapGesture . Note that when panning is
disabled, kinetic panning will also be blocked, even if it is enabled.
Parameters:
enabled
A boolean specifying whether panning is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setPinchEnabled (boolean enabled)
HERE Android SDK Developer's Guide
API Reference
980
Sets whether pinch interactions are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether pinch is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setRotateEnabled (boolean enabled)
Sets whether two-finger rotate interactions are enabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether rotate is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setSingleTapEnabled (boolean enabled)
Sets whether single-tap interactions are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether single-tap is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setTiltEnabled (boolean enabled)
Sets whether tilt interactions are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether tilt is enabled
Returns:
The modified MapGesture itself.
public abstract MapGesture setTwoFingerPanningEnabled (boolean enable)
Sets whether the two-finger panning interaction is enabled for this MapGesture .
HERE Android SDK Developer's Guide
API Reference
981
Parameters:
enable
True if two finger panning will be enabled (default). False if two-finger panning will not be enabled.
Returns:
The modified MapGesture itself.
public abstract MapGesture setTwoFingerTapEnabled (boolean enabled)
Sets whether two-finger tap gestures are enabled or disabled for this MapGesture .
Parameters:
enabled
A boolean specifying whether two-finger tap is enabled
Returns:
The modified MapGesture itself.
OnGestureListener
The interface OnGestureListener is a member of com.here.android.mpa.mapping.MapGesture.
Interface Summary
public static abstract interface MapGesture.OnGestureListener
Event Listener interface for gesture events.
[For complete information, see the section Interface Details]
Nested Class Summary
Table 479: Nested Classes in OnGestureListener
Nested Classes
public static abstract class MapGesture.OnGestureListener.OnGestureListenerAdapter
Default implementation for the OnGestureListener interface.
Method Summary
Table 480: Methods in OnGestureListener
Methods
public abstract boolean onDoubleTapEvent (PointF p)
A callback indicating that a user has performed a double tap gesture on a map.
HERE Android SDK Developer's Guide
API Reference
982
Methods
public abstract boolean onLongPressEvent (PointF p)
A callback indicating that a user has performed a long-press gesture on a map.
public abstract void onLongPressRelease ()
A callback indicating that a user has released a long-press gesture on a map.
public abstract boolean onMapObjectsSelected (java.util.List <ViewObject> objects)
A callback indicating that at least one ViewObject has been selected as a result of a user tapping on the map.
public abstract void onMultiFingerManipulationEnd ()
A callback indicating the user has removed all or all-except-one fingers from the screen.
public abstract void onMultiFingerManipulationStart ()
A callback indicating the user has put more than one finger onto the screen.
public abstract void onPanEnd ()
A callback indicating the user has lifted up their finger and stopped panning.
public abstract void onPanStart ()
A callback indicating the user has put one finger on the screen and moved their finger to trigger panning.
public abstract void onPinchLocked ()
A callback indicating that a user has pinched enough to be recognized as the two-finger zoom gesture.
public abstract boolean onPinchZoomEvent (float scaleFactor, PointF p)
A callback indicating that a user has performed a pinch-to-zoom gesture on a map.
public abstract boolean onRotateEvent (float rotateAngle)
A callback indicating that a user has performed a rotate gesture on a map.
public abstract void onRotateLocked ()
A callback indicating that a user has rotated enough to be recognized as the two-finger rotation gesture.
public abstract boolean onTapEvent (PointF p)
A callback indicating that a user has performed a single-tap gesture on a map.
public abstract boolean onTiltEvent (float angle)
A callback indicating that a user has performed a two-finger-tilt gesture on a map.
public abstract boolean onTwoFingerTapEvent (PointF p)
A callback indicating that a user has performed a two-finger tap gesture on a map.
Interface Details
Event Listener interface for gesture events. Please use MapGesture.OnGestureListener if all events are
necessary and MapGesture.OnGestureListener.OnGestureListenerAdapter if some events are required. This
interface can be added via addOnGestureListener(MapGesture.OnGestureListener, int, boolean) and removed
via removeOnGestureListener(MapGesture.OnGestureListener) Please see MapGesture for a full set of
configurable APIs.
HERE Android SDK Developer's Guide
API Reference
983
Method Details
public abstract boolean onDoubleTapEvent (PointF p)
A callback indicating that a user has performed a double tap gesture on a map.
Parameters:
p
A PointF representing the on-screen point of the double-tap gesture
Returns:
True if consumed (which prevents the default map zoom-in behavior), false otherwise
public abstract boolean onLongPressEvent (PointF p)
A callback indicating that a user has performed a long-press gesture on a map.
If a MapMarker with dragging enabled is located at the same location, returning true for this method will
nullify that setting.
Parameters:
p
A PointF representing the on-screen point where a user has long-pressed
Returns:
True if consumed (which prevents the default map move-to-here behavior), false otherwise
See also:
setDraggable(boolean)
public abstract void onLongPressRelease ()
A callback indicating that a user has released a long-press gesture on a map.
This callback may also occur when the user has panned around the map.
public abstract boolean onMapObjectsSelected (java.util.List <ViewObject>
objects)
A callback indicating that at least one ViewObject has been selected as a result of a user tapping on the map.
If the user tapping on the map results in ViewObject selection (there are selectable objects located at the tap
point), this callback will be made after onTapEvent(PointF), if and only if, false is returned for that callback.
Note: If the user taps on an Android view in a MapOverlay, this method is triggered, but objects will be
populated with a list of substitute MapMarker objects. These markers have the same geocoordinates as the
map overlays. To avoid this behavior and these substitute markers, do not use this callback method. Instead,
use Android gesture handling on the MapOverlay subclass.
HERE Android SDK Developer's Guide
API Reference
984
Parameters:
objects
A list of selected ViewObject objects
Returns:
true if consumed, false otherwise
See also:
getSelectedObjectsNearby(PointF)
public abstract void onMultiFingerManipulationEnd ()
A callback indicating the user has removed all or all-except-one fingers from the screen.
public abstract void onMultiFingerManipulationStart ()
A callback indicating the user has put more than one finger onto the screen. Pinch, Rotate or Tilt
manipulation events may also be called back.
See also:
onTiltEvent(float)
onRotateEvent(float)
onPinchZoomEvent(float, PointF)
public abstract void onPanEnd ()
A callback indicating the user has lifted up their finger and stopped panning.
public abstract void onPanStart ()
A callback indicating the user has put one finger on the screen and moved their finger to trigger panning.
public abstract void onPinchLocked ()
A callback indicating that a user has pinched enough to be recognized as the two-finger zoom gesture. This
callback will only occur if MapGesture is set to exclusive mode from setRotateEnabled(boolean)
See also:
setRotateEnabled(boolean)
public abstract boolean onPinchZoomEvent (float scaleFactor, PointF p)
A callback indicating that a user has performed a pinch-to-zoom gesture on a map.
HERE Android SDK Developer's Guide
API Reference
985
Parameters:
scaleFactor
A scale factor relative to the points of the two simultaneous touches at separate screen coordinates
p
A PointF representing the on-screen point of the pinch gesture
Returns:
True if consumed (which prevents the default map zoom-in or zoom-out behavior), false otherwise
public abstract boolean onRotateEvent (float rotateAngle)
A callback indicating that a user has performed a rotate gesture on a map.
Parameters:
rotateAngle
An angle, in degrees, of the user interaction gesture since its last change
Returns:
True if consumed (which prevents the default map rotate-to-here behavior), false otherwise
public abstract void onRotateLocked ()
A callback indicating that a user has rotated enough to be recognized as the two-finger rotation gesture. This
callback will only occur if MapGesture is set to exclusive mode from setRotateEnabled(boolean)
See also:
setRotateEnabled(boolean)
public abstract boolean onTapEvent (PointF p)
A callback indicating that a user has performed a single-tap gesture on a map.
If true is returned from this callback, no onMapObjectsSelected(List) callback will be made to any gesture
subscribers even if any objects are found at the screen point.
Parameters:
p
A PointF representing the on-screen point of the single-tap gesture
Returns:
true if consumed (which prevents the default pan-to-here behavior), false otherwise.
See also:
getSelectedObjectsNearby(PointF)
HERE Android SDK Developer's Guide
API Reference
986
public abstract boolean onTiltEvent (float angle)
A callback indicating that a user has performed a two-finger-tilt gesture on a map.
Parameters:
angle
An angle, in degrees between the range of the minimum and maximum angle inclusively, to which the
map tilt will change. The minimum and maximum angle can be retrieved thru the calls getMinTilt() and
getMaxTilt().
Returns:
True if consumed (which prevents the default map tilt-to-here behavior), false otherwise
See also:
getMaxTilt()
getMinTilt()
public abstract boolean onTwoFingerTapEvent (PointF p)
A callback indicating that a user has performed a two-finger tap gesture on a map.
Parameters:
p
A PointF representing the on-screen point where the two-finger tap occurred
Returns:
True if consumed (which prevents the default map zoom-out behavior), false otherwise
OnGestureListenerAdapter
The class OnGestureListenerAdapter is a member of
com.here.android.mpa.mapping.MapGesture.OnGestureListener.
Class Summary
public static abstract class MapGesture.OnGestureListener.OnGestureListenerAdapter
implements com.here.android.mpa.mapping.MapGesture.OnGestureListener
extends java.lang.Object
Default implementation for the OnGestureListener interface.
[For complete information, see the section Class Details]
See also:
MapGesture.OnGestureListener
HERE Android SDK Developer's Guide
API Reference
987
Constructor Summary
Table 481: Constructors in OnGestureListenerAdapter
Constructors
OnGestureListenerAdapter ()
Method Summary
Table 482: Methods in OnGestureListenerAdapter
Methods
public boolean onDoubleTapEvent (PointF p)
A callback indicating that a user has performed a double tap gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onDoubleTapEvent(PointF)
public boolean onLongPressEvent (PointF p)
A callback indicating that a user has performed a long-press gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onLongPressEvent(PointF)
public void onLongPressRelease ()
A callback indicating that a user has released a long-press gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onLongPressRelease(void)
public boolean onMapObjectsSelected (java.util.List <ViewObject> objects)
A callback indicating that at least one ViewObject has been selected as a result of a user tapping on the map.
This method overrides mapping.MapGesture.OnGestureListener.onMapObjectsSelected(List)
public void onMultiFingerManipulationEnd ()
A callback indicating the user has removed all or all-except-one fingers from the screen.
This method overrides mapping.MapGesture.OnGestureListener.onMultiFingerManipulationEnd(void)
public void onMultiFingerManipulationStart ()
A callback indicating the user has put more than one finger onto the screen.
This method overrides mapping.MapGesture.OnGestureListener.onMultiFingerManipulationStart(void)
public void onPanEnd ()
A callback indicating the user has lifted up their finger and stopped panning.
This method overrides mapping.MapGesture.OnGestureListener.onPanEnd(void)
public void onPanStart ()
A callback indicating the user has put one finger on the screen and moved their finger to trigger panning.
This method overrides mapping.MapGesture.OnGestureListener.onPanStart(void)
public void onPinchLocked ()
A callback indicating that a user has pinched enough to be recognized as the two-finger zoom gesture.
This method overrides mapping.MapGesture.OnGestureListener.onPinchLocked(void)
HERE Android SDK Developer's Guide
API Reference
988
Methods
public boolean onPinchZoomEvent (float scaleFactor, PointF p)
A callback indicating that a user has performed a pinch-to-zoom gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onPinchZoomEvent(float, PointF)
public boolean onRotateEvent (float rotateAngle)
A callback indicating that a user has performed a rotate gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onRotateEvent(float)
public void onRotateLocked ()
A callback indicating that a user has rotated enough to be recognized as the two-finger rotation gesture.
This method overrides mapping.MapGesture.OnGestureListener.onRotateLocked(void)
public boolean onTapEvent (PointF p)
A callback indicating that a user has performed a single-tap gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onTapEvent(PointF)
public boolean onTiltEvent (float angle)
A callback indicating that a user has performed a two-finger-tilt gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onTiltEvent(float)
public boolean onTwoFingerTapEvent (PointF p)
A callback indicating that a user has performed a two-finger tap gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onTwoFingerTapEvent(PointF)
Class Details
Default implementation for the OnGestureListener interface. Users may use this abstract class and overload
specific methods to have a smaller code footprint.
See also:
MapGesture.OnGestureListener
Constructor Details
OnGestureListenerAdapter ()
Method Details
public boolean onDoubleTapEvent (PointF p)
A callback indicating that a user has performed a double tap gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onDoubleTapEvent(PointF)
Parameters:
p
HERE Android SDK Developer's Guide
API Reference
989
public boolean onLongPressEvent (PointF p)
A callback indicating that a user has performed a long-press gesture on a map.
If a MapMarker with dragging enabled is located at the same location, returning true for this method will
nullify that setting.
This method overrides mapping.MapGesture.OnGestureListener.onLongPressEvent(PointF)
Parameters:
p
public void onLongPressRelease ()
A callback indicating that a user has released a long-press gesture on a map.
This callback may also occur when the user has panned around the map.
This method overrides mapping.MapGesture.OnGestureListener.onLongPressRelease(void)
public boolean onMapObjectsSelected (java.util.List <ViewObject> objects)
A callback indicating that at least one ViewObject has been selected as a result of a user tapping on the map.
If the user tapping on the map results in ViewObject selection (there are selectable objects located at the tap
point), this callback will be made after onTapEvent(PointF), if and only if, false is returned for that callback.
Note: If the user taps on an Android view in a MapOverlay, this method is triggered, but objects will be
populated with a list of substitute MapMarker objects. These markers have the same geocoordinates as the
map overlays. To avoid this behavior and these substitute markers, do not use this callback method. Instead,
use Android gesture handling on the MapOverlay subclass.
This method overrides mapping.MapGesture.OnGestureListener.onMapObjectsSelected(List)
Parameters:
objects
public void onMultiFingerManipulationEnd ()
A callback indicating the user has removed all or all-except-one fingers from the screen.
This method overrides mapping.MapGesture.OnGestureListener.onMultiFingerManipulationEnd(void)
public void onMultiFingerManipulationStart ()
A callback indicating the user has put more than one finger onto the screen. Pinch, Rotate or Tilt
manipulation events may also be called back.
This method overrides mapping.MapGesture.OnGestureListener.onMultiFingerManipulationStart(void)
HERE Android SDK Developer's Guide
API Reference
990
public void onPanEnd ()
A callback indicating the user has lifted up their finger and stopped panning.
This method overrides mapping.MapGesture.OnGestureListener.onPanEnd(void)
public void onPanStart ()
A callback indicating the user has put one finger on the screen and moved their finger to trigger panning.
This method overrides mapping.MapGesture.OnGestureListener.onPanStart(void)
public void onPinchLocked ()
A callback indicating that a user has pinched enough to be recognized as the two-finger zoom gesture. This
callback will only occur if MapGesture is set to exclusive mode from setRotateEnabled(boolean)
This method overrides mapping.MapGesture.OnGestureListener.onPinchLocked(void)
public boolean onPinchZoomEvent (float scaleFactor, PointF p)
A callback indicating that a user has performed a pinch-to-zoom gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onPinchZoomEvent(float, PointF)
Parameters:
scaleFactor
p
public boolean onRotateEvent (float rotateAngle)
A callback indicating that a user has performed a rotate gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onRotateEvent(float)
Parameters:
rotateAngle
public void onRotateLocked ()
A callback indicating that a user has rotated enough to be recognized as the two-finger rotation gesture. This
callback will only occur if MapGesture is set to exclusive mode from setRotateEnabled(boolean)
This method overrides mapping.MapGesture.OnGestureListener.onRotateLocked(void)
public boolean onTapEvent (PointF p)
HERE Android SDK Developer's Guide
API Reference
991
A callback indicating that a user has performed a single-tap gesture on a map.
If true is returned from this callback, no onMapObjectsSelected(List) callback will be made to any gesture
subscribers even if any objects are found at the screen point.
This method overrides mapping.MapGesture.OnGestureListener.onTapEvent(PointF)
Parameters:
p
public boolean onTiltEvent (float angle)
A callback indicating that a user has performed a two-finger-tilt gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onTiltEvent(float)
Parameters:
angle
public boolean onTwoFingerTapEvent (PointF p)
A callback indicating that a user has performed a two-finger tap gesture on a map.
This method overrides mapping.MapGesture.OnGestureListener.onTwoFingerTapEvent(PointF)
Parameters:
p
MapLabeledMarker
The class MapLabeledMarker is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapLabeledMarker
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
This class represents a labeled icon on the Map.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
992
Constructor Summary
Table 483: Constructors in MapLabeledMarker
Constructors
MapLabeledMarker (GeoCoordinate loc)
Creates a MapLabeledMarker at a specific GeoCoordinate with a default POI icon.
MapLabeledMarker (GeoCoordinate loc, Image icon)
Creates a MapLabeledMarker at a specific GeoCoordinate with the specified Image.
Method Summary
Table 484: Methods in MapLabeledMarker
Methods
public PointF getAnchorPoint ()
Returns the anchor point for this MapLabeledMarker .
public GeoCoordinate getCoordinate ()
Returns the current GeoCoordinate for this MapLabeledMarker .
public float getFontScalingFactor ()
This method get the current font scaling factor applied to draw the fonts.
public String getLabelText (String marcCode)
This method retrieves the localized text of the MapLabeledMarker .
public float getTransparency ()
Gets the current transparency for the icon.
public boolean isDeclutteringEnabled ()
This method queries if the icon decluttering is enabled.
public boolean isFadingAnimationEnabled ()
This method queries whether fading animation is enabled for the label.
public boolean isOverlappingEnabled ()
This method queries if icons can be rendered overlapping the labels in the map if they share a common screen area.
public MapLabeledMarker setAnchorPoint (PointF anchor)
Sets an anchor point for this MapLabeledMarker .
public MapLabeledMarker setCoordinate (GeoCoordinate value)
Sets a GeoCoordinate for this MapLabeledMarker .
public MapLabeledMarker setDeclutteringEnabled (boolean enabled)
This method enables or disables decluttering in tilted view.
public MapLabeledMarker setFadingAnimationEnabled (boolean enabled)
This method enables or disables fading animation for the label.
HERE Android SDK Developer's Guide
API Reference
993
Methods
public MapLabeledMarker setFontScalingFactor (float value)
This method set the new font scaling factor will be applied to draw the fonts.
public MapLabeledMarker setIcon (IconCategory value)
Sets this MapLabeledMarker to use the default places category icon of the specified IconCategory.
public MapLabeledMarker setIcon (Image icon)
Sets an icon image for this MapLabeledMarker .
public MapLabeledMarker setLabelText (String marcCode, String text)
This method sets the localized text of the MapLabeledMarker .
public MapLabeledMarker setOverlappingEnabled (boolean enabled)
This method enables or disables labels rendered later in the map to overlap on the icon if they share a common screen
area.
public MapLabeledMarker setTransparency (float value)
Sets a transparency level, within the range of [0..1], for the icon.
Class Details
This class represents a labeled icon on the Map.
Different from MapMarkers, the MapLabeledMarker s avoid overlapping with other user-defined labeled
icons as well as built-in icons and texts on the map. It provides the possibility of using built-in POI icons by
specifying a IconCategory or using an Image. One can specify multilingual texts to the icon. Depending on the
current language and secondary language of Map , different language of text can be displayed.
Constructor Details
MapLabeledMarker (GeoCoordinate loc)
Creates a MapLabeledMarker at a specific GeoCoordinate with a default POI icon.
Parameters:
loc
A GeoCoordinate representing this marker's location.
Throws:
IllegalArgumentException
if loc is invalid.
MapLabeledMarker (GeoCoordinate loc, Image icon)
Creates a MapLabeledMarker at a specific GeoCoordinate with the specified Image.
Parameters:
loc
HERE Android SDK Developer's Guide
API Reference
994
A GeoCoordinate representing this marker's location.
icon
An Image representing this marker's icon.
Throws:
IllegalArgumentException
if loc or icon is invalid.
Method Details
public PointF getAnchorPoint ()
Returns the anchor point for this MapLabeledMarker .
The marker is drawn with the specified pixel offset from its getCoordinate() position. To clear an anchor set
previously, pass a PointF to this method with an X-coordinate equal to half the width of the marker and a
Y-coordinate equal to half the height of the marker.
By default, there is no offset and the MapLabeledMarker is centered in the center of the icon image.
Returns:
The anchor point for this MapLabeledMarker.
public GeoCoordinate getCoordinate ()
Returns the current GeoCoordinate for this MapLabeledMarker .
Returns:
The current GeoCoordinate location
public float getFontScalingFactor ()
This method get the current font scaling factor applied to draw the fonts.
Returns:
A float value representing the current font factor. If the value cannot be retrieved, returns -1.
public String getLabelText (String marcCode)
This method retrieves the localized text of the MapLabeledMarker .
For more information about MARC code, see http://www.loc.gov/marc/languages.
Parameters:
marcCode
The international MARC code describing the language of the text. Case-insensitive.
HERE Android SDK Developer's Guide
API Reference
995
Returns:
The text for the marker corresponds to the language MARC code.
Throws:
IllegalArgumentException
if invalid marcCode provided.
public float getTransparency ()
Gets the current transparency for the icon.
The transparency level is only precise to two decimal places due to numerical operations performed
internally when rendering the map.
Returns:
The current transparency of the icon
public boolean isDeclutteringEnabled ()
This method queries if the icon decluttering is enabled.
Returns:
true if the decluttering is enabled. Otherwise returns false.
public boolean isFadingAnimationEnabled ()
This method queries whether fading animation is enabled for the label.
Returns:
true if fading animation is enabled, false otherwise.
public boolean isOverlappingEnabled ()
This method queries if icons can be rendered overlapping the labels in the map if they share a common
screen area.
Returns:
true if icon overlapping is enabled, false otherwise.
public MapLabeledMarker setAnchorPoint (PointF anchor)
Sets an anchor point for this MapLabeledMarker .
The marker is drawn with the specified pixel offset from its getCoordinate() position. To clear an anchor set
previously, pass a PointF to this method with an X-coordinate equal to half the width of the marker and a
Y-coordinate equal to half the height of the marker.
HERE Android SDK Developer's Guide
API Reference
996
By default, there is no offset and the MapLabeledMarker is centered in the center of the icon image.
Parameters:
anchor
A PointF relative to the top-left corner of the MapLabeledMarker.
Returns:
The updated MapLabeledMarker itself.
public MapLabeledMarker setCoordinate (GeoCoordinate value)
Sets a GeoCoordinate for this MapLabeledMarker .
Parameters:
value
Desired GeoCoordinate location for this marker.
Returns:
The updated MapLabeledMarker itself.
Throws:
IllegalArgumentException
if value is invalid.
public MapLabeledMarker setDeclutteringEnabled (boolean enabled)
This method enables or disables decluttering in tilted view. By enabling this, icons will not be shown when
they are faraway in tilted view. By default, decluttering is disabled.
Parameters:
enabled
true means enabling icon decluttering.
Returns:
The updated MapLabeledMarker itself.
public MapLabeledMarker setFadingAnimationEnabled (boolean enabled)
This method enables or disables fading animation for the label. However, the fading animation set using
setFadingAnimations(boolean) takes priority over this setting. For example, if the fading animation is
disabled for the Map, which contains the label, the fading will be also disabled for the label regardless the
state set to this label.
Fading animation is enabled by default.
Parameters:
HERE Android SDK Developer's Guide
API Reference
997
enabled
true to enable fading animation.
Returns:
The updated MapLabeledMarker itself.
public MapLabeledMarker setFontScalingFactor (float value)
This method set the new font scaling factor will be applied to draw the fonts.
Parameters:
value
A floating point value representing the new font factor. Valid values must be between 1.0 and 2.0.
Returns:
The updated MapLabeledMarker itself.
Throws:
IllegalArgumentException
if invalid value provided is out of range.
public MapLabeledMarker setIcon (IconCategory value)
Sets this MapLabeledMarker to use the default places category icon of the specified IconCategory.
If no icon is available for the specified IconCategory , a default icon will be used.
Parameters:
value
An IconCategory of the icon to be used for the marker.
Returns:
The updated MapLabeledMarker itself.
public MapLabeledMarker setIcon (Image icon)
Sets an icon image for this MapLabeledMarker .
Parameters:
icon
An Image representing this marker's icon
Returns:
The updated MapLabeledMarker itself.
Throws:
HERE Android SDK Developer's Guide
API Reference
998
IllegalArgumentException
if icon is invalid.
public MapLabeledMarker setLabelText (String marcCode, String text)
This method sets the localized text of the MapLabeledMarker . If there is an existing localization for the
specified language, the existing one will be replaced. Otherwise, the new localized text will be stored. When
text is an empty string, the existing localized text, if any, will be removed.
If the text contains any glyphs, which are currently not supported by the fonts shipped with the library, those
glyphs will not be displayed.
The text label may not be displayed in certain Schemes to ensure scheme-specific visual effects are
unaffected.
For more information about MARC code, see http://www.loc.gov/marc/languages.
Parameters:
marcCode
The international MARC code describing the language of the text. Case-insensitive.
text
The text for the marker in the language described by the marcCode.
Returns:
The updated MapLabeledMarker itself.
Throws:
IllegalArgumentException
if invalid marcCode provided.
public MapLabeledMarker setOverlappingEnabled (boolean enabled)
This method enables or disables labels rendered later in the map to overlap on the icon if they share a
common screen area. By default, overlapping is enabled.
Parameters:
enabled
true to enable icon overlapping, false otherwise.
Returns:
The updated MapLabeledMarker itself.
public MapLabeledMarker setTransparency (float value)
Sets a transparency level, within the range of [0..1], for the icon. By default, transparency level is 1.
Parameters:
HERE Android SDK Developer's Guide
API Reference
999
value
Desired alpha value for the icon, 0 for fully transparent, 1 for fully opaque.
Returns:
The updated MapLabeledMarker itself.
Throws:
IllegalArgumentException
if value is out of range.
MapLocalModel
The class MapLocalModel is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapLocalModel
extends com.here.android.mpa.mapping.MapModelObject, com.here.android.mpa.mapping.MapObject,
com.here.android.mpa.common.ViewObject, java.lang.Object
Represents a relative local coordinate mesh displayed on a map.
[For complete information, see the section Class Details]
See also:
LocalMesh
MapGeoModel
Constructor Summary
Table 485: Constructors in MapLocalModel
Constructors
MapLocalModel ()
Creates a MapLocalModel .
Method Summary
Table 486: Methods in MapLocalModel
Methods
public GeoCoordinate getAnchor ()
Gets the GeoCoordinate representing the anchor that is currently associated with the MapLocalModel .
public LocalMesh getMesh ()
Gets the LocalMesh currently associated with the MapLocalModel .
HERE Android SDK Developer's Guide
API Reference
1000
Methods
public float getPitch ()
Gets the current pitch of the MapLocalModel .
public float getRoll ()
Gets the current roll or the MapLocalModel .
public float getScale ()
Gets the current scaling factor for the LocalMesh.
public Image getTexture ()
Gets the current texture Image of the MapLocalModel .
public float getYaw ()
Gets the current yaw of the MapLocalModel .
public boolean isDynamicScalingEnabled ()
Gets the boolean indicating whether dynamic scaling is enabled for the MapLocalModel .
public MapLocalModel setAnchor (GeoCoordinate anchor)
Sets an anchor GeoCoordinate for the MapLocalModel .
public MapLocalModel setDynamicScalingEnabled (boolean enable)
Sets dynamic scaling to be either enabled or disabled for the MapLocalModel .
public MapLocalModel setMesh (LocalMesh mesh)
Sets a LocalMesh for the MapLocalModel
public MapLocalModel setPitch (float angle)
Sets a pitch value for the MapLocalModel .
public MapLocalModel setRoll (float angle)
Sets a roll value for the MapLocalModel .
public MapLocalModel setScale (float scale)
Sets a scaling factor used to scale the size of the LocalMesh.
public MapLocalModel setTexture (Image texture)
Sets a texture Image for the MapLocalModel .
public MapLocalModel setYaw (float angle)
Sets a yaw value for the MapLocalModel .
Class Details
Represents a relative local coordinate mesh displayed on a map. The format for the mesh is interpreted as
an array of float offsets relative to the anchor, which itself specifies the center base of the objects.
A unit of 1.0f represents 1 meter in the real world. For example, a Vector3f( 100, 200, 300 )
represents a point offset by 100 meters in the x-axis direction (east), 200 meters in the y-axis direction
(north), and 300 meters in the z-axis direction (up), all relative to the anchor.
HERE Android SDK Developer's Guide
API Reference
1001
Note: a MapLocalModel object can be augmented by specifying additional attributes such as scale, scale
style, or rotation.
See also:
LocalMesh
MapGeoModel
Constructor Details
MapLocalModel ()
Creates a MapLocalModel .
Method Details
public GeoCoordinate getAnchor ()
Gets the GeoCoordinate representing the anchor that is currently associated with the MapLocalModel .
Returns:
The GeoCoordinate
public LocalMesh getMesh ()
Gets the LocalMesh currently associated with the MapLocalModel .
Returns:
The LocalMesh
public float getPitch ()
Gets the current pitch of the MapLocalModel .
Returns:
The current pitch in degrees
public float getRoll ()
Gets the current roll or the MapLocalModel .
Returns:
The current roll in degrees
public float getScale ()
HERE Android SDK Developer's Guide
API Reference
1002
Gets the current scaling factor for the LocalMesh.
Returns:
The current scaling factor
public Image getTexture ()
Gets the current texture Image of the MapLocalModel .
Returns:
The texture Image
public float getYaw ()
Gets the current yaw of the MapLocalModel .
Returns:
The current yaw in degrees
public boolean isDynamicScalingEnabled ()
Gets the boolean indicating whether dynamic scaling is enabled for the MapLocalModel .
Returns:
True if dynamic scaling is enabled, false otherwise
public MapLocalModel setAnchor (GeoCoordinate anchor)
Sets an anchor GeoCoordinate for the MapLocalModel .
Parameters:
anchor
Desired GeoCoordinate
Returns:
The modified MapLocalModel itself.
public MapLocalModel setDynamicScalingEnabled (boolean enable)
Sets dynamic scaling to be either enabled or disabled for the MapLocalModel . When dynamic scaling is
enabled, the rendered size of the model on screen is constant regardless of the map's zoom level.
Parameters:
enable
A boolean specifying whether dynamic scaling is enabled
HERE Android SDK Developer's Guide
API Reference
1003
Returns:
The modified MapLocalModel itself.
public MapLocalModel setMesh (LocalMesh mesh)
Sets a LocalMesh for the MapLocalModel
Parameters:
mesh
Desired LocalMesh
Returns:
The modified MapLocalModel itself.
public MapLocalModel setPitch (float angle)
Sets a pitch value for the MapLocalModel .
Parameters:
angle
Desired pitch in degrees
Returns:
The modified MapLocalModel itself.
public MapLocalModel setRoll (float angle)
Sets a roll value for the MapLocalModel .
Parameters:
angle
Desired roll in degrees
Returns:
The modified
public MapLocalModel setScale (float scale)
Sets a scaling factor used to scale the size of the LocalMesh.
Note: The effect of scale on the model size varies significantly depending on whether or not dynamic scaling
is enabled and the magnitude of the model vertices. Therefore, depending on these factors you may have to
tweak the scale (by orders of magnitude perhaps) to get a model of the same relative size as another.
Parameters:
scale
HERE Android SDK Developer's Guide
API Reference
1004
Desired scaling factor
Returns:
The modified MapLocalModel itself.
See also:
setDynamicScalingEnabled(boolean)
public MapLocalModel setTexture (Image texture)
Sets a texture Image for the MapLocalModel .
Parameters:
texture
Desired texture Image
Returns:
The modified MapLocalModel itself.
public MapLocalModel setYaw (float angle)
Sets a yaw value for the MapLocalModel .
Parameters:
angle
Desired yaw in degrees
Returns:
The modified MapLocalModel itself.
MapMarker
The class MapMarker is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapMarker
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a marker used to display an icon at a geographical position on a map.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1005
Nested Class Summary
Table 487: Nested Classes in MapMarker
Nested Classes
public static abstract interface MapMarker.OnDragListener
Callback interface for drag events on MapMarker objects.
Constructor Summary
Table 488: Constructors in MapMarker
Constructors
MapMarker ()
Creates a default MapMarker.
MapMarker (float hue)
Creates a default MapMarker.
MapMarker (GeoCoordinate coordinate, Image image)
Creates a MapMarker with a specified GeoCoordinate and Image.
Method Summary
Table 489: Methods in MapMarker
Methods
public PointF getAnchorPoint ()
Returns the anchor point for this MapMarker .
public GeoCoordinate getCoordinate ()
Returns the current map GeoCoordinate for this MapMarker .
public String getDescription ()
Gets the current description text.
public Image getIcon ()
Returns the icon image for this MapMarker .
public int getInfoBubbleHashCode ()
Deprecated: Deprecated as of version 3.6.
Returns non-zero hash code of the info bubble if it is showing.
public float getSvgIconScaling ()
Get the scaling factor for markers using SVG Image .
public String getTitle ()
Gets the current title to be used by the default info bubble.
HERE Android SDK Developer's Guide
API Reference
1006
Methods
public float getTransparency ()
Gets the current transparency for the icon
public boolean isDeclutteringEnabled ()
This method queries if the icon decluttering is enabled.
public boolean isDraggable ()
Returns a boolean indicating whether the marker is draggable.
public boolean isInfoBubbleVisible ()
Deprecated: Deprecated as of version 3.6.
Returns a boolean indicating if the info bubble is currently displayed on this marker.
public MapMarker setAnchorPoint (PointF anchor)
Sets an anchor point for this MapMarker .
public MapMarker setCoordinate (GeoCoordinate coordinate)
Sets a map GeoCoordinate for this MapMarker .
public MapMarker setDeclutteringEnabled (boolean enabled)
This method enables or disables decluttering in tilted view.
public MapMarker setDescription (String description)
Sets the description text.
public MapMarker setDraggable (boolean isDraggable)
Sets whether this marker is draggable or not.
public MapMarker setIcon (Image icon)
Sets an icon image for this MapMarker .
public boolean setSvgIconScaling (float scale)
Set a scaling factor for markers using SVG Image .
public MapMarker setTitle (String title)
Sets a title to be used by the default info bubble.
public boolean setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the icon.
Class Details
Represents a marker used to display an icon at a geographical position on a map. The map handles proper
placement of icons on the screen as well as panning and rotation.
MapMarker objects can be selected by application users.
Constructor Details
MapMarker ()
HERE Android SDK Developer's Guide
API Reference
1007
Creates a default MapMarker. The marker will contain the default marker image.
See also:
MapMarker(float)
MapMarker(GeoCoordinate, Image)
MapMarker (float hue)
Creates a default MapMarker. The marker will contain a colorization of the default marker image.
Parameters:
hue
The hue of the marker. Value must be greater or equal to 0 and less than 360.
Throws:
IllegalArgumentException
For hue values outside the acceptable range.
See also:
MapMarker()
MapMarker(GeoCoordinate, Image)
MapMarker (GeoCoordinate coordinate, Image image)
Creates a MapMarker with a specified GeoCoordinate and Image.
Parameters:
coordinate
A GeoCoordinate representing the map coordinates of the marker
image
An Image used to display the marker
See also:
MapMarker()
MapMarker(float)
Method Details
public PointF getAnchorPoint ()
Returns the anchor point for this MapMarker .
HERE Android SDK Developer's Guide
API Reference
1008
The marker is drawn with the specified pixel offset from its getCoordinate() position. To clear an anchor set
previously, pass a PointF to this method with an X-coordinate equal to half the width of the marker and a
Y-coordinate equal to half the height of the marker.
By default, there is no offset and the MapMarker is centered in the center of the icon image.
Returns:
The anchor point for this MapMarker.
public GeoCoordinate getCoordinate ()
Returns the current map GeoCoordinate for this MapMarker .
Returns:
The current GeoCoordinate location
public String getDescription ()
Gets the current description text.
Returns:
The current description. Can be null if it has not been set.
public Image getIcon ()
Returns the icon image for this MapMarker .
Returns:
An Image representing this marker's icon
public int getInfoBubbleHashCode ()
Deprecated: Deprecated as of version 3.6.
Always returns 0. Use MapOverlay instead.
Returns non-zero hash code of the info bubble if it is showing.
Use this hash code to compare against the hash code of the objects returned by onMapObjectsSelected(List)
to determine if object selected is an info bubble.
Returns:
The hash code of the info bubble that is visible. 0 if the info bubble is not showing.
See also:
onMapObjectsSelected(List<ViewObject>)
public float getSvgIconScaling ()
HERE Android SDK Developer's Guide
API Reference
1009
Get the scaling factor for markers using SVG Image .
Returns:
scale
public String getTitle ()
Gets the current title to be used by the default info bubble.
Returns:
The current title. Can be null if it has not been set.
public float getTransparency ()
Gets the current transparency for the icon
The transparency level is only precise to two decimal places due to numerical operations performed
internally when rendering the map.
Returns:
The current transparency of the icon
public boolean isDeclutteringEnabled ()
This method queries if the icon decluttering is enabled.
Returns:
True if the decluttering is enabled. Otherwise return false.
public boolean isDraggable ()
Returns a boolean indicating whether the marker is draggable.
Returns:
True if the marker is draggable, false otherwise.
public boolean isInfoBubbleVisible ()
Deprecated: Deprecated as of version 3.6.
Always returns false. Use MapOverlay instead.
Returns a boolean indicating if the info bubble is currently displayed on this marker.
Returns:
True if the info bubble is displayed, false otherwise.
HERE Android SDK Developer's Guide
API Reference
1010
public MapMarker setAnchorPoint (PointF anchor)
Sets an anchor point for this MapMarker .
The marker is drawn with the specified pixel offset from its getCoordinate() position. To clear an anchor set
previously, pass a PointF to this method with an X-coordinate equal to half the width of the marker and a
Y-coordinate equal to half the height of the marker.
By default, there is no offset and the MapMarker is centered in the center of the icon image.
Parameters:
anchor
A PointF relative to the top-left corner of the MapMarker.
Returns:
The updated MapMarker itself.
public MapMarker setCoordinate (GeoCoordinate coordinate)
Sets a map GeoCoordinate for this MapMarker .
Parameters:
coordinate
Desired GeoCoordinate location for this marker
Returns:
The updated MapMarker itself.
public MapMarker setDeclutteringEnabled (boolean enabled)
This method enables or disables decluttering in tilted view. By enabling this, icons will not be shown when
they are faraway in tilted view. By default, decluttering is disabled.
Parameters:
enabled
true means enabling icon decluttering.
Returns:
The updated MapMarker itself.
public MapMarker setDescription (String description)
Sets the description text. This will be shown below the title in normal typeface.
Parameters:
description
The description to be set.
HERE Android SDK Developer's Guide
API Reference
1011
Returns:
The updated MapMarker itself.
public MapMarker setDraggable (boolean isDraggable)
Sets whether this marker is draggable or not. By default, the marker is not draggable.
If any user overridden methods of onLongPressEvent(PointF) or onDoubleTapEvent(PointF) that is registered
with MapGesture returns true , the MapMarker will ignore any drag events even if the marker is set to
enable dragging.
Parameters:
isDraggable
true if the marker is draggable, false otherwise.
Returns:
The updated MapMarker itself.
See also:
MapGesture
public MapMarker setIcon (Image icon)
Sets an icon image for this MapMarker .
Parameters:
icon
An Image representing this marker's icon
Returns:
The updated MapMarker itself.
public boolean setSvgIconScaling (float scale)
Set a scaling factor for markers using SVG Image . Only works with scales from 1.0 to 2.0 inclusive.
Parameters:
scale
Scaling factor.
Returns:
true if the scaling factor has been applied (number from 1.0 to 2.0), false otherwise.
public MapMarker setTitle (String title)
Sets a title to be used by the default info bubble.
HERE Android SDK Developer's Guide
API Reference
1012
Parameters:
title
The title to set.
Returns:
The updated MapMarker itself.
public boolean setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the icon.
Parameters:
alpha
Desired alpha value for the icon, 0 for fully transparent, 1 for fully opaque (the default value is 1)
Returns:
True if successful, false otherwise.
OnDragListener
The interface OnDragListener is a member of com.here.android.mpa.mapping.MapMarker.
Interface Summary
public static abstract interface MapMarker.OnDragListener
Callback interface for drag events on MapMarker objects.
[For complete information, see the section Interface Details]
Method Summary
Table 490: Methods in OnDragListener
Methods
public abstract void onMarkerDrag (MapMarker marker)
Called repeatedly while a marker is being dragged.
public abstract void onMarkerDragEnd (MapMarker marker)
Called when a marker has finished being dragged.
public abstract void onMarkerDragStart (MapMarker marker)
Called when a marker starts being dragged.
HERE Android SDK Developer's Guide
API Reference
1013
Interface Details
Callback interface for drag events on MapMarker objects.
Method Details
public abstract void onMarkerDrag (MapMarker marker)
Called repeatedly while a marker is being dragged. The MapMarker 's location can be accessed through
getCoordinate().
Parameters:
marker
The MapMarker that is being dragged.
public abstract void onMarkerDragEnd (MapMarker marker)
Called when a marker has finished being dragged. The MapMarker 's location can be accessed through
getCoordinate().
Parameters:
marker
The MapMarker that is being dragged.
public abstract void onMarkerDragStart (MapMarker marker)
Called when a marker starts being dragged. The MapMarker 's location can be accessed via getCoordinate().
This position may be different to the position prior to the start of the drag because the marker is popped up
above the touch point.
Parameters:
marker
The MapMarker that is being dragged.
MapModelObject
The class MapModelObject is a member of com.here.android.mpa.mapping .
Class Summary
public class MapModelObject
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Base class for MapLocalModel and MapGeoModel.
HERE Android SDK Developer's Guide
API Reference
1014
[For complete information, see the section Class Details]
Nested Class Summary
Table 491: Nested Classes in MapModelObject
Nested Classes
public static final class MapModelObject.DirectionalLight
This class specifies a directional light.
public static abstract interface MapModelObject.Light
Base Interface for all Lights supported by MapModel This class will be extended in the new future with more methods.
public static abstract interface MapModelObject.Material
Base Interface for all Materials supported by MapModel This class will be extended in future with more methods.
public static final class MapModelObject.PhongMaterial
PhongMaterial is used for shading a model.
Method Summary
Table 492: Methods in MapModelObject
Methods
public static int ARGBToRGBA (int color)
Simple color converter.
public static int RGBAToARGB (int color)
Simple color converter.
public boolean addLight (Light light)
Add a light to the object.
public Light getLight (int index)
Get an already added Light
public Material getMaterial ()
Get the Material
public int getNumLights ()
Get the number of lights.
public int getNumberLightsSupported ()
Get the maximum number of lights supported.
public boolean removeAllLights ()
Remove all lights from this model object.
public boolean setLight (int index, Light light)
Update the light for a particular light
HERE Android SDK Developer's Guide
API Reference
1015
Methods
public boolean setMaterial (Material material)
Set the Material
Class Details
Base class for MapLocalModel and MapGeoModel. This class provides additional functionalities to set lighting
and material properties to a model object.
Method Details
public static int ARGBToRGBA (int color)
Simple color converter. Converts from ARGB to RGBA.
Parameters:
color
Color to be converted.
Returns:
Color in RGBA.
public static int RGBAToARGB (int color)
Simple color converter. Converts from RRGB to ARGB.
Parameters:
color
Color to be converted.
Returns:
Color in ARGB.
public boolean addLight (Light light)
Add a light to the object.
Parameters:
light
New light to add.
Returns:
true if successful, false otherwise.
See also:
getNumberLightsSupported()
HERE Android SDK Developer's Guide
API Reference
1016
public Light getLight (int index)
Get an already added Light
Parameters:
index
Index of the light to get
Returns:
Light object if successful
public Material getMaterial ()
Get the Material
Returns:
Material object.
public int getNumLights ()
Get the number of lights.
Returns:
int, number of lights.
public int getNumberLightsSupported ()
Get the maximum number of lights supported.
Returns:
int maximum light count.
public boolean removeAllLights ()
Remove all lights from this model object.
Returns:
true if the operation was successful.
public boolean setLight (int index, Light light)
Update the light for a particular light
Parameters:
index
HERE Android SDK Developer's Guide
API Reference
1017
Index of the light to update
light
Light object to update
Returns:
true if successful, false otherwise.
public boolean setMaterial (Material material)
Set the Material
Parameters:
material
Material to be used.
Returns:
boolean true if successful, false otherwise.
DirectionalLight
The class DirectionalLight is a member of com.here.android.mpa.mapping.MapModelObject.
Class Summary
public static final class MapModelObject.DirectionalLight
implements com.here.android.mpa.mapping.MapModelObject.Light
extends java.lang.Object
This class specifies a directional light.
[For complete information, see the section Class Details]
Constructor Summary
Table 493: Constructors in DirectionalLight
Constructors
DirectionalLight ()
Default Constructor
DirectionalLight (Vector3f direction)
Construct a DirectionalLight.
HERE Android SDK Developer's Guide
API Reference
1018
Method Summary
Table 494: Methods in DirectionalLight
Methods
public Vector3f getSource ()
Get the directional light direction.
public void setSource (Vector3f direction)
Set the directional light source.
Class Details
This class specifies a directional light.
Constructor Details
DirectionalLight ()
Default Constructor
DirectionalLight (Vector3f direction)
Construct a DirectionalLight.
Parameters:
direction
The directional light direction.
Method Details
public Vector3f getSource ()
Get the directional light direction.
Returns:
Vector3d vector containing the light direction.
public void setSource (Vector3f direction)
Set the directional light source. This will only take effect before the light is added.
Parameters:
direction
The directional light direction.
HERE Android SDK Developer's Guide
API Reference
1019
Light
The interface Light is a member of com.here.android.mpa.mapping.MapModelObject.
Interface Summary
public static abstract interface MapModelObject.Light
Base Interface for all Lights supported by MapModel This class will be extended in the new future with more
methods.
[For complete information, see the section Interface Details]
Interface Details
Base Interface for all Lights supported by MapModel This class will be extended in the new future with more
methods.
Material
The interface Material is a member of com.here.android.mpa.mapping.MapModelObject.
Interface Summary
public static abstract interface MapModelObject.Material
Base Interface for all Materials supported by MapModel This class will be extended in future with more
methods.
[For complete information, see the section Interface Details]
Interface Details
Base Interface for all Materials supported by MapModel This class will be extended in future with more
methods.
PhongMaterial
The class PhongMaterial is a member of com.here.android.mpa.mapping.MapModelObject.
Class Summary
public static final class MapModelObject.PhongMaterial
implements com.here.android.mpa.mapping.MapModelObject.Material
extends java.lang.Object
PhongMaterial is used for shading a model.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1020
Constructor Summary
Table 495: Constructors in PhongMaterial
Constructors
PhongMaterial ()
Default constructor
PhongMaterial (int diffuseColor, int ambiantColor)
Field Summary
Table 496: Fields in PhongMaterial
Fields
public static final int DEFAULT_AMBIANT_COLOR
public static final int DEFAULT_DIFFUSE_COLOR
Method Summary
Table 497: Methods in PhongMaterial
Methods
public int getAmbientColor ()
Get the Ambient Material color
public int getDiffuseColor ()
Get the Diffuse Material color
public PhongMaterial setAmbientColor (int color)
Set the Ambient Material color
public PhongMaterial setDiffuseColor (int color)
Set the Diffuse Material color
Class Details
PhongMaterial is used for shading a model. This class can be used to change the transparency or color of
textured map models.
Constructor Details
PhongMaterial ()
Default constructor
PhongMaterial (int diffuseColor, int ambiantColor)
HERE Android SDK Developer's Guide
API Reference
1021
Parameters:
diffuseColor
ambiantColor
Field Details
public static final int DEFAULT_AMBIANT_COLOR
public static final int DEFAULT_DIFFUSE_COLOR
Method Details
public int getAmbientColor ()
Get the Ambient Material color
Returns:
color Color The color format is in ARGB
public int getDiffuseColor ()
Get the Diffuse Material color
Returns:
color Color
public PhongMaterial setAmbientColor (int color)
Set the Ambient Material color
Parameters:
color
Color The color format is in ARGB
Returns:
PhongMaterial builder pattern.
public PhongMaterial setDiffuseColor (int color)
Set the Diffuse Material color
Parameters:
color
HERE Android SDK Developer's Guide
API Reference
1022
Color
Returns:
PhongMaterial builder pattern.
MapObject
The class MapObject is a member of com.here.android.mpa.mapping .
Class Summary
public abstract class MapObject
extends com.here.android.mpa.common.ViewObject, java.lang.Object
Represents a base class for all map-related objects that users can add to a Map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 498: Nested Classes in MapObject
Nested Classes
public static final enumeration MapObject.Type
Represents values describing the types of MapObject objects that can be added to a Map.
Method Summary
Table 499: Methods in MapObject
Methods
public MapOverlayType getOverlayType ()
Returns the overlay in which this MapObject appears.
public MapContainer getParent ()
Returns the parent of this MapObject .
public MapOverlayType getReserveOverlayType ()
Returns the overlay in which this MapObject reserves screen space.
public Type getType ()
Returns the type of object that this MapObject represents.
public BitSet getVisibleMask ()
Returns the visibility bit mask of this MapObject
HERE Android SDK Developer's Guide
API Reference
1023
Methods
public int getZIndex ()
Returns the current z-index (stacking order) of this MapObject .
public boolean isVisible ()
Determines whether the visibility of this MapObject on the map is enabled.
public MapObject resetVisibleMask (boolean set)
Resets the entire visibility bit mask of this MapObject to be either 1s or 0s.
public MapObject setOverlayType (MapOverlayType type)
Sets the display order in which this MapObject appears relating to other layers of the map.
public MapObject setReserveOverlayType (MapOverlayType type)
Currently this method is only supported for MapLabeledMarker objects.
public MapObject setVisible (boolean isVisible)
Sets whether the visibility of the MapObject on the map is enabled.
public MapObject setVisibleMask (int level)
Sets this MapObject to be visible at the specified zoom level.
public MapObject setVisibleMask (int levelStart, int levelEnd)
Sets this MapObject to be visible for the specified range of zoom levels.
public MapObject setZIndex (int index)
Sets a z-index (stacking order) value for this MapObject .
public MapObject unsetVisibleMask (int level)
Sets this MapObject to be invisible at the specified zoom level by unsetting the visibility bit mask.
public MapObject unsetVisibleMask (int levelStart, int levelEnd)
Sets this MapObject to be invisible for the specified range of zoom levels by unsetting the visibility bit mask.
Class Details
Represents a base class for all map-related objects that users can add to a Map.
This abstract class serves as a base for several more specified map object types, bundling their common
properties. The types of map objects that you can add to a map include:
MapContainer
MapCircle
MapPolygon
MapPolyline
MapRoute
MapMarker
MapScreenMarker
MapLocalModel
MapGeoModel
HERE Android SDK Developer's Guide
API Reference
1024
Objects extending this class, with the exception of MapRoute and MapContainer, can be grouped within a
MapContainer instance.
For a complete enumeration of available MapObject types, refer to MapObject.Type.
Method Details
public MapOverlayType getOverlayType ()
Returns the overlay in which this MapObject appears.
Returns:
A MapOverlayType specifying the display grouping of the MapObject
public MapContainer getParent ()
Returns the parent of this MapObject .
Returns:
The parent MapContainer. If the current object is the root object, null is returned.
public MapOverlayType getReserveOverlayType ()
Returns the overlay in which this MapObject reserves screen space.
Returns:
A MapOverlayType specifying the display grouping of the MapObject
public Type getType ()
Returns the type of object that this MapObject represents.
Returns:
One of the MapObject.Type values
public BitSet getVisibleMask ()
Returns the visibility bit mask of this MapObject
Returns:
BitSet which defines the visibility bit mask of the MapObject
public int getZIndex ()
Returns the current z-index (stacking order) of this MapObject . A higher z-index indicates that the object is
positioned more in front.
HERE Android SDK Developer's Guide
API Reference
1025
Returns:
The current ordinal z-index number
public boolean isVisible ()
Determines whether the visibility of this MapObject on the map is enabled. Whether the MapObject is
actually visible depends on whether the visible mask is set for the desired zoom level.
Returns:
True if this MapObject is visible, false otherwise
See also:
setVisibleMask(int)
setVisibleMask(int, int)
unsetVisibleMask(int)
unsetVisibleMask(int, int)
getVisibleMask()
public MapObject resetVisibleMask (boolean set)
Resets the entire visibility bit mask of this MapObject to be either 1s or 0s. This method can only be used
after the MapObject has been added to the Map.
Note: The MapObject is visible at the specified zoom level only if the visibility of the MapObject is also set
to true via setVisible(boolean).
Parameters:
set
True to reset mask to all 1s; false to reset mask to all 0s
Returns:
The updated MapObject itself.
See also:
setVisible(boolean)
public MapObject setOverlayType (MapOverlayType type)
Sets the display order in which this MapObject appears relating to other layers of the map. Note that
this API only takes effect if the object is currently not added to a Map. To change the MapOverlayType, the
MapObject object must be removed and added from the map again.
Parameters:
type
HERE Android SDK Developer's Guide
API Reference
1026
A MapOverlayType specifying the display grouping of this MapObject
Returns:
The updated MapObject itself.
See also:
addMapObject(MapObject)
removeMapObject(MapObject)
public MapObject setReserveOverlayType (MapOverlayType type)
Currently this method is only supported for MapLabeledMarker objects.
It sets the reserve order in which this MapObject reserves screen space relating to other layers of the map.
When applied, the screen space around the label will be reserved for the layer and ensure the label can be
rendered without obstruction by other objects.
Note that this API only takes effect if the object is currently not added to a Map. To change the
MapOverlayType, the MapObject object must be removed and added from the map again.
Parameters:
type
A MapOverlayType specifying the display grouping of this MapObject
Returns:
The updated MapObject itself.
Throws:
IllegalArgumentException
if the MapObject is not a MapLabeledMarker object.
See also:
addMapObject(MapObject)
removeMapObject(MapObject)
public MapObject setVisible (boolean isVisible)
Sets whether the visibility of the MapObject on the map is enabled. Whether the MapObject is actually
visible depends on whether the visible mask is set for the desired zoom level.
This setting is independent but takes priority over the per-zoom level mask. For example, if you call
setVisibleMask(0, 6) and then call setVisible(false) , the object will not appear on the map.
Calling setVisible(true) will then cause the object to be visible in zoom levels 0 to 6.
Parameters:
isVisible
A boolean variable specifying whether this MapObject is visible
HERE Android SDK Developer's Guide
API Reference
1027
Returns:
The updated MapObject itself.
See also:
setVisibleMask(int)
setVisibleMask(int, int)
unsetVisibleMask(int)
unsetVisibleMask(int, int)
getVisibleMask()
public MapObject setVisibleMask (int level)
Sets this MapObject to be visible at the specified zoom level. The MapObject is only visible at the specified
zoom level only if the visibility of the MapObject is set to true via setVisible(boolean).
Setting the bit mask at a particular zoom level does not affect other levels. By default, the visibility bit masks
for all zoom levels are set to true.
Parameters:
level
A zoom level
Returns:
The updated MapObject itself.
See also:
setVisible(boolean)
setVisibleMask(int, int)
unsetVisibleMask(int)
unsetVisibleMask(int, int)
getVisibleMask()
public MapObject setVisibleMask (int levelStart, int levelEnd)
Sets this MapObject to be visible for the specified range of zoom levels. The MapObject is only
visible for the specified range of zoom levels only if the visibility of the MapObject is set to true via
setVisible(boolean).
Setting the bit mask on a range of zoom levels does not affect other levels. By default, the visibility bit masks
for all zoom levels are set to true.
Parameters:
levelStart
A starting zoom level of the range
HERE Android SDK Developer's Guide
API Reference
1028
levelEnd
An ending zoom level of the range
Returns:
The updated MapObject itself.
See also:
setVisible(boolean)
setVisibleMask(int)
unsetVisibleMask(int)
unsetVisibleMask(int, int)
getVisibleMask()
public MapObject setZIndex (int index)
Sets a z-index (stacking order) value for this MapObject .
Note that this API is not supported by MapLabeledMarker.
Parameters:
index
A new z-index value for this MapObject, a 16-bit int within the range of [0..65535]
Returns:
The updated MapObject itself.
Throws:
IllegalArgumentException
if index is not within the valid range.
public MapObject unsetVisibleMask (int level)
Sets this MapObject to be invisible at the specified zoom level by unsetting the visibility bit mask.
Setting the bit mask at a particular zoom level does not affect other levels. By default, the visibility bit masks
for all zoom levels are set to true.
Parameters:
level
A zoom level
Returns:
The updated MapObject itself.
See also:
setVisible(boolean)
HERE Android SDK Developer's Guide
API Reference
1029
unsetVisibleMask(int, int)
setVisibleMask(int)
setVisibleMask(int, int)
getVisibleMask()
public MapObject unsetVisibleMask (int levelStart, int levelEnd)
Sets this MapObject to be invisible for the specified range of zoom levels by unsetting the visibility bit mask.
Unsetting the bit mask on a range of zoom levels does not affect other levels. By default, the visibility bit
masks for all zoom levels are set to true.
Parameters:
levelStart
A starting zoom level of the range
levelEnd
An ending zoom level of the range
Returns:
The updated MapObject itself.
See also:
setVisible(boolean)
unsetVisibleMask(int)
setVisibleMask(int)
setVisibleMask(int, int)
getVisibleMask()
Type
The enumeration Type is a member of com.here.android.mpa.mapping.MapObject.
Enumeration Summary
public static final enumeration MapObject.Type
extends java.lang.Enum, java.lang.Object
Represents values describing the types of MapObject objects that can be added to a Map.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1030
Enum Constant Summary
Table 500: Enum Constants in Type
Fields
public static final Type UNKNOWN
An unknown type of MapObject .
public static final Type MARKER
A MapMarker.
public static final Type SCREEN_MARKER
A MapScreenMarker.
public static final Type POLYGON
A MapPolygon.
public static final Type POLYLINE
A MapPolyline.
public static final Type ROUTE
A MapRoute.
public static final Type CONTAINER
A MapContainer.
public static final Type CIRCLE
A MapCircle.
public static final Type LOCAL_MODEL
A MapLocalModel.
public static final Type GEO_MODEL
A MapGeoModel.
public static final Type LABELED_MARKER
A MapLabeledMarker.
Method Summary
Table 501: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1031
Enumeration Details
Represents values describing the types of MapObject objects that can be added to a Map.
Enum Constant Details
public static final Type UNKNOWN
An unknown type of MapObject .
public static final Type MARKER
A MapMarker.
public static final Type SCREEN_MARKER
A MapScreenMarker.
public static final Type POLYGON
A MapPolygon.
public static final Type POLYLINE
A MapPolyline.
public static final Type ROUTE
A MapRoute.
public static final Type CONTAINER
A MapContainer.
public static final Type CIRCLE
A MapCircle.
public static final Type LOCAL_MODEL
A MapLocalModel.
public static final Type GEO_MODEL
HERE Android SDK Developer's Guide
API Reference
1032
A MapGeoModel.
public static final Type LABELED_MARKER
A MapLabeledMarker.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapOffScreenRenderer
The class MapOffScreenRenderer is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapOffScreenRenderer
implements com.here.android.mpa.common.OffScreenRenderer
extends java.lang.Object
Map derivation of the OffScreenRenderer.
[For complete information, see the section Class Details]
Constructor Summary
Table 502: Constructors in MapOffScreenRenderer
Constructors
MapOffScreenRenderer (Context ctx)
Constructor of a MapOffScreenRenderer .
HERE Android SDK Developer's Guide
API Reference
1033
Method Summary
Table 503: Methods in MapOffScreenRenderer
Methods
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
public boolean getBlockingRendering ()
Get whether the offscreen renderer is rendering synchronously.
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the Map .
public void pause ()
Pause currently running offscreen renderer.
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
public void resume ()
Resume currently paused offscreen renderer.
public MapOffScreenRenderer setBlockingRendering (boolean blocking)
Toggle if the offscreen renderer draws synchronously.
public MapOffScreenRenderer setMap (Map map)
Associate the Map with the OffScreen renderer.
public MapOffScreenRenderer setSize (int width, int height)
Set the size of the requested screen surface.
public MapOffScreenRenderer setViewRect (ViewRect viewRect)
Set the view rectangle where the map will be drawn.
public void start ()
Start the offscreen renderer.
public void start (SurfaceHolder renderTarget, SurfaceUpdatedListener listener)
Start the offscreen renderer.
public void stop ()
Stop the offscreen renderer.
Class Details
Map derivation of the OffScreenRenderer. This class as allows users to capture screenshots of a Map with or
without the map rendered in an Android android.view.android.view.View.
Here's a short example to capture a screenshot of a Map not rendered in a View :
OnMapRenderListener listener = new OnMapRenderListener() {
// ...
HERE Android SDK Developer's Guide
API Reference
1034
public void onPostDraw(boolean invalidated, long renderTime)
{
// map has been rendered, now it's OK to get screen
capture!
renderer.getScreenCapture(...);
}
// ...
} Map map = new Map();
MapOffScreenRenderer renderer = new MapOffScreenRenderer(ctx);
renderer.setMap(map);
renderer.setSize(500, 500);
renderer.addRenderListener(listener);
renderer.start();
// ...
// option to pause renderer, e.g. if UI is not visible anymore
renderer.pause();
// ...
// option to resume renderer, e.g. if UI becomes visible
renderer.resume();
// ...
renderer.stop();
renderer.removeRenderListener(listener);
renderer.setMap(null);
Constructor Details
MapOffScreenRenderer (Context ctx)
Constructor of a MapOffScreenRenderer .
Parameters:
ctx
Context to be used by the MapOffScreenRenderer
Method Details
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events. This method is only effective after a Map has
been associated with the renderer by calling setMap(Map).
Parameters:
listener
A OnMapRenderListener to add to the MapOffScreenRenderer
See also:
removeOnMapRenderListener(OnMapRenderListener)
public boolean getBlockingRendering ()
Get whether the offscreen renderer is rendering synchronously.
This API only takes effect after setMap(Map) has been called. By default, blocking rendering is disabled.
HERE Android SDK Developer's Guide
API Reference
1035
Returns:
true if rendering synchronously, false otherwise.
public void getScreenCapture (OnScreenCaptureListener listener)
Returns the full screen bitmap for the Map . This method is asynchronous and will invoke a callback once the
operation is completed through the OnScreenCaptureListener.
The MapOffScreenRenderer must have been started and the Map rendered in order to create the screen
capture. For Map being rendered in a View , users can use the methods getHeight() or getWidth() to verify
that the Map has been rendered. Otherwise, users can also utilize the onPostDraw(boolean, long) callback to
confirm when the Map has been rendered.
Note that this requires the device to support EGL pBuffer Surfaces. It is recommended to have a size of a
power of two. (For example 128x128, 256x256).
Parameters:
listener
A OnScreenCaptureListener to listen for the callback when screen capture is complete.
Throws:
IllegalArgumentException
if listener is null.
See also:
start()
start(SurfaceHolder, SurfaceUpdatedListener)
onPostDraw(boolean, long)
public void pause ()
Pause currently running offscreen renderer. Use this method if renderer needs to be paused for some time.
Allocated resources will not be released. To resume renderer call resume(). Only started renderer can be
paused.
Throws:
IllegalStateException
if this MapOffScreenRenderer is not started.
See also:
resume()
stop()
public void removeOnMapRenderListener (OnMapRenderListener listener)
HERE Android SDK Developer's Guide
API Reference
1036
Removes an existing OnMapRenderListener.
Parameters:
listener
A OnMapRenderListener to remove from the MapOffScreenRenderer
public void resume ()
Resume currently paused offscreen renderer. Only paused renderer can be resumed.
Throws:
IllegalStateException
if this MapOffScreenRenderer is not in pause state.
See also:
pause()
public MapOffScreenRenderer setBlockingRendering (boolean blocking)
Toggle if the offscreen renderer draws synchronously. This means it will block waiting for all required data to
complete rendering.
This API only takes effect after setMap(Map) has been called.
It is also recommended animations be disabled with the method setFadingAnimations(boolean).
Parameters:
blocking
true if rendering will block, false otherwise. Default is false.
Returns:
This MapOffScreenRenderer object
public MapOffScreenRenderer setMap (Map map)
Associate the Map with the OffScreen renderer.
Make sure to set the map back to null after calling stop() to free up resources properly.
Parameters:
map
Map instance to render in the offscreen renderer.
Returns:
This MapOffScreenRenderer object
HERE Android SDK Developer's Guide
API Reference
1037
public MapOffScreenRenderer setSize (int width, int height)
Set the size of the requested screen surface. This method must be called before start().
Parameters:
width
The screen surface width, in number of pixels
height
The screen surface height, in number of pixels
Returns:
This MapOffScreenRenderer object
Throws:
IllegalArgumentException
if width or length is less than or equal to 0
public MapOffScreenRenderer setViewRect (ViewRect viewRect)
Set the view rectangle where the map will be drawn. This API can only called after the setMap(Map) with a
valid Map has been called.
Parameters:
viewRect
Rectangle where the map will be drawn to the view.
Returns:
This MapOffScreenRenderer object
Throws:
RuntimeException
if a map has not been set to the MapOffScreenRenderer.
public void start ()
Start the offscreen renderer. A new PBuffer based surface will be allocated. Before calling this method,
setSize(int, int) must have been called with valid values.
Throws:
IllegalStateException
if MapOffScreenRenderer is already started.
See also:
pause()
stop()
HERE Android SDK Developer's Guide
API Reference
1038
public void start (SurfaceHolder renderTarget, SurfaceUpdatedListener
listener)
Start the offscreen renderer. The renderer will be attached to the supplied SurfaceHolder argument.
Parameters:
renderTarget
Surface to attach to.
listener
Callback when the surface has been updated
Throws:
IllegalStateException
if MapOffScreenRenderer is already started.
See also:
pause()
stop()
public void stop ()
Stop the offscreen renderer. All resource allocated will be released. Use this method if renderer is not
needed anymore, otherwise use pause().
See also:
pause()
resume()
MapOverlay
The class MapOverlay is a member of com.here.android.mpa.mapping .
Class Summary
public class MapOverlay
extends java.lang.Object
The MapOverlay class can be used to display custom Android View-based content at a fixed location on the
map.
[For complete information, see the section Class Details]
See also:
addMapOverlay(MapOverlay)
HERE Android SDK Developer's Guide
API Reference
1039
removeMapOverlay(MapOverlay)
Constructor Summary
Table 504: Constructors in MapOverlay
Constructors
MapOverlay (View view, GeoCoordinate coordinate)
Constructs new MapOverlay object.
Method Summary
Table 505: Methods in MapOverlay
Methods
public PointF getAnchorPoint ()
Returns the anchor point for this MapOverlay .
public GeoCoordinate getCoordinate ()
Returns the current map GeoCoordinate for this MapOverlay .
public View getView ()
Returns the View object that was passed to the constructor.
public MapOverlay setAnchorPoint (PointF anchor)
Sets an anchor point for this MapOverlay .
public MapOverlay setCoordinate (GeoCoordinate coordinate)
Sets a map GeoCoordinate for this MapOverlay .
Class Details
The MapOverlay class can be used to display custom Android View-based content at a fixed location on the
map.
To use, create a MapOverlay with the custom view you wish to display and the position at which the view
should be displayed. The overlay should be then added to the map with addMapOverlay(MapOverlay)
method. The overlay will be automatically repositioned on the screen as the map moves.
See also:
addMapOverlay(MapOverlay)
removeMapOverlay(MapOverlay)
Constructor Details
MapOverlay (View view, GeoCoordinate coordinate)
Constructs new MapOverlay object.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1040
view
Custom view that will be displayed on the map.
coordinate
Position at which the view should be displayed.
Throws:
NullPointerException
If any of given parameters is null.
IllegalArgumentException
If given coordinates are not valid.
Method Details
public PointF getAnchorPoint ()
Returns the anchor point for this MapOverlay .
The overlay is drawn with the specified pixel offset from its getCoordinate() position.
By default, there is no offset and the MapOverlay anchor is positioned in the center of the overlay.
Returns:
The current MapOverlay anchor point.
public GeoCoordinate getCoordinate ()
Returns the current map GeoCoordinate for this MapOverlay .
Returns:
The current GeoCoordinate location.
public View getView ()
Returns the View object that was passed to the constructor.
Returns:
View assigned to this MapOverlay
public MapOverlay setAnchorPoint (PointF anchor)
Sets an anchor point for this MapOverlay .
The overlay is drawn with the specified pixel offset from its getCoordinate() position. To clear an anchor set
previously, pass a PointF to this method with an X-coordinate equal to half the width of the view and a Y-
coordinate equal to half the height of the view.
HERE Android SDK Developer's Guide
API Reference
1041
By default, there is no offset and the MapOverlay anchor is positioned in the center of the overlay.
Parameters:
anchor
A PointF relative to the top-left corner of the MapOverlay.
Returns:
The updated MapOverlay itself.
public MapOverlay setCoordinate (GeoCoordinate coordinate)
Sets a map GeoCoordinate for this MapOverlay .
Parameters:
coordinate
Desired GeoCoordinate location for this overlay.
Returns:
The updated MapOverlay itself.
MapOverlayType
The enumeration MapOverlayType is a member of com.here.android.mpa.mapping .
Enumeration Summary
public final enumeration MapOverlayType
extends java.lang.Enum, java.lang.Object
Represents values describing the display grouping of MapObject objects when added to a Map.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 506: Enum Constants in MapOverlayType
Fields
public static final MapOverlayType FOREGROUND_OVERLAY
Identifies objects that are to be placed on top of any other objects.
public static final MapOverlayType POI_OVERLAY
Identifies objects which augment POI information.
public static final MapOverlayType TRANSIT_STOP_OVERLAY
Identifies objects which augment Transit Stop information.
HERE Android SDK Developer's Guide
API Reference
1042
Fields
public static final MapOverlayType ROAD_OVERLAY
Identifies objects which add some information to the road network, such as traffic or GPS location.
public static final MapOverlayType AREA_OVERLAY
Identifies objects which add information to area features such as heat maps.
public static final MapOverlayType BACKGROUND_OVERLAY
Identifies objects which are placed directly over (on top or in front of) BACKGROUND_REPLACEMENT objects.
public static final MapOverlayType BACKGROUND_REPLACEMENT
Identifies objects that replace the background, such as custom satellite data.
Method Summary
Table 507: Methods in MapOverlayType
Methods
public int getValue ()
public static MapOverlayType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapOverlayType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the display grouping of MapObject objects when added to a Map.
Enum Constant Details
public static final MapOverlayType FOREGROUND_OVERLAY
Identifies objects that are to be placed on top of any other objects. These objects appear closer to the viewer
than other objects.
public static final MapOverlayType POI_OVERLAY
Identifies objects which augment POI information.
public static final MapOverlayType TRANSIT_STOP_OVERLAY
Identifies objects which augment Transit Stop information. Transit-related objects have higher priority over
street names and other area feature labels.
public static final MapOverlayType ROAD_OVERLAY
HERE Android SDK Developer's Guide
API Reference
1043
Identifies objects which add some information to the road network, such as traffic or GPS location.
public static final MapOverlayType AREA_OVERLAY
Identifies objects which add information to area features such as heat maps.
public static final MapOverlayType BACKGROUND_OVERLAY
Identifies objects which are placed directly over (on top or in front of) BACKGROUND_REPLACEMENT objects.
Apply this type to custom raster tiles and other map objects that should be drawn on top of the (background)
map, but should not hide other objects.
public static final MapOverlayType BACKGROUND_REPLACEMENT
Identifies objects that replace the background, such as custom satellite data. Note that this semantic type
does not disable rendering of the background.
Method Details
public int getValue ()
public static MapOverlayType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapOverlayType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapPolygon
The class MapPolygon is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapPolygon
HERE Android SDK Developer's Guide
API Reference
1044
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
A graphical representation of a GeoPolygon to be rendered on a map.
[For complete information, see the section Class Details]
See also:
GeoPolygon
Constructor Summary
Table 508: Constructors in MapPolygon
Constructors
MapPolygon ()
Creates a MapPolygon , which is a MapObject in the shape of a polygon.
MapPolygon (GeoPolygon polygon)
Creates a MapPolygon , which is a MapObject in the shape of a polygon.
Method Summary
Table 509: Methods in MapPolygon
Methods
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapPolygon is rendered with depth test.
public int getFillColor ()
Returns the current fill color for this MapPolygon , returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public GeoPolygon getGeoPolygon ()
Gets a copy of the GeoPolygon rendered by this MapPolygon .
public int getLineColor ()
Returns the current border line color for this MapPolygon , returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getLineWidth ()
Returns the current border line width for the MapPolygon , in pixels.
public boolean isGeodesicEnabled ()
Returns a boolean indicating whether each segment of this GeoPolygon is drawn as a geodesic.
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapPolygon with depth test.
public MapPolygon setFillColor (int color)
Sets a fill color for this MapPolygon , using an ARGB (Alpha/Red/Green/Blue) integer color value.
HERE Android SDK Developer's Guide
API Reference
1045
Methods
public MapPolygon setGeoPolygon (GeoPolygon polygon)
Changes the GeoPolygon rendered by this MapPolygon .
public MapPolygon setGeodesicEnabled (boolean enabled)
Specifies whether to draw each segment of the represented GeoPolygon as a geodesic.
public MapPolygon setLineColor (int color)
Sets a border line color for this MapPolygon , using an ARGB (Alpha/Red/Green/Blue) integer color value.
public MapPolygon setLineWidth (int width)
Sets a border line width, in pixels, for this MapPolygon , an int value within the [0..100] range.
Class Details
A graphical representation of a GeoPolygon to be rendered on a map. In contrast to a MapPolyline, it is
assumed that the last coordinate within the path is connected with the first coordinate, thereby constructing
an enclosed geometry. Self-intersecting polygons rendering are not supported.
See also:
GeoPolygon
Constructor Details
MapPolygon ()
Creates a MapPolygon , which is a MapObject in the shape of a polygon.
MapPolygon (GeoPolygon polygon)
Creates a MapPolygon , which is a MapObject in the shape of a polygon.
Parameters:
polygon
GeoPolygon to construct the MapPolygon
Throws:
IllegalArgumentException
if the input GeoPolygon is invalid, it is a self-intersecting polygon or vertices are at different altitudes.
Method Details
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapPolygon is rendered with depth test. By default, depth test is
disabled.
HERE Android SDK Developer's Guide
API Reference
1046
Returns:
True if the MapPolygon is rendered with depth test, false otherwise
public int getFillColor ()
Returns the current fill color for this MapPolygon , returning an ARGB (Alpha/Red/Green/Blue) integer color
value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component, and
255 meaning 100% contribution
See also:
android.graphics.Color
public GeoPolygon getGeoPolygon ()
Gets a copy of the GeoPolygon rendered by this MapPolygon .
Returns:
rendered GeoPolygon.
public int getLineColor ()
Returns the current border line color for this MapPolygon , returning an ARGB (Alpha/Red/Green/Blue)
integer color value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component, and
255 meaning 100% contribution
See also:
android.graphics.Color
public int getLineWidth ()
Returns the current border line width for the MapPolygon , in pixels.
Returns:
The current width of the line defining the border of the MapPolygon
public boolean isGeodesicEnabled ()
HERE Android SDK Developer's Guide
API Reference
1047
Returns a boolean indicating whether each segment of this GeoPolygon is drawn as a geodesic.
Returns:
true if GeoPolygon segments are drawn as a geodesic, false otherwise.
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapPolygon with depth test.
Rendering with depth test should be used if map object altitude is relevant in your application. Rendering
objects with different heights while disabling depth test may cause object occlusion.
Parameters:
enabled
true if MapPolygon is rendered with depth test
public MapPolygon setFillColor (int color)
Sets a fill color for this MapPolygon , using an ARGB (Alpha/Red/Green/Blue) integer color value.
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component,
and 255 meaning 100% contribution
Returns:
The updated MapPolygon object itself.
See also:
android.graphics.Color
public MapPolygon setGeoPolygon (GeoPolygon polygon)
Changes the GeoPolygon rendered by this MapPolygon .
Parameters:
polygon
GeoPolygon to be rendered
Returns:
The updated MapPolygon itself.
Throws:
IllegalArgumentException
if the input GeoPolygon is invalid, it is a self-intersecting polygon or vertices are at different altitudes.
HERE Android SDK Developer's Guide
API Reference
1048
public MapPolygon setGeodesicEnabled (boolean enabled)
Specifies whether to draw each segment of the represented GeoPolygon as a geodesic.
Parameters:
enabled
true if GeoPolygon segments will be drawn as a geodesic
Returns:
The updated @ code MapPolygon} itself.
public MapPolygon setLineColor (int color)
Sets a border line color for this MapPolygon , using an ARGB (Alpha/Red/Green/Blue) integer color value.
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component,
and 255 meaning 100% contribution
Returns:
The updated @ code MapPolygon} itself.
See also:
android.graphics.Color
public MapPolygon setLineWidth (int width)
Sets a border line width, in pixels, for this MapPolygon , an int value within the [0..100] range. By default,
the line width is 1.
Parameters:
width
Width of the line defining the border of the MapPolygon
Returns:
The updated @ code MapPolygon} itself.
Throws:
IllegalArgumentException
is width is out of range.
HERE Android SDK Developer's Guide
API Reference
1049
MapPolyline
The class MapPolyline is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapPolyline
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
A graphical representation of a GeoPolyline that can be rendered on a map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 510: Nested Classes in MapPolyline
Nested Classes
public static final enumeration MapPolyline.CapStyle
Line ending cap rendering styles
Constructor Summary
Table 511: Constructors in MapPolyline
Constructors
MapPolyline ()
Creates a MapPolyline , which is a MapObject in the shape of a polyline.
MapPolyline (GeoPolyline polyline)
Creates a MapPolyline , which is a MapObject in the shape of a polyline.
Method Summary
Table 512: Methods in MapPolyline
Methods
public CapStyle getCapStyle ()
Get the MapPolyline rendering cap style
public int getDashPrimaryLength ()
Returns the current length of the primary dash segment of a dashed MapPolyline , in pixels.
public int getDashSecondaryLength ()
Returns the current length of the secondary (empty) dash segments of a dashed MapPolyline , in pixels.
HERE Android SDK Developer's Guide
API Reference
1050
Methods
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapPolyline is rendered with depth test.
public GeoPolyline getGeoPolyline ()
Gets copy of the GeoPolyline rendered by this MapPolyline .
public int getLineColor ()
Gets the current line color for this MapPolyline , returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getLineWidth ()
Returns the current line width for this MapPolyline , in pixels.
public int getOutlineColor ()
Gets the current outline color for this MapPolyline , returning an ARGB (Alpha/Red/Green/Blue) integer color value.
public int getOutlineWidth ()
Returns the current outline width for this MapPolyline , in pixels.
public boolean isDashEnabled ()
Returns a boolean indicating whether the MapPolyline appears as a dashed line.
public boolean isGeodesicEnabled ()
Returns a boolean indicating whether each segment of this GeoPolyline is drawn as a geodesic.
public boolean isPerspectiveEnabled ()
Returns a boolean indicating whether the MapPolyline appears thinner further away when the map is tilted.
public MapPolyline setCapStyle (CapStyle style)
Set the MapPolyline rendering cap style.
public MapPolyline setDashEnabled (boolean enabled)
Sets the appearance of this MapPolyline as either a dashed or solid line.
public MapPolyline setDashPrimaryLength (int length)
Sets a length, in pixels, for the primary dash segment of a dashed MapPolyline .
public MapPolyline setDashSecondaryLength (int length)
Sets a length, in pixels, for the secondary (empty) dash segments of a dashed MapPolyline .
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapPolyline with depth test.
public MapPolyline setGeoPolyline (GeoPolyline polyline)
Changes the GeoPolyline rendered by this GeoPolyline
public MapPolyline setGeodesicEnabled (boolean enabled)
Set whether to draw each segment of the represented GeoPolyline as a geodesic.
public MapPolyline setLineColor (int color)
Sets a line color for this MapPolyline , using an ARGB (Alpha/Red/Green/Blue) integer color value.
HERE Android SDK Developer's Guide
API Reference
1051
Methods
public MapPolyline setLineWidth (int width)
Sets a line width, in pixels, for this MapPolyline , an int value within the [0..100] range.
public MapPolyline setOutlineColor (int color)
Sets an outline color for this MapPolyline , using an ARGB (Alpha/Red/Green/Blue) integer color value.
public MapPolyline setOutlineWidth (int width)
Sets an outline width, in pixels, for this MapPolyline , an int value within the [0..100] range.
public MapPolyline setPerspectiveEnabled (boolean enabled)
Sets the width of this MapPolyline to be thinner further away when the map is tilted.
Class Details
A graphical representation of a GeoPolyline that can be rendered on a map. A MapPolyline has multiple
points that combine to create its path.
Constructor Details
MapPolyline ()
Creates a MapPolyline , which is a MapObject in the shape of a polyline.
MapPolyline (GeoPolyline polyline)
Creates a MapPolyline , which is a MapObject in the shape of a polyline.
Parameters:
polyline
GeoPolyline to construct the MapPolyline.
Method Details
public CapStyle getCapStyle ()
Get the MapPolyline rendering cap style
Returns:
CapStyle cap style.
public int getDashPrimaryLength ()
Returns the current length of the primary dash segment of a dashed MapPolyline , in pixels.
Returns:
The current length of the primary dash
HERE Android SDK Developer's Guide
API Reference
1052
See also:
getDashSecondaryLength()
public int getDashSecondaryLength ()
Returns the current length of the secondary (empty) dash segments of a dashed MapPolyline , in pixels.
Returns:
The current length of the empty dash
See also:
getDashPrimaryLength()
public boolean getDepthTestEnabled ()
Returns a boolean indicating whether the MapPolyline is rendered with depth test. By default, depth test
is disabled.
Returns:
True if the MapPolyline is rendered with depth test, false otherwise
public GeoPolyline getGeoPolyline ()
Gets copy of the GeoPolyline rendered by this MapPolyline .
Returns:
rendered GeoPolyline.
public int getLineColor ()
Gets the current line color for this MapPolyline , returning an ARGB (Alpha/Red/Green/Blue) integer color
value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution
See also:
android.graphics.Color
public int getLineWidth ()
Returns the current line width for this MapPolyline , in pixels.
Returns:
HERE Android SDK Developer's Guide
API Reference
1053
The current line width for this MapPolyline
public int getOutlineColor ()
Gets the current outline color for this MapPolyline , returning an ARGB (Alpha/Red/Green/Blue) integer
color value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution
See also:
android.graphics.Color
public int getOutlineWidth ()
Returns the current outline width for this MapPolyline , in pixels.
Returns:
The current line width for this MapPolyline
public boolean isDashEnabled ()
Returns a boolean indicating whether the MapPolyline appears as a dashed line. By default, dash is
disabled.
Returns:
True if the MapPolyline is dashed, false otherwise
public boolean isGeodesicEnabled ()
Returns a boolean indicating whether each segment of this GeoPolyline is drawn as a geodesic. By default,
GeoDesic is disabled.
Returns:
true if GeoPolyline segments are drawn as a geodesic, false otherwise.
public boolean isPerspectiveEnabled ()
Returns a boolean indicating whether the MapPolyline appears thinner further away when the map is
tilted. By default, perspective is disabled.
Returns:
true if the MapPolyline has perspective enabled, false otherwise
HERE Android SDK Developer's Guide
API Reference
1054
public MapPolyline setCapStyle (CapStyle style)
Set the MapPolyline rendering cap style.
Parameters:
style
CapStyle
Returns:
The updated MapPolyline itself.
public MapPolyline setDashEnabled (boolean enabled)
Sets the appearance of this MapPolyline as either a dashed or solid line.
Parameters:
enabled
A boolean specifying whether the MapPolyline should be dashed
Returns:
The updated MapPolyline itself.
public MapPolyline setDashPrimaryLength (int length)
Sets a length, in pixels, for the primary dash segment of a dashed MapPolyline . By default, the primary
dash length is 1.
Parameters:
length
Desired length of the primary dash
Returns:
The updated MapPolyline itself.
Throws:
IllegalArgumentException
if length is less than or equal to 0.
See also:
setDashSecondaryLength(int)
public MapPolyline setDashSecondaryLength (int length)
Sets a length, in pixels, for the secondary (empty) dash segments of a dashed MapPolyline . By default, the
secondary dash length is 1.
HERE Android SDK Developer's Guide
API Reference
1055
Parameters:
length
Desired length of the empty dash
Returns:
The updated MapPolyline itself.
Throws:
IllegalArgumentException
if length is less than or equal 0.
See also:
setDashPrimaryLength(int)
public void setDepthTestEnabled (boolean enabled)
Set whether to render MapPolyline with depth test.
Rendering with depth test should be used if map object altitude is relevant in your application. Rendering
objects with different heights while disabling depth test may cause object occlusion.
Parameters:
enabled
true if MapPolyline is rendered with depth test
public MapPolyline setGeoPolyline (GeoPolyline polyline)
Changes the GeoPolyline rendered by this GeoPolyline
Parameters:
polyline
GeoPolyline to be rendered
Returns:
The updated MapPolyline itself.
public MapPolyline setGeodesicEnabled (boolean enabled)
Set whether to draw each segment of the represented GeoPolyline as a geodesic.
Parameters:
enabled
true if GeoPolyline segments will be drawn as a geodesic
Returns:
The updated MapPolyline itself.
HERE Android SDK Developer's Guide
API Reference
1056
public MapPolyline setLineColor (int color)
Sets a line color for this MapPolyline , using an ARGB (Alpha/Red/Green/Blue) integer color value. The
default line color is Color.BLUE .
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated MapPolyline itself.
See also:
android.graphics.Color
public MapPolyline setLineWidth (int width)
Sets a line width, in pixels, for this MapPolyline , an int value within the [0..100] range. By default, the line
width is 1.
Parameters:
width
Desired width of the line defining the MapPolyline
Returns:
The updated MapPolyline itself.
Throws:
IllegalArgumentException
is width is out of range.
public MapPolyline setOutlineColor (int color)
Sets an outline color for this MapPolyline , using an ARGB (Alpha/Red/Green/Blue) integer color value. The
default line color is Color.TRANSPARENT .
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
HERE Android SDK Developer's Guide
API Reference
1057
The updated MapPolyline itself.
See also:
android.graphics.Color
public MapPolyline setOutlineWidth (int width)
Sets an outline width, in pixels, for this MapPolyline , an int value within the [0..100] range. By default, the
line width is 0.
Parameters:
width
Desired width of the outline defining the MapPolyline
Returns:
The updated MapPolyline itself.
Throws:
IllegalArgumentException
is width is out of range.
public MapPolyline setPerspectiveEnabled (boolean enabled)
Sets the width of this MapPolyline to be thinner further away when the map is tilted.
Parameters:
enabled
A boolean specifying whether the MapPolyline should have perspective enabled
Returns:
The updated MapPolyline itself.
CapStyle
The enumeration CapStyle is a member of com.here.android.mpa.mapping.MapPolyline.
Enumeration Summary
public static final enumeration MapPolyline.CapStyle
extends java.lang.Enum, java.lang.Object
Line ending cap rendering styles
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1058
Enum Constant Summary
Table 513: Enum Constants in CapStyle
Fields
public static final CapStyle BUTT
The line ends exactly where the endpoint is located.
public static final CapStyle ROUND
Adding a round cap to the endpoint.
Method Summary
Table 514: Methods in CapStyle
Methods
public static CapStyle toCapStyle (int style)
public int value ()
public static CapStyle valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapPolyline.CapStyle[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Line ending cap rendering styles
Enum Constant Details
public static final CapStyle BUTT
The line ends exactly where the endpoint is located.
public static final CapStyle ROUND
Adding a round cap to the endpoint.
Method Details
public static CapStyle toCapStyle (int style)
Parameters:
style
HERE Android SDK Developer's Guide
API Reference
1059
public int value ()
public static CapStyle valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapPolyline.CapStyle[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapProxyObject
The class MapProxyObject is a member of com.here.android.mpa.mapping .
Class Summary
public abstract class MapProxyObject
extends com.here.android.mpa.common.ViewObject, java.lang.Object
Represents a base interface for all view objects rendered as part of the map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 515: Nested Classes in MapProxyObject
Nested Classes
public static final enumeration MapProxyObject.Type
Represents values describing the types of MapProxyObject objects that can be added to a Map.
Method Summary
Table 516: Methods in MapProxyObject
Methods
public Type getType ()
Returns the type of object that the MapProxyObject represents.
HERE Android SDK Developer's Guide
API Reference
1060
Class Details
Represents a base interface for all view objects rendered as part of the map. A proxy object may contain
special information depending on its type (for example, TransitStopObject may provide transit stop-
related information), but it cannot be created or modified.
This interface serves as a generalization for several more specified proxy object types, bundling their
common properties.
Method Details
public Type getType ()
Returns the type of object that the MapProxyObject represents.
Returns:
The MapProxyObject.Type
Type
The enumeration Type is a member of com.here.android.mpa.mapping.MapProxyObject.
Enumeration Summary
public static final enumeration MapProxyObject.Type
extends java.lang.Enum, java.lang.Object
Represents values describing the types of MapProxyObject objects that can be added to a Map.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 517: Enum Constants in Type
Fields
public static final Type UNKNOWN
An unknown type of MapProxyObject .
public static final Type SAFETY_SPOT
A SafetySpotObject .
public static final Type TRAFFIC_EVENT
A TrafficEventObject .
public static final Type TRANSIT_ACCESS
A TransitAccessObject .
HERE Android SDK Developer's Guide
API Reference
1061
Fields
public static final Type TRANSIT_LINE
A TransitLineObject .
public static final Type TRANSIT_LINE_SEGMENT
A TransitLineSegmentObject .
public static final Type TRANSIT_STOP
A TransitStopObject .
public static final Type EXTRUDED_BUILDING
A MapBuildingObject .
public static final Type MAP_CARTO_MARKER
A MapCartoMarker .
public static final Type CLUSTER_MARKER
A com.here.android.mpa.cluster.ClusterViewObject .
Method Summary
Table 518: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapProxyObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the types of MapProxyObject objects that can be added to a Map.
Enum Constant Details
public static final Type UNKNOWN
An unknown type of MapProxyObject .
public static final Type SAFETY_SPOT
A SafetySpotObject . Not supported.
public static final Type TRAFFIC_EVENT
A TrafficEventObject .
HERE Android SDK Developer's Guide
API Reference
1062
public static final Type TRANSIT_ACCESS
A TransitAccessObject .
public static final Type TRANSIT_LINE
A TransitLineObject .
public static final Type TRANSIT_LINE_SEGMENT
A TransitLineSegmentObject .
public static final Type TRANSIT_STOP
A TransitStopObject .
public static final Type EXTRUDED_BUILDING
A MapBuildingObject .
public static final Type MAP_CARTO_MARKER
A MapCartoMarker .
public static final Type CLUSTER_MARKER
A com.here.android.mpa.cluster.ClusterViewObject .
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapProxyObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1063
MapRasterTileSource
The class MapRasterTileSource is a member of com.here.android.mpa.mapping .
Class Summary
public abstract class MapRasterTileSource
extends java.lang.Object
Represents an interface for a map raster tile source, used to render custom tile images on top of a Map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 519: Nested Classes in MapRasterTileSource
Nested Classes
public static final class MapRasterTileSource.MapTileSystemHelper
Represents a helper class for converting raster tile coordinates to other tile system values.
public static class MapRasterTileSource.TileResult
Result class for getting tile.
public static final enumeration MapRasterTileSource.Transparency
Represents values describing the state of raster tile image transparency.
Constructor Summary
Table 520: Constructors in MapRasterTileSource
Constructors
MapRasterTileSource ()
Method Summary
Table 521: Methods in MapRasterTileSource
Methods
public GeoBoundingBox getBoundingArea ()
Gets the GeoBoundingBox representing the bounding area within which raster tiles are visible.
public int getCacheExpiration ()
Get the cache expiration time
public MapOverlayType getOverlayType ()
Gets the raster tile overlay type.
HERE Android SDK Developer's Guide
API Reference
1064
Methods
public int getTileSize ()
Gets the raster tile image size, in pixels.
public TileResult getTileWithError (int x, int y, int zoomLevel)
Method to be overwritten by derived class to get a tile.
public int getZIndex ()
Gets the current z-index (stacking order) of the MapObject .
public abstract boolean hasTile (int x, int y, int zoomLevel)
Abstract method to be overwritten by derived class to check if a tile exists.
public boolean hasTransparency ()
Determines whether raster tile images have transparency enabled.
public MapRasterTileSource hideAtZoomLevel (int level)
Hides tiles at the specified zoom level of the Map .
public MapRasterTileSource hideAtZoomRange (int beginZoomLevel, int endZoomLevel)
Hides tiles within a given zoom level range of the Map .
public boolean isCachingEnabled ()
Get whether tiles are cached to the file system
public boolean isShownAtZoomLevel (int zoomLevel)
Determines whether raster tiles are shown at the specified zoom level of the Map .
public MapRasterTileSource setBoundingArea (GeoBoundingBox boundingBox)
Sets a bounding area within which raster tiles are visible.
public MapRasterTileSource setCacheExpiration (int expireSeconds)
Set the cache expiration time
public MapRasterTileSource setCachePrefix (String cache)
Set the cache file prefix
public MapRasterTileSource setCachingEnabled (boolean enabled)
Set whether tiles are cached to the file system.
public MapRasterTileSource setOverlayType (MapOverlayType newValue)
Sets a MapOverlayType for the MapRasterTileSource .
public MapRasterTileSource setTileSize (int newValue)
Sets a size, in pixels, for the raster tile image.
public MapRasterTileSource setTransparency (Transparency value)
Sets a Transparency state for raster tile image.
public MapRasterTileSource setZIndex (int zIndex)
Sets a z-index (stacking order) value for the MapObject .
HERE Android SDK Developer's Guide
API Reference
1065
Methods
public MapRasterTileSource showAtZoomLevel (int level)
Shows tiles at the specified zoom level of the Map .
public MapRasterTileSource showAtZoomRange (int beginZoomLevel, int endZoomLevel)
Shows tiles within a given zoom level range of the Map .
Class Details
Represents an interface for a map raster tile source, used to render custom tile images on top of a Map.
Default attribute values are as follows:
Overlay type: RasterTileOverlayType.BACKGROUND_REPLACEMENT
Transparency: Transparency.TRANSPARENCY_ON
Tile size: 256x256 pixels
Valid zoom levels: 0-20 (all zoom levels)
Bounding area: Top-Left coordinate: (-180.0, 90.0), Bottom-Right coordinate: (179.99, -90.0)
Note: the currently supported pixel format for the tile images is RGBA.
Constructor Details
MapRasterTileSource ()
Method Details
public GeoBoundingBox getBoundingArea ()
Gets the GeoBoundingBox representing the bounding area within which raster tiles are visible.
Returns:
The raster tile bounding area
public int getCacheExpiration ()
Get the cache expiration time
Returns:
Expire time in seconds
public MapOverlayType getOverlayType ()
Gets the raster tile overlay type.
Returns:
The raster tile overlay type, a MapOverlayType value
HERE Android SDK Developer's Guide
API Reference
1066
public int getTileSize ()
Gets the raster tile image size, in pixels.
Returns:
The size of the raster tile image
public TileResult getTileWithError (int x, int y, int zoomLevel)
Method to be overwritten by derived class to get a tile.
Parameters:
x
X coordinate
y
Y coordinate
zoomLevel
zoom level
Returns:
A TileResult representing tile data and operation error. Check TileResult#getError() to check for
error. Check TileResult#getData() to get RasterTile
public int getZIndex ()
Gets the current z-index (stacking order) of the MapObject .
Returns:
The current ordinal z-index number
public abstract boolean hasTile (int x, int y, int zoomLevel)
Abstract method to be overwritten by derived class to check if a tile exists.
Parameters:
x
X coordinate
y
Y coordinate
zoomLevel
zoom level
Returns:
HERE Android SDK Developer's Guide
API Reference
1067
true if the tile exists, false otherwise
public boolean hasTransparency ()
Determines whether raster tile images have transparency enabled.
Returns:
True if raster tile images are set to Transparency.TRANSPARENCY_ON, false otherwise
public MapRasterTileSource hideAtZoomLevel (int level)
Hides tiles at the specified zoom level of the Map .
Parameters:
level
Zoom level at which tiles are to be hidden (see getMaxZoomLevel() and getMinZoomLevel() to retrieve the
supported zoom level range)
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource hideAtZoomRange (int beginZoomLevel, int
endZoomLevel)
Hides tiles within a given zoom level range of the Map .
Parameters:
beginZoomLevel
Zoom level representing the beginning of the range within which tiles are to be hidden (see
getMaxZoomLevel() and getMinZoomLevel() to retrieve the supported zoom level range).
endZoomLevel
Zoom level representing the end of the range within which tiles are to be hidden
Returns:
The updated MapRasterTileSource itself (see getMaxZoomLevel() and getMinZoomLevel() to retrieve the
supported zoom level range).
public boolean isCachingEnabled ()
Get whether tiles are cached to the file system
Returns:
True of tiles are cached. False otherwise.
HERE Android SDK Developer's Guide
API Reference
1068
public boolean isShownAtZoomLevel (int zoomLevel)
Determines whether raster tiles are shown at the specified zoom level of the Map .
Parameters:
zoomLevel
Zoom level to check for raster tile visibility (see getZoomLevel() to retrieve the current zoom level of the
Map).
Returns:
True if raster tiles are shown at the specified zoom level, false otherwise
public MapRasterTileSource setBoundingArea (GeoBoundingBox boundingBox)
Sets a bounding area within which raster tiles are visible.
Parameters:
boundingBox
A GeoBoundingBox representing the bounding area of visible raster tiles
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setCacheExpiration (int expireSeconds)
Set the cache expiration time
Parameters:
expireSeconds
Expire time in seconds
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setCachePrefix (String cache)
Set the cache file prefix
Parameters:
cache
Prefix tag
Returns:
The updated MapRasterTileSource itself.
HERE Android SDK Developer's Guide
API Reference
1069
public MapRasterTileSource setCachingEnabled (boolean enabled)
Set whether tiles are cached to the file system.
Parameters:
enabled
True to cache, False otherwise
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setOverlayType (MapOverlayType newValue)
Sets a MapOverlayType for the MapRasterTileSource .
Parameters:
newValue
A MapOverlayType value representing the desired raster tile overlay type
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setTileSize (int newValue)
Sets a size, in pixels, for the raster tile image.
Parameters:
newValue
Desired size of the raster tile image
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setTransparency (Transparency value)
Sets a Transparency state for raster tile image.
Parameters:
value
A Transparency value representing the desired raster tile image transparency
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource setZIndex (int zIndex)
HERE Android SDK Developer's Guide
API Reference
1070
Sets a z-index (stacking order) value for the MapObject .
Parameters:
zIndex
A new z-index value for the MapObject, a 16-bit int within the range of [0..655xx]
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource showAtZoomLevel (int level)
Shows tiles at the specified zoom level of the Map .
Parameters:
level
Zoom level at which tiles are to be shown (see getMaxZoomLevel() and getMinZoomLevel() to retrieve the
supported zoom level range).
Returns:
The updated MapRasterTileSource itself.
public MapRasterTileSource showAtZoomRange (int beginZoomLevel, int
endZoomLevel)
Shows tiles within a given zoom level range of the Map .
Parameters:
beginZoomLevel
Zoom level representing the beginning of the range within which tiles are to be shown (see
getMaxZoomLevel() and getMinZoomLevel() to retrieve the supported zoom level range).
endZoomLevel
Zoom level representing the end of the range within which tiles are to be shown
Returns:
The updated MapRasterTileSource itself (see getMaxZoomLevel() and getMinZoomLevel() to retrieve the
supported zoom level range).
MapTileSystemHelper
The class MapTileSystemHelper is a member of com.here.android.mpa.mapping.MapRasterTileSource.
Class Summary
public static final class MapRasterTileSource.MapTileSystemHelper
HERE Android SDK Developer's Guide
API Reference
1071
extends java.lang.Object
Represents a helper class for converting raster tile coordinates to other tile system values.
[For complete information, see the section Class Details]
Constructor Summary
Table 522: Constructors in MapTileSystemHelper
Constructors
MapTileSystemHelper ()
Method Summary
Table 523: Methods in MapTileSystemHelper
Methods
public static String tileXYToQuadKey (int x, int y, int zoomLevel)
Converts a raster tile's X-coordinate and Y-coordinate into an equivalent QuadKey at a specified zoom level.
Class Details
Represents a helper class for converting raster tile coordinates to other tile system values.
Constructor Details
MapTileSystemHelper ()
Method Details
public static String tileXYToQuadKey (int x, int y, int zoomLevel)
Converts a raster tile's X-coordinate and Y-coordinate into an equivalent QuadKey at a specified zoom level.
See also The Tile Coordinates and Quadkeys.
Parameters:
x
Current X-coordinate of the tile
y
Current Y-coordinate of the tile
zoomLevel
Desired zoom level, an int within a range from 1 (lowest detail) to 20 (highest detail)
Returns:
The QuadKey
HERE Android SDK Developer's Guide
API Reference
1072
TileResult
The class TileResult is a member of com.here.android.mpa.mapping.MapRasterTileSource.
Class Summary
public static class MapRasterTileSource.TileResult
extends java.lang.Object
Result class for getting tile.
[For complete information, see the section Class Details]
See also:
getTileWithError(int, int, int)
Nested Class Summary
Table 524: Nested Classes in TileResult
Nested Classes
public static final enumeration MapRasterTileSource.TileResult.Error
Error code for raster tile result.
Constructor Summary
Table 525: Constructors in TileResult
Constructors
TileResult (Error error, byte[] data)
Method Summary
Table 526: Methods in TileResult
Methods
public byte[] getData ()
Get the retrieved tile.
public Error getError ()
Get the Error for get tile operation
Class Details
Result class for getting tile.
HERE Android SDK Developer's Guide
API Reference
1073
See also:
getTileWithError(int, int, int)
Constructor Details
TileResult (Error error, byte[] data)
Parameters:
error
data
Method Details
public byte[] getData ()
Get the retrieved tile.
Returns:
RasterTile
public Error getError ()
Get the Error for get tile operation
Returns:
Error encountered during get tile operation
Error
The enumeration Error is a member of com.here.android.mpa.mapping.MapRasterTileSource.TileResult.
Enumeration Summary
public static final enumeration MapRasterTileSource.TileResult.Error
extends java.lang.Enum, java.lang.Object
Error code for raster tile result.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 527: Enum Constants in Error
Fields
public static final Error NONE
HERE Android SDK Developer's Guide
API Reference
1074
Fields
public static final Error NOT_READY
public static final Error NOT_FOUND
Method Summary
Table 528: Methods in Error
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapRasterTileSource.TileResult.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Error code for raster tile result.
Enum Constant Details
public static final Error NONE
public static final Error NOT_READY
public static final Error NOT_FOUND
Method Details
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapRasterTileSource.TileResult.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1075
Transparency
The enumeration Transparency is a member of com.here.android.mpa.mapping.MapRasterTileSource.
Enumeration Summary
public static final enumeration MapRasterTileSource.Transparency
extends java.lang.Enum, java.lang.Object
Represents values describing the state of raster tile image transparency.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 529: Enum Constants in Transparency
Fields
public static final Transparency ON
Raster tile image transparency is enabled.
public static final Transparency OFF
Raster tile image transparency is disabled.
Method Summary
Table 530: Methods in Transparency
Methods
public static Transparency valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapRasterTileSource.Transparency[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the state of raster tile image transparency.
Enum Constant Details
public static final Transparency ON
Raster tile image transparency is enabled.
public static final Transparency OFF
HERE Android SDK Developer's Guide
API Reference
1076
Raster tile image transparency is disabled.
Method Details
public static Transparency valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapRasterTileSource.Transparency[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapRoute
The class MapRoute is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapRoute
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a Route that can be displayed on a Map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 531: Nested Classes in MapRoute
Nested Classes
public static final enumeration MapRoute.RenderType
Render style of the route.
HERE Android SDK Developer's Guide
API Reference
1077
Constructor Summary
Table 532: Constructors in MapRoute
Constructors
MapRoute ()
Creates a MapRoute object.
MapRoute (Route route)
Creates a MapRoute with a specified Route .
Method Summary
Table 533: Methods in MapRoute
Methods
public int getColor ()
Returns the current ARGB (Alpha/Red/Green/Blue) integer color value used to display this route.
public RenderType getRenderType ()
Returns the RenderType associated with this MapRoute .
public Route getRoute ()
Returns the Route that has been displayed on the Map .
public int getTraveledColor ()
Returns the current ARGB (Alpha/Red/Green/Blue) integer color value used to display the traveled route.
public boolean isManeuverNumberVisible ()
Returns a boolean indicating whether maneuver numbers are displayed along with this route.
public boolean isTrafficEnabled ()
Checks if traffic is enabled for this route.
public MapRoute setColor (int argbColor)
Sets a color for displaying the route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
public MapRoute setManeuverNumberVisible (boolean visible)
Sets maneuver numbers to be either displayed along with this route or not displayed.
public MapRoute setRenderType (RenderType type)
Sets the RenderType associated with this MapRoute .
public MapRoute setRoute (Route route)
Sets a Route that will be displayed on the Map .
public MapRoute setTrafficEnabled (boolean enable)
Enable display of traffic on this MapRoute .
public MapRoute setTraveledColor (int argbColor)
Sets a color for displaying the traveled route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
HERE Android SDK Developer's Guide
API Reference
1078
Class Details
Represents a Route that can be displayed on a Map.
Constructor Details
MapRoute ()
Creates a MapRoute object.
MapRoute (Route route)
Creates a MapRoute with a specified Route .
Typically, a MapRoute is created after a Route has been calculated. An application can pass a calculated
Route as a parameter to this method instead of making an explicit call to setRoute(Route). Adding the new
MapRoute object to a Map can be done by way of the addMapObject(MapObject) method.
Parameters:
route
A calculated Route used to set to the MapRoute
Method Details
public int getColor ()
Returns the current ARGB (Alpha/Red/Green/Blue) integer color value used to display this route.
If MapRoute.RenderType is set to USER_DEFINED getting this property will return the value you set. Otherwise,
will return pre-defined value for map scheme. If MapRoute is not added to map, 0 will be returned.
Note: Alpha-value transparency is supported.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution
See also:
android.graphics.Color
public RenderType getRenderType ()
Returns the RenderType associated with this MapRoute .
Default value is PRIMARY.
Returns:
The RenderType associated with the MapRoute.
HERE Android SDK Developer's Guide
API Reference
1079
public Route getRoute ()
Returns the Route that has been displayed on the Map .
Returns:
The Route
public int getTraveledColor ()
Returns the current ARGB (Alpha/Red/Green/Blue) integer color value used to display the traveled route.
If MapRoute.RenderType is set to USER_DEFINED getting this property will return the value you set. Otherwise,
will return pre-defined value for map scheme. If MapRoute is not added to map, 0 will be returned.
Note: Alpha-value transparency is supported.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution.
See also:
android.graphics.Color
public boolean isManeuverNumberVisible ()
Returns a boolean indicating whether maneuver numbers are displayed along with this route.
Returns:
True if maneuver numbers are displayed with the route, false otherwise
public boolean isTrafficEnabled ()
Checks if traffic is enabled for this route.
Returns:
True if traffic is enabled for this MapRoute, false otherwise.
public MapRoute setColor (int argbColor)
Sets a color for displaying the route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
Setting this property will change the color of the MapRoute and change the RenderType to USER_DEFINED.
Calling setRenderType(MapRoute.RenderType) other than USER_DEFINED will reset any color previously set by
using this method.
Note: Alpha-value transparency is supported.
HERE Android SDK Developer's Guide
API Reference
1080
Parameters:
argbColor
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and
255 meaning 100% contribution.
Returns:
The updated MapRoute itself.
See also:
android.graphics.Color
public MapRoute setManeuverNumberVisible (boolean visible)
Sets maneuver numbers to be either displayed along with this route or not displayed. By default, maneuver
number is invisible.
Parameters:
visible
A boolean specifying whether maneuver numbers are displayed
Returns:
The updated MapRoute itself.
public MapRoute setRenderType (RenderType type)
Sets the RenderType associated with this MapRoute .
Note: setting setColor(int) or setTraveledColor(int) will reset MapRoute.RenderType to USER_DEFINED.
Default value is PRIMARY.
Note: MapRoute must be added to a Map before calling this method. Otherwise, its value will not be changed.
Parameters:
type
The RenderType to be used.
Returns:
The updated MapRoute itself.
Throws:
IllegalArgumentException
if type is invalid.
IllegalStateException
if MapRoute is not added to Map.
HERE Android SDK Developer's Guide
API Reference
1081
public MapRoute setRoute (Route route)
Sets a Route that will be displayed on the Map .
Parameters:
route
A Route representing the route to be displayed on the Map.
Returns:
The updated MapRoute itself.
public MapRoute setTrafficEnabled (boolean enable)
Enable display of traffic on this MapRoute . By default traffic on route is disabled.
Note: Truck routes and public transport timetable routes are unsupported.
Parameters:
enable
True will display traffic if ONROUTE and setTrafficInfoVisible(boolean) have been enabled. False will hide
traffic on route rendering for this route.
Returns:
The updated MapRoute itself.
public MapRoute setTraveledColor (int argbColor)
Sets a color for displaying the traveled route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
Setting this property will change the traveled color of the MapRoute and change the RenderType to
USER_DEFINED. Calling setRenderType(MapRoute.RenderType) other than USER_DEFINED will reset any color
previously set by using this method.
setTraveledColor(int) is not supported by Transit and UrbanMobility routes.
Note: Alpha-value transparency is supported.
Parameters:
argbColor
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and
255 meaning 100% contribution.
Returns:
The updated MapRoute itself.
See also:
android.graphics.Color
HERE Android SDK Developer's Guide
API Reference
1082
RenderType
The enumeration RenderType is a member of com.here.android.mpa.mapping.MapRoute.
Enumeration Summary
public static final enumeration MapRoute.RenderType
extends java.lang.Enum, java.lang.Object
Render style of the route.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 534: Enum Constants in RenderType
Fields
public static final RenderType PRIMARY
Predefined "Primary" route style with fixed color.
public static final RenderType SECONDARY
Predefined "Secondary" route stlye with fixed color.
public static final RenderType TRAVELED
Deprecated: As of SDK 3.6.
Predefined "Traveled" route style with fixed colors.
public static final RenderType USER_DEFINED
Configurable custom route style.
Method Summary
Table 535: Methods in RenderType
Methods
public void setValue (int val)
Please contact HERE technical support if you require a custom configuration.
public int value ()
public static RenderType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapRoute.RenderType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1083
Enumeration Details
Render style of the route.
Note: route render style is defined per map scheme.
Enum Constant Details
public static final RenderType PRIMARY
Predefined "Primary" route style with fixed color.
public static final RenderType SECONDARY
Predefined "Secondary" route stlye with fixed color. Designed for rendering alternate routes.
public static final RenderType TRAVELED
Deprecated: As of SDK 3.6.
Use setTraveledColor(int).
Predefined "Traveled" route style with fixed colors. Renders the traveled and remaining sections of the route
in different colors.
public static final RenderType USER_DEFINED
Configurable custom route style. Use this render type to customize the route colors.
Method Details
public void setValue (int val)
Please contact HERE technical support if you require a custom configuration.
Parameters:
val
MapRoute.RenderType value.
public int value ()
public static RenderType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
1084
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapRoute.RenderType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapScreenMarker
The class MapScreenMarker is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapScreenMarker
extends com.here.android.mpa.mapping.MapObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a marker used to display an icon at a screen position on a map.
[For complete information, see the section Class Details]
Constructor Summary
Table 536: Constructors in MapScreenMarker
Constructors
MapScreenMarker ()
Default constructor.
MapScreenMarker (PointF position, Image icon)
Constructor
Method Summary
Table 537: Methods in MapScreenMarker
Methods
public PointF getAnchorPoint ()
Gets the anchor point for the MapScreenMarker .
public Image getIcon ()
Gets the icon image for the MapScreenMarker .
public PointF getScreenCoordinate ()
Gets the screen location of the MapScreenMarker .
HERE Android SDK Developer's Guide
API Reference
1085
Methods
public float getTransparency ()
Gets the current transparency level of the MapScreenMarker .
public MapScreenMarker setAnchorPoint (PointF anchor)
Sets an anchor point for the MapScreenMarker .
public MapScreenMarker setIcon (Image icon)
Sets an icon image for the MapScreenMarker .
public MapScreenMarker setScreenCoordinate (PointF position)
Sets the screen location of the MapScreenMarker .
public MapScreenMarker setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the MapScreenMarker .
Class Details
Represents a marker used to display an icon at a screen position on a map. The marker stays at its screen
location regardless of map movements such as panning and rotation.
MapScreenMarker are selectable MapObjects.
Constructor Details
MapScreenMarker ()
Default constructor. Call setIcon(Image) and setAnchorPoint(PointF) to place the marker.
MapScreenMarker (PointF position, Image icon)
Constructor
Parameters:
position
Anchor position
icon
An Image representing the icon. @see
See also:
setAnchorPoint(PointF)
setIcon(Image)
Method Details
public PointF getAnchorPoint ()
HERE Android SDK Developer's Guide
API Reference
1086
Gets the anchor point for the MapScreenMarker .
By default, the MapScreenMarker is anchored at the center of the icon image.
Returns:
A PointF representing the anchor point of the MapScreenMarker.
public Image getIcon ()
Gets the icon image for the MapScreenMarker .
Returns:
An Image representing the icon.
public PointF getScreenCoordinate ()
Gets the screen location of the MapScreenMarker .
Returns:
A PointF representing the screen location of the marker.
public float getTransparency ()
Gets the current transparency level of the MapScreenMarker .
The transparency level is only precise to two decimal places due to numerical operations performed
internally when rendering the map.
Returns:
The current transparency level of the MapScreenMarker.
public MapScreenMarker setAnchorPoint (PointF anchor)
Sets an anchor point for the MapScreenMarker .
The marker is drawn with the specified pixel offset from its getScreenCoordinate() position. To clear an
anchor set previously, pass a PointF to this method with an X-coordinate equal to half the width of the
marker and a Y-coordinate equal to half the height of the marker.
By default, the MapScreenMarker is anchored at the center of the icon image.
Parameters:
anchor
A PointF representing the anchor point of the MapScreenMarker.
Returns:
The updated MapScreenMarker itself.
HERE Android SDK Developer's Guide
API Reference
1087
public MapScreenMarker setIcon (Image icon)
Sets an icon image for the MapScreenMarker .
Parameters:
icon
An Image representing the icon.
Returns:
The updated MapScreenMarker object itself.
public MapScreenMarker setScreenCoordinate (PointF position)
Sets the screen location of the MapScreenMarker .
Parameters:
position
A PointF
Returns:
The updated MapScreenMarker itself.
public MapScreenMarker setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the MapScreenMarker .
Parameters:
alpha
Desired alpha value for the MapScreenMarker, 0 for fully transparent, 1 for fully opaque. Default value
is 1.
Returns:
The modified MapScreenMarker itself.
Throws:
IllegalArgumentException
if alpha is not within the range [0..1]
MapState
The class MapState is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapState
HERE Android SDK Developer's Guide
API Reference
1088
implements android.os.Parcelable
extends java.lang.Object
Represents a composite class comprised of tilt, orientation, zoom level and center point for a Map.
[For complete information, see the section Class Details]
Constructor Summary
Table 538: Constructors in MapState
Constructors
MapState (float tilt, float orientation, double zoomLevel, GeoCoordinate center)
A constructor that initializes state values for tilt, orientation, zoom level, and map center.
Field Summary
Table 539: Fields in MapState
Fields
public static final android.os.Parcelable.Creator <MapState> CREATOR
Method Summary
Table 540: Methods in MapState
Methods
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public GeoCoordinate getCenter ()
Returns the GeoCoordinate representing the center position.
public float getOrientation ()
Returns the orientation, in degrees relative to true-north (which is designated as being an orientation of 0 degrees).
public float getTilt ()
Returns the tilt, in degrees.
public double getZoomLevel ()
Returns the zoom level.
public void writeToParcel (Parcel dest, int flags)
For documentation, see android.os.Parcelable.writeToParcel()
Class Details
Represents a composite class comprised of tilt, orientation, zoom level and center point for a Map. This
object can be retrieved by calling getMapState().
HERE Android SDK Developer's Guide
API Reference
1089
Constructor Details
MapState (float tilt, float orientation, double zoomLevel, GeoCoordinate
center)
A constructor that initializes state values for tilt, orientation, zoom level, and map center.
Parameters:
tilt
tilt value, in degrees
orientation
orientation value, in degrees, where true-north is 0 degrees
zoomLevel
zoom level value
center
A GeoCoordinate representing the center of the map
See also:
setTilt(float)
setOrientation(float)
setZoomLevel(double)
Field Details
public static final android.os.Parcelable.Creator <MapState> CREATOR
Method Details
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public GeoCoordinate getCenter ()
Returns the GeoCoordinate representing the center position.
Returns:
The center position GeoCoordinate
public float getOrientation ()
Returns the orientation, in degrees relative to true-north (which is designated as being an orientation of 0
degrees).
HERE Android SDK Developer's Guide
API Reference
1090
Returns:
orientation, in degrees relative to true-north
public float getTilt ()
Returns the tilt, in degrees.
Returns:
tilt, in degrees
public double getZoomLevel ()
Returns the zoom level.
Returns:
zoom level
public void writeToParcel (Parcel dest, int flags)
For documentation, see android.os.Parcelable.writeToParcel()
Parameters:
dest
flags
MapTrafficLayer
The class MapTrafficLayer is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapTrafficLayer
extends java.lang.Object
Class to represent Traffic rendering information.
[For complete information, see the section Class Details]
See also:
getMapTrafficLayer()
HERE Android SDK Developer's Guide
API Reference
1091
Nested Class Summary
Table 541: Nested Classes in MapTrafficLayer
Nested Classes
public static final enumeration MapTrafficLayer.RenderLayer
Represents values describing various traffic layers that can be displayed within a MapTrafficLayer .
Method Summary
Table 542: Methods in MapTrafficLayer
Methods
public Severity getDisplayFilter ()
This method retrieves current value of the display filter.
public boolean isEnabled (RenderLayer layer)
Checks if a Traffic Layer defined in RenderLayer is enabled.
public boolean setDisplayFilter (Severity severity)
This method sets a minimal severity of Traffic Events which shall be displayed.
public void setEnabled (RenderLayer layer, boolean enable)
Enable a Traffic Layer defined in RenderLayer .
Class Details
Class to represent Traffic rendering information. This class can be used to control which types of traffic are
rendered.
See also:
getMapTrafficLayer()
Method Details
public Severity getDisplayFilter ()
This method retrieves current value of the display filter.
Returns:
severity The current value of the display filter.
public boolean isEnabled (RenderLayer layer)
Checks if a Traffic Layer defined in RenderLayer is enabled.
Parameters:
layer
HERE Android SDK Developer's Guide
API Reference
1092
a traffic layer defined in RenderLayer.
Returns:
True if the layer is enabled. False, otherwise.
public boolean setDisplayFilter (Severity severity)
This method sets a minimal severity of Traffic Events which shall be displayed. So, calling
setDisplayFilter(Severity) with filter set to BLOCKING means that only blocking events will be displayed.
Calling setDisplayFilter(Severity) with filter set to NORMAL means that all events (BLOCKING, VERY_HIGH,
HIGH, NORMAL) will be displayed. The default display filter is NORMAL.
Parameters:
severity
A minimal severity which shall be displayed.
Returns:
true if successful, false otherwise. Passing UNDEFINED will return false.
public void setEnabled (RenderLayer layer, boolean enable)
Enable a Traffic Layer defined in RenderLayer . The default behavior is that all RenderLayers are enabled.
Parameters:
layer
a traffic layer defined in RenderLayer.
enable
True to enable, false to disable.
RenderLayer
The enumeration RenderLayer is a member of com.here.android.mpa.mapping.MapTrafficLayer.
Enumeration Summary
public static final enumeration MapTrafficLayer.RenderLayer
extends java.lang.Enum, java.lang.Object
Represents values describing various traffic layers that can be displayed within a MapTrafficLayer .
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1093
Enum Constant Summary
Table 543: Enum Constants in RenderLayer
Fields
public static final RenderLayer FLOW
Show traffic flow layer
public static final RenderLayer INCIDENT
Show traffic incidents layer
public static final RenderLayer ONROUTE
Show on route traffic layer
Method Summary
Table 544: Methods in RenderLayer
Methods
public int getValue ()
public static RenderLayer valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapTrafficLayer.RenderLayer[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing various traffic layers that can be displayed within a MapTrafficLayer .
Enum Constant Details
public static final RenderLayer FLOW
Show traffic flow layer
public static final RenderLayer INCIDENT
Show traffic incidents layer
public static final RenderLayer ONROUTE
Show on route traffic layer
HERE Android SDK Developer's Guide
API Reference
1094
Method Details
public int getValue ()
public static RenderLayer valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapTrafficLayer.RenderLayer[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapTransitLayer
The class MapTransitLayer is a member of com.here.android.mpa.mapping .
Class Summary
public final class MapTransitLayer
extends java.lang.Object
Represents a Map layer that can display any combination of transit stops, accesses, and lines (including
none).
[For complete information, see the section Class Details]
See also:
getMapTransitLayer()
Nested Class Summary
Table 545: Nested Classes in MapTransitLayer
Nested Classes
public static final enumeration MapTransitLayer.Mode
Represents values describing various ways to display public transit within a MapTransitLayer .
HERE Android SDK Developer's Guide
API Reference
1095
Method Summary
Table 546: Methods in MapTransitLayer
Methods
public void clearTransitHighlights ()
Clears all MapTransitLayer elements, resetting them to a non-highlighted state.
public Mode getMode ()
Gets the Mode for the MapTransitLayer .
public void highlightTransitAccesses (java.util.List <Identifier> ids)
Highlights a specified list of transit accesses.
public void highlightTransitLineSegments (java.util.List <Identifier> ids)
Highlights a specified list of transit segment lines.
public void highlightTransitLines (java.util.List <Identifier> ids)
Highlights a specified list of transit lines.
public void highlightTransitStops (java.util.List <Identifier> ids)
Highlights a specified list of transit stops.
public void setMode (Mode mode)
Sets a Mode for the MapTransitLayer .
Class Details
Represents a Map layer that can display any combination of transit stops, accesses, and lines (including
none).
See also:
getMapTransitLayer()
Method Details
public void clearTransitHighlights ()
Clears all MapTransitLayer elements, resetting them to a non-highlighted state.
public Mode getMode ()
Gets the Mode for the MapTransitLayer .
Returns:
The Mode
public void highlightTransitAccesses (java.util.List <Identifier> ids)
HERE Android SDK Developer's Guide
API Reference
1096
Highlights a specified list of transit accesses. Previously highlighted lines remain highlighted until
clearTransitHighlights() is called to clear all highlighted objects.
Parameters:
ids
A list of IDs Identifier representing the accesses to highlight. If an Identifier supplied does not
match any transit accesses, it will be ignored.
See also:
getStopId()
getId()
clearTransitHighlights()
public void highlightTransitLineSegments (java.util.List <Identifier> ids)
Highlights a specified list of transit segment lines. Previously highlighted lines remain highlighted until
clearTransitHighlights() is called to clear all highlighted objects.
Parameters:
ids
A list of IDs Identifier representing the segment lines to highlight. If an Identifier supplied does
not match any transit segment lines, it will be ignored.
See also:
getLineSegmentId()
clearTransitHighlights()
public void highlightTransitLines (java.util.List <Identifier> ids)
Highlights a specified list of transit lines. Previously highlighted lines remain highlighted until
clearTransitHighlights() is called to clear all highlighted objects.
Parameters:
ids
A list of Identifiers representing the lines to highlight. If an Identifier supplied does not match any
transit lines, it will be ignored.
See also:
getLineId()
clearTransitHighlights()
public void highlightTransitStops (java.util.List <Identifier> ids)
HERE Android SDK Developer's Guide
API Reference
1097
Highlights a specified list of transit stops. Previously highlighted lines remain highlighted until
clearTransitHighlights() is called to clear all highlighted objects.
Parameters:
ids
A list of Identifiers representing the stops to highlight. If an Identifier supplied does not match
any transit stops, it will be ignored.
See also:
getStopId()
getId()
clearTransitHighlights()
public void setMode (Mode mode)
Sets a Mode for the MapTransitLayer . The default mode is STOPS_AND_ACCESSES.
Parameters:
mode
A Mode to set
Mode
The enumeration Mode is a member of com.here.android.mpa.mapping.MapTransitLayer.
Enumeration Summary
public static final enumeration MapTransitLayer.Mode
extends java.lang.Enum, java.lang.Object
Represents values describing various ways to display public transit within a MapTransitLayer .
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 547: Enum Constants in Mode
Fields
public static final Mode NOTHING
Hide all transit stops, accesses, and lines.
public static final Mode STOPS_AND_ACCESSES
(Default) Show transit stops and accesses, but hide transit lines.
HERE Android SDK Developer's Guide
API Reference
1098
Fields
public static final Mode EVERYTHING
Show transit stops, accesses, and lines.
Method Summary
Table 548: Methods in Mode
Methods
public int getValue ()
public static Mode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapTransitLayer.Mode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing various ways to display public transit within a MapTransitLayer .
Enum Constant Details
public static final Mode NOTHING
Hide all transit stops, accesses, and lines.
public static final Mode STOPS_AND_ACCESSES
(Default) Show transit stops and accesses, but hide transit lines.
public static final Mode EVERYTHING
Show transit stops, accesses, and lines.
Method Details
public int getValue ()
public static Mode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
1099
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapTransitLayer.Mode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapView
The class MapView is a member of com.here.android.mpa.mapping .
Class Summary
public class MapView
extends java.lang.Object
Represents a map view.
[For complete information, see the section Class Details]
See also:
MapActivity
android.view.ViewGroup
Constructor Summary
Table 549: Constructors in MapView
Constructors
MapView (Context context)
Constructor that initializes the context.
MapView (Context context, AttributeSet attrs)
Constructor that initializes the context and a set of attributes.
Method Summary
Table 550: Methods in MapView
Methods
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
protected void dispatchRestoreInstanceState (SparseArray container)
Override to prevent thawing of any child views.
HERE Android SDK Developer's Guide
API Reference
1100
Methods
protected void dispatchSaveInstanceState (SparseArray container)
Override to prevent freezing of any child views.
public ViewRect getClipRect ()
Gets the ViewRect representing the clip rectangle for the MapView .
public Rect getCopyrightBoundaryRect ()
Gets the current rectangle relative to the MapView's boundary as a container for the HERE copyright logo.
public int getCopyrightLogoHeight ()
Gets the height of the copyright logo.
public CopyrightLogoPosition getCopyrightLogoPosition ()
Gets the current position for the HERE copyright logo.
public int getCopyrightLogoVisibility ()
Gets the visibility of the HERE copyright logo.
public int getCopyrightLogoWidth ()
Gets the width of the copyright logo.
public int getCopyrightMargin ()
Gets the current margin, in pixels, for the HERE copyright logo, an offset from the edge of the visible map area to the edge
of the logo.
public Map getMap ()
Returns the instance of Map associated with this MapView
public MapGesture getMapGesture ()
Gets the MapGesture representing the current gesture handler for the MapView .
public PositionIndicator getPositionIndicator ()
Returns the PositionIndicator instance that renders the current position with a marker.
public void getScreenCapture (OnScreenCaptureListener listener)
Gets the full screen bitmap for the MapView.
protected void onLayout (boolean changed, int left, int top, int right, int bottom)
For documentation, see android.view.ViewGroup
protected void onMeasure (int widthMeasureSpec, int heightMeasureSpec)
For documentation, see android.view.ViewGroup
public void onPause ()
Propagates an activity's onPause() event to the view.
public void onRestoreInstanceState (Parcelable state)
Callback indicating that a stored view state was restored (e.g.
public void onResume ()
Propagates an activity's onResume() event to the view.
HERE Android SDK Developer's Guide
API Reference
1101
Methods
public Parcelable onSaveInstanceState ()
Callback indicating that the internal state of a view was saved for later use (e.g.
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the MapView .
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to the MapView .
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the MapView's boundary, for the placement of the HERE
copyright logo.
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
Sets a position for the HERE copyright logo.
public void setCopyrightMargin (int margin)
Sets a margin, in pixels, for the HERE copyright logo, an offset from the edge of the visible map area (or copyright boundary
rect, if used) to the edge of the logo (depending on the placement).
public void setMap (Map aMap)
Associates the graphical view element with a Map .
public void setMapMarkerDragListener (OnDragListener listener)
Sets a MapMarker.OnDragListener to be invoked whenever any MapMarker added onto a Map that is attached to this
MapView is dragged.
public void setOnTouchListener (View.OnTouchListener listener)
Sets an OnTouchListener to be invoked whenever a touch event is sent to the MapView .
Class Details
Represents a map view. This is the "View" UI class designed to handle all UI-related use cases, including
rendering and screen touch events.
Each MapView must be bound to a Map, and map-related objects should be persisted during application
runtime. MapView objects live and expire according to the associated activity's lifecycle.
A MapView is defined in an Android layout XML file. For example:
<com.here.android.mpa.mapping.MapView
android:id="@+id/mapview"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:visibility="visible"/>
Each MapView should follow the regular android lifecycle. When an activity's onResume() and onPause()
are called, the view should also be notified via calls from within those methods. Please take care in how
HERE Android SDK Developer's Guide
API Reference
1102
much processing is done in the onResume() method of an activity. Performing significant amounts of
processing may delay the view rendering in cases such as device orientation change. It is recommended to
use a specifically designated handler for organizing the amount of processing to be done in such cases.
Note that MapView does not notify the MapEngine when it is paused or resumed. User of MapView is
responsible for handling the pausing and resuming of the MapEngine if needed. Another option is to utilize
the MapActivity class when creating an activity with a MapView.
Although this class inherits from ViewGroup , it is not advisable for users to add children to MapView as no
layout actions will be performed on any added children views.
See also:
MapActivity
android.view.ViewGroup
Constructor Details
MapView (Context context)
Constructor that initializes the context.
Parameters:
context
Context of the MapView
See also:
MapView(Context, AttributeSet)
android.content.Context
MapView (Context context, AttributeSet attrs)
Constructor that initializes the context and a set of attributes.
Parameters:
context
Context of the MapView
attrs
An AttributeSet representing attributes of the MapView
See also:
MapView(Context)
android.content.Context
android.util.AttributeSet
HERE Android SDK Developer's Guide
API Reference
1103
Method Details
public void addOnMapRenderListener (OnMapRenderListener listener)
Adds a OnMapRenderListener to listen for map render events.
Parameters:
listener
A OnMapRenderListener to add to the MapView
See also:
removeOnMapRenderListener(OnMapRenderListener)
protected void dispatchRestoreInstanceState (SparseArray container)
Override to prevent thawing of any child views. As child views created and added to the view group
dynamically have the same id as the parent, causing conflict when the state is saved, all child views are
blocked from being saved. Instead, this container will manually trigger the save and restore.
Parameters:
container
protected void dispatchSaveInstanceState (SparseArray container)
Override to prevent freezing of any child views. As child views created and added to the view group
dynamically have the same id as the parent, causing conflict when the state is saved, all child views are
blocked from being saved. Instead, this container will manually trigger the save and restore.
Parameters:
container
public ViewRect getClipRect ()
Gets the ViewRect representing the clip rectangle for the MapView .
Returns:
The clip rectangle for rendering MapObject objects and similar map-related screen elements
public Rect getCopyrightBoundaryRect ()
Gets the current rectangle relative to the MapView's boundary as a container for the HERE copyright logo.
null is returned unless a boundary rect has been set previously.
Returns:
The boundary rect (null if not set).
See also:
HERE Android SDK Developer's Guide
API Reference
1104
getClipRect()
setCopyrightBoundaryRect(Rect)
public int getCopyrightLogoHeight ()
Gets the height of the copyright logo.
This method only returns a valid value once a Map has been set to this view.
Returns:
The height of the copyright logo in pixels. Returns -1 if unavailable.
public CopyrightLogoPosition getCopyrightLogoPosition ()
Gets the current position for the HERE copyright logo.
Returns:
The position of the logo.
public int getCopyrightLogoVisibility ()
Gets the visibility of the HERE copyright logo. Copyright logo is defaulted to be visible. Once changed, the
visibility of logo stays effective even when the screen is rotated or re-created.
Returns:
One of the two values View.VISIBLE or View.INVISIBLE to represent the copyright logo's visibility.
public int getCopyrightLogoWidth ()
Gets the width of the copyright logo.
This method only returns a valid value once a Map has been set to this view.
Returns:
The width of the copyright logo in pixels. Returns -1 if unavailable.
public int getCopyrightMargin ()
Gets the current margin, in pixels, for the HERE copyright logo, an offset from the edge of the visible map
area to the edge of the logo.
This method only returns a valid value once a Map has been set to this view.
Returns:
The current offset from the edge of the MapView
HERE Android SDK Developer's Guide
API Reference
1105
public Map getMap ()
Returns the instance of Map associated with this MapView
Returns:
The Map object currently displayed in this view.
public MapGesture getMapGesture ()
Gets the MapGesture representing the current gesture handler for the MapView . Applications can intercept
this object and override the default events.
Returns:
The MapGesture
public PositionIndicator getPositionIndicator ()
Returns the PositionIndicator instance that renders the current position with a marker. The position indicator
should be used with PositioningManager.
Returns:
The PositionIndicator
public void getScreenCapture (OnScreenCaptureListener listener)
Gets the full screen bitmap for the MapView. This API can be used to capture a screen shot of the MapView.
The API is asynchronous and will callback once the operation is completed via OnScreenCaptureListener.
Note the MapView must be visible to create the screen capture.
Parameters:
listener
A OnScreenCaptureListener to callback on screen capture completion.
protected void onLayout (boolean changed, int left, int top, int right, int
bottom)
For documentation, see android.view.ViewGroup
Parameters:
changed
left
top
right
bottom
HERE Android SDK Developer's Guide
API Reference
1106
protected void onMeasure (int widthMeasureSpec, int heightMeasureSpec)
For documentation, see android.view.ViewGroup
Parameters:
widthMeasureSpec
heightMeasureSpec
public void onPause ()
Propagates an activity's onPause() event to the view. Applications can call this method within the
onPause() method of any activity which has a MapView as part of its view hierarchy. Note that unlike
MapFragment, MapView does not automatically handle the pausing and/or resuming of MapEngine. Owner of
MapView is responsible to address the handling of onPause() if needed.
See also:
onPause()
onPause()
public void onRestoreInstanceState (Parcelable state)
Callback indicating that a stored view state was restored (e.g. to create a new MapView with the same state).
Parameters:
state
An android.os.Parcelable in which the view state was stored
See also:
android.view.View.onRestoreInstanceState(Parcelable)
public void onResume ()
Propagates an activity's onResume() event to the view. Applications can call this method within the
onResume() method of any activity which has a MapView as part of its view hierarchy. Note that unlike
MapFragment, MapView does not automatically handle the pausing and/or resuming of MapEngine. Owner of
MapView is responsible to address the handling of onResume() if needed.
See also:
onResume()
onResume()
public Parcelable onSaveInstanceState ()
Callback indicating that the internal state of a view was saved for later use (e.g. to create a new MapView
with the same state).
HERE Android SDK Developer's Guide
API Reference
1107
Returns:
The android.os.Parcelable for storing the view state
See also:
android.view.View.onSaveInstanceState()
public void removeOnMapRenderListener (OnMapRenderListener listener)
Removes an existing OnMapRenderListener.
Parameters:
listener
A OnMapRenderListener to remove from the MapView
public void setClipRect (ViewRect rect, PointF transformCenter)
Sets a clipping rectangle to the MapView .
The center of the map is not moved and remains at the center of the map control. Only the ViewRect
specified here will be used for rendering.
Note that the size of the map remains the same as the size of the map control.
The clipping rectangle (and the view rectangle) is reset to full-screen upon screen rotation or upon
recreating the screen.
Moreover, setting the clipping rectangle will reset the view rectangle to full-screen.
Parameters:
rect
A ViewRect for rendering MapObject objects and similar map-related screen elements
transformCenter
A PointF representing the center coordinate for map transformations such as zooming and rotation
Throws:
IllegalArgumentException
if ViewRect is not valid.
See also:
setClipRect(ViewRect)
public void setClipRect (ViewRect rect)
Sets a clipping rectangle to the MapView .
Note that the size of the map remains the same as the size of the map control.
HERE Android SDK Developer's Guide
API Reference
1108
The clipping rectangle (and the view rectangle) is reset to full-screen upon screen rotation or upon
recreating the screen.
Parameters:
rect
A ViewRect for rendering MapObject objects and similar map-related screen elements
Throws:
IllegalArgumentException
if ViewRect is not valid.
See also:
setClipRect(ViewRect, PointF)
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the MapView's boundary, for the placement of the
HERE copyright logo.
If the specified rectangle is not contained completely within the current visible map area, their area of
intersection will be used instead of the specified rectangle's area. If the specified rectangle is outside
the current visible map area, it will be ignored. The copyright logo and copyright margin must fit into the
rectangle, otherwise specified rectangle will be ignored.
The copyright boundary rectangle is reset upon screen rotation or upon screen re-creation.
Parameters:
rect
A Rect representing the rectangular container to position the copyright logo. Use null Rect to reset
the boundary container.
Throws:
IllegalArgumentException
if Rect supplied is invalid
public void setCopyrightLogoPosition (CopyrightLogoPosition position)
Sets a position for the HERE copyright logo. The current default is to place the logo at the center-bottom of
the visible map view area.
Note: after the logo's position is set, it stays effective even when the screen is rotated or re-created.
Parameters:
position
A CopyrightLogoPosition value representing the desired placement of the HERE copyright logo with
respect to the visible map view area
HERE Android SDK Developer's Guide
API Reference
1109
public void setCopyrightMargin (int margin)
Sets a margin, in pixels, for the HERE copyright logo, an offset from the edge of the visible map area (or
copyright boundary rect, if used) to the edge of the logo (depending on the placement). The logo and margin
must fit into the visible area (or copyright bounding rect). Therefore, the maximum allowed margin value is:
(bounding rect dimension - logo size) / 2. The default (minimum) margin value is 1/2 of logo width. A margin
value smaller than the default will not be saved.
Parameters:
margin
Desired offset from the edge of the MapView
See also:
setCopyrightBoundaryRect(Rect)
public void setMap (Map aMap)
Associates the graphical view element with a Map . Applications must call this method to bind the MapView
and Map .
Note: the Map that gets passed as a parameter to this method could be null , in which case all listeners will
be cleaned up.
Users are advised to call setMap(Map) with null to detach the map only after the onPause() is called to
avoid memory leaks.
Calling this method with null , allows map resources to be released in case there are no more references on
Map object. Otherwise map resources will not be released.
Parameters:
aMap
A Map to associate with the MapView (could be null)
public void setMapMarkerDragListener (OnDragListener listener)
Sets a MapMarker.OnDragListener to be invoked whenever any MapMarker added onto a Map that is attached
to this MapView is dragged.
Parameters:
listener
An MapMarker.OnDragListener to set for this MapView
public void setOnTouchListener (View.OnTouchListener listener)
Sets an OnTouchListener to be invoked whenever a touch event is sent to the MapView .
Parameters:
listener
HERE Android SDK Developer's Guide
API Reference
1110
An OnTouchListener to set for the MapView
See also:
android.view.View.OnTouchListener
Mesh
The class Mesh is a member of com.here.android.mpa.mapping .
Class Summary
public abstract class Mesh
extends java.lang.Object
Represents a base class specifying common mesh data for a MapGeoModelObject or
MapLocalModelObject .
[For complete information, see the section Class Details]
Method Summary
Table 551: Methods in Mesh
Methods
public FloatBuffer getTextureCoordinates ()
Gets a FloatBuffer containing the list of uv coordinates for the mesh.
public IntBuffer getVertexIndices ()
Gets the IntBuffer representing the list of mesh triangles.
public Mesh setTextureCoordinates (FloatBuffer uvCoordinates)
Sets a FloatBuffer representing a list of uv coordinates for the mesh.
public Mesh setVertexIndices (IntBuffer triangles)
Sets an IntBuffer representing a list of mesh triangles to render.
Class Details
Represents a base class specifying common mesh data for a MapGeoModelObject or
MapLocalModelObject .
Properties of a mesh include:
Vertex positions - positions of the mesh vertices (the maximum number of positions is 65536). Note: the
number of vertex positions should match the number of vertex texture coordinates, and both should be
equal to the number of vertices in the mesh data.
Vertex texture coordinates - coordinates within the range of [0..1], used to reference the specified
texture image (the maximum number of texture coordinates is 65536). Note: the number of vertex texture
HERE Android SDK Developer's Guide
API Reference
1111
coordinates should match the number of vertex positions, and both should be equal to the number of
vertices in the mesh data.
Triangles - the triangular faces of the mesh, defined as three indices referencing the corresponding set
of vertices.
Method Details
public FloatBuffer getTextureCoordinates ()
Gets a FloatBuffer containing the list of uv coordinates for the mesh. The buffer contains pairs for each
coordinate, where each pair is in the format uv( u, v ) and within the range of [0..1].
Returns:
A FloatBuffer with the mesh uv coordinates
public IntBuffer getVertexIndices ()
Gets the IntBuffer representing the list of mesh triangles. The buffer contains triplets for each triangle,
where each triplet is in the format t( v1, v2, v3 ) .
Returns:
A IntBuffer with mesh triangles
public Mesh setTextureCoordinates (FloatBuffer uvCoordinates)
Sets a FloatBuffer representing a list of uv coordinates for the mesh. The buffer should be in pairs for
each coordinate, where each pair is in the format uv( u, v ) and within the range of [0..1].
Parameters:
uvCoordinates
A FloatBuffer of desired mesh uv coordinates
Returns:
The updated Mesh
Throws:
IllegalArgumentException
if uvCoordinates is empty
IllegalArgumentException
if uvCoordinates does not contain even number of float values.
See also:
java.nio.FloatBuffer
public Mesh setVertexIndices (IntBuffer triangles)
HERE Android SDK Developer's Guide
API Reference
1112
Sets an IntBuffer representing a list of mesh triangles to render. The buffer should be in triplets for each
triangle, where each triplet is in the format t( v1, v2, v3 ) .
Parameters:
triangles
A IntBuffer of desired mesh triangles
Returns:
The updated Mesh
Throws:
IllegalArgumentException
if triangles is empty.
IllegalArgumentException
if triangles is not containing triplets of integers.
See also:
java.nio.IntBuffer
OnMapRenderListener
The interface OnMapRenderListener is a member of com.here.android.mpa.mapping .
Interface Summary
public abstract interface OnMapRenderListener
Represents an abstract class listener to provide notification upon completion of a Map rendering event.
[For complete information, see the section Interface Details]
See also:
addOnMapRenderListener(OnMapRenderListener)
removeOnMapRenderListener(OnMapRenderListener)
addOnMapRenderListener(OnMapRenderListener)
removeOnMapRenderListener(OnMapRenderListener)
Nested Class Summary
Table 552: Nested Classes in OnMapRenderListener
Nested Classes
public static abstract class OnMapRenderListener.OnMapRenderListenerAdapter
Default implementation for the OnMapRenderListener interface.
HERE Android SDK Developer's Guide
API Reference
1113
Method Summary
Table 553: Methods in OnMapRenderListener
Methods
public abstract void onGraphicsDetached ()
Callback indicating that the map renderer has been cleanly detached from the view.
public abstract void onPostDraw (boolean invalidated, long renderTime)
Callback indicating that a Map drawing event has ended.
public abstract void onPreDraw ()
Callback indicating that a Map drawing event is about to occur.
public abstract void onRenderBufferCreated ()
Callback indicating that the map render buffer has been created.
public abstract void onSizeChanged (int width, int height)
Callback indicating that a Map size has changed following a rotation.
Interface Details
Represents an abstract class listener to provide notification upon completion of a Map rendering event.
See also:
addOnMapRenderListener(OnMapRenderListener)
removeOnMapRenderListener(OnMapRenderListener)
addOnMapRenderListener(OnMapRenderListener)
removeOnMapRenderListener(OnMapRenderListener)
Method Details
public abstract void onGraphicsDetached ()
Callback indicating that the map renderer has been cleanly detached from the view.
public abstract void onPostDraw (boolean invalidated, long renderTime)
Callback indicating that a Map drawing event has ended. Applications can perform custom rendering when
this callback is sent.
Note: This callback is made on the rendering thread.
Parameters:
invalidated
A boolean specifying whether the map is invalidated and will redraw
renderTime
The time taken to render the map
HERE Android SDK Developer's Guide
API Reference
1114
public abstract void onPreDraw ()
Callback indicating that a Map drawing event is about to occur. Applications can perform custom rendering
when this callback is sent.
This callback is preferred to onPostDraw(boolean, long) when making changes to MapObjects as the changes
can be made during the upcoming draw and another Map invalidation will not need to take place.
Note: This callback is made on the rendering thread.
public abstract void onRenderBufferCreated ()
Callback indicating that the map render buffer has been created.
Note: This callback is made on the rendering thread.
public abstract void onSizeChanged (int width, int height)
Callback indicating that a Map size has changed following a rotation. Applications can perform custom
rendering when this callback is sent.
Note: This callback is made on the UI thread.
Parameters:
width
A post-rotation width
height
A post-rotation height
OnMapRenderListenerAdapter
The class OnMapRenderListenerAdapter is a member of
com.here.android.mpa.mapping.OnMapRenderListener.
Class Summary
public static abstract class OnMapRenderListener.OnMapRenderListenerAdapter
implements com.here.android.mpa.mapping.OnMapRenderListener
extends java.lang.Object
Default implementation for the OnMapRenderListener interface.
[For complete information, see the section Class Details]
See also:
OnMapRenderListener
HERE Android SDK Developer's Guide
API Reference
1115
Constructor Summary
Table 554: Constructors in OnMapRenderListenerAdapter
Constructors
OnMapRenderListenerAdapter ()
Method Summary
Table 555: Methods in OnMapRenderListenerAdapter
Methods
public void onGraphicsDetached ()
public void onPostDraw (boolean invalidated, long renderTime)
public void onPreDraw ()
public void onRenderBufferCreated ()
public void onSizeChanged (int width, int height)
Class Details
Default implementation for the OnMapRenderListener interface. Users may use this abstract class and
overload specific methods to have a smaller code footprint.
See also:
OnMapRenderListener
Constructor Details
OnMapRenderListenerAdapter ()
Method Details
public void onGraphicsDetached ()
public void onPostDraw (boolean invalidated, long renderTime)
Parameters:
invalidated
renderTime
public void onPreDraw ()
HERE Android SDK Developer's Guide
API Reference
1116
public void onRenderBufferCreated ()
public void onSizeChanged (int width, int height)
Parameters:
width
height
OperatingHours
The class OperatingHours is a member of com.here.android.mpa.mapping .
Class Summary
public final class OperatingHours
extends java.lang.Object
Represents the hours of operation for different days of the week, plus holidays.
[For complete information, see the section Class Details]
Method Summary
Table 556: Methods in OperatingHours
Methods
public java.util.List <TimeInterval> getFridaySchedule ()
Friday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getHolidaySchedule ()
Holiday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getMondaySchedule ()
Monday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getSaturdaySchedule ()
Saturday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getSundaySchedule ()
Sunday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getThursdaySchedule ()
Thursday schedule as a list of TimeInverval TimeInverval .
public java.util.List <TimeInterval> getTuesdaySchedule ()
Tuesday schedule as a list of TimeInverval TimeInverval .
HERE Android SDK Developer's Guide
API Reference
1117
Methods
public java.util.List <TimeInterval> getWednesdaySchedule ()
Wednesday schedule as a list of TimeInverval TimeInverval .
Class Details
Represents the hours of operation for different days of the week, plus holidays. For each day, the operating
hours are a non-overlapping sequence of intervals in increasing order of time. Used for specifying hours of
operation for services.
Method Details
public java.util.List <TimeInterval> getFridaySchedule ()
Friday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getHolidaySchedule ()
Holiday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getMondaySchedule ()
Monday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getSaturdaySchedule ()
Saturday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getSundaySchedule ()
Sunday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
HERE Android SDK Developer's Guide
API Reference
1118
public java.util.List <TimeInterval> getThursdaySchedule ()
Thursday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getTuesdaySchedule ()
Tuesday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
public java.util.List <TimeInterval> getWednesdaySchedule ()
Wednesday schedule as a list of TimeInverval TimeInverval .
Returns:
The array that contains the TimeInverval TimeInverval
PositionIndicator
The class PositionIndicator is a member of com.here.android.mpa.mapping .
Class Summary
public final class PositionIndicator
extends java.lang.Object
Represents a class for rendering a map marker to indicate the current position.
[For complete information, see the section Class Details]
See also:
PositioningManager
Method Summary
Table 557: Methods in PositionIndicator
Methods
public int getAccuracyIndicatorColor ()
Gets the current color of accuracy indicator circle, returning an ARGB (Alpha/Red/Green/Blue) integer color value.
HERE Android SDK Developer's Guide
API Reference
1119
Methods
public Image getMarker ()
Gets the current marker image.
public int getZIndex ()
Get the Z index of the position indicator.
public boolean isAccuracyIndicatorVisible ()
Gets the current visibility state of the GPS accuracy indicator.
public boolean isVisible ()
Gets the boolean indicating whether the PositionIndicator instance is visible.
public PositionIndicator setAccuracyIndicatorColor (int color)
Sets the color of the accuracy indicator circle using an ARGB (Alpha/Red/Green/Blue) integer color value.
public PositionIndicator setAccuracyIndicatorVisible (boolean visible)
Sets a GPS accuracy indicator for the PositionIndicator to be either visible or hidden.
public PositionIndicator setMarker (Image marker)
Sets a marker image, overriding the default marker image.
public PositionIndicator setVisible (boolean visible)
Sets a PositionIndicator to be either visible or hidden.
public PositionIndicator setZIndex (int index)
Set the Z index of the position indicator.
Class Details
Represents a class for rendering a map marker to indicate the current position. The marker is surrounded by
a circle, the diameter of which illustrates the accuracy of the marked position.
See also:
PositioningManager
Method Details
public int getAccuracyIndicatorColor ()
Gets the current color of accuracy indicator circle, returning an ARGB (Alpha/Red/Green/Blue) integer color
value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255], with 0 meaning no contribution for that component and 255
meaning 100% contribution
See also:
android.graphics.Color
HERE Android SDK Developer's Guide
API Reference
1120
public Image getMarker ()
Gets the current marker image.
Returns:
The marker Image used to display the current position on a map
public int getZIndex ()
Get the Z index of the position indicator.
Returns:
int current z index.
public boolean isAccuracyIndicatorVisible ()
Gets the current visibility state of the GPS accuracy indicator.
Returns:
True if the GPS accuracy indicator is visible, false otherwise
public boolean isVisible ()
Gets the boolean indicating whether the PositionIndicator instance is visible.
Returns:
True if the PositionIndicator is visible, false otherwise
public PositionIndicator setAccuracyIndicatorColor (int color)
Sets the color of the accuracy indicator circle using an ARGB (Alpha/Red/Green/Blue) integer color value.
The default line color is Color.GREEN .
Parameters:
color
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated PositionIndicator itself.
See also:
android.graphics.Color
HERE Android SDK Developer's Guide
API Reference
1121
public PositionIndicator setAccuracyIndicatorVisible (boolean visible)
Sets a GPS accuracy indicator for the PositionIndicator to be either visible or hidden. Accuracy is
represented by a circle surrounding the marked position, with a smaller diameter representing higher
accuracy. The default is the GPS accuracy is visible.
Note: if the PositionIndicator is hidden, the GPS accuracy indicator will be hidden as well.
Parameters:
visible
A boolean specifying whether the accuracy indicator should be visible
Returns:
PositionIndicator this object for method chaining.
See also:
setVisible(boolean)
public PositionIndicator setMarker (Image marker)
Sets a marker image, overriding the default marker image.
Parameters:
marker
An Image representing the marker used to display the current position on a map
Returns:
PositionIndicator this object for method chaining.
public PositionIndicator setVisible (boolean visible)
Sets a PositionIndicator to be either visible or hidden. By default, the position indicator is invisible.
Parameters:
visible
A boolean specifying PositionIndicator visibility
Returns:
PositionIndicator this object for method chaining.
public PositionIndicator setZIndex (int index)
Set the Z index of the position indicator. The default Z-Index is currently the max value supported.
Parameters:
index
HERE Android SDK Developer's Guide
API Reference
1122
A new z-index value for the MapObject, a 16-bit int within the range of [0..65535]
Returns:
PositionIndicator this object for method chaining.
See also:
setZIndex(int)
SafetySpotInfo
The class SafetySpotInfo is a member of com.here.android.mpa.mapping .
Class Summary
public final class SafetySpotInfo
extends java.lang.Object
Contains information about a particular safety spot.
[For complete information, see the section Class Details]
Nested Class Summary
Table 558: Nested Classes in SafetySpotInfo
Nested Classes
public static final enumeration SafetySpotInfo.Type
Method Summary
Table 559: Methods in SafetySpotInfo
Methods
public GeoCoordinate getCoordinate ()
Gets the position GeoCoordinate for the safety spot.
public int getHeading1Deg ()
Returns the heading, in degrees, representing the operational direction of the safety spot camera.
public int getHeading2Deg ()
Returns the heading for the ( possible ) second camera.
public int getSpeedLimit1 ()
Returns the speed limit the camera on heading 1 is triggered.
public int getSpeedLimit2 ()
Returns the speed limit the camera on heading 2 is triggered.
HERE Android SDK Developer's Guide
API Reference
1123
Methods
public Type getType ()
Returns the type of this safety spot.
public String toString ()
For documentation, see java.lang.Object
Class Details
Contains information about a particular safety spot. Common types of safety spots include speed camera
and red light camera.
Method Details
public GeoCoordinate getCoordinate ()
Gets the position GeoCoordinate for the safety spot.
Returns:
position of the stop.
public int getHeading1Deg ()
Returns the heading, in degrees, representing the operational direction of the safety spot camera. The
operational direction is the direction of travel for vehicles to be detected by the camera, regardless of
whether the camera photographs the front or rear of the vehicle. If no heading is returned (the returned
value is zero), then this means the camera operates in all directions.
A safety spot may have two cameras, for more information see getHeading2Deg().
Returns:
The heading, 1 - 359, 1 = north increases clockwise.
public int getHeading2Deg ()
Returns the heading for the ( possible ) second camera. If heading 1 is not zero, and heading 2 is zero, then
there is only one camera, using the heading 1.
Returns:
The heading, 1 - 359, 1 = north increases clockwise.
public int getSpeedLimit1 ()
Returns the speed limit the camera on heading 1 is triggered.
Returns:
The speed limit, in meters per second
HERE Android SDK Developer's Guide
API Reference
1124
public int getSpeedLimit2 ()
Returns the speed limit the camera on heading 2 is triggered.
Returns:
The speed limit, in meters per second
public Type getType ()
Returns the type of this safety spot.
Returns:
the safetyspot type
public String toString ()
For documentation, see java.lang.Object
Type
The enumeration Type is a member of com.here.android.mpa.mapping.SafetySpotInfo.
Enumeration Summary
public static final enumeration SafetySpotInfo.Type
extends java.lang.Enum, java.lang.Object
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 560: Enum Constants in Type
Fields
public static final Type UNDEFINED
Type of safety spot is unknown.
public static final Type SPEED_CAMERA
Type of safety spot is speed camera.
public static final Type REDLIGHT_CAMERA
Type of safety spot is red light camera.
public static final Type SPEED_REDLIGHT_CAMERA
Type of safety spot is a combination of red light camera and speed camera.
HERE Android SDK Developer's Guide
API Reference
1125
Method Summary
Table 561: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static SafetySpotInfo.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final Type UNDEFINED
Type of safety spot is unknown.
public static final Type SPEED_CAMERA
Type of safety spot is speed camera.
public static final Type REDLIGHT_CAMERA
Type of safety spot is red light camera.
public static final Type SPEED_REDLIGHT_CAMERA
Type of safety spot is a combination of red light camera and speed camera.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static SafetySpotInfo.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1126
SafetySpotObject
The class SafetySpotObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class SafetySpotObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a public safety spot on a map.
[For complete information, see the section Class Details]
See also:
SafetySpotInfo
Method Summary
Table 562: Methods in SafetySpotObject
Methods
public SafetySpotInfo getSafetySpotInfo ()
Gets the SafetySpotInfo object.
Class Details
Encapsulates information about a public safety spot on a map.
A SafetySpotObject represents a specialized MapProxyObject. User can retrieve an instance of this object
by calling getSelectedObjects(PointF) or getSelectedObjects(ViewRect) with the location where a safety spot is
located.
See also:
SafetySpotInfo
Method Details
public SafetySpotInfo getSafetySpotInfo ()
Gets the SafetySpotInfo object.
Returns:
The SafetySpotInfo
HERE Android SDK Developer's Guide
API Reference
1127
TrafficEvent
The class TrafficEvent is a member of com.here.android.mpa.mapping .
Class Summary
public final class TrafficEvent
extends java.lang.Object
Represents information about a traffic event.
[For complete information, see the section Class Details]
Nested Class Summary
Table 563: Nested Classes in TrafficEvent
Nested Classes
public static abstract interface TrafficEvent.Listener
Event Listener interface for traffic event
public static final enumeration TrafficEvent.Severity
Indicates the serverity of the traffic events.
Field Summary
Table 564: Fields in TrafficEvent
Fields
public static final int DATA_UNAVAILABLE
Indicates it was not possible to obtain the requested data.
Method Summary
Table 565: Methods in TrafficEvent
Methods
public Date getActivationDate ()
To get date and time when this TrafficEvent will be or has been activated.
public GeoBoundingBox getAffectedArea ()
Return the bounding box affected by this TrafficEvent .
public int getAffectedLength ()
Return the length of this TrafficEvent .
HERE Android SDK Developer's Guide
API Reference
1128
Methods
public java.util.List <RoadElement> getAffectedRoadElements ()
Return affected RoadElements.
public List getAffectedStreets ()
The names of the streets that are affected by this TrafficEvent .
public void getAffectedStreets (Listener<String> listener)
Gets the names of the streets that are affected by this TrafficEvent asynchronously.
public int getDistanceTo (GeoCoordinate geoCoordinates)
Calculate distance to the TrafficEvent .
public int getEstimatedSpeedLimit ()
Return the estimated speed that applies on the road elements affected by the traffic event.
public String getEventText ()
Gets the text of the traffic event.
public String getFirstAffectedStreet ()
Gets the name of the first street affected by this TrafficEvent .
public void getFirstAffectedStreet (Listener<String> listener)
Gets the name of the first street affected by this TrafficEvent asynchronously.
public List getFromStreets ()
Gets the names of the streets of the intersection where the location of the traffic event starts.
public void getFromStreets (Listener<String> listener)
Gets the names of the streets of the intersection where the location of the traffic event starts (asynchronously).
public Image getIconOffRoute ()
Return the off-route icon associated to this TrafficEvent .
public Image getIconOnRoute ()
Return the on-route icon associated to this TrafficEvent .
public short getPenalty ()
Gets the penalty associated with this event where 100 is blocked and 0 is unblocked.
public Severity getSeverity ()
Gets the TrafficEvent.Severity of this event.
public String getShortText ()
Gets the short text (category) of this event.
public int getSpeedLimit ()
Return the speed that applies on the road elements affected by the traffic event.
public List getToStreets ()
Gets the names of the streets of the intersection where the location of the traffic event ends.
HERE Android SDK Developer's Guide
API Reference
1129
Methods
public void getToStreets (Listener<String> listener)
Gets the names of the streets of the intersection where the location of the traffic event ends (asynchronously).
public Date getUpdateDate ()
To get date and time when this TrafficEvent has been updated.
public boolean isActive ()
Check if this TrafficEvent is active.
public boolean isFlow ()
Check if this TrafficEvent is a flow event.
public boolean isIncident ()
Check if this TrafficEvent is an incident event.
public boolean isOnRoute (Route route)
Check if the given Route is affected by this TrafficEvent .
public boolean isReroutable ()
Check if this TrafficEvent is re-routable.
public boolean isVisible ()
Check if this TrafficEvent is visible.
public String toString ()
Class Details
Represents information about a traffic event. Traffic events are displayed on a client device by way of a
TrafficEventObject object, which encapsulates its map coordinates.
Field Details
public static final int DATA_UNAVAILABLE
Indicates it was not possible to obtain the requested data.
Method Details
public Date getActivationDate ()
To get date and time when this TrafficEvent will be or has been activated.
Returns:
date and time.
public GeoBoundingBox getAffectedArea ()
HERE Android SDK Developer's Guide
API Reference
1130
Return the bounding box affected by this TrafficEvent .
Returns:
The GeoBoundingBox representing the area affected.
public int getAffectedLength ()
Return the length of this TrafficEvent .
Returns:
total length in meters.
public java.util.List <RoadElement> getAffectedRoadElements ()
Return affected RoadElements.
Returns:
array of RoadElement.
public List getAffectedStreets ()
The names of the streets that are affected by this TrafficEvent . The order of the street names does not
have any significance.
Returns:
The List of street names affected by the traffic event. Can be null if not yet processed. Use
getAffectedStreets(Listener) to avoid receiving null.
public void getAffectedStreets (Listener<String> listener)
Gets the names of the streets that are affected by this TrafficEvent asynchronously. The order of the
street names does not have any significance.
Parameters:
listener
The TrafficEvent.Listener that receives the result callback.
public int getDistanceTo (GeoCoordinate geoCoordinates)
Calculate distance to the TrafficEvent .
Parameters:
geoCoordinates
coordinates
Returns:
HERE Android SDK Developer's Guide
API Reference
1131
distance in meters.
public int getEstimatedSpeedLimit ()
Return the estimated speed that applies on the road elements affected by the traffic event. Speed in this
context refers to how fast traffic is moving.
If it is not possible to obtain an estimated speed DATA_UNAVAILABLE will be returned. It is possible a trusted
speed may be available instead, this can be checked by way of getSpeedLimit().
Returns:
speed limit in km/h or DATA_UNAVAILABLE if no estimated speed is available.
public String getEventText ()
Gets the text of the traffic event.
Returns:
The String containing traffic event information
public String getFirstAffectedStreet ()
Gets the name of the first street affected by this TrafficEvent .
Returns:
the street name. Can be null if not yet processed. Use getFirstAffectedStreet(Listener) to avoid receiving
null.
public void getFirstAffectedStreet (Listener<String> listener)
Gets the name of the first street affected by this TrafficEvent asynchronously.
Parameters:
listener
The TrafficEvent.Listener that receives the result callback.
public List getFromStreets ()
Gets the names of the streets of the intersection where the location of the traffic event starts.
Returns:
A list of streets. Can be null if not yet processed. When null the caller should try again later or use
getFromStreets(Listener).
public void getFromStreets (Listener<String> listener)
HERE Android SDK Developer's Guide
API Reference
1132
Gets the names of the streets of the intersection where the location of the traffic event starts
(asynchronously).
Parameters:
listener
The TrafficEvent.Listener that receives the result callback.
public Image getIconOffRoute ()
Return the off-route icon associated to this TrafficEvent . Can be null if there is no icon.
Returns:
traffic event icon.
public Image getIconOnRoute ()
Return the on-route icon associated to this TrafficEvent . Can be null if there is no icon.
Returns:
traffic event icon.
public short getPenalty ()
Gets the penalty associated with this event where 100 is blocked and 0 is unblocked.
Returns:
The penalty associated with this event.
public Severity getSeverity ()
Gets the TrafficEvent.Severity of this event.
Returns:
The Severity of this event.
public String getShortText ()
Gets the short text (category) of this event.
Returns:
The default possible return values are "CLOSURE", "ROADWORKS", "ACCIDENT", "CONGESTION", "OTHER",
"FLOW". The text is NOT localized.
public int getSpeedLimit ()
HERE Android SDK Developer's Guide
API Reference
1133
Return the speed that applies on the road elements affected by the traffic event. Speed in this context refers
to how fast traffic is moving. This value is expected to be accurate, because it reflects field probes.
If it is not possible to obtain a trusted speed DATA_UNAVAILABLE will be returned. It is possible an estimated
speed may be available instead, this can be checked by way of getEstimatedSpeedLimit().
Returns:
speed limit in km/h or DATA_UNAVAILABLE if no trusted speed is available.
public List getToStreets ()
Gets the names of the streets of the intersection where the location of the traffic event ends.
Returns:
A list of streets. Can be null if not yet processed. When null the caller should try again later or use
getToStreets(TrafficEvent.Listener).
public void getToStreets (Listener<String> listener)
Gets the names of the streets of the intersection where the location of the traffic event ends
(asynchronously).
Parameters:
listener
The TrafficEvent.Listener that receives the result callback.
public Date getUpdateDate ()
To get date and time when this TrafficEvent has been updated.
Returns:
date and time.
public boolean isActive ()
Check if this TrafficEvent is active.
Returns:
true if this TrafficEvent is active, false otherwise
public boolean isFlow ()
Check if this TrafficEvent is a flow event.
Returns:
true if this TrafficEvent is a flow event, false otherwise.
HERE Android SDK Developer's Guide
API Reference
1134
public boolean isIncident ()
Check if this TrafficEvent is an incident event.
Returns:
true if this TrafficEvent is an incident event, false otherwise.
public boolean isOnRoute (Route route)
Check if the given Route is affected by this TrafficEvent .
Parameters:
route
Route to be checked.
Returns:
true if affected, otherwise false.
public boolean isReroutable ()
Check if this TrafficEvent is re-routable.
Returns:
true if this TrafficEvent is re-routable, false otherwise.
public boolean isVisible ()
Check if this TrafficEvent is visible.
Returns:
true if this TrafficEvent is visible, false otherwise
public String toString ()
Listener<T>
The interface Listener<T> is a member of com.here.android.mpa.mapping.TrafficEvent.
Type Parameters:
T
HERE Android SDK Developer's Guide
API Reference
1135
Interface Summary
public static abstract interface TrafficEvent.Listener
Event Listener interface for traffic event
[For complete information, see the section Interface Details]
Method Summary
Table 566: Methods in Listener<T>
Methods
public abstract void onComplete (T result)
A callback indicating that traffic events information retrieval completed.
Interface Details
Event Listener interface for traffic event
Method Details
public abstract void onComplete (T result)
A callback indicating that traffic events information retrieval completed.
Parameters:
result
The object containing result value.
Severity
The enumeration Severity is a member of com.here.android.mpa.mapping.TrafficEvent.
Enumeration Summary
public static final enumeration TrafficEvent.Severity
extends java.lang.Enum, java.lang.Object
Indicates the serverity of the traffic events.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1136
Enum Constant Summary
Table 567: Enum Constants in Severity
Fields
public static final Severity UNDEFINED
Undefined.
public static final Severity NORMAL
Normal.
public static final Severity HIGH
High.
public static final Severity VERY_HIGH
Very high.
public static final Severity BLOCKING
Blocking.
Method Summary
Table 568: Methods in Severity
Methods
public int getValue ()
public static Severity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TrafficEvent.Severity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Indicates the serverity of the traffic events.
Enum Constant Details
public static final Severity UNDEFINED
Undefined.
public static final Severity NORMAL
Normal.
public static final Severity HIGH
HERE Android SDK Developer's Guide
API Reference
1137
High.
public static final Severity VERY_HIGH
Very high.
public static final Severity BLOCKING
Blocking.
Method Details
public int getValue ()
public static Severity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TrafficEvent.Severity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficEventObject
The class TrafficEventObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class TrafficEventObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a traffic event on a map.
[For complete information, see the section Class Details]
See also:
TrafficEvent
HERE Android SDK Developer's Guide
API Reference
1138
Method Summary
Table 569: Methods in TrafficEventObject
Methods
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the traffic event icon on the map.
public TrafficEvent getTrafficEvent ()
Gets the TrafficEvent associated with the TrafficEventObject .
Class Details
Encapsulates information about a traffic event on a map.
A TrafficEventObject represents a specialized MapProxyObject .User can retrieve an instance of this
object by calling getSelectedObjects(PointF) or getSelectedObjects(ViewRect) with the location where a traffic
event is located.
See also:
TrafficEvent
Method Details
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the traffic event icon on the map.
Returns:
The GeoCoordinate
public TrafficEvent getTrafficEvent ()
Gets the TrafficEvent associated with the TrafficEventObject . A TrafficEvent instance contains
detailed information about a traffic event.
Returns:
The TrafficEvent.
TransitAccessInfo
The class TransitAccessInfo is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitAccessInfo
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1139
Data structure class containing information about Transit Access locations.
[For complete information, see the section Class Details]
See also:
TransitAccessObject
Nested Class Summary
Table 570: Nested Classes in TransitAccessInfo
Nested Classes
public static final enumeration TransitAccessInfo.Attribute
Represents values describing the attributes of transit access.
public static final enumeration TransitAccessInfo.Method
Represents values describing the accessible methods of transit access.
Method Summary
Table 571: Methods in TransitAccessInfo
Methods
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute of the transit access.
public GeoCoordinate getCoordinate ()
Gets the position GeoCoordinate for the transit access.
public java.util.EnumSet <Method> getEntranceMethods ()
Gets all the entrance Method s provided by the transit access.
public java.util.EnumSet <Method> getExitMethods ()
Gets all the exit Method s provided by the transit access.
public Identifier getId ()
Gets the Identifier for the transit access.
public int getLevel ()
Gets the access level.
public String getName ()
Gets the name for the transit access.
public OperatingHours getOpeningHours ()
Gets the opening hours.
public Identifier getStopId ()
Gets the Identifier for the stop at the transit access.
HERE Android SDK Developer's Guide
API Reference
1140
Methods
public java.util.EnumSet <TransitType> getTransitTypes ()
Gets all the TransitTypes the transit access supports.
Class Details
Data structure class containing information about Transit Access locations.
See also:
TransitAccessObject
Method Details
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute of the transit access.
Returns:
A EnumSet containing all the Attributes of the transit access.
public GeoCoordinate getCoordinate ()
Gets the position GeoCoordinate for the transit access.
Returns:
position of the transit access.
public java.util.EnumSet <Method> getEntranceMethods ()
Gets all the entrance Method s provided by the transit access.
Returns:
A EnumSet containing all the entrance Methods provided by the transit access.
public java.util.EnumSet <Method> getExitMethods ()
Gets all the exit Method s provided by the transit access.
Returns:
A EnumSet containing all the exit Methods provided by the transit access.
public Identifier getId ()
Gets the Identifier for the transit access.
Returns:
HERE Android SDK Developer's Guide
API Reference
1141
the unique object Identifier.
See also:
TransitDatabase
public int getLevel ()
Gets the access level.
Returns:
the access level.
public String getName ()
Gets the name for the transit access. This text is localized according to the device's locale.
Returns:
name of the transit access.
public OperatingHours getOpeningHours ()
Gets the opening hours.
Returns:
The OperatingHours representing the opening hours of this transit access.
public Identifier getStopId ()
Gets the Identifier for the stop at the transit access.
Returns:
the unique object Identifier.
See also:
TransitDatabase
public java.util.EnumSet <TransitType> getTransitTypes ()
Gets all the TransitTypes the transit access supports.
Returns:
A EnumSet containing all the supported TransitTypes.
HERE Android SDK Developer's Guide
API Reference
1142
Attribute
The enumeration Attribute is a member of com.here.android.mpa.mapping.TransitAccessInfo.
Enumeration Summary
public static final enumeration TransitAccessInfo.Attribute
extends java.lang.Enum, java.lang.Object
Represents values describing the attributes of transit access.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 572: Enum Constants in Attribute
Fields
public static final Attribute ALLOWS_ENTERING
Transit access allows to enter.
public static final Attribute ALLOWS_EXITING
Transit access allows to exit.
public static final Attribute ACCESSIBLE_TO_DISABLED
Transit access accessible to disability.
public static final Attribute LEVEL_DIFFERENT_FROM_GROUND
Transit access's level is different from ground.
public static final Attribute HAS_NAMES
Transit access has proper name.
Method Summary
Table 573: Methods in Attribute
Methods
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitAccessInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the attributes of transit access.
HERE Android SDK Developer's Guide
API Reference
1143
Enum Constant Details
public static final Attribute ALLOWS_ENTERING
Transit access allows to enter.
public static final Attribute ALLOWS_EXITING
Transit access allows to exit.
public static final Attribute ACCESSIBLE_TO_DISABLED
Transit access accessible to disability.
public static final Attribute LEVEL_DIFFERENT_FROM_GROUND
Transit access's level is different from ground.
public static final Attribute HAS_NAMES
Transit access has proper name.
Method Details
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitAccessInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Method
The enumeration Method is a member of com.here.android.mpa.mapping.TransitAccessInfo.
Enumeration Summary
public static final enumeration TransitAccessInfo.Method
HERE Android SDK Developer's Guide
API Reference
1144
extends java.lang.Enum, java.lang.Object
Represents values describing the accessible methods of transit access.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 574: Enum Constants in Method
Fields
public static final Method STAIRS
Transit access has stairs access.
public static final Method ESCALATOR
Transit access has escalator access.
public static final Method ELEVATOR
Transit access has elevator access.
public static final Method PEDESTRIAN_RAMP
Transit access has pedestrian ramp access.
Method Summary
Table 575: Methods in Method
Methods
public static Method valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitAccessInfo.Method[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the accessible methods of transit access.
Enum Constant Details
public static final Method STAIRS
Transit access has stairs access.
public static final Method ESCALATOR
Transit access has escalator access.
public static final Method ELEVATOR
HERE Android SDK Developer's Guide
API Reference
1145
Transit access has elevator access.
public static final Method PEDESTRIAN_RAMP
Transit access has pedestrian ramp access.
Method Details
public static Method valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitAccessInfo.Method[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TransitAccessObject
The class TransitAccessObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitAccessObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a public transit access point on a map.
[For complete information, see the section Class Details]
See also:
getSelectedObjects(PointF)
getSelectedObjectsNearby(PointF)
getSelectedObjects(ViewRect)
HERE Android SDK Developer's Guide
API Reference
1146
Method Summary
Table 576: Methods in TransitAccessObject
Methods
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the transit access icon on the map.
public java.util.List <Image> getIcons ()
Get the list of icons associated with the TransitAccessObject .
public TransitAccessInfo getTransitAccessInfo ()
Gets the TransitAccessInfo associated with the TransitAccessObject .
Class Details
Encapsulates information about a public transit access point on a map.
A TransitAccessObject represents a specialized MapProxyObject. Users can retrieve an instance
of this object with a call to either getSelectedObjects(PointF) or getSelectedObjectsNearby(PointF) or
getSelectedObjects(ViewRect) at the point or area where a public transit access point exists.
See also:
getSelectedObjects(PointF)
getSelectedObjectsNearby(PointF)
getSelectedObjects(ViewRect)
Method Details
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the transit access icon on the map.
Returns:
The GeoCoordinate where the transit access object is located.
public java.util.List <Image> getIcons ()
Get the list of icons associated with the TransitAccessObject .
Returns:
List of icon Images.
public TransitAccessInfo getTransitAccessInfo ()
Gets the TransitAccessInfo associated with the TransitAccessObject . A TransitAccessInfo instance
contains information about the types of transit that can be accessed at a particular transit access point, as
well as the Identifier of any transit stop that is associated with the access point.
HERE Android SDK Developer's Guide
API Reference
1147
Returns:
The TransitAccessInfo
TransitDatabase
The class TransitDatabase is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitDatabase
extends java.lang.Object
Represents an interface used to get information about public transit elements.
[For complete information, see the section Class Details]
Nested Class Summary
Table 577: Nested Classes in TransitDatabase
Nested Classes
public static final enumeration TransitDatabase.Error
Represents values describing possible kinds of errors that can be encountered while initiating an asynchronous request to
a TransitDatabase.
public static abstract interface TransitDatabase.OnGetTransitInfoListener
Represents a listener to provide information about TransitDatabase events.
public static abstract class TransitDatabase.OnGetTransitInfoListenerAdapter
Represents a listener to provide information about TransitDatabase events.
Constructor Summary
Table 578: Constructors in TransitDatabase
Constructors
TransitDatabase ()
Constructor.
Method Summary
Table 579: Methods in TransitDatabase
Methods
public void cancel ()
Cancels the current request for transit information.
HERE Android SDK Developer's Guide
API Reference
1148
Methods
public Error getAccessInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit access.
public Error getLineInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit line.
public Error getStopInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit stop.
public Error getSystemInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit system.
Class Details
Represents an interface used to get information about public transit elements.
Constructor Details
TransitDatabase ()
Constructor. Instantiates an instance of the transit database.
Method Details
public void cancel ()
Cancels the current request for transit information.
public Error getAccessInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit access.
Parameters:
id
An unique Identifier for the transit access
listener
An OnGetTransitInfoListener to provide information about TransitDatabase events
Returns:
The appropriate Error value, which could be:
NONE if the asynchronous request started successfully
INVALID_OPERATION if another request operation is already in progress
INVALID_PARAMETERS if any of the input parameters is invalid
See also:
HERE Android SDK Developer's Guide
API Reference
1149
getId()
public Error getLineInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit line.
Parameters:
id
An unique Identifier for the transit line
listener
An OnGetTransitInfoListener to provide information about TransitDatabase events
Returns:
The appropriate Error value, which could be:
NONE if the asynchronous request started successfully
INVALID_OPERATION if another request operation is already in progress
INVALID_PARAMETERS if any of the input parameters is invalid
See also:
getId()
getLineId()
getLineId()
getLines()
public Error getStopInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit stop.
Parameters:
id
An unique Identifier for the transit stop
listener
An OnGetTransitInfoListener to provide information about TransitDatabase events
Returns:
The appropriate Error value, which could be:
NONE if the asynchronous request started successfully
INVALID_OPERATION if another request operation is already in progress
INVALID_PARAMETERS if any of the input parameters is invalid
See also:
getId()
getStopId()
HERE Android SDK Developer's Guide
API Reference
1150
public Error getSystemInfo (Identifier id, OnGetTransitInfoListener listener)
Initiates an asynchronous request for information about a transit system.
Parameters:
id
An unique Identifier for the transit system.
listener
An OnGetTransitInfoListener to provide information about TransitDatabase events
Returns:
The appropriate Error value, which could be:
NONE if the asynchronous request started successfully
INVALID_OPERATION if another request operation is already in progress
INVALID_PARAMETERS if any of the input parameters is invalid
See also:
getSystemId()
Error
The enumeration Error is a member of com.here.android.mpa.mapping.TransitDatabase.
Enumeration Summary
public static final enumeration TransitDatabase.Error
extends java.lang.Enum, java.lang.Object
Represents values describing possible kinds of errors that can be encountered while initiating an
asynchronous request to a TransitDatabase.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 580: Enum Constants in Error
Fields
public static final Error NONE
There was no error, the request started successfully.
public static final Error NOT_FOUND
There was an error encountered while trying to access the database.
HERE Android SDK Developer's Guide
API Reference
1151
Fields
public static final Error ABORTED
The request was aborted.
public static final Error INVALID_PARAMETERS
One or more parameters accompanying the request is invalid.
public static final Error INVALID_OPERATION
Another request operation is already in progress.
public static final Error UNKNOWN
There was an error encountered, cause unknown.
Method Summary
Table 581: Methods in Error
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitDatabase.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible kinds of errors that can be encountered while initiating an
asynchronous request to a TransitDatabase.
Enum Constant Details
public static final Error NONE
There was no error, the request started successfully.
public static final Error NOT_FOUND
There was an error encountered while trying to access the database.
public static final Error ABORTED
The request was aborted.
public static final Error INVALID_PARAMETERS
One or more parameters accompanying the request is invalid.
HERE Android SDK Developer's Guide
API Reference
1152
public static final Error INVALID_OPERATION
Another request operation is already in progress.
public static final Error UNKNOWN
There was an error encountered, cause unknown.
Method Details
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitDatabase.Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnGetTransitInfoListener
The interface OnGetTransitInfoListener is a member of com.here.android.mpa.mapping.TransitDatabase.
Interface Summary
public static abstract interface TransitDatabase.OnGetTransitInfoListener
Represents a listener to provide information about TransitDatabase events.
[For complete information, see the section Interface Details]
Method Summary
Table 582: Methods in OnGetTransitInfoListener
Methods
public abstract void onEnd (Error error)
A callback indicating the end of available transit database results or an encountered error.
public abstract void onTransitAccessInfo (TransitAccessInfo info)
A callback indicating the availability of transit access information.
HERE Android SDK Developer's Guide
API Reference
1153
Methods
public abstract void onTransitLineInfo (TransitLineInfo info)
A callback indicating the availability of transit line information.
public abstract void onTransitStopInfo (TransitStopInfo info)
A callback indicating the availability of transit stop information.
public abstract void onTransitSystemInfo (TransitSystemInfo info)
A callback indicating the availability of transit system information.
Interface Details
Represents a listener to provide information about TransitDatabase events.
Method Details
public abstract void onEnd (Error error)
A callback indicating the end of available transit database results or an encountered error.
Parameters:
error
A Error value
public abstract void onTransitAccessInfo (TransitAccessInfo info)
A callback indicating the availability of transit access information.
Parameters:
info
A TransitAccessInfo for the requested transit access point
public abstract void onTransitLineInfo (TransitLineInfo info)
A callback indicating the availability of transit line information.
Parameters:
info
A TransitLineInfo for the requested transit line
public abstract void onTransitStopInfo (TransitStopInfo info)
A callback indicating the availability of transit stop information.
Parameters:
info
HERE Android SDK Developer's Guide
API Reference
1154
A TransitStopInfo for the requested transit stop
public abstract void onTransitSystemInfo (TransitSystemInfo info)
A callback indicating the availability of transit system information.
Parameters:
info
A TransitSystemInfo for the requested transit system
OnGetTransitInfoListenerAdapter
The class OnGetTransitInfoListenerAdapter is a member of com.here.android.mpa.mapping.TransitDatabase.
Class Summary
public static abstract class TransitDatabase.OnGetTransitInfoListenerAdapter
implements com.here.android.mpa.mapping.TransitDatabase.OnGetTransitInfoListener
extends java.lang.Object
Represents a listener to provide information about TransitDatabase events.
[For complete information, see the section Class Details]
Constructor Summary
Table 583: Constructors in OnGetTransitInfoListenerAdapter
Constructors
OnGetTransitInfoListenerAdapter ()
Method Summary
Table 584: Methods in OnGetTransitInfoListenerAdapter
Methods
public abstract void onEnd (Error error)
A callback indicating the end of available transit database results or an encountered error.
public void onTransitAccessInfo (TransitAccessInfo info)
A callback indicating the availability of transit access information.
public void onTransitLineInfo (TransitLineInfo info)
A callback indicating the availability of transit line information.
HERE Android SDK Developer's Guide
API Reference
1155
Methods
public void onTransitStopInfo (TransitStopInfo info)
A callback indicating the availability of transit stop information.
public void onTransitSystemInfo (TransitSystemInfo info)
A callback indicating the availability of transit system information.
Class Details
Represents a listener to provide information about TransitDatabase events.
Constructor Details
OnGetTransitInfoListenerAdapter ()
Method Details
public abstract void onEnd (Error error)
A callback indicating the end of available transit database results or an encountered error.
Parameters:
error
An appropriate Error value
public void onTransitAccessInfo (TransitAccessInfo info)
A callback indicating the availability of transit access information.
Parameters:
info
A TransitAccessInfo for the requested transit access point
public void onTransitLineInfo (TransitLineInfo info)
A callback indicating the availability of transit line information.
Parameters:
info
A TransitLineInfo for the requested transit line
public void onTransitStopInfo (TransitStopInfo info)
A callback indicating the availability of transit stop information.
HERE Android SDK Developer's Guide
API Reference
1156
Parameters:
info
A TransitStopInfo for the requested transit stop
public void onTransitSystemInfo (TransitSystemInfo info)
A callback indicating the availability of transit system information.
Parameters:
info
A TransitSystemInfo for the requested transit system
TransitLineInfo
The class TransitLineInfo is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitLineInfo
extends java.lang.Object
Represents information about a public transit line.
[For complete information, see the section Class Details]
Nested Class Summary
Table 585: Nested Classes in TransitLineInfo
Nested Classes
public static final enumeration TransitLineInfo.Attribute
Represents values describing the attributes of transit line.
Method Summary
Table 586: Methods in TransitLineInfo
Methods
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute s applicable to the transit line.
public int getColor ()
Gets the current line color for the transit line, an ARGB (Alpha/Red/Green/Blue) value.
HERE Android SDK Developer's Guide
API Reference
1157
Methods
public Identifier getId ()
Gets the unique Identifier of the transit line.
public String getInformalName ()
Gets the informal name for the line associated with the transit line.
public String getOfficialName ()
Gets the official name for the line associated with the transit line.
public String getShortName ()
Gets the short name for the line associated with the transit line.
public Identifier getSystemId ()
Gets transit system Identifier for the transit line.
public TransitType getTransitType ()
Gets the TransitType of the transit line.
Class Details
Represents information about a public transit line.
Method Details
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute s applicable to the transit line.
Returns:
A EnumSet containing all the applicable Attributes.
public int getColor ()
Gets the current line color for the transit line, an ARGB (Alpha/Red/Green/Blue) value.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
android.graphics.Color
public Identifier getId ()
Gets the unique Identifier of the transit line.
Returns:
HERE Android SDK Developer's Guide
API Reference
1158
The Identifier
See also:
TransitDatabase
public String getInformalName ()
Gets the informal name for the line associated with the transit line. This text is localized according to the
device's locale.
Returns:
The informal name
public String getOfficialName ()
Gets the official name for the line associated with the transit line. This text is localized according to the
device's locale.
Returns:
The official name
public String getShortName ()
Gets the short name for the line associated with the transit line. This text is localized according to the
device's locale.
Returns:
The short name
public Identifier getSystemId ()
Gets transit system Identifier for the transit line.
Returns:
the unique object Identifier.
See also:
TransitDatabase
public TransitType getTransitType ()
Gets the TransitType of the transit line.
Returns:
The TransitType
HERE Android SDK Developer's Guide
API Reference
1159
Attribute
The enumeration Attribute is a member of com.here.android.mpa.mapping.TransitLineInfo.
Enumeration Summary
public static final enumeration TransitLineInfo.Attribute
extends java.lang.Enum, java.lang.Object
Represents values describing the attributes of transit line.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 587: Enum Constants in Attribute
Fields
public static final Attribute EXPRESS
Express line.
public static final Attribute ACCESSIBLE_TO_DISABLED
Accessible to disabled people.
public static final Attribute LUGGAGE_RACKS
Luggage racks available.
public static final Attribute ONBOARD_TOILETS
Onboard toilets available.
public static final Attribute ONBOARD_FOOD
Onboard food available.
public static final Attribute SMOKING_ALLOWED
Smoking allowed.
public static final Attribute SLEEPING_CARS
Sleeping cars available.
Method Summary
Table 588: Methods in Attribute
Methods
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1160
Methods
public static TransitLineInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the attributes of transit line.
Enum Constant Details
public static final Attribute EXPRESS
Express line.
public static final Attribute ACCESSIBLE_TO_DISABLED
Accessible to disabled people.
public static final Attribute LUGGAGE_RACKS
Luggage racks available.
public static final Attribute ONBOARD_TOILETS
Onboard toilets available.
public static final Attribute ONBOARD_FOOD
Onboard food available.
public static final Attribute SMOKING_ALLOWED
Smoking allowed.
public static final Attribute SLEEPING_CARS
Sleeping cars available.
Method Details
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1161
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitLineInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TransitLineObject
The class TransitLineObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitLineObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a public transit line on a map.
[For complete information, see the section Class Details]
See also:
TransitLineInfo
Method Summary
Table 589: Methods in TransitLineObject
Methods
public Identifier getLineId ()
Gets the unique Identifier for the TransitLineObject .
Class Details
Encapsulates information about a public transit line on a map.
A TransitLineObject represents a specialized MapProxyObject . User can retrieve an instance of this
object by calling getSelectedObjects(PointF) or getSelectedObjects(ViewRect) with the location where a public
transit line is located.
See also:
TransitLineInfo
HERE Android SDK Developer's Guide
API Reference
1162
Method Details
public Identifier getLineId ()
Gets the unique Identifier for the TransitLineObject . Applications can use this Identifier to highlight
the transit line and to get information about the line.
Returns:
The Identifier
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
TransitLineSegmentObject
The class TransitLineSegmentObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitLineSegmentObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a transit line segment on the map.
[For complete information, see the section Class Details]
See also:
getSelectedObjects(PointF)
getSelectedObjectsNearby(PointF)
getSelectedObjects(ViewRect)
onMapObjectsSelected(List<ViewObject>)
Method Summary
Table 590: Methods in TransitLineSegmentObject
Methods
public Identifier getLineId ()
Returns the transit line info Identifier.
public Identifier getLineSegmentId ()
Returns the transit line segment Identifier .
HERE Android SDK Developer's Guide
API Reference
1163
Class Details
Encapsulates information about a transit line segment on the map. TransitLineSegmentObject s are
returned when they are selected on Map .
See also:
getSelectedObjects(PointF)
getSelectedObjectsNearby(PointF)
getSelectedObjects(ViewRect)
onMapObjectsSelected(List<ViewObject>)
Method Details
public Identifier getLineId ()
Returns the transit line info Identifier. The Identifier can be used to highlight the transit line and to get
transit line info.
Returns:
the unique object Identifier.
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
public Identifier getLineSegmentId ()
Returns the transit line segment Identifier . A transit line segment is a section of a line. The Identifier
can be used to highlight the transit line segment.
Returns:
the unique object Identifier.
See also:
highlightTransitLineSegments(List<Identifier>)
TransitStopInfo
The class TransitStopInfo is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitStopInfo
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1164
Represents information about a public transit stop.
[For complete information, see the section Class Details]
Nested Class Summary
Table 591: Nested Classes in TransitStopInfo
Nested Classes
public static final enumeration TransitStopInfo.Attribute
Represents values describing attributes of transit stops
public static final enumeration TransitStopInfo.ParkingSize
Number of parking spots available.
Method Summary
Table 592: Methods in TransitStopInfo
Methods
public java.util.EnumSet <Attribute> getAttributes ()
Gets the stop attributes Attributes for the transit stop.
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate position for the transit stop.
public java.util.List <Identifier> getDepartingLines ()
Gets the list of departing transit line Identifier s for the transit stop.
public java.util.List <Identifier> getDepartingSystems ()
Gets the array of departing transit systems Identifier s for the transit stop.
public Identifier getId ()
Gets the unique Identifier for the transit stop.
public String getInformalName ()
Gets the informal name for the stop associated with the TransitStopInfo .
public java.util.List <Identifier> getLines ()
Gets the list of transit line Identifier s associated with the transit stop.
public String getOfficialName ()
Gets the official name for the stop associated with the TransitStopInfo .
public OperatingHours getOperatingHours ()
Gets the OperatingHours for the transit stop.
public OperatingHours getParkingHours ()
Gets the parking OperatingHours for the transit stop, if a parking lot is present.
HERE Android SDK Developer's Guide
API Reference
1165
Methods
public ParkingSize getParkingSize ()
Gets the ParkingSize for the transit stop, if a parking lot is present.
public java.util.List <Identifier> getSystems ()
Gets the list of transit systems Identifier s associated with the transit stop.
public java.util.List <Identifier> getTerminatingLines ()
Gets the list of terminating line Identifier s for the transit stop.
public java.util.List <Identifier> getTerminatingSystems ()
Gets the list of terminating systems Identifier s for the transit stop.
public java.util.List <Identifier> getTransfers ()
Gets the list of transfer stops Identifier s for the transit stop.
public java.util.EnumSet <TransitType> getTransitTypes ()
Gets the TransitType(s) for the stop associated with the TransitStopInfo .
Class Details
Represents information about a public transit stop.
Method Details
public java.util.EnumSet <Attribute> getAttributes ()
Gets the stop attributes Attributes for the transit stop.
Returns:
A EnumSet containing all the Attributes associated with the transit stop.
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate position for the transit stop.
Returns:
position of the stop.
public java.util.List <Identifier> getDepartingLines ()
Gets the list of departing transit line Identifier s for the transit stop.
Returns:
The list of Identifier of transit lines.
See also:
highlightTransitLines(List<Identifier>)
HERE Android SDK Developer's Guide
API Reference
1166
getLineInfo(Identifier, OnGetTransitInfoListener)
public java.util.List <Identifier> getDepartingSystems ()
Gets the array of departing transit systems Identifier s for the transit stop.
Returns:
The list of Identifier of transit systems.
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
public Identifier getId ()
Gets the unique Identifier for the transit stop. Applications can use this Identifier to highlight the transit
stop using highlightTransitStops(List).
Returns:
The Identifier of this transit stop.
See also:
getStopInfo(Identifier, OnGetTransitInfoListener)
public String getInformalName ()
Gets the informal name for the stop associated with the TransitStopInfo . This text is localized according
to the device's locale.
Returns:
The informal name
public java.util.List <Identifier> getLines ()
Gets the list of transit line Identifier s associated with the transit stop. Applications can use the
Identifier s to highlight the transit lines and to get information about the lines.
Returns:
The list of transit line Identifiers.
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
HERE Android SDK Developer's Guide
API Reference
1167
public String getOfficialName ()
Gets the official name for the stop associated with the TransitStopInfo . This text is localized according
to the device's locale.
Returns:
The official name
public OperatingHours getOperatingHours ()
Gets the OperatingHours for the transit stop.
Returns:
The operating hours.
public OperatingHours getParkingHours ()
Gets the parking OperatingHours for the transit stop, if a parking lot is present.
Returns:
parking hours.
public ParkingSize getParkingSize ()
Gets the ParkingSize for the transit stop, if a parking lot is present.
Returns:
The ParkingSize of the transit stop.
public java.util.List <Identifier> getSystems ()
Gets the list of transit systems Identifier s associated with the transit stop.
Returns:
The list of transit system Identifiers.
public java.util.List <Identifier> getTerminatingLines ()
Gets the list of terminating line Identifier s for the transit stop.
Returns:
The List of Identifiers.
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
HERE Android SDK Developer's Guide
API Reference
1168
public java.util.List <Identifier> getTerminatingSystems ()
Gets the list of terminating systems Identifier s for the transit stop.
Returns:
The List of Identifiers.
See also:
highlightTransitLines(List<Identifier>)
getLineInfo(Identifier, OnGetTransitInfoListener)
public java.util.List <Identifier> getTransfers ()
Gets the list of transfer stops Identifier s for the transit stop.
Returns:
The List of Identifiers.
public java.util.EnumSet <TransitType> getTransitTypes ()
Gets the TransitType(s) for the stop associated with the TransitStopInfo .
Returns:
The EnumSet of all TransitType associated with the stop.
Attribute
The enumeration Attribute is a member of com.here.android.mpa.mapping.TransitStopInfo.
Enumeration Summary
public static final enumeration TransitStopInfo.Attribute
extends java.lang.Enum, java.lang.Object
Represents values describing attributes of transit stops
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 593: Enum Constants in Attribute
Fields
public static final Attribute CONNECTED_STOP
HERE Android SDK Developer's Guide
API Reference
1169
Fields
public static final Attribute INTER_STOPS_TRANSFER
public static final Attribute TERMINATING_STOP
public static final Attribute DEPARTING_STOP
public static final Attribute PAY_CAR_PARKING
public static final Attribute FREE_CAR_PARKING
public static final Attribute BICYCLE_PARKING
public static final Attribute SMOKING_ALLOWED
public static final Attribute TOILETS
public static final Attribute WIRELESS_INTERNET
public static final Attribute CELLULAR_SERVICE
public static final Attribute TICKET_MACHINES
public static final Attribute LUGGAGE_LOCKERS
public static final Attribute LUGGAGE_CHECKS
public static final Attribute ATTENDANT_BOOTH
public static final Attribute SHOPS
public static final Attribute OUTDOOR
public static final Attribute COVERED
public static final Attribute PEDESTRIAN_RAMPS
public static final Attribute ELEVATORS
public static final Attribute ESCALATORS
public static final Attribute STAIRS
Method Summary
Table 594: Methods in Attribute
Methods
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitStopInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing attributes of transit stops
HERE Android SDK Developer's Guide
API Reference
1170
Enum Constant Details
public static final Attribute CONNECTED_STOP
public static final Attribute INTER_STOPS_TRANSFER
public static final Attribute TERMINATING_STOP
public static final Attribute DEPARTING_STOP
public static final Attribute PAY_CAR_PARKING
public static final Attribute FREE_CAR_PARKING
public static final Attribute BICYCLE_PARKING
public static final Attribute SMOKING_ALLOWED
public static final Attribute TOILETS
public static final Attribute WIRELESS_INTERNET
public static final Attribute CELLULAR_SERVICE
public static final Attribute TICKET_MACHINES
public static final Attribute LUGGAGE_LOCKERS
public static final Attribute LUGGAGE_CHECKS
public static final Attribute ATTENDANT_BOOTH
HERE Android SDK Developer's Guide
API Reference
1171
public static final Attribute SHOPS
public static final Attribute OUTDOOR
public static final Attribute COVERED
public static final Attribute PEDESTRIAN_RAMPS
public static final Attribute ELEVATORS
public static final Attribute ESCALATORS
public static final Attribute STAIRS
Method Details
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitStopInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ParkingSize
The enumeration ParkingSize is a member of com.here.android.mpa.mapping.TransitStopInfo.
Enumeration Summary
public static final enumeration TransitStopInfo.ParkingSize
extends java.lang.Enum, java.lang.Object
Number of parking spots available.
HERE Android SDK Developer's Guide
API Reference
1172
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 595: Enum Constants in ParkingSize
Fields
public static final ParkingSize UNKNOWN
public static final ParkingSize FIVE_OR_LESS
public static final ParkingSize TEN_OR_LESS
public static final ParkingSize FIFTY_OR_LESS
public static final ParkingSize TWO_HUNDRED_OR_LESS
public static final ParkingSize MORE_THAN_200
Method Summary
Table 596: Methods in ParkingSize
Methods
public static ParkingSize valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitStopInfo.ParkingSize[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Number of parking spots available.
Enum Constant Details
public static final ParkingSize UNKNOWN
public static final ParkingSize FIVE_OR_LESS
public static final ParkingSize TEN_OR_LESS
public static final ParkingSize FIFTY_OR_LESS
public static final ParkingSize TWO_HUNDRED_OR_LESS
HERE Android SDK Developer's Guide
API Reference
1173
public static final ParkingSize MORE_THAN_200
Method Details
public static ParkingSize valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitStopInfo.ParkingSize[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TransitStopObject
The class TransitStopObject is a member of com.here.android.mpa.mapping .
Class Summary
public final class TransitStopObject
extends com.here.android.mpa.mapping.MapProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Encapsulates information about a public transit stop on a map.
[For complete information, see the section Class Details]
See also:
TransitStopInfo
Method Summary
Table 597: Methods in TransitStopObject
Methods
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the transit stop icon on the map.
public java.util.List <Image> getIcons ()
Get the list of icons associated with the TransitStopObject .
HERE Android SDK Developer's Guide
API Reference
1174
Methods
public TransitStopInfo getTransitStopInfo ()
Gets the TransitStopInfo associated with the TransitStopObject .
Class Details
Encapsulates information about a public transit stop on a map.
A TransitStopObject represents a specialized MapProxyObject. User can retrieve an instance of this
object by calling getSelectedObjects(PointF) or getSelectedObjects(ViewRect) with the location where a public
transit stop is located.
See also:
TransitStopInfo
Method Details
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate representing the position of the transit stop icon on the map.
Returns:
The GeoCoordinate
public java.util.List <Image> getIcons ()
Get the list of icons associated with the TransitStopObject .
Returns:
List of icon Images.
public TransitStopInfo getTransitStopInfo ()
Gets the TransitStopInfo associated with the TransitStopObject . A TransitStopInfo instance contains
information about the name of the stop, the types of transit that use the stop, and the IDs of particular
transit lines that stop there.
Returns:
The TransitStopInfo
TransitSystemInfo
The class TransitSystemInfo is a member of com.here.android.mpa.mapping .
HERE Android SDK Developer's Guide
API Reference
1175
Class Summary
public final class TransitSystemInfo
extends java.lang.Object
Represents information about a public transit system.
[For complete information, see the section Class Details]
Nested Class Summary
Table 598: Nested Classes in TransitSystemInfo
Nested Classes
public static final enumeration TransitSystemInfo.Attribute
Attributes or LOGOS of a Transit System.
Method Summary
Table 599: Methods in TransitSystemInfo
Methods
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute s for the transit system.
public OperatingHours getBicycleHours ()
Gets the Bicycle Parking Hours.
public String getCompanyInformalName ()
Gets the company informal name for the transit system.
public Image getCompanyLogo ()
Gets the Company Logo, if present.
public String getCompanyOfficialName ()
Gets the company official name for the transit system.
public String getCompanyPhone ()
Gets the company phone number for the transit system.
public String getCompanyRoutePlannerUrl ()
Gets the company route planner url for the transit system.
public String getCompanyScheduleUrl ()
Gets the company schedule url for the transit system.
public String getCompanyShortName ()
Gets the company short name for the transit system.
public String getCompanyWebsiteUrl ()
Gets the company website url for the transit system.
HERE Android SDK Developer's Guide
API Reference
1176
Methods
public Identifier getId ()
Gets the ID for the transit system.
public Image getSystemAccessLogo ()
Gets the System Access Logo, if present.
public String getSystemInformalName ()
Gets the informal name for the transit system.
public Image getSystemLogo ()
Gets the System Logo, if present.
public String getSystemOfficialName ()
Gets the official name for the transit system.
public String getSystemShortName ()
Gets the short name for the transit system.
public String getSystemWebsiteUrl ()
Gets the website url for the transit system.
Class Details
Represents information about a public transit system.
Method Details
public java.util.EnumSet <Attribute> getAttributes ()
Gets all the Attribute s for the transit system.
Returns:
A EnumSet containing all the Attributes associated with the transit system.
public OperatingHours getBicycleHours ()
Gets the Bicycle Parking Hours.
Returns:
The bicycle parking hours as OperatingHours of this transit system.
public String getCompanyInformalName ()
Gets the company informal name for the transit system. This text is localized according to the device's locale.
Returns:
company informal name.
HERE Android SDK Developer's Guide
API Reference
1177
public Image getCompanyLogo ()
Gets the Company Logo, if present.
Returns:
The Company Logo as an Image.
public String getCompanyOfficialName ()
Gets the company official name for the transit system. This text is localized according to the device's locale.
Returns:
company official name.
public String getCompanyPhone ()
Gets the company phone number for the transit system. This text is localized according to the device's locale.
Returns:
company phone number.
public String getCompanyRoutePlannerUrl ()
Gets the company route planner url for the transit system.
Returns:
company route planner url.
public String getCompanyScheduleUrl ()
Gets the company schedule url for the transit system.
Returns:
company schedule url.
public String getCompanyShortName ()
Gets the company short name for the transit system. This text is localized according to the device's locale.
Returns:
company short name.
public String getCompanyWebsiteUrl ()
HERE Android SDK Developer's Guide
API Reference
1178
Gets the company website url for the transit system.
Returns:
company website url.
public Identifier getId ()
Gets the ID for the transit system.
Returns:
the unique object Identifier.
See also:
getSystemInfo(Identifier, OnGetTransitInfoListener)
public Image getSystemAccessLogo ()
Gets the System Access Logo, if present.
Returns:
System Access Logo as an Image.
public String getSystemInformalName ()
Gets the informal name for the transit system. This text is localized according to the device's locale.
Returns:
informal name.
public Image getSystemLogo ()
Gets the System Logo, if present.
Returns:
System Logo as an Image.
public String getSystemOfficialName ()
Gets the official name for the transit system. This text is localized according to the device's locale.
Returns:
official name.
public String getSystemShortName ()
HERE Android SDK Developer's Guide
API Reference
1179
Gets the short name for the transit system. This text is localized according to the device's locale.
Returns:
short name.
public String getSystemWebsiteUrl ()
Gets the website url for the transit system.
Returns:
website url.
Attribute
The enumeration Attribute is a member of com.here.android.mpa.mapping.TransitSystemInfo.
Enumeration Summary
public static final enumeration TransitSystemInfo.Attribute
extends java.lang.Enum, java.lang.Object
Attributes or LOGOS of a Transit System.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 600: Enum Constants in Attribute
Fields
public static final Attribute COMPANY_LOGO
public static final Attribute SYSTEM_LOGO
public static final Attribute SYSTEM_ACCESS_LOGO
Method Summary
Table 601: Methods in Attribute
Methods
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitSystemInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1180
Enumeration Details
Attributes or LOGOS of a Transit System.
Enum Constant Details
public static final Attribute COMPANY_LOGO
public static final Attribute SYSTEM_LOGO
public static final Attribute SYSTEM_ACCESS_LOGO
Method Details
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitSystemInfo.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UrlMapRasterTileSourceBase
The class UrlMapRasterTileSourceBase is a member of com.here.android.mpa.mapping .
Class Summary
public abstract class UrlMapRasterTileSourceBase
extends com.here.android.mpa.mapping.MapRasterTileSource, java.lang.Object
Represents an abstract base class for URL map raster tile sources.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1181
Constructor Summary
Table 602: Constructors in UrlMapRasterTileSourceBase
Constructors
UrlMapRasterTileSourceBase ()
Method Summary
Table 603: Methods in UrlMapRasterTileSourceBase
Methods
public TileResult getTileWithError (int x, int y, int zoomLevel)
UrlMapRasterTileSourceBase will only retrieve tile data using the source URL.
public abstract String getUrl (int x, int y, int zoomLevel)
Gets the URL representing the source of the specified raster tile image.
public boolean hasTile (int x, int y, int zoomLevel)
UrlMapRasterTileSourceBase will only retrieve tile data using the source URL.
Class Details
Represents an abstract base class for URL map raster tile sources. Extend this class and implement the
getUrl(int, int, int) method to create custom URL raster tile sources.
Constructor Details
UrlMapRasterTileSourceBase ()
Method Details
public TileResult getTileWithError (int x, int y, int zoomLevel)
UrlMapRasterTileSourceBase will only retrieve tile data using the source URL. A TileResult.getData()
always returns null and TileResult.getError() always returns NONE.
Parameters:
x
X coordinate
y
Y coordinate
zoomLevel
zoom level
Returns:
HERE Android SDK Developer's Guide
API Reference
1182
A TileResult representing tile data and operation error. Check TileResult#getError() to check for
error. Check TileResult#getData() to get RasterTile
public abstract String getUrl (int x, int y, int zoomLevel)
Gets the URL representing the source of the specified raster tile image.
Note: implementations of raster tile sources must override this method to provide a complete URL string
pointing to the raster tile image.
Parameters:
x
A current raster tile's X-coordinate
y
A current raster tile's Y-coordinate
zoomLevel
A current raster tile's zoom level
Returns:
The URL source for the raster tile image. Return null if an URL cannot be created.
public boolean hasTile (int x, int y, int zoomLevel)
UrlMapRasterTileSourceBase will only retrieve tile data using the source URL. So hasTile always
returned false .
Parameters:
x
X coordinate
y
Y coordinate
zoomLevel
zoom level
Returns:
true if the tile exists, false otherwise
ZoomLevelToTiltFunction
The interface ZoomLevelToTiltFunction is a member of com.here.android.mpa.mapping .
Interface Summary
public abstract interface ZoomLevelToTiltFunction
HERE Android SDK Developer's Guide
API Reference
1183
Defines a interface to implement a function that provides a tilt value output for a zoom level input.
[For complete information, see the section Interface Details]
See also:
setMaximumTiltFunction(ZoomLevelToTiltFunction)
Method Summary
Table 604: Methods in ZoomLevelToTiltFunction
Methods
public abstract float getTilt (float zoomLevel)
Method use to control maximum tilt allowed on a map view at a given zoom level.
Interface Details
Defines a interface to implement a function that provides a tilt value output for a zoom level input.
See also:
setMaximumTiltFunction(ZoomLevelToTiltFunction)
Method Details
public abstract float getTilt (float zoomLevel)
Method use to control maximum tilt allowed on a map view at a given zoom level.
The function takes an input zoom level that will be in the range [ getMaxTilt(), getMinTilt()]. The output should
be a tilt value in the range [0, getMinTilt()].
Parameters:
zoomLevel
Desired fractional zoom level.
Returns:
A tilt value in the range [0, getMinTilt()].
customization
The package customization is a member of com.here.android.mpa.mapping .
Package Summary
customization
This package provides classes, interfaces, and enumerations for map scheme customization, including
customizable variables and properties.
HERE Android SDK Developer's Guide
API Reference
1184
Package Details
This package provides classes, interfaces, and enumerations for map scheme customization, including
customizable variables and properties.
CustomizableScheme
The class CustomizableScheme is a member of com.here.android.mpa.mapping.customization .
Class Summary
public class CustomizableScheme
extends java.lang.Object
Represent a scheme that can be customize.
[For complete information, see the section Class Details]
Nested Class Summary
Table 605: Nested Classes in CustomizableScheme
Nested Classes
public static final enumeration CustomizableScheme.ErrorCode
Error code specific to configuration scheme or variable
Method Summary
Table 606: Methods in CustomizableScheme
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getName ()
Retrieve name of customizable scheme object.
public int getVariableValue (SchemeColorProperty variable, double zoomLevel)
Retrieve color of an existing variable.
public float getVariableValue (SchemeFloatProperty variable, double zoomLevel)
Retrieve value of an existing variable.
public int getVariableValue (SchemeIntegerProperty variable, double zoomLevel)
Retrieve value to an existent integer variable.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1185
Methods
public boolean isValid ()
Returns true if the customizable scheme object is in a valid state, false otherwise.
public ErrorCode setVariableValue (SchemeColorProperty variable, int value, ZoomRange range)
Sets color for an existing variable.
public ErrorCode setVariableValue (SchemeFloatProperty variable, float value, ZoomRange range)
Sets value to an existing float variable.
public ErrorCode setVariableValue (SchemeIntegerProperty variable, int value, ZoomRange range)
Sets value to existing integer variable.
Class Details
Represent a scheme that can be customize. A customizable scheme cannot be directly constructed,
but one can be created through a Map object, by using an existing base Map.Scheme. Call
getCustomizableScheme(String) to get Customizable Scheme instance.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getName ()
Retrieve name of customizable scheme object.
Returns:
name of customizable scheme object OR null if this scheme is not valid.
public int getVariableValue (SchemeColorProperty variable, double zoomLevel)
Retrieve color of an existing variable.
Parameters:
variable
variable name
zoomLevel
Get value of variable for this zoom level.
Returns:
color value of variable for given zoom level.
HERE Android SDK Developer's Guide
API Reference
1186
Throws:
IllegalArgumentException
if variable is null OR zoomLevel is not valid
public float getVariableValue (SchemeFloatProperty variable, double zoomLevel)
Retrieve value of an existing variable.
Parameters:
variable
variable name
zoomLevel
Get value of variable for this zoom level.
Returns:
value of variable for given zoom level.
Throws:
IllegalArgumentException
if variable is null OR zoomLevel is not valid
public int getVariableValue (SchemeIntegerProperty variable, double zoomLevel)
Retrieve value to an existent integer variable.
Parameters:
variable
variable name
zoomLevel
Get value of variable for this zoom level.
Returns:
value of variable for given zoom level.
Throws:
IllegalArgumentException
if variable is null OR zoomLevel is not valid
public int hashCode ()
For documentation, see java.lang.Object
public boolean isValid ()
HERE Android SDK Developer's Guide
API Reference
1187
Returns true if the customizable scheme object is in a valid state, false otherwise.
A scheme may not be valid either because the scheme was removed or a new configuration has been set.
Returns:
true if the scheme is valid, false otherwise.
public ErrorCode setVariableValue (SchemeColorProperty variable, int value,
ZoomRange range)
Sets color for an existing variable.
Parameters:
variable
Name of color variable. Can be get from CustomizableVariables class.
value
Value to set.
range
Zoom range where this variable value will come into effect.
Returns:
ERROR_NONE if operation was successful.
ERROR_INVALID_PARAMETERS if there's no variable with that name OR variable is null OR range is null or
not valid
ERROR_INVALID_OPERATION if this scheme is not valid.
ERROR_OUT_OF_MEMORY if operation failed due to an out of memory error.
public ErrorCode setVariableValue (SchemeFloatProperty variable, float value,
ZoomRange range)
Sets value to an existing float variable.
Parameters:
variable
Name of variable. Can be get from CustomizableVariables class.
value
Value to set.
range
Zoom range where this variable value will come into effect.
Returns:
ERROR_NONE if operation was successful.
ERROR_INVALID_PARAMETERS if there's no variable with that name OR variable is null OR range is null or
not valid
ERROR_INVALID_OPERATION if this scheme is not valid.
HERE Android SDK Developer's Guide
API Reference
1188
ERROR_OUT_OF_MEMORY if operation failed due to an out of memory error.
public ErrorCode setVariableValue (SchemeIntegerProperty variable, int value,
ZoomRange range)
Sets value to existing integer variable.
Parameters:
variable
Name of variable. Can be get from CustomizableVariables class.
value
Value to set.
range
Zoom range where this variable value will come into effect.
Returns:
ERROR_NONE if operation was successful.
ERROR_INVALID_PARAMETERS if there's no variable with that name OR variable is null OR range is null or
not valid
ERROR_INVALID_OPERATION if this scheme is not valid.
ERROR_OUT_OF_MEMORY if operation failed due to an out of memory error.
ErrorCode
The enumeration ErrorCode is a member of
com.here.android.mpa.mapping.customization.CustomizableScheme.
Enumeration Summary
public static final enumeration CustomizableScheme.ErrorCode
extends java.lang.Enum, java.lang.Object
Error code specific to configuration scheme or variable
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 607: Enum Constants in ErrorCode
Fields
public static final ErrorCode ERROR_NONE
No Error
public static final ErrorCode ERROR_UNKNOWN
Generic error.
HERE Android SDK Developer's Guide
API Reference
1189
Fields
public static final ErrorCode ERROR_OUT_OF_MEMORY
Out of memory.
public static final ErrorCode ERROR_INVALID_PARAMETERS
Invalid parameters received.
public static final ErrorCode ERROR_INVALID_OPERATION
Operation is not allowed at the time of the call.
Method Summary
Table 608: Methods in ErrorCode
Methods
public static ErrorCode getCode (int value)
public int getValue ()
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CustomizableScheme.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Error code specific to configuration scheme or variable
Enum Constant Details
public static final ErrorCode ERROR_NONE
No Error
public static final ErrorCode ERROR_UNKNOWN
Generic error.
public static final ErrorCode ERROR_OUT_OF_MEMORY
Out of memory.
public static final ErrorCode ERROR_INVALID_PARAMETERS
Invalid parameters received.
HERE Android SDK Developer's Guide
API Reference
1190
public static final ErrorCode ERROR_INVALID_OPERATION
Operation is not allowed at the time of the call.
Method Details
public static ErrorCode getCode (int value)
Parameters:
value
public int getValue ()
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CustomizableScheme.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CustomizableVariables
The class CustomizableVariables is a member of com.here.android.mpa.mapping.customization .
Class Summary
public class CustomizableVariables
extends java.lang.Object
[For complete information, see the section Class Details]
Nested Class Summary
Table 609: Nested Classes in CustomizableVariables
Nested Classes
public static class CustomizableVariables.AirportArea
HERE Android SDK Developer's Guide
API Reference
1191
Nested Classes
public static class CustomizableVariables.AirportAreaInfo
public static class CustomizableVariables.Allotment
public static class CustomizableVariables.AllotmentInfo
public static class CustomizableVariables.AmbientLight
public static class CustomizableVariables.AmusementPark
public static class CustomizableVariables.AmusementParkInfo
public static class CustomizableVariables.AnimalPark
public static class CustomizableVariables.AnimalParkInfo
public static class CustomizableVariables.Area
public static class CustomizableVariables.AvoidBlockedRoute
public static class CustomizableVariables.BayHarbour
public static class CustomizableVariables.Beach
public static class CustomizableVariables.BeachInfo
public static class CustomizableVariables.Billboard
public static class CustomizableVariables.Building
public static class CustomizableVariables.Building1
public static class CustomizableVariables.Building1Outline
public static class CustomizableVariables.BuildingAddress
public static class CustomizableVariables.BuildingInfo
public static class CustomizableVariables.BuildingOutline
public static class CustomizableVariables.BuiltupArea
public static class CustomizableVariables.BuiltupBorder
public static class CustomizableVariables.CanalWaterChannel
public static class CustomizableVariables.Cemetery
public static class CustomizableVariables.CemeteryInfo
public static class CustomizableVariables.CityCenter
public static class CustomizableVariables.CongestionZone
public static class CustomizableVariables.CongestionZoneBorder
public static class CustomizableVariables.CongestionZoneInfo
public static class CustomizableVariables.ContinentLabel
public static class CustomizableVariables.CountryBoundary
HERE Android SDK Developer's Guide
API Reference
1192
Nested Classes
public static class CustomizableVariables.CountryBoundaryDisputed
public static class CustomizableVariables.CountrySideLabel
public static class CustomizableVariables.DirectionalLight1
public static class CustomizableVariables.DirectionalLight2
public static class CustomizableVariables.DirectionalLight3
public static class CustomizableVariables.ElevationMap
public static class CustomizableVariables.EnvironmentalZone
public static class CustomizableVariables.EnvironmentalZoneBorder
public static class CustomizableVariables.EnvironmentalZoneInfo
public static class CustomizableVariables.ExitInfo
public static class CustomizableVariables.ExitInfoSimplified
public static class CustomizableVariables.ExtrudedBuildings
public static class CustomizableVariables.FarPlane
public static class CustomizableVariables.Ferry
public static class CustomizableVariables.Fog
public static class CustomizableVariables.GolfCourse
public static class CustomizableVariables.GolfCourseInfo
public static class CustomizableVariables.GuidanceArrow
public static class CustomizableVariables.HarborArea
public static class CustomizableVariables.HarborAreaInfo
public static class CustomizableVariables.HospitalCampus
public static class CustomizableVariables.HospitalCampusInfo
public static class CustomizableVariables.IndustrialComplex
public static class CustomizableVariables.IndustrialComplexInfo
public static class CustomizableVariables.IntermittentRiver
public static class CustomizableVariables.IslandInfo
public static class CustomizableVariables.Lake
public static class CustomizableVariables.Land
public static class CustomizableVariables.LandCover
public static class CustomizableVariables.LaneWidthM
public static class CustomizableVariables.LineOfControl
HERE Android SDK Developer's Guide
API Reference
1193
Nested Classes
public static class CustomizableVariables.MajorCountryLabel
public static class CustomizableVariables.MarkingDivider
public static class CustomizableVariables.MarkingLane
public static class CustomizableVariables.MilitaryBase
public static class CustomizableVariables.MilitaryBaseInfo
public static class CustomizableVariables.MinorCountryLabel
public static class CustomizableVariables.MotorwayJunctionSimplified
public static class CustomizableVariables.MountainPeak
public static class CustomizableVariables.MountainPeakHeight
public static class CustomizableVariables.MountainPeakInfo
public static class CustomizableVariables.MountainRangeInfo
public static class CustomizableVariables.NationalForest
public static class CustomizableVariables.NationalForestInfo
public static class CustomizableVariables.NationalGrassland
public static class CustomizableVariables.NationalGrasslandInfo
public static class CustomizableVariables.NationalHistoricPark
public static class CustomizableVariables.NationalHistoricParkInfo
public static class CustomizableVariables.NationalMilitaryPark
public static class CustomizableVariables.NationalPark
public static class CustomizableVariables.NationalParkInfo
public static class CustomizableVariables.NationalRecreationArea
public static class CustomizableVariables.NationalRecreationAreaInfo
public static class CustomizableVariables.NationalReserve
public static class CustomizableVariables.NationalStatePark
public static class CustomizableVariables.NationalStateParkInfo
public static class CustomizableVariables.NationalWildlifeRefuge
public static class CustomizableVariables.NativeReservation
public static class CustomizableVariables.NativeReservationInfo
public static class CustomizableVariables.Neighborhood
public static class CustomizableVariables.NeighborhoodInfo
public static class CustomizableVariables.Ocean
HERE Android SDK Developer's Guide
API Reference
1194
Nested Classes
public static class CustomizableVariables.Panorama
public static class CustomizableVariables.Park
public static class CustomizableVariables.ParkInfo
public static class CustomizableVariables.PedestrianArea
public static class CustomizableVariables.PedestrianAreaInfo
public static class CustomizableVariables.PedestrianPoint
public static class CustomizableVariables.PointOfInterest
public static class CustomizableVariables.Rail
public static class CustomizableVariables.Railway
public static class CustomizableVariables.Railyard
public static class CustomizableVariables.RailyardInfo
public static class CustomizableVariables.RemainingRangeEV
public static class CustomizableVariables.River
public static class CustomizableVariables.RoadSign
public static class CustomizableVariables.RouteStyle
public static class CustomizableVariables.Runway
public static class CustomizableVariables.SSAO
public static class CustomizableVariables.Sea
public static class CustomizableVariables.ShoppingComplex
public static class CustomizableVariables.ShoppingComplexInfo
public static class CustomizableVariables.Sky
public static class CustomizableVariables.SportsComplex
public static class CustomizableVariables.SportsComplexInfo
public static class CustomizableVariables.StateAbbreviationLabel
public static class CustomizableVariables.StateBoundary
public static class CustomizableVariables.StateBoundaryDisputed
public static class CustomizableVariables.StateLabel
public static class CustomizableVariables.Street
public static class CustomizableVariables.Transit
public static class CustomizableVariables.TransitAccess
public static class CustomizableVariables.TruckIcon
HERE Android SDK Developer's Guide
API Reference
1195
Nested Classes
public static class CustomizableVariables.TruckLine
public static class CustomizableVariables.UniversityCampus
public static class CustomizableVariables.UniversityCampusInfo
public static class CustomizableVariables.Water
public static class CustomizableVariables.Woodland
public static class CustomizableVariables.WoodlandInfo
public static class CustomizableVariables.WorldMountains
public static class CustomizableVariables.ZoneBorder
Constructor Summary
Table 610: Constructors in CustomizableVariables
Constructors
CustomizableVariables ()
Class Details
Constructor Details
CustomizableVariables ()
AirportArea
The class AirportArea is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AirportArea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 611: Constructors in AirportArea
Constructors
AirportArea ()
HERE Android SDK Developer's Guide
API Reference
1196
Field Summary
Table 612: Fields in AirportArea
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
AirportArea ()
Field Details
public static final SchemeColorProperty COLOR
AirportAreaInfo
The class AirportAreaInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AirportAreaInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 613: Constructors in AirportAreaInfo
Constructors
AirportAreaInfo ()
Field Summary
Table 614: Fields in AirportAreaInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1197
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
AirportAreaInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Allotment
The class Allotment is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Allotment
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 615: Constructors in Allotment
Constructors
Allotment ()
HERE Android SDK Developer's Guide
API Reference
1198
Field Summary
Table 616: Fields in Allotment
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Allotment ()
Field Details
public static final SchemeColorProperty COLOR
AllotmentInfo
The class AllotmentInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AllotmentInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 617: Constructors in AllotmentInfo
Constructors
AllotmentInfo ()
Field Summary
Table 618: Fields in AllotmentInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1199
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
AllotmentInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
AmbientLight
The class AmbientLight is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AmbientLight
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 619: Constructors in AmbientLight
Constructors
AmbientLight ()
HERE Android SDK Developer's Guide
API Reference
1200
Field Summary
Table 620: Fields in AmbientLight
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
AmbientLight ()
Field Details
public static final SchemeColorProperty COLOR
AmusementPark
The class AmusementPark is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AmusementPark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 621: Constructors in AmusementPark
Constructors
AmusementPark ()
Field Summary
Table 622: Fields in AmusementPark
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1201
Class Details
Constructor Details
AmusementPark ()
Field Details
public static final SchemeColorProperty COLOR
AmusementParkInfo
The class AmusementParkInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AmusementParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 623: Constructors in AmusementParkInfo
Constructors
AmusementParkInfo ()
Field Summary
Table 624: Fields in AmusementParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1202
Class Details
Constructor Details
AmusementParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
AnimalPark
The class AnimalPark is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AnimalPark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 625: Constructors in AnimalPark
Constructors
AnimalPark ()
Field Summary
Table 626: Fields in AnimalPark
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1203
Class Details
Constructor Details
AnimalPark ()
Field Details
public static final SchemeColorProperty COLOR
AnimalParkInfo
The class AnimalParkInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AnimalParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 627: Constructors in AnimalParkInfo
Constructors
AnimalParkInfo ()
Field Summary
Table 628: Fields in AnimalParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1204
Class Details
Constructor Details
AnimalParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Area
The class Area is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Area
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 629: Constructors in Area
Constructors
Area ()
Field Summary
Table 630: Fields in Area
Fields
public static final SchemeIntegerProperty ICONSIZE
HERE Android SDK Developer's Guide
API Reference
1205
Class Details
Constructor Details
Area ()
Field Details
public static final SchemeIntegerProperty ICONSIZE
AvoidBlockedRoute
The class AvoidBlockedRoute is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.AvoidBlockedRoute
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 631: Constructors in AvoidBlockedRoute
Constructors
AvoidBlockedRoute ()
Field Summary
Table 632: Fields in AvoidBlockedRoute
Fields
public static final SchemeColorProperty DASHCOLOR
public static final SchemeColorProperty GAPCOLOR
public static final SchemeColorProperty OUTLINECOLOR
public static final SchemeFloatProperty OUTLINEWIDTH
public static final SchemeFloatProperty WIDTH
HERE Android SDK Developer's Guide
API Reference
1206
Class Details
Constructor Details
AvoidBlockedRoute ()
Field Details
public static final SchemeColorProperty DASHCOLOR
public static final SchemeColorProperty GAPCOLOR
public static final SchemeColorProperty OUTLINECOLOR
public static final SchemeFloatProperty OUTLINEWIDTH
public static final SchemeFloatProperty WIDTH
BayHarbour
The class BayHarbour is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BayHarbour
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 633: Constructors in BayHarbour
Constructors
BayHarbour ()
HERE Android SDK Developer's Guide
API Reference
1207
Field Summary
Table 634: Fields in BayHarbour
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1208
Fields
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
BayHarbour ()
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1209
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1210
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1211
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Beach
The class Beach is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Beach
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 635: Constructors in Beach
Constructors
Beach ()
HERE Android SDK Developer's Guide
API Reference
1212
Field Summary
Table 636: Fields in Beach
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Beach ()
Field Details
public static final SchemeColorProperty COLOR
BeachInfo
The class BeachInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BeachInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 637: Constructors in BeachInfo
Constructors
BeachInfo ()
Field Summary
Table 638: Fields in BeachInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1213
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
BeachInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Billboard
The class Billboard is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Billboard
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 639: Constructors in Billboard
Constructors
Billboard ()
HERE Android SDK Developer's Guide
API Reference
1214
Field Summary
Table 640: Fields in Billboard
Fields
public static final SchemeColorProperty ADJACENT_COLOR
public static final SchemeColorProperty ADJACENT_FONTSTYLE_COLOR
public static final SchemeColorProperty ADJACENT_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty ADJACENT_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty ADJACENT_FONTSTYLE_SIZE
public static final SchemeColorProperty ADJACENT_OUTLINECOLOR
public static final SchemeFloatProperty ADJACENT_OUTLINEWIDTH
public static final SchemeFloatProperty ADJACENT_POINTERHEIGHT
public static final SchemeColorProperty OFFROUTE_COLOR
public static final SchemeColorProperty OFFROUTE_FONTSTYLE_COLOR
public static final SchemeColorProperty OFFROUTE_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty OFFROUTE_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty OFFROUTE_FONTSTYLE_SIZE
public static final SchemeColorProperty OFFROUTE_OUTLINECOLOR
public static final SchemeFloatProperty OFFROUTE_OUTLINEWIDTH
public static final SchemeFloatProperty OFFROUTE_POINTERHEIGHT
Class Details
Constructor Details
Billboard ()
Field Details
public static final SchemeColorProperty ADJACENT_COLOR
public static final SchemeColorProperty ADJACENT_FONTSTYLE_COLOR
public static final SchemeColorProperty ADJACENT_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1215
public static final SchemeFloatProperty ADJACENT_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty ADJACENT_FONTSTYLE_SIZE
public static final SchemeColorProperty ADJACENT_OUTLINECOLOR
public static final SchemeFloatProperty ADJACENT_OUTLINEWIDTH
public static final SchemeFloatProperty ADJACENT_POINTERHEIGHT
public static final SchemeColorProperty OFFROUTE_COLOR
public static final SchemeColorProperty OFFROUTE_FONTSTYLE_COLOR
public static final SchemeColorProperty OFFROUTE_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty OFFROUTE_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty OFFROUTE_FONTSTYLE_SIZE
public static final SchemeColorProperty OFFROUTE_OUTLINECOLOR
public static final SchemeFloatProperty OFFROUTE_OUTLINEWIDTH
public static final SchemeFloatProperty OFFROUTE_POINTERHEIGHT
Building
The class Building is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Building
HERE Android SDK Developer's Guide
API Reference
1216
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 641: Constructors in Building
Constructors
Building ()
Field Summary
Table 642: Fields in Building
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Building ()
Field Details
public static final SchemeColorProperty COLOR
Building1
The class Building1 is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Building1
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 643: Constructors in Building1
Constructors
Building1 ()
HERE Android SDK Developer's Guide
API Reference
1217
Field Summary
Table 644: Fields in Building1
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Building1 ()
Field Details
public static final SchemeColorProperty COLOR
Building1Outline
The class Building1Outline is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Building1Outline
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 645: Constructors in Building1Outline
Constructors
Building1Outline ()
Field Summary
Table 646: Fields in Building1Outline
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1218
Class Details
Constructor Details
Building1Outline ()
Field Details
public static final SchemeColorProperty COLOR
BuildingAddress
The class BuildingAddress is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BuildingAddress
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 647: Constructors in BuildingAddress
Constructors
BuildingAddress ()
Field Summary
Table 648: Fields in BuildingAddress
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1219
Class Details
Constructor Details
BuildingAddress ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
BuildingInfo
The class BuildingInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BuildingInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 649: Constructors in BuildingInfo
Constructors
BuildingInfo ()
Field Summary
Table 650: Fields in BuildingInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1220
Fields
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
BuildingInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
BuildingOutline
The class BuildingOutline is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BuildingOutline
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 651: Constructors in BuildingOutline
Constructors
BuildingOutline ()
HERE Android SDK Developer's Guide
API Reference
1221
Field Summary
Table 652: Fields in BuildingOutline
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
BuildingOutline ()
Field Details
public static final SchemeColorProperty COLOR
BuiltupArea
The class BuiltupArea is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BuiltupArea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 653: Constructors in BuiltupArea
Constructors
BuiltupArea ()
Field Summary
Table 654: Fields in BuiltupArea
Fields
public static final SchemeColorProperty COLOR
public static final SchemeIntegerProperty MINPIXELHEIGHT
public static final SchemeIntegerProperty MINPIXELWIDTH
HERE Android SDK Developer's Guide
API Reference
1222
Class Details
Constructor Details
BuiltupArea ()
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeIntegerProperty MINPIXELHEIGHT
public static final SchemeIntegerProperty MINPIXELWIDTH
BuiltupBorder
The class BuiltupBorder is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.BuiltupBorder
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 655: Constructors in BuiltupBorder
Constructors
BuiltupBorder ()
Field Summary
Table 656: Fields in BuiltupBorder
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
HERE Android SDK Developer's Guide
API Reference
1223
Class Details
Constructor Details
BuiltupBorder ()
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
CanalWaterChannel
The class CanalWaterChannel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CanalWaterChannel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 657: Constructors in CanalWaterChannel
Constructors
CanalWaterChannel ()
Field Summary
Table 658: Fields in CanalWaterChannel
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1224
Fields
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
HERE Android SDK Developer's Guide
API Reference
1225
Fields
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
CanalWaterChannel ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1226
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1227
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
HERE Android SDK Developer's Guide
API Reference
1228
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1229
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
Cemetery
The class Cemetery is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Cemetery
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 659: Constructors in Cemetery
Constructors
Cemetery ()
Field Summary
Table 660: Fields in Cemetery
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1230
Class Details
Constructor Details
Cemetery ()
Field Details
public static final SchemeColorProperty COLOR
CemeteryInfo
The class CemeteryInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CemeteryInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 661: Constructors in CemeteryInfo
Constructors
CemeteryInfo ()
Field Summary
Table 662: Fields in CemeteryInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
CemeteryInfo ()
HERE Android SDK Developer's Guide
API Reference
1231
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
CityCenter
The class CityCenter is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CityCenter
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 663: Constructors in CityCenter
Constructors
CityCenter ()
Field Summary
Table 664: Fields in CityCenter
Fields
public static final SchemeColorProperty CLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS2_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1232
Fields
public static final SchemeFloatProperty CLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISTRICT_FONTSTYLE_COLOR
public static final SchemeColorProperty DISTRICT_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISTRICT_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISTRICT_FONTSTYLE_SIZE
public static final SchemeColorProperty HAMLET_FONTSTYLE_COLOR
public static final SchemeColorProperty HAMLET_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty HAMLET_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty HAMLET_FONTSTYLE_SIZE
Class Details
Constructor Details
CityCenter ()
Field Details
public static final SchemeColorProperty CLASS1_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1233
public static final SchemeColorProperty CLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty CLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty CLASS5_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1234
public static final SchemeColorProperty CLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISTRICT_FONTSTYLE_COLOR
public static final SchemeColorProperty DISTRICT_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISTRICT_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISTRICT_FONTSTYLE_SIZE
public static final SchemeColorProperty HAMLET_FONTSTYLE_COLOR
public static final SchemeColorProperty HAMLET_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty HAMLET_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty HAMLET_FONTSTYLE_SIZE
CongestionZone
The class CongestionZone is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CongestionZone
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1235
Constructor Summary
Table 665: Constructors in CongestionZone
Constructors
CongestionZone ()
Field Summary
Table 666: Fields in CongestionZone
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
CongestionZone ()
Field Details
public static final SchemeColorProperty COLOR
CongestionZoneBorder
The class CongestionZoneBorder is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CongestionZoneBorder
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 667: Constructors in CongestionZoneBorder
Constructors
CongestionZoneBorder ()
HERE Android SDK Developer's Guide
API Reference
1236
Field Summary
Table 668: Fields in CongestionZoneBorder
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
CongestionZoneBorder ()
Field Details
public static final SchemeColorProperty COLOR
CongestionZoneInfo
The class CongestionZoneInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CongestionZoneInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 669: Constructors in CongestionZoneInfo
Constructors
CongestionZoneInfo ()
Field Summary
Table 670: Fields in CongestionZoneInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1237
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
CongestionZoneInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
ContinentLabel
The class ContinentLabel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ContinentLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 671: Constructors in ContinentLabel
Constructors
ContinentLabel ()
HERE Android SDK Developer's Guide
API Reference
1238
Field Summary
Table 672: Fields in ContinentLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
ContinentLabel ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
CountryBoundary
The class CountryBoundary is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CountryBoundary
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1239
Constructor Summary
Table 673: Constructors in CountryBoundary
Constructors
CountryBoundary ()
Field Summary
Table 674: Fields in CountryBoundary
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
CountryBoundary ()
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
CountryBoundaryDisputed
The class CountryBoundaryDisputed is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1240
Class Summary
public static class CustomizableVariables.CountryBoundaryDisputed
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 675: Constructors in CountryBoundaryDisputed
Constructors
CountryBoundaryDisputed ()
Field Summary
Table 676: Fields in CountryBoundaryDisputed
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
CountryBoundaryDisputed ()
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
HERE Android SDK Developer's Guide
API Reference
1241
CountrySideLabel
The class CountrySideLabel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.CountrySideLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 677: Constructors in CountrySideLabel
Constructors
CountrySideLabel ()
Field Summary
Table 678: Fields in CountrySideLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
CountrySideLabel ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1242
public static final SchemeFloatProperty FONTSTYLE_SIZE
DirectionalLight1
The class DirectionalLight1 is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.DirectionalLight1
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 679: Constructors in DirectionalLight1
Constructors
DirectionalLight1 ()
Field Summary
Table 680: Fields in DirectionalLight1
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
DirectionalLight1 ()
Field Details
public static final SchemeColorProperty COLOR
DirectionalLight2
The class DirectionalLight2 is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1243
Class Summary
public static class CustomizableVariables.DirectionalLight2
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 681: Constructors in DirectionalLight2
Constructors
DirectionalLight2 ()
Field Summary
Table 682: Fields in DirectionalLight2
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
DirectionalLight2 ()
Field Details
public static final SchemeColorProperty COLOR
DirectionalLight3
The class DirectionalLight3 is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.DirectionalLight3
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1244
Constructor Summary
Table 683: Constructors in DirectionalLight3
Constructors
DirectionalLight3 ()
Field Summary
Table 684: Fields in DirectionalLight3
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
DirectionalLight3 ()
Field Details
public static final SchemeColorProperty COLOR
ElevationMap
The class ElevationMap is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ElevationMap
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 685: Constructors in ElevationMap
Constructors
ElevationMap ()
HERE Android SDK Developer's Guide
API Reference
1245
Field Summary
Table 686: Fields in ElevationMap
Fields
public static final SchemeColorProperty COLOR0
public static final SchemeColorProperty COLOR1
public static final SchemeColorProperty COLOR2
public static final SchemeColorProperty COLOR3
public static final SchemeColorProperty COLOR4
public static final SchemeColorProperty COLOR5
public static final SchemeColorProperty COLOR6
public static final SchemeColorProperty COLOR7
public static final SchemeIntegerProperty HEIGHT0
public static final SchemeIntegerProperty HEIGHT1
public static final SchemeIntegerProperty HEIGHT2
public static final SchemeIntegerProperty HEIGHT3
public static final SchemeIntegerProperty HEIGHT4
public static final SchemeIntegerProperty HEIGHT5
public static final SchemeIntegerProperty HEIGHT6
public static final SchemeIntegerProperty HEIGHT7
public static final SchemeIntegerProperty NUMHEIGHTS
public static final SchemeIntegerProperty RANGEDSCALE0_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE1_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE2_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE3_MAXHEIGHT
public static final SchemeColorProperty SHADER_SHADOW_COLOR
public static final SchemeColorProperty SHADER_SPECULAR_COLOR
Class Details
Constructor Details
ElevationMap ()
HERE Android SDK Developer's Guide
API Reference
1246
Field Details
public static final SchemeColorProperty COLOR0
public static final SchemeColorProperty COLOR1
public static final SchemeColorProperty COLOR2
public static final SchemeColorProperty COLOR3
public static final SchemeColorProperty COLOR4
public static final SchemeColorProperty COLOR5
public static final SchemeColorProperty COLOR6
public static final SchemeColorProperty COLOR7
public static final SchemeIntegerProperty HEIGHT0
public static final SchemeIntegerProperty HEIGHT1
public static final SchemeIntegerProperty HEIGHT2
public static final SchemeIntegerProperty HEIGHT3
public static final SchemeIntegerProperty HEIGHT4
public static final SchemeIntegerProperty HEIGHT5
public static final SchemeIntegerProperty HEIGHT6
HERE Android SDK Developer's Guide
API Reference
1247
public static final SchemeIntegerProperty HEIGHT7
public static final SchemeIntegerProperty NUMHEIGHTS
public static final SchemeIntegerProperty RANGEDSCALE0_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE1_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE2_MAXHEIGHT
public static final SchemeIntegerProperty RANGEDSCALE3_MAXHEIGHT
public static final SchemeColorProperty SHADER_SHADOW_COLOR
public static final SchemeColorProperty SHADER_SPECULAR_COLOR
EnvironmentalZone
The class EnvironmentalZone is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.EnvironmentalZone
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 687: Constructors in EnvironmentalZone
Constructors
EnvironmentalZone ()
HERE Android SDK Developer's Guide
API Reference
1248
Field Summary
Table 688: Fields in EnvironmentalZone
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
EnvironmentalZone ()
Field Details
public static final SchemeColorProperty COLOR
EnvironmentalZoneBorder
The class EnvironmentalZoneBorder is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.EnvironmentalZoneBorder
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 689: Constructors in EnvironmentalZoneBorder
Constructors
EnvironmentalZoneBorder ()
Field Summary
Table 690: Fields in EnvironmentalZoneBorder
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1249
Class Details
Constructor Details
EnvironmentalZoneBorder ()
Field Details
public static final SchemeColorProperty COLOR
EnvironmentalZoneInfo
The class EnvironmentalZoneInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.EnvironmentalZoneInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 691: Constructors in EnvironmentalZoneInfo
Constructors
EnvironmentalZoneInfo ()
Field Summary
Table 692: Fields in EnvironmentalZoneInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1250
Class Details
Constructor Details
EnvironmentalZoneInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
ExitInfo
The class ExitInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ExitInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 693: Constructors in ExitInfo
Constructors
ExitInfo ()
Field Summary
Table 694: Fields in ExitInfo
Fields
public static final SchemeColorProperty STREETCATEGORY0_COLOR
public static final SchemeColorProperty STREETCATEGORY0_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1251
Fields
public static final SchemeColorProperty STREETCATEGORY0_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY0_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY0_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY0_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY0_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY0_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty STREETCATEGORY0_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY0_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_COLOR
public static final SchemeColorProperty STREETCATEGORY1_FONTSTYLE_COLOR
public static final SchemeColorProperty STREETCATEGORY1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY1_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY1_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty STREETCATEGORY1_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY1_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_COLOR
public static final SchemeColorProperty STREETCATEGORY2_FONTSTYLE_COLOR
public static final SchemeColorProperty STREETCATEGORY2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY2_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1252
Fields
public static final SchemeColorProperty STREETCATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY2_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty STREETCATEGORY2_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY2_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_OUTLINEWIDTH
Class Details
Constructor Details
ExitInfo ()
Field Details
public static final SchemeColorProperty STREETCATEGORY0_COLOR
public static final SchemeColorProperty STREETCATEGORY0_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY0_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY0_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY0_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY0_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1253
public static final SchemeColorProperty STREETCATEGORY0_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY0_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY0_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY0_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY0_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_COLOR
public static final SchemeColorProperty STREETCATEGORY1_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY1_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1254
public static final SchemeColorProperty STREETCATEGORY1_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY1_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY1_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY1_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY1_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_COLOR
public static final SchemeColorProperty STREETCATEGORY2_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY2_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1255
public static final SchemeColorProperty STREETCATEGORY2_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY2_TOLL_FONTSTYLE_COLOR
public static final SchemeColorProperty
STREETCATEGORY2_TOLL_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
STREETCATEGORY2_TOLL_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_FONTSTYLE_SIZE
public static final SchemeColorProperty STREETCATEGORY2_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_OUTLINEWIDTH
ExitInfoSimplified
The class ExitInfoSimplified is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ExitInfoSimplified
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 695: Constructors in ExitInfoSimplified
Constructors
ExitInfoSimplified ()
HERE Android SDK Developer's Guide
API Reference
1256
Field Summary
Table 696: Fields in ExitInfoSimplified
Fields
public static final SchemeColorProperty STREETCATEGORY0_COLOR
public static final SchemeColorProperty STREETCATEGORY0_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY0_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY0_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_COLOR
public static final SchemeColorProperty STREETCATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY1_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_COLOR
public static final SchemeColorProperty STREETCATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY2_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_OUTLINEWIDTH
Class Details
Constructor Details
ExitInfoSimplified ()
Field Details
public static final SchemeColorProperty STREETCATEGORY0_COLOR
public static final SchemeColorProperty STREETCATEGORY0_OUTLINECOLOR
HERE Android SDK Developer's Guide
API Reference
1257
public static final SchemeFloatProperty STREETCATEGORY0_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY0_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY0_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY0_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_COLOR
public static final SchemeColorProperty STREETCATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY1_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY1_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY1_TOLL_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_COLOR
public static final SchemeColorProperty STREETCATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_OUTLINEWIDTH
public static final SchemeColorProperty STREETCATEGORY2_TOLL_COLOR
public static final SchemeColorProperty STREETCATEGORY2_TOLL_OUTLINECOLOR
public static final SchemeFloatProperty STREETCATEGORY2_TOLL_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1258
ExtrudedBuildings
The class ExtrudedBuildings is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ExtrudedBuildings
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 697: Constructors in ExtrudedBuildings
Constructors
ExtrudedBuildings ()
Field Summary
Table 698: Fields in ExtrudedBuildings
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty COLOR_HIGHLIGHT0
public static final SchemeColorProperty COLOR_HIGHLIGHT1
public static final SchemeColorProperty COLOR_HIGHLIGHT2
public static final SchemeColorProperty COLOR_HIGHLIGHT3
public static final SchemeColorProperty COLOR_HIGHLIGHT4
public static final SchemeColorProperty COLOR_HIGHLIGHT5
public static final SchemeColorProperty COLOR_NAMED
public static final SchemeColorProperty COLOR_SELECTED
public static final SchemeFloatProperty DEFAULTHEIGHT
public static final SchemeFloatProperty GRADIENTSTOPHEIGHT
Class Details
Constructor Details
ExtrudedBuildings ()
HERE Android SDK Developer's Guide
API Reference
1259
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty COLOR_HIGHLIGHT0
public static final SchemeColorProperty COLOR_HIGHLIGHT1
public static final SchemeColorProperty COLOR_HIGHLIGHT2
public static final SchemeColorProperty COLOR_HIGHLIGHT3
public static final SchemeColorProperty COLOR_HIGHLIGHT4
public static final SchemeColorProperty COLOR_HIGHLIGHT5
public static final SchemeColorProperty COLOR_NAMED
public static final SchemeColorProperty COLOR_SELECTED
public static final SchemeFloatProperty DEFAULTHEIGHT
public static final SchemeFloatProperty GRADIENTSTOPHEIGHT
FarPlane
The class FarPlane is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.FarPlane
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1260
Constructor Summary
Table 699: Constructors in FarPlane
Constructors
FarPlane ()
Field Summary
Table 700: Fields in FarPlane
Fields
public static final SchemeFloatProperty HORIZONHEIGHT_PERCENT
public static final SchemeFloatProperty HORIZONHEIGHT_TILTRANGE
public static final SchemeFloatProperty HORIZONHEIGHT_TILTSTART
Class Details
Constructor Details
FarPlane ()
Field Details
public static final SchemeFloatProperty HORIZONHEIGHT_PERCENT
public static final SchemeFloatProperty HORIZONHEIGHT_TILTRANGE
public static final SchemeFloatProperty HORIZONHEIGHT_TILTSTART
Ferry
The class Ferry is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Ferry
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1261
Constructor Summary
Table 701: Constructors in Ferry
Constructors
Ferry ()
Field Summary
Table 702: Fields in Ferry
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeColorProperty TUNNELCOLOR
Class Details
Constructor Details
Ferry ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeColorProperty TUNNELCOLOR
HERE Android SDK Developer's Guide
API Reference
1262
Fog
The class Fog is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Fog
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 703: Constructors in Fog
Constructors
Fog ()
Field Summary
Table 704: Fields in Fog
Fields
public static final SchemeColorProperty DARKCOLOR
public static final SchemeColorProperty DISTANCECOLOR
public static final SchemeIntegerProperty HEIGHT
public static final SchemeColorProperty LIGHTCOLOR
Class Details
Constructor Details
Fog ()
Field Details
public static final SchemeColorProperty DARKCOLOR
public static final SchemeColorProperty DISTANCECOLOR
public static final SchemeIntegerProperty HEIGHT
HERE Android SDK Developer's Guide
API Reference
1263
public static final SchemeColorProperty LIGHTCOLOR
GolfCourse
The class GolfCourse is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.GolfCourse
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 705: Constructors in GolfCourse
Constructors
GolfCourse ()
Field Summary
Table 706: Fields in GolfCourse
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
GolfCourse ()
Field Details
public static final SchemeColorProperty COLOR
GolfCourseInfo
The class GolfCourseInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1264
Class Summary
public static class CustomizableVariables.GolfCourseInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 707: Constructors in GolfCourseInfo
Constructors
GolfCourseInfo ()
Field Summary
Table 708: Fields in GolfCourseInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
GolfCourseInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1265
GuidanceArrow
The class GuidanceArrow is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.GuidanceArrow
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 709: Constructors in GuidanceArrow
Constructors
GuidanceArrow ()
Field Summary
Table 710: Fields in GuidanceArrow
Fields
public static final SchemeFloatProperty ARROWTIP_WIDTH_FACTOR
public static final SchemeFloatProperty OUTLINEWIDTH
public static final SchemeFloatProperty WIDTH_FACTOR
Class Details
Constructor Details
GuidanceArrow ()
Field Details
public static final SchemeFloatProperty ARROWTIP_WIDTH_FACTOR
public static final SchemeFloatProperty OUTLINEWIDTH
public static final SchemeFloatProperty WIDTH_FACTOR
HERE Android SDK Developer's Guide
API Reference
1266
HarborArea
The class HarborArea is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.HarborArea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 711: Constructors in HarborArea
Constructors
HarborArea ()
Field Summary
Table 712: Fields in HarborArea
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
HarborArea ()
Field Details
public static final SchemeColorProperty COLOR
HarborAreaInfo
The class HarborAreaInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.HarborAreaInfo
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1267
[For complete information, see the section Class Details]
Constructor Summary
Table 713: Constructors in HarborAreaInfo
Constructors
HarborAreaInfo ()
Field Summary
Table 714: Fields in HarborAreaInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
HarborAreaInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HospitalCampus
The class HospitalCampus is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1268
Class Summary
public static class CustomizableVariables.HospitalCampus
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 715: Constructors in HospitalCampus
Constructors
HospitalCampus ()
Field Summary
Table 716: Fields in HospitalCampus
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
HospitalCampus ()
Field Details
public static final SchemeColorProperty COLOR
HospitalCampusInfo
The class HospitalCampusInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.HospitalCampusInfo
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1269
Constructor Summary
Table 717: Constructors in HospitalCampusInfo
Constructors
HospitalCampusInfo ()
Field Summary
Table 718: Fields in HospitalCampusInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
HospitalCampusInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
IndustrialComplex
The class IndustrialComplex is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1270
Class Summary
public static class CustomizableVariables.IndustrialComplex
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 719: Constructors in IndustrialComplex
Constructors
IndustrialComplex ()
Field Summary
Table 720: Fields in IndustrialComplex
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
IndustrialComplex ()
Field Details
public static final SchemeColorProperty COLOR
IndustrialComplexInfo
The class IndustrialComplexInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.IndustrialComplexInfo
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1271
Constructor Summary
Table 721: Constructors in IndustrialComplexInfo
Constructors
IndustrialComplexInfo ()
Field Summary
Table 722: Fields in IndustrialComplexInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
IndustrialComplexInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
IntermittentRiver
The class IntermittentRiver is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1272
Class Summary
public static class CustomizableVariables.IntermittentRiver
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 723: Constructors in IntermittentRiver
Constructors
IntermittentRiver ()
Field Summary
Table 724: Fields in IntermittentRiver
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
HERE Android SDK Developer's Guide
API Reference
1273
Fields
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
public static final SchemeColorProperty FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1274
Fields
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
IntermittentRiver ()
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1275
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
HERE Android SDK Developer's Guide
API Reference
1276
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1277
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
IslandInfo
The class IslandInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.IslandInfo
HERE Android SDK Developer's Guide
API Reference
1278
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 725: Constructors in IslandInfo
Constructors
IslandInfo ()
Field Summary
Table 726: Fields in IslandInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
IslandInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Lake
The class Lake is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1279
Class Summary
public static class CustomizableVariables.Lake
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 727: Constructors in Lake
Constructors
Lake ()
Field Summary
Table 728: Fields in Lake
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1280
Fields
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
Lake ()
HERE Android SDK Developer's Guide
API Reference
1281
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1282
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1283
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Land
The class Land is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1284
Class Summary
public static class CustomizableVariables.Land
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 729: Constructors in Land
Constructors
Land ()
Field Summary
Table 730: Fields in Land
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Land ()
Field Details
public static final SchemeColorProperty COLOR
LandCover
The class LandCover is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.LandCover
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1285
Constructor Summary
Table 731: Constructors in LandCover
Constructors
LandCover ()
Field Summary
Table 732: Fields in LandCover
Fields
public static final SchemeColorProperty DESERT_COLOR
public static final SchemeColorProperty DESERT_FONTSTYLE_COLOR
public static final SchemeColorProperty DESERT_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DESERT_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DESERT_FONTSTYLE_SIZE
public static final SchemeColorProperty GLACIER_COLOR
public static final SchemeColorProperty GLACIER_FONTSTYLE_COLOR
public static final SchemeColorProperty GLACIER_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty GLACIER_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty GLACIER_FONTSTYLE_SIZE
Class Details
Constructor Details
LandCover ()
Field Details
public static final SchemeColorProperty DESERT_COLOR
public static final SchemeColorProperty DESERT_FONTSTYLE_COLOR
public static final SchemeColorProperty DESERT_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DESERT_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1286
public static final SchemeFloatProperty DESERT_FONTSTYLE_SIZE
public static final SchemeColorProperty GLACIER_COLOR
public static final SchemeColorProperty GLACIER_FONTSTYLE_COLOR
public static final SchemeColorProperty GLACIER_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty GLACIER_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty GLACIER_FONTSTYLE_SIZE
LaneWidthM
The class LaneWidthM is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.LaneWidthM
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 733: Constructors in LaneWidthM
Constructors
LaneWidthM ()
Field Summary
Table 734: Fields in LaneWidthM
Fields
public static final SchemeFloatProperty LANEWIDTHM
HERE Android SDK Developer's Guide
API Reference
1287
Class Details
Constructor Details
LaneWidthM ()
Field Details
public static final SchemeFloatProperty LANEWIDTHM
LineOfControl
The class LineOfControl is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.LineOfControl
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 735: Constructors in LineOfControl
Constructors
LineOfControl ()
Field Summary
Table 736: Fields in LineOfControl
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
LineOfControl ()
HERE Android SDK Developer's Guide
API Reference
1288
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
MajorCountryLabel
The class MajorCountryLabel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MajorCountryLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 737: Constructors in MajorCountryLabel
Constructors
MajorCountryLabel ()
Field Summary
Table 738: Fields in MajorCountryLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1289
Class Details
Constructor Details
MajorCountryLabel ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
MarkingDivider
The class MarkingDivider is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MarkingDivider
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 739: Constructors in MarkingDivider
Constructors
MarkingDivider ()
Field Summary
Table 740: Fields in MarkingDivider
Fields
public static final SchemeColorProperty CENTERCOLOR
HERE Android SDK Developer's Guide
API Reference
1290
Class Details
Constructor Details
MarkingDivider ()
Field Details
public static final SchemeColorProperty CENTERCOLOR
MarkingLane
The class MarkingLane is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MarkingLane
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 741: Constructors in MarkingLane
Constructors
MarkingLane ()
Field Summary
Table 742: Fields in MarkingLane
Fields
public static final SchemeColorProperty DASHEDCOLOR
public static final SchemeColorProperty SOLIDCOLOR
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
MarkingLane ()
HERE Android SDK Developer's Guide
API Reference
1291
Field Details
public static final SchemeColorProperty DASHEDCOLOR
public static final SchemeColorProperty SOLIDCOLOR
public static final SchemeFloatProperty WIDTH
MilitaryBase
The class MilitaryBase is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MilitaryBase
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 743: Constructors in MilitaryBase
Constructors
MilitaryBase ()
Field Summary
Table 744: Fields in MilitaryBase
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
MilitaryBase ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1292
MilitaryBaseInfo
The class MilitaryBaseInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MilitaryBaseInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 745: Constructors in MilitaryBaseInfo
Constructors
MilitaryBaseInfo ()
Field Summary
Table 746: Fields in MilitaryBaseInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
MilitaryBaseInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1293
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
MinorCountryLabel
The class MinorCountryLabel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MinorCountryLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 747: Constructors in MinorCountryLabel
Constructors
MinorCountryLabel ()
Field Summary
Table 748: Fields in MinorCountryLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
MinorCountryLabel ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1294
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
MotorwayJunctionSimplified
The class MotorwayJunctionSimplified is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MotorwayJunctionSimplified
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 749: Constructors in MotorwayJunctionSimplified
Constructors
MotorwayJunctionSimplified ()
Field Summary
Table 750: Fields in MotorwayJunctionSimplified
Fields
public static final SchemeColorProperty ICON_COLOR
public static final SchemeColorProperty ICON_OUTLINECOLOR
public static final SchemeFloatProperty ICON_OUTLINEWIDTH
Class Details
Constructor Details
MotorwayJunctionSimplified ()
HERE Android SDK Developer's Guide
API Reference
1295
Field Details
public static final SchemeColorProperty ICON_COLOR
public static final SchemeColorProperty ICON_OUTLINECOLOR
public static final SchemeFloatProperty ICON_OUTLINEWIDTH
MountainPeak
The class MountainPeak is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MountainPeak
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 751: Constructors in MountainPeak
Constructors
MountainPeak ()
Field Summary
Table 752: Fields in MountainPeak
Fields
public static final SchemeIntegerProperty ICONSIZE
Class Details
Constructor Details
MountainPeak ()
Field Details
public static final SchemeIntegerProperty ICONSIZE
HERE Android SDK Developer's Guide
API Reference
1296
MountainPeakHeight
The class MountainPeakHeight is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MountainPeakHeight
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 753: Constructors in MountainPeakHeight
Constructors
MountainPeakHeight ()
Field Summary
Table 754: Fields in MountainPeakHeight
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
MountainPeakHeight ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1297
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
MountainPeakInfo
The class MountainPeakInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MountainPeakInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 755: Constructors in MountainPeakInfo
Constructors
MountainPeakInfo ()
Field Summary
Table 756: Fields in MountainPeakInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
MountainPeakInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1298
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
MountainRangeInfo
The class MountainRangeInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.MountainRangeInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 757: Constructors in MountainRangeInfo
Constructors
MountainRangeInfo ()
Field Summary
Table 758: Fields in MountainRangeInfo
Fields
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1299
Fields
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
MountainRangeInfo ()
Field Details
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1300
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalForest
The class NationalForest is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalForest
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 759: Constructors in NationalForest
Constructors
NationalForest ()
HERE Android SDK Developer's Guide
API Reference
1301
Field Summary
Table 760: Fields in NationalForest
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalForest ()
Field Details
public static final SchemeColorProperty COLOR
NationalForestInfo
The class NationalForestInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalForestInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 761: Constructors in NationalForestInfo
Constructors
NationalForestInfo ()
Field Summary
Table 762: Fields in NationalForestInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1302
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
NationalForestInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalGrassland
The class NationalGrassland is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalGrassland
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 763: Constructors in NationalGrassland
Constructors
NationalGrassland ()
HERE Android SDK Developer's Guide
API Reference
1303
Field Summary
Table 764: Fields in NationalGrassland
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalGrassland ()
Field Details
public static final SchemeColorProperty COLOR
NationalGrasslandInfo
The class NationalGrasslandInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalGrasslandInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 765: Constructors in NationalGrasslandInfo
Constructors
NationalGrasslandInfo ()
Field Summary
Table 766: Fields in NationalGrasslandInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1304
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
NationalGrasslandInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalHistoricPark
The class NationalHistoricPark is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalHistoricPark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 767: Constructors in NationalHistoricPark
Constructors
NationalHistoricPark ()
HERE Android SDK Developer's Guide
API Reference
1305
Field Summary
Table 768: Fields in NationalHistoricPark
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalHistoricPark ()
Field Details
public static final SchemeColorProperty COLOR
NationalHistoricParkInfo
The class NationalHistoricParkInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalHistoricParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 769: Constructors in NationalHistoricParkInfo
Constructors
NationalHistoricParkInfo ()
Field Summary
Table 770: Fields in NationalHistoricParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1306
Fields
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
NationalHistoricParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalMilitaryPark
The class NationalMilitaryPark is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalMilitaryPark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 771: Constructors in NationalMilitaryPark
Constructors
NationalMilitaryPark ()
HERE Android SDK Developer's Guide
API Reference
1307
Field Summary
Table 772: Fields in NationalMilitaryPark
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalMilitaryPark ()
Field Details
public static final SchemeColorProperty COLOR
NationalPark
The class NationalPark is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalPark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 773: Constructors in NationalPark
Constructors
NationalPark ()
Field Summary
Table 774: Fields in NationalPark
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1308
Class Details
Constructor Details
NationalPark ()
Field Details
public static final SchemeColorProperty COLOR
NationalParkInfo
The class NationalParkInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 775: Constructors in NationalParkInfo
Constructors
NationalParkInfo ()
Field Summary
Table 776: Fields in NationalParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1309
Class Details
Constructor Details
NationalParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalRecreationArea
The class NationalRecreationArea is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalRecreationArea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 777: Constructors in NationalRecreationArea
Constructors
NationalRecreationArea ()
Field Summary
Table 778: Fields in NationalRecreationArea
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1310
Class Details
Constructor Details
NationalRecreationArea ()
Field Details
public static final SchemeColorProperty COLOR
NationalRecreationAreaInfo
The class NationalRecreationAreaInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalRecreationAreaInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 779: Constructors in NationalRecreationAreaInfo
Constructors
NationalRecreationAreaInfo ()
Field Summary
Table 780: Fields in NationalRecreationAreaInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1311
Class Details
Constructor Details
NationalRecreationAreaInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalReserve
The class NationalReserve is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalReserve
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 781: Constructors in NationalReserve
Constructors
NationalReserve ()
Field Summary
Table 782: Fields in NationalReserve
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1312
Class Details
Constructor Details
NationalReserve ()
Field Details
public static final SchemeColorProperty COLOR
NationalStatePark
The class NationalStatePark is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalStatePark
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 783: Constructors in NationalStatePark
Constructors
NationalStatePark ()
Field Summary
Table 784: Fields in NationalStatePark
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalStatePark ()
HERE Android SDK Developer's Guide
API Reference
1313
Field Details
public static final SchemeColorProperty COLOR
NationalStateParkInfo
The class NationalStateParkInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalStateParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 785: Constructors in NationalStateParkInfo
Constructors
NationalStateParkInfo ()
Field Summary
Table 786: Fields in NationalStateParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
NationalStateParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1314
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
NationalWildlifeRefuge
The class NationalWildlifeRefuge is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NationalWildlifeRefuge
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 787: Constructors in NationalWildlifeRefuge
Constructors
NationalWildlifeRefuge ()
Field Summary
Table 788: Fields in NationalWildlifeRefuge
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NationalWildlifeRefuge ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1315
NativeReservation
The class NativeReservation is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NativeReservation
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 789: Constructors in NativeReservation
Constructors
NativeReservation ()
Field Summary
Table 790: Fields in NativeReservation
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
NativeReservation ()
Field Details
public static final SchemeColorProperty COLOR
NativeReservationInfo
The class NativeReservationInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NativeReservationInfo
HERE Android SDK Developer's Guide
API Reference
1316
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 791: Constructors in NativeReservationInfo
Constructors
NativeReservationInfo ()
Field Summary
Table 792: Fields in NativeReservationInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
NativeReservationInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1317
Neighborhood
The class Neighborhood is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Neighborhood
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 793: Constructors in Neighborhood
Constructors
Neighborhood ()
Field Summary
Table 794: Fields in Neighborhood
Fields
public static final SchemeColorProperty COLOR_0
public static final SchemeColorProperty COLOR_1
public static final SchemeColorProperty COLOR_2
public static final SchemeColorProperty COLOR_3
public static final SchemeColorProperty COLOR_4
public static final SchemeColorProperty COLOR_5
Class Details
Constructor Details
Neighborhood ()
Field Details
public static final SchemeColorProperty COLOR_0
public static final SchemeColorProperty COLOR_1
HERE Android SDK Developer's Guide
API Reference
1318
public static final SchemeColorProperty COLOR_2
public static final SchemeColorProperty COLOR_3
public static final SchemeColorProperty COLOR_4
public static final SchemeColorProperty COLOR_5
NeighborhoodInfo
The class NeighborhoodInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.NeighborhoodInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 795: Constructors in NeighborhoodInfo
Constructors
NeighborhoodInfo ()
Field Summary
Table 796: Fields in NeighborhoodInfo
Fields
public static final SchemeColorProperty FONTSTYLE_0_COLOR
public static final SchemeColorProperty FONTSTYLE_0_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_0_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_0_SIZE
public static final SchemeColorProperty FONTSTYLE_1_COLOR
public static final SchemeColorProperty FONTSTYLE_1_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1319
Fields
public static final SchemeFloatProperty FONTSTYLE_1_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_1_SIZE
public static final SchemeColorProperty FONTSTYLE_2_COLOR
public static final SchemeColorProperty FONTSTYLE_2_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_2_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_2_SIZE
public static final SchemeColorProperty FONTSTYLE_3_COLOR
public static final SchemeColorProperty FONTSTYLE_3_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_3_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_3_SIZE
public static final SchemeColorProperty FONTSTYLE_4_COLOR
public static final SchemeColorProperty FONTSTYLE_4_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_4_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_4_SIZE
public static final SchemeColorProperty FONTSTYLE_5_COLOR
public static final SchemeColorProperty FONTSTYLE_5_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_5_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_5_SIZE
Class Details
Constructor Details
NeighborhoodInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_0_COLOR
public static final SchemeColorProperty FONTSTYLE_0_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_0_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1320
public static final SchemeFloatProperty FONTSTYLE_0_SIZE
public static final SchemeColorProperty FONTSTYLE_1_COLOR
public static final SchemeColorProperty FONTSTYLE_1_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_1_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_1_SIZE
public static final SchemeColorProperty FONTSTYLE_2_COLOR
public static final SchemeColorProperty FONTSTYLE_2_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_2_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_2_SIZE
public static final SchemeColorProperty FONTSTYLE_3_COLOR
public static final SchemeColorProperty FONTSTYLE_3_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_3_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_3_SIZE
public static final SchemeColorProperty FONTSTYLE_4_COLOR
public static final SchemeColorProperty FONTSTYLE_4_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_4_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1321
public static final SchemeFloatProperty FONTSTYLE_4_SIZE
public static final SchemeColorProperty FONTSTYLE_5_COLOR
public static final SchemeColorProperty FONTSTYLE_5_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_5_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_5_SIZE
Ocean
The class Ocean is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Ocean
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 797: Constructors in Ocean
Constructors
Ocean ()
Field Summary
Table 798: Fields in Ocean
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1322
Fields
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1323
Fields
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
Ocean ()
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1324
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1325
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1326
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Panorama
The class Panorama is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Panorama
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 799: Constructors in Panorama
Constructors
Panorama ()
Field Summary
Table 800: Fields in Panorama
Fields
public static final SchemeColorProperty COVERAGE_COLOR
public static final SchemeColorProperty COVERAGE_OUTLINECOLOR
public static final SchemeIntegerProperty COVERAGE_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1327
Fields
public static final SchemeIntegerProperty COVERAGE_WIDTH
public static final SchemeColorProperty HIGHLIGHT_PRIMARYCOLOR
public static final SchemeColorProperty HIGHLIGHT_SECONDARYCOLOR
public static final SchemeFloatProperty RASTERCOVERAGE_BLENDWIDTHFACTOR
public static final SchemeColorProperty RASTERCOVERAGE_COLOR
public static final SchemeColorProperty RASTERCOVERAGE_OUTLINECOLOR
public static final SchemeFloatProperty RASTERCOVERAGE_OUTLINEWIDTHFACTOR
public static final SchemeColorProperty ROUTEARROW_COLOR
public static final SchemeColorProperty ROUTEARROW_HIGHLIGHTCOLOR
public static final SchemeFloatProperty ROUTEARROW_WIDTHM
public static final SchemeColorProperty ROUTE_COLOR
public static final SchemeColorProperty ROUTE_SECONDARYCOLOR
public static final SchemeColorProperty STREET_COLOR
public static final SchemeColorProperty STREET_FONTSTYLE_COLOR
public static final SchemeColorProperty STREET_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREET_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STREET_FONTSTYLE_SIZE
public static final SchemeFloatProperty STREET_WIDTHM
Class Details
Constructor Details
Panorama ()
Field Details
public static final SchemeColorProperty COVERAGE_COLOR
public static final SchemeColorProperty COVERAGE_OUTLINECOLOR
public static final SchemeIntegerProperty COVERAGE_OUTLINEWIDTH
HERE Android SDK Developer's Guide
API Reference
1328
public static final SchemeIntegerProperty COVERAGE_WIDTH
public static final SchemeColorProperty HIGHLIGHT_PRIMARYCOLOR
public static final SchemeColorProperty HIGHLIGHT_SECONDARYCOLOR
public static final SchemeFloatProperty RASTERCOVERAGE_BLENDWIDTHFACTOR
public static final SchemeColorProperty RASTERCOVERAGE_COLOR
public static final SchemeColorProperty RASTERCOVERAGE_OUTLINECOLOR
public static final SchemeFloatProperty RASTERCOVERAGE_OUTLINEWIDTHFACTOR
public static final SchemeColorProperty ROUTEARROW_COLOR
public static final SchemeColorProperty ROUTEARROW_HIGHLIGHTCOLOR
public static final SchemeFloatProperty ROUTEARROW_WIDTHM
public static final SchemeColorProperty ROUTE_COLOR
public static final SchemeColorProperty ROUTE_SECONDARYCOLOR
public static final SchemeColorProperty STREET_COLOR
public static final SchemeColorProperty STREET_FONTSTYLE_COLOR
public static final SchemeColorProperty STREET_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STREET_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1329
public static final SchemeFloatProperty STREET_FONTSTYLE_SIZE
public static final SchemeFloatProperty STREET_WIDTHM
Park
The class Park is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Park
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 801: Constructors in Park
Constructors
Park ()
Field Summary
Table 802: Fields in Park
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Park ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1330
ParkInfo
The class ParkInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ParkInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 803: Constructors in ParkInfo
Constructors
ParkInfo ()
Field Summary
Table 804: Fields in ParkInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
ParkInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1331
public static final SchemeFloatProperty FONTSTYLE_SIZE
PedestrianArea
The class PedestrianArea is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.PedestrianArea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 805: Constructors in PedestrianArea
Constructors
PedestrianArea ()
Field Summary
Table 806: Fields in PedestrianArea
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
PedestrianArea ()
Field Details
public static final SchemeColorProperty COLOR
PedestrianAreaInfo
The class PedestrianAreaInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1332
Class Summary
public static class CustomizableVariables.PedestrianAreaInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 807: Constructors in PedestrianAreaInfo
Constructors
PedestrianAreaInfo ()
Field Summary
Table 808: Fields in PedestrianAreaInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
PedestrianAreaInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1333
PedestrianPoint
The class PedestrianPoint is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.PedestrianPoint
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 809: Constructors in PedestrianPoint
Constructors
PedestrianPoint ()
Field Summary
Table 810: Fields in PedestrianPoint
Fields
public static final SchemeIntegerProperty ICONSIZE
Class Details
Constructor Details
PedestrianPoint ()
Field Details
public static final SchemeIntegerProperty ICONSIZE
PointOfInterest
The class PointOfInterest is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.PointOfInterest
HERE Android SDK Developer's Guide
API Reference
1334
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 811: Constructors in PointOfInterest
Constructors
PointOfInterest ()
Field Summary
Table 812: Fields in PointOfInterest
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeColorProperty FUELTYPE_FONTSTYLE_COLOR
public static final SchemeColorProperty FUELTYPE_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FUELTYPE_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FUELTYPE_FONTSTYLE_SIZE
public static final SchemeIntegerProperty FUELTYPE_ICONSIZE
public static final SchemeIntegerProperty GENERAL_ICONSIZE
public static final SchemeColorProperty POINTOFINTEREST_24HOUR_FONTSTYLE_COLOR
public static final SchemeColorProperty POINTOFINTEREST_24HOUR_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty POINTOFINTEREST_24HOUR_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty POINTOFINTEREST_24HOUR_FONTSTYLE_SIZE
public static final SchemeIntegerProperty POINTOFINTEREST_24HOUR_ICONSIZE
Class Details
Constructor Details
PointOfInterest ()
HERE Android SDK Developer's Guide
API Reference
1335
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeColorProperty FUELTYPE_FONTSTYLE_COLOR
public static final SchemeColorProperty FUELTYPE_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FUELTYPE_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FUELTYPE_FONTSTYLE_SIZE
public static final SchemeIntegerProperty FUELTYPE_ICONSIZE
public static final SchemeIntegerProperty GENERAL_ICONSIZE
public static final SchemeColorProperty POINTOFINTEREST_24HOUR_FONTSTYLE_COLOR
public static final SchemeColorProperty
POINTOFINTEREST_24HOUR_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
POINTOFINTEREST_24HOUR_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty POINTOFINTEREST_24HOUR_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1336
public static final SchemeIntegerProperty POINTOFINTEREST_24HOUR_ICONSIZE
Rail
The class Rail is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Rail
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 813: Constructors in Rail
Constructors
Rail ()
Field Summary
Table 814: Fields in Rail
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
Rail ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1337
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Railway
The class Railway is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Railway
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 815: Constructors in Railway
Constructors
Railway ()
Field Summary
Table 816: Fields in Railway
Fields
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
HERE Android SDK Developer's Guide
API Reference
1338
Class Details
Constructor Details
Railway ()
Field Details
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
HERE Android SDK Developer's Guide
API Reference
1339
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
Railyard
The class Railyard is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Railyard
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 817: Constructors in Railyard
Constructors
Railyard ()
Field Summary
Table 818: Fields in Railyard
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Railyard ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1340
RailyardInfo
The class RailyardInfo is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.RailyardInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 819: Constructors in RailyardInfo
Constructors
RailyardInfo ()
Field Summary
Table 820: Fields in RailyardInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
RailyardInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1341
public static final SchemeFloatProperty FONTSTYLE_SIZE
RemainingRangeEV
The class RemainingRangeEV is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.RemainingRangeEV
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 821: Constructors in RemainingRangeEV
Constructors
RemainingRangeEV ()
Field Summary
Table 822: Fields in RemainingRangeEV
Fields
public static final SchemeColorProperty GRADIENT_COLORINNER
public static final SchemeColorProperty GRADIENT_COLOROUTER
public static final SchemeColorProperty LINE_COLOR
public static final SchemeFloatProperty LINE_WIDTH
public static final SchemeColorProperty OUTLINE_COLOR
public static final SchemeFloatProperty OUTLINE_WIDTH
Class Details
Constructor Details
RemainingRangeEV ()
HERE Android SDK Developer's Guide
API Reference
1342
Field Details
public static final SchemeColorProperty GRADIENT_COLORINNER
public static final SchemeColorProperty GRADIENT_COLOROUTER
public static final SchemeColorProperty LINE_COLOR
public static final SchemeFloatProperty LINE_WIDTH
public static final SchemeColorProperty OUTLINE_COLOR
public static final SchemeFloatProperty OUTLINE_WIDTH
River
The class River is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.River
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 823: Constructors in River
Constructors
River ()
Field Summary
Table 824: Fields in River
Fields
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1343
Fields
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1344
Fields
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
River ()
Field Details
public static final SchemeColorProperty COLOR
public static final SchemeColorProperty DISPLAYCLASS1_COLOR
HERE Android SDK Developer's Guide
API Reference
1345
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS1_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS1_WIDTH
public static final SchemeColorProperty DISPLAYCLASS2_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS2_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS2_WIDTH
public static final SchemeColorProperty DISPLAYCLASS3_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS3_FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1346
public static final SchemeFloatProperty DISPLAYCLASS3_WIDTH
public static final SchemeColorProperty DISPLAYCLASS4_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS4_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS4_WIDTH
public static final SchemeColorProperty DISPLAYCLASS5_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS5_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS5_WIDTH
public static final SchemeColorProperty DISPLAYCLASS6_COLOR
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1347
public static final SchemeColorProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS6_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS6_WIDTH
public static final SchemeColorProperty DISPLAYCLASS7_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS7_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS7_WIDTH
public static final SchemeColorProperty DISPLAYCLASS8_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_COLOR
public static final SchemeColorProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty DISPLAYCLASS8_FONTSTYLE_SIZE
public static final SchemeFloatProperty DISPLAYCLASS8_WIDTH
HERE Android SDK Developer's Guide
API Reference
1348
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
public static final SchemeFloatProperty WIDTH
RoadSign
The class RoadSign is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.RoadSign
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 825: Constructors in RoadSign
Constructors
RoadSign ()
Field Summary
Table 826: Fields in RoadSign
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
HERE Android SDK Developer's Guide
API Reference
1349
Class Details
Constructor Details
RoadSign ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
RouteStyle
The class RouteStyle is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.RouteStyle
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 827: Constructors in RouteStyle
Constructors
RouteStyle ()
Field Summary
Table 828: Fields in RouteStyle
Fields
public static final SchemeColorProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_COLOR
public static final SchemeColorProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1350
Fields
public static final SchemeFloatProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_SIZE
Class Details
Constructor Details
RouteStyle ()
Field Details
public static final SchemeColorProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_COLOR
public static final SchemeColorProperty
ROUTESTYLE_1_BILLBOARD_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
ROUTESTYLE_1_BILLBOARD_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty ROUTESTYLE_1_BILLBOARD_FONTSTYLE_SIZE
Runway
The class Runway is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Runway
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 829: Constructors in Runway
Constructors
Runway ()
HERE Android SDK Developer's Guide
API Reference
1351
Field Summary
Table 830: Fields in Runway
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Runway ()
Field Details
public static final SchemeColorProperty COLOR
SSAO
The class SSAO is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.SSAO
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 831: Constructors in SSAO
Constructors
SSAO ()
Field Summary
Table 832: Fields in SSAO
Fields
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1352
Class Details
Constructor Details
SSAO ()
Field Details
public static final SchemeColorProperty COLOR
Sea
The class Sea is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Sea
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 833: Constructors in Sea
Constructors
Sea ()
Field Summary
Table 834: Fields in Sea
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
Sea ()
HERE Android SDK Developer's Guide
API Reference
1353
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
ShoppingComplex
The class ShoppingComplex is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ShoppingComplex
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 835: Constructors in ShoppingComplex
Constructors
ShoppingComplex ()
Field Summary
Table 836: Fields in ShoppingComplex
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
ShoppingComplex ()
HERE Android SDK Developer's Guide
API Reference
1354
Field Details
public static final SchemeColorProperty COLOR
ShoppingComplexInfo
The class ShoppingComplexInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ShoppingComplexInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 837: Constructors in ShoppingComplexInfo
Constructors
ShoppingComplexInfo ()
Field Summary
Table 838: Fields in ShoppingComplexInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
ShoppingComplexInfo ()
HERE Android SDK Developer's Guide
API Reference
1355
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Sky
The class Sky is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Sky
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 839: Constructors in Sky
Constructors
Sky ()
Field Summary
Table 840: Fields in Sky
Fields
public static final SchemeColorProperty COLORBOTTOM
public static final SchemeColorProperty COLORINTERMEDIATE
public static final SchemeColorProperty COLORTOP
Class Details
Constructor Details
Sky ()
HERE Android SDK Developer's Guide
API Reference
1356
Field Details
public static final SchemeColorProperty COLORBOTTOM
public static final SchemeColorProperty COLORINTERMEDIATE
public static final SchemeColorProperty COLORTOP
SportsComplex
The class SportsComplex is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.SportsComplex
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 841: Constructors in SportsComplex
Constructors
SportsComplex ()
Field Summary
Table 842: Fields in SportsComplex
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
SportsComplex ()
HERE Android SDK Developer's Guide
API Reference
1357
Field Details
public static final SchemeColorProperty COLOR
SportsComplexInfo
The class SportsComplexInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.SportsComplexInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 843: Constructors in SportsComplexInfo
Constructors
SportsComplexInfo ()
Field Summary
Table 844: Fields in SportsComplexInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
SportsComplexInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1358
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
StateAbbreviationLabel
The class StateAbbreviationLabel is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.StateAbbreviationLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 845: Constructors in StateAbbreviationLabel
Constructors
StateAbbreviationLabel ()
Field Summary
Table 846: Fields in StateAbbreviationLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
StateAbbreviationLabel ()
HERE Android SDK Developer's Guide
API Reference
1359
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
StateBoundary
The class StateBoundary is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.StateBoundary
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 847: Constructors in StateBoundary
Constructors
StateBoundary ()
Field Summary
Table 848: Fields in StateBoundary
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
HERE Android SDK Developer's Guide
API Reference
1360
Class Details
Constructor Details
StateBoundary ()
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
StateBoundaryDisputed
The class StateBoundaryDisputed is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.StateBoundaryDisputed
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 849: Constructors in StateBoundaryDisputed
Constructors
StateBoundaryDisputed ()
Field Summary
Table 850: Fields in StateBoundaryDisputed
Fields
public static final SchemeColorProperty BACKGROUNDCOLOR
HERE Android SDK Developer's Guide
API Reference
1361
Fields
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
StateBoundaryDisputed ()
Field Details
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeFloatProperty BACKGROUNDWIDTH
public static final SchemeColorProperty COLOR
public static final SchemeFloatProperty WIDTH
StateLabel
The class StateLabel is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.StateLabel
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 851: Constructors in StateLabel
Constructors
StateLabel ()
HERE Android SDK Developer's Guide
API Reference
1362
Field Summary
Table 852: Fields in StateLabel
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
StateLabel ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Street
The class Street is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Street
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1363
Constructor Summary
Table 853: Constructors in Street
Constructors
Street ()
Field Summary
Table 854: Fields in Street
Fields
public static final SchemeColorProperty CATEGORY0_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY0_CENTERLINE_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY0_CENTERLINE_WIDTH
public static final SchemeColorProperty CATEGORY0_COLOR
public static final SchemeColorProperty CATEGORY0_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY0_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY0_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY0_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY0_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY0_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY0_THINCOLOR
public static final SchemeColorProperty CATEGORY0_TUNNELCOLOR
HERE Android SDK Developer's Guide
API Reference
1364
Fields
public static final SchemeFloatProperty CATEGORY0_WIDTH
public static final SchemeColorProperty CATEGORY1_COLOR
public static final SchemeColorProperty CATEGORY1_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY1_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY1_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY1_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY1_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY1_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY1_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY1_THINCOLOR
public static final SchemeColorProperty CATEGORY1_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY1_WIDTH
public static final SchemeColorProperty CATEGORY2_COLOR
public static final SchemeColorProperty CATEGORY2_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY2_FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1365
Fields
public static final SchemeFloatProperty CATEGORY2_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY2_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY2_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY2_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY2_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY2_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY2_THINCOLOR
public static final SchemeColorProperty CATEGORY2_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY2_WIDTH
public static final SchemeColorProperty CATEGORY3_COLOR
public static final SchemeColorProperty CATEGORY3_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY3_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY3_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY3_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY3_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY3_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1366
Fields
public static final SchemeFloatProperty CATEGORY3_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY3_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY3_THINCOLOR
public static final SchemeColorProperty CATEGORY3_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY3_WIDTH
public static final SchemeColorProperty CATEGORY4_COLOR
public static final SchemeColorProperty CATEGORY4_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY4_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY4_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY4_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY4_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY4_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY4_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY4_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
HERE Android SDK Developer's Guide
API Reference
1367
Fields
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY4_THINCOLOR
public static final SchemeColorProperty CATEGORY4_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY4_WIDTH
public static final SchemeColorProperty PEDESTRIAN_COLOR
public static final SchemeColorProperty PEDESTRIAN_FONTSTYLE_COLOR
public static final SchemeColorProperty PEDESTRIAN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty PEDESTRIAN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty PEDESTRIAN_FONTSTYLE_SIZE
public static final SchemeColorProperty PEDESTRIAN_OUTLINECOLOR
public static final SchemeFloatProperty PEDESTRIAN_OUTLINE_WIDTH
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
HERE Android SDK Developer's Guide
API Reference
1368
Fields
public static final SchemeColorProperty PEDESTRIAN_THINCOLOR
public static final SchemeColorProperty PEDESTRIAN_TUNNELCOLOR
public static final SchemeFloatProperty PEDESTRIAN_WIDTH
public static final SchemeColorProperty WALKWAY_COLOR
public static final SchemeColorProperty WALKWAY_FONTSTYLE_COLOR
public static final SchemeColorProperty WALKWAY_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty WALKWAY_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty WALKWAY_FONTSTYLE_SIZE
public static final SchemeColorProperty WALKWAY_OUTLINECOLOR
public static final SchemeFloatProperty WALKWAY_OUTLINE_WIDTH
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty WALKWAY_THINCOLOR
public static final SchemeColorProperty WALKWAY_TUNNELCOLOR
public static final SchemeFloatProperty WALKWAY_WIDTH
Class Details
Constructor Details
Street ()
HERE Android SDK Developer's Guide
API Reference
1369
Field Details
public static final SchemeColorProperty CATEGORY0_CENTERLINE_COLOR
public static final SchemeColorProperty CATEGORY0_CENTERLINE_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY0_CENTERLINE_WIDTH
public static final SchemeColorProperty CATEGORY0_COLOR
public static final SchemeColorProperty CATEGORY0_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY0_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY0_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY0_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY0_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY0_OUTLINE_WIDTH
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
HERE Android SDK Developer's Guide
API Reference
1370
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY0_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY0_THINCOLOR
public static final SchemeColorProperty CATEGORY0_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY0_WIDTH
public static final SchemeColorProperty CATEGORY1_COLOR
HERE Android SDK Developer's Guide
API Reference
1371
public static final SchemeColorProperty CATEGORY1_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY1_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY1_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY1_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY1_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY1_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY1_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty
CATEGORY1_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
CATEGORY1_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY1_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
HERE Android SDK Developer's Guide
API Reference
1372
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY1_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY1_THINCOLOR
public static final SchemeColorProperty CATEGORY1_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY1_WIDTH
public static final SchemeColorProperty CATEGORY2_COLOR
HERE Android SDK Developer's Guide
API Reference
1373
public static final SchemeColorProperty CATEGORY2_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY2_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY2_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY2_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY2_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY2_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY2_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty
CATEGORY2_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
CATEGORY2_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY2_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
HERE Android SDK Developer's Guide
API Reference
1374
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY2_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY2_THINCOLOR
public static final SchemeColorProperty CATEGORY2_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY2_WIDTH
public static final SchemeColorProperty CATEGORY3_COLOR
HERE Android SDK Developer's Guide
API Reference
1375
public static final SchemeColorProperty CATEGORY3_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY3_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY3_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY3_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY3_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY3_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY3_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty
CATEGORY3_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
CATEGORY3_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY3_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
HERE Android SDK Developer's Guide
API Reference
1376
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY3_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY3_THINCOLOR
public static final SchemeColorProperty CATEGORY3_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY3_WIDTH
public static final SchemeColorProperty CATEGORY4_COLOR
HERE Android SDK Developer's Guide
API Reference
1377
public static final SchemeColorProperty CATEGORY4_FONTSTYLE_COLOR
public static final SchemeColorProperty CATEGORY4_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty CATEGORY4_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY4_FONTSTYLE_SIZE
public static final SchemeColorProperty CATEGORY4_OUTLINECOLOR
public static final SchemeFloatProperty CATEGORY4_OUTLINE_WIDTH
public static final SchemeColorProperty CATEGORY4_ROADSIGN_FONTSTYLE_COLOR
public static final SchemeColorProperty
CATEGORY4_ROADSIGN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty
CATEGORY4_ROADSIGN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty CATEGORY4_ROADSIGN_FONTSTYLE_SIZE
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
HERE Android SDK Developer's Guide
API Reference
1378
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
CATEGORY4_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty CATEGORY4_THINCOLOR
public static final SchemeColorProperty CATEGORY4_TUNNELCOLOR
public static final SchemeFloatProperty CATEGORY4_WIDTH
public static final SchemeColorProperty PEDESTRIAN_COLOR
HERE Android SDK Developer's Guide
API Reference
1379
public static final SchemeColorProperty PEDESTRIAN_FONTSTYLE_COLOR
public static final SchemeColorProperty PEDESTRIAN_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty PEDESTRIAN_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty PEDESTRIAN_FONTSTYLE_SIZE
public static final SchemeColorProperty PEDESTRIAN_OUTLINECOLOR
public static final SchemeFloatProperty PEDESTRIAN_OUTLINE_WIDTH
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
HERE Android SDK Developer's Guide
API Reference
1380
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
PEDESTRIAN_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty PEDESTRIAN_THINCOLOR
public static final SchemeColorProperty PEDESTRIAN_TUNNELCOLOR
public static final SchemeFloatProperty PEDESTRIAN_WIDTH
public static final SchemeColorProperty WALKWAY_COLOR
public static final SchemeColorProperty WALKWAY_FONTSTYLE_COLOR
public static final SchemeColorProperty WALKWAY_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty WALKWAY_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty WALKWAY_FONTSTYLE_SIZE
public static final SchemeColorProperty WALKWAY_OUTLINECOLOR
HERE Android SDK Developer's Guide
API Reference
1381
public static final SchemeFloatProperty WALKWAY_OUTLINE_WIDTH
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_TOLL_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_ARROW_UNPAVED_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_BRIDGE_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_CENTERLINE_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_OUTLINE_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_THIN_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_TOLL_TUNNEL_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_COLOR
HERE Android SDK Developer's Guide
API Reference
1382
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_OUTLINE_COLOR
public static final SchemeColorProperty
WALKWAY_STREETPOLYLINEATTRIBUTE_UNPAVED_THIN_COLOR
public static final SchemeColorProperty WALKWAY_THINCOLOR
public static final SchemeColorProperty WALKWAY_TUNNELCOLOR
public static final SchemeFloatProperty WALKWAY_WIDTH
Transit
The class Transit is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Transit
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 855: Constructors in Transit
Constructors
Transit ()
Field Summary
Table 856: Fields in Transit
Fields
public static final SchemeColorProperty AERIAL_DEFAULTCOLOR
public static final SchemeIntegerProperty AERIAL_WIDTH
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeColorProperty BLENDCOLOR
public static final SchemeColorProperty BUS_EXPRESS_DEFAULTCOLOR
HERE Android SDK Developer's Guide
API Reference
1383
Fields
public static final SchemeIntegerProperty BUS_EXPRESS_WIDTH
public static final SchemeColorProperty BUS_INTERCITY_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_INTERCITY_WIDTH
public static final SchemeColorProperty BUS_PUBLIC_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_PUBLIC_WIDTH
public static final SchemeColorProperty BUS_TOURISTIC_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_TOURISTIC_WIDTH
public static final SchemeColorProperty HIGHLIGHTEDBACKGROUNDCOLOR
public static final SchemeColorProperty HIGHLIGHTEDFONTOUTLINECOLOR
public static final SchemeColorProperty INCLINED_DEFAULTCOLOR
public static final SchemeIntegerProperty INCLINED_WIDTH
public static final SchemeColorProperty MONORAIL_DEFAULTCOLOR
public static final SchemeIntegerProperty MONORAIL_WIDTH
public static final SchemeIntegerProperty OUTLINEWIDTH
public static final SchemeColorProperty RAIL_CITYMETRO_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_CITYMETRO_WIDTH
public static final SchemeColorProperty RAIL_LIGHT_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_LIGHT_WIDTH
public static final SchemeColorProperty RAIL_REGIONAL_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_REGIONAL_WIDTH
public static final SchemeColorProperty STOP_FONTSTYLE_COLOR
public static final SchemeColorProperty STOP_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STOP_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STOP_FONTSTYLE_SIZE
public static final SchemeColorProperty TRAIN_HIGHSPEED_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_HIGHSPEED_WIDTH
public static final SchemeColorProperty TRAIN_INTERCITY_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_INTERCITY_WIDTH
public static final SchemeColorProperty TRAIN_REGIONAL_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_REGIONAL_WIDTH
public static final SchemeColorProperty WATER_BACKGROUNDCOLOR
HERE Android SDK Developer's Guide
API Reference
1384
Fields
public static final SchemeColorProperty WATER_DEFAULTCOLOR
public static final SchemeColorProperty WATER_HIGHLIGHTEDBACKGROUNDCOLOR
public static final SchemeColorProperty WATER_HIGHLIGHTEDFONTOUTLINECOLOR
public static final SchemeIntegerProperty WATER_WIDTH
Class Details
Constructor Details
Transit ()
Field Details
public static final SchemeColorProperty AERIAL_DEFAULTCOLOR
public static final SchemeIntegerProperty AERIAL_WIDTH
public static final SchemeColorProperty BACKGROUNDCOLOR
public static final SchemeColorProperty BLENDCOLOR
public static final SchemeColorProperty BUS_EXPRESS_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_EXPRESS_WIDTH
public static final SchemeColorProperty BUS_INTERCITY_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_INTERCITY_WIDTH
public static final SchemeColorProperty BUS_PUBLIC_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_PUBLIC_WIDTH
HERE Android SDK Developer's Guide
API Reference
1385
public static final SchemeColorProperty BUS_TOURISTIC_DEFAULTCOLOR
public static final SchemeIntegerProperty BUS_TOURISTIC_WIDTH
public static final SchemeColorProperty HIGHLIGHTEDBACKGROUNDCOLOR
public static final SchemeColorProperty HIGHLIGHTEDFONTOUTLINECOLOR
public static final SchemeColorProperty INCLINED_DEFAULTCOLOR
public static final SchemeIntegerProperty INCLINED_WIDTH
public static final SchemeColorProperty MONORAIL_DEFAULTCOLOR
public static final SchemeIntegerProperty MONORAIL_WIDTH
public static final SchemeIntegerProperty OUTLINEWIDTH
public static final SchemeColorProperty RAIL_CITYMETRO_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_CITYMETRO_WIDTH
public static final SchemeColorProperty RAIL_LIGHT_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_LIGHT_WIDTH
public static final SchemeColorProperty RAIL_REGIONAL_DEFAULTCOLOR
public static final SchemeIntegerProperty RAIL_REGIONAL_WIDTH
public static final SchemeColorProperty STOP_FONTSTYLE_COLOR
HERE Android SDK Developer's Guide
API Reference
1386
public static final SchemeColorProperty STOP_FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty STOP_FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty STOP_FONTSTYLE_SIZE
public static final SchemeColorProperty TRAIN_HIGHSPEED_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_HIGHSPEED_WIDTH
public static final SchemeColorProperty TRAIN_INTERCITY_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_INTERCITY_WIDTH
public static final SchemeColorProperty TRAIN_REGIONAL_DEFAULTCOLOR
public static final SchemeIntegerProperty TRAIN_REGIONAL_WIDTH
public static final SchemeColorProperty WATER_BACKGROUNDCOLOR
public static final SchemeColorProperty WATER_DEFAULTCOLOR
public static final SchemeColorProperty WATER_HIGHLIGHTEDBACKGROUNDCOLOR
public static final SchemeColorProperty WATER_HIGHLIGHTEDFONTOUTLINECOLOR
public static final SchemeIntegerProperty WATER_WIDTH
TransitAccess
The class TransitAccess is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1387
Class Summary
public static class CustomizableVariables.TransitAccess
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 857: Constructors in TransitAccess
Constructors
TransitAccess ()
Field Summary
Table 858: Fields in TransitAccess
Fields
public static final SchemeIntegerProperty AIRLINE_ICONSIZE
public static final SchemeIntegerProperty ICONSIZE
Class Details
Constructor Details
TransitAccess ()
Field Details
public static final SchemeIntegerProperty AIRLINE_ICONSIZE
public static final SchemeIntegerProperty ICONSIZE
TruckIcon
The class TruckIcon is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.TruckIcon
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1388
Constructor Summary
Table 859: Constructors in TruckIcon
Constructors
TruckIcon ()
Field Summary
Table 860: Fields in TruckIcon
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
TruckIcon ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
TruckLine
The class TruckLine is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.TruckLine
HERE Android SDK Developer's Guide
API Reference
1389
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 861: Constructors in TruckLine
Constructors
TruckLine ()
Field Summary
Table 862: Fields in TruckLine
Fields
public static final SchemeIntegerProperty CATEGORY0_WIDTH
public static final SchemeIntegerProperty CATEGORY1_WIDTH
public static final SchemeIntegerProperty CATEGORY2_WIDTH
public static final SchemeIntegerProperty CATEGORY3_WIDTH
public static final SchemeIntegerProperty CATEGORY4_WIDTH
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
TruckLine ()
Field Details
public static final SchemeIntegerProperty CATEGORY0_WIDTH
public static final SchemeIntegerProperty CATEGORY1_WIDTH
public static final SchemeIntegerProperty CATEGORY2_WIDTH
public static final SchemeIntegerProperty CATEGORY3_WIDTH
HERE Android SDK Developer's Guide
API Reference
1390
public static final SchemeIntegerProperty CATEGORY4_WIDTH
public static final SchemeColorProperty COLOR
UniversityCampus
The class UniversityCampus is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.UniversityCampus
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 863: Constructors in UniversityCampus
Constructors
UniversityCampus ()
Field Summary
Table 864: Fields in UniversityCampus
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
UniversityCampus ()
Field Details
public static final SchemeColorProperty COLOR
HERE Android SDK Developer's Guide
API Reference
1391
UniversityCampusInfo
The class UniversityCampusInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.UniversityCampusInfo
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 865: Constructors in UniversityCampusInfo
Constructors
UniversityCampusInfo ()
Field Summary
Table 866: Fields in UniversityCampusInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
UniversityCampusInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
HERE Android SDK Developer's Guide
API Reference
1392
public static final SchemeFloatProperty FONTSTYLE_SIZE
Water
The class Water is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Water
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 867: Constructors in Water
Constructors
Water ()
Field Summary
Table 868: Fields in Water
Fields
public static final SchemeColorProperty COLOR_0M
public static final SchemeColorProperty COLOR_3000M
Class Details
Constructor Details
Water ()
Field Details
public static final SchemeColorProperty COLOR_0M
public static final SchemeColorProperty COLOR_3000M
HERE Android SDK Developer's Guide
API Reference
1393
Woodland
The class Woodland is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.Woodland
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 869: Constructors in Woodland
Constructors
Woodland ()
Field Summary
Table 870: Fields in Woodland
Fields
public static final SchemeColorProperty COLOR
Class Details
Constructor Details
Woodland ()
Field Details
public static final SchemeColorProperty COLOR
WoodlandInfo
The class WoodlandInfo is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.WoodlandInfo
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1394
[For complete information, see the section Class Details]
Constructor Summary
Table 871: Constructors in WoodlandInfo
Constructors
WoodlandInfo ()
Field Summary
Table 872: Fields in WoodlandInfo
Fields
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
Class Details
Constructor Details
WoodlandInfo ()
Field Details
public static final SchemeColorProperty FONTSTYLE_COLOR
public static final SchemeColorProperty FONTSTYLE_OUTLINE_COLOR
public static final SchemeFloatProperty FONTSTYLE_OUTLINE_WIDTH
public static final SchemeFloatProperty FONTSTYLE_SIZE
WorldMountains
The class WorldMountains is a member of
com.here.android.mpa.mapping.customization.CustomizableVariables.
HERE Android SDK Developer's Guide
API Reference
1395
Class Summary
public static class CustomizableVariables.WorldMountains
extends java.lang.Object
[For complete information, see the section Class Details]
Constructor Summary
Table 873: Constructors in WorldMountains
Constructors
WorldMountains ()
Field Summary
Table 874: Fields in WorldMountains
Fields
public static final SchemeColorProperty COLOR_1500M
public static final SchemeColorProperty COLOR_3000M
Class Details
Constructor Details
WorldMountains ()
Field Details
public static final SchemeColorProperty COLOR_1500M
public static final SchemeColorProperty COLOR_3000M
ZoneBorder
The class ZoneBorder is a member of com.here.android.mpa.mapping.customization.CustomizableVariables.
Class Summary
public static class CustomizableVariables.ZoneBorder
extends java.lang.Object
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1396
Constructor Summary
Table 875: Constructors in ZoneBorder
Constructors
ZoneBorder ()
Field Summary
Table 876: Fields in ZoneBorder
Fields
public static final SchemeFloatProperty WIDTH
Class Details
Constructor Details
ZoneBorder ()
Field Details
public static final SchemeFloatProperty WIDTH
SchemeColorProperty
The class SchemeColorProperty is a member of com.here.android.mpa.mapping.customization .
Class Summary
public final class SchemeColorProperty
extends java.lang.Object
Represents a color property that can be set in a customizable scheme.
[For complete information, see the section Class Details]
Method Summary
Table 877: Methods in SchemeColorProperty
Methods
public String getName ()
Get name of variable
HERE Android SDK Developer's Guide
API Reference
1397
Methods
public String getTypeName ()
Get value type in String form.
Class Details
Represents a color property that can be set in a customizable scheme. A color property cannot be
constructed. Instead, it should be retrieved from CustomizableVariables class.
Method Details
public String getName ()
Get name of variable
Returns:
name of variable
public String getTypeName ()
Get value type in String form.
Returns:
value type in String form.
SchemeFloatProperty
The class SchemeFloatProperty is a member of com.here.android.mpa.mapping.customization .
Class Summary
public class SchemeFloatProperty
extends java.lang.Object
Represents a float property that can be set in a customizable scheme.
[For complete information, see the section Class Details]
Method Summary
Table 878: Methods in SchemeFloatProperty
Methods
public String getName ()
Get name of variable
HERE Android SDK Developer's Guide
API Reference
1398
Methods
public String getTypeName ()
Get value type in String form.
Class Details
Represents a float property that can be set in a customizable scheme. A float property cannot be
constructed. Instead, it should be retrieved from CustomizableVariables class.
Method Details
public String getName ()
Get name of variable
Returns:
name of variable
public String getTypeName ()
Get value type in String form.
Returns:
value type in String form.
SchemeIntegerProperty
The class SchemeIntegerProperty is a member of com.here.android.mpa.mapping.customization .
Class Summary
public class SchemeIntegerProperty
extends java.lang.Object
Represents a integer property that can be set in a customizable scheme.
[For complete information, see the section Class Details]
Method Summary
Table 879: Methods in SchemeIntegerProperty
Methods
public String getName ()
Get name of variable
HERE Android SDK Developer's Guide
API Reference
1399
Methods
public String getTypeName ()
Get value type in String form.
Class Details
Represents a integer property that can be set in a customizable scheme. A integer property cannot be
constructed. Instead, it should be retrieved from CustomizableVariables class.
Method Details
public String getName ()
Get name of variable
Returns:
name of variable
public String getTypeName ()
Get value type in String form.
Returns:
value type in String form.
ZoomRange
The class ZoomRange is a member of com.here.android.mpa.mapping.customization .
Class Summary
public class ZoomRange
extends java.lang.Object
Specify range for zoom level.
[For complete information, see the section Class Details]
Constructor Summary
Table 880: Constructors in ZoomRange
Constructors
ZoomRange (double min, double max)
HERE Android SDK Developer's Guide
API Reference
1400
Method Summary
Table 881: Methods in ZoomRange
Methods
public double getMax ()
public double getMin ()
public void setMax (double max)
public void setMin (double min)
Class Details
Specify range for zoom level.
Constructor Details
ZoomRange (double min, double max)
Parameters:
min
max
Method Details
public double getMax ()
Returns:
the max
public double getMin ()
Returns:
the min
public void setMax (double max)
Parameters:
max
the max to set
public void setMin (double min)
HERE Android SDK Developer's Guide
API Reference
1401
Parameters:
min
the min to set
nlp
The package nlp is a member of com.here.android.mpa.
Package Summary
nlp
The package nlp (Natural Language Processing) provides classes, interfaces, and enumerations that allow
your application to add natural language processing to your HERE SDK app.
Package Details
The package nlp (Natural Language Processing) provides classes, interfaces, and enumerations that allow
your application to add natural language processing to your HERE SDK app. The APIs in this package are
considered Beta and are subject to change without notice.
CollectionProvider
The interface CollectionProvider is a member of com.here.android.mpa.nlp .
Interface Summary
public abstract interface CollectionProvider
Collection interface for adding, removing, renaming, retrieving collections and/or places.
[For complete information, see the section Interface Details]
Method Summary
Table 882: Methods in CollectionProvider
Methods
public abstract void addCollection (String collectionName, java.lang.ref.WeakReference
<OnCollectionListener> listener)
Add the specified collection.
public abstract void addPlace (String collectionName, Place place, java.lang.ref.WeakReference
<OnCollectionListener> listener)
Add the specified place to the specified collection.
HERE Android SDK Developer's Guide
API Reference
1402
Methods
public abstract void clear (java.lang.ref.WeakReference <OnCollectionListener> listener)
Remove all collections.
public abstract void copyCollection (String sourceCollectionName, String
destinationCollectionName, java.lang.ref.WeakReference <OnCollectionListener> listener)
Copy a collection.
public abstract void copyPlace (String sourceCollectionName, String placeName, String
destinationCollectionName, java.lang.ref.WeakReference <OnCollectionListener> listener)
Copy the specified place in a collection to another collection.
public abstract List getCollectionNames ()
Retrieve all collection names.
public abstract List getCollectionNames (String placeName)
Get all collection names that has a place with the specified name.
public abstract Place getPlace (String collectionName, String placeName)
Retrieve the place matching the specified name from the specified collection.
public abstract java.util.List <Place> getPlaces (String collectionName)
Retrieve all places in the specified collection.
public abstract void removeCollection (String collectionName, java.lang.ref.WeakReference
<OnCollectionListener> listener)
Remove the specified collection.
public abstract void removePlace (String collectionName, String placeName,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Remove the specified place from the specified collection.
public abstract void renameCollection (String originalCollectionName, String newCollectionName,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Rename a collection.
public abstract void renamePlace (String collectionName, String originalPlaceName, String
newPlaceName, java.lang.ref.WeakReference <OnCollectionListener> listener)
Rename the specified place in a collection.
Interface Details
Collection interface for adding, removing, renaming, retrieving collections and/or places. If this interface
is not implemented, all collection related utterances will result in feature not supported announcement
to the users. If application chooses to implement this interface, be sure to adopt a strategy for handling
the use cases where a user does not explicitly specify a collection name, whether to persist collection
data and how to persist and synchronize data, whether to support duplicates, and whether to allow any
discrepancies in the names to accommodate inaccuracies of speech-to-text or user accents. To achieve
better user experience, it's highly recommended that the names used for collections and places be a single
word without any punctuation or symbol and they should be case insensitive.
HERE Android SDK Developer's Guide
API Reference
1403
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Method Details
public abstract void addCollection (String collectionName,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Add the specified collection.
Here are a few things to consider:
If your collection provider does not support duplicates, you'll need to validate whether the specified
collection already exists and what to do if it is, e.g. will you replace the old one with the new one and
inform user through Error? Or will you disallow this by informing user to delete the existing one first and
then retry?
If your collection provider supports duplicates, how will you handle copyCollection(String, String,
WeakReference), removeCollection(String, WeakReference), renameCollection(String, String,
WeakReference), and getPlaces(String) when duplicates exist? Will the operation be applied to all
instances or just the first one? For 3.5, user will not be prompted to clarify which one nor will user be
allowed to iterate through the collection via USE_FIRST, USE_LAST, USE_NEXT, or USE_PREV. Any desired
customization requires intercepting Intention handling through Nlp.OnIntentListener.
How will your collection provider handle adding a place to an unspecified collection? Will you create
a special collection, if so, please make sure the name of this special collection is returned from
getCollectionNames(String) and getCollectionNames() where applicable.
Does your collection provider support the concept of a collection? If not, what should happen with these
collection related utterances? Will you ignore them, or will you inform the user that these features are
not supported?
Parameters:
collectionName
The name of the collection to be added. null if user does not explicitly specify the name of the collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in
the onComplete(Error) should be NONE if the specified collection is successfully added; otherwise
return FAILED. Any message returned from getMessage() will be read to the user regardless whether the
operation is successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
public abstract void addPlace (String collectionName, Place place,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Add the specified place to the specified collection.
Here are a few things to consider:
If your collection provider does not support duplicates, you'll need to validate whether the specified
place is already in the collection and what to do if it is, e.g. will you replace the old one with the new one
and inform user through Error? Or will you disallow this by informing user to delete the existing one first
and then retry?
HERE Android SDK Developer's Guide
API Reference
1404
If your collection provider supports duplicates, how will you handle copyPlace(String, String, String,
WeakReference), removePlace(String, String, WeakReference), renamePlace(String, String, String,
WeakReference), and getPlace(String, String) when duplicates exist? Will the operation be applied to all
instances or just the first one? For 3.5, user will not be prompted to clarify which one nor will user be
allowed to iterate through the collection via USE_FIRST, USE_LAST, USE_NEXT, or USE_PREV. Any desired
customization requires intercepting Intention handling through Nlp.OnIntentListener.
How will your collection provider handle adding a place to an unspecified collection? Will you create
a special collection, if so, please make sure the name of this special collection is returned from
getCollectionNames(String) and getCollectionNames() where applicable.
How will your collection provider handle adding a place to a non-existing collection? Will it automatically
create it or inform user to create it first?
Does your collection provider support the concept of a collection? If not, what should happen if user
explicitly specify a collection name? Will you ignore the collection name parameter or will you inform the
user and have your user to try again without specifying a collection name?
Parameters:
collectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
place
The Place to be added into collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in the
onComplete(Error) should be NONE if the specified place is successfully added; otherwise return FAILED.
Any message returned from getMessage() will be read to the user regardless whether the operation is
successful.
public abstract void clear (java.lang.ref.WeakReference <OnCollectionListener>
listener)
Remove all collections.
Parameters:
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in the
onComplete(Error) should be NONE if all collections are successfully removed; otherwise return FAILED.
Any message returned from getMessage() will be read to the user regardless whether the operation is
successful.
public abstract void copyCollection (String sourceCollectionName, String
destinationCollectionName, java.lang.ref.WeakReference <OnCollectionListener>
listener)
Copy a collection.
Parameters:
sourceCollectionName
HERE Android SDK Developer's Guide
API Reference
1405
The name of the collection to be renamed. null if user does not explicitly specify the name of the
collection.
destinationCollectionName
The new name of the collection. null if user does not explicitly specify the name of the collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in
the onComplete(Error) should be NONE if the specified collection is successfully renamed; otherwise
return FAILED. Any message returned from getMessage() will be read to the user regardless whether the
operation is successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
addCollection(String, WeakReference<OnCollectionListener>)
public abstract void copyPlace (String sourceCollectionName, String
placeName, String destinationCollectionName, java.lang.ref.WeakReference
<OnCollectionListener> listener)
Copy the specified place in a collection to another collection.
Parameters:
sourceCollectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
placeName
The name of the place to be copied.
destinationCollectionName
The name of the collection to copied to. null if user does not explicitly specify the name of the collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in the
onComplete(Error) should be NONE if the specified place is successfully copied; otherwise return FAILED.
Any message returned from getMessage() will be read to the user regardless whether the operation is
successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
public abstract List getCollectionNames ()
Retrieve all collection names. These names may be announced to the users so if you have a special
collection to store places whenever user does not explicitly a collection, return the name of that special
collection. e.g. A special collection called "unnamed", then return "unnamed" instead of an empty string or
null.
HERE Android SDK Developer's Guide
API Reference
1406
Returns:
A list of collection names. An empty list if there isn't any collection.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
addCollection(String, WeakReference<OnCollectionListener>)
public abstract List getCollectionNames (String placeName)
Get all collection names that has a place with the specified name. These names may be announced to the
users so if you have a special collection to store places whenever user does not explicitly a collection and
the given place is found in that special collection, return the name of that collection. e.g. A special collection
called "unnamed", then return "unnamed" instead of an empty string or null.
Parameters:
placeName
The name of the place.
Returns:
A list of collection names, or empty list if the specified place exists but does not belong to any collection, or
null if the specified place does not exist.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
addCollection(String, WeakReference<OnCollectionListener>)
public abstract Place getPlace (String collectionName, String placeName)
Retrieve the place matching the specified name from the specified collection.
Parameters:
collectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
placeName
The name of the place to retrieve.
Returns:
Place in the specified collection. null if the specified place does not exist in the specified collection.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
public abstract java.util.List <Place> getPlaces (String collectionName)
HERE Android SDK Developer's Guide
API Reference
1407
Retrieve all places in the specified collection.
Parameters:
collectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
Returns:
Places in the specified collection. null if the specified collection does not exist; an empty list if the specified
collection exists but does not contain any place.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
addCollection(String, WeakReference<OnCollectionListener>)
public abstract void removeCollection (String collectionName,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Remove the specified collection.
Parameters:
collectionName
The name of the collection to be removed. null if user does not explicitly specify the name of the
collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in
the onComplete(Error) should be NONE for the following scenarios: 1) if the specified collection is
successfully removed. 2) if the specified collection does not exist to begin with. If the specified collection
cannot be successfully removed, return FAILED. Any message returned from getMessage() will be read to
the user regardless whether the operation is successful.
See also:
addCollection(String, WeakReference<OnCollectionListener>)
public abstract void removePlace (String collectionName, String placeName,
java.lang.ref.WeakReference <OnCollectionListener> listener)
Remove the specified place from the specified collection.
Parameters:
collectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
placeName
The name of the place to be removed from collection.
listener
HERE Android SDK Developer's Guide
API Reference
1408
The OnCollectionListener to handle the callback after operation is completed. The error provided in the
onComplete(Error) should be NONE for the following scenarios: 1) if the specified place is successfully
removed from the specified collection. 2) if the specified place does not exist in the specified collection
to begin with. If the specified place cannot be successfully removed from the specified collection,
return FAILED. Any message returned from getMessage() will be read to the user regardless whether the
operation is successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
public abstract void renameCollection (String originalCollectionName,
String newCollectionName, java.lang.ref.WeakReference <OnCollectionListener>
listener)
Rename a collection.
Parameters:
originalCollectionName
The name of the collection to be renamed. null if user does not explicitly specify the name of the
collection.
newCollectionName
The new name of the collection. null if user does not explicitly specify the name of the collection.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in
the onComplete(Error) should be NONE if the specified collection is successfully renamed; otherwise
return FAILED. Any message returned from getMessage() will be read to the user regardless whether the
operation is successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
addCollection(String, WeakReference<OnCollectionListener>)
public abstract void renamePlace (String collectionName, String
originalPlaceName, String newPlaceName, java.lang.ref.WeakReference
<OnCollectionListener> listener)
Rename the specified place in a collection.
Parameters:
collectionName
The name of the collection. null if user does not explicitly specify the name of the collection.
originalPlaceName
The name of the place to be renamed.
HERE Android SDK Developer's Guide
API Reference
1409
newPlaceName
The new name of the place.
listener
The OnCollectionListener to handle the callback after operation is completed. The error provided in
the onComplete(Error) should be NONE if the specified place is successfully renamed; otherwise return
FAILED. Any message returned from getMessage() will be read to the user regardless whether the
operation is successful.
See also:
addPlace(String, Place, WeakReference<OnCollectionListener>)
Error
The enumeration Error is a member of com.here.android.mpa.nlp .
Enumeration Summary
public final enumeration Error
extends java.lang.Enum, java.lang.Object
Represents the status of a NLP operation.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 883: Enum Constants in Error
Fields
public static final Error NONE
Operation is successfully performed
public static final Error FAILED
Operation failed
Method Summary
Table 884: Methods in Error
Methods
public static Error create (Error error, String message)
Constructs an error with the specified error code and message
public String getMessage ()
Retrieve the message
HERE Android SDK Developer's Guide
API Reference
1410
Methods
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents the status of a NLP operation.
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Enum Constant Details
public static final Error NONE
Operation is successfully performed
public static final Error FAILED
Operation failed
Method Details
public static Error create (Error error, String message)
Constructs an error with the specified error code and message
Parameters:
error
NONE or FAILED
message
The detailed message about the operation performed
Returns:
The Error object.
public String getMessage ()
Retrieve the message
Returns:
The detailed message about the operation performed
HERE Android SDK Developer's Guide
API Reference
1411
public static Error valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Error[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Intention
The class Intention is a member of com.here.android.mpa.nlp .
Class Summary
public final class Intention
extends java.lang.Object
Natural language processor intention object, an abstract description of an operation from voice input.
[For complete information, see the section Class Details]
Nested Class Summary
Table 885: Nested Classes in Intention
Nested Classes
public static final enumeration Intention.Field
Intention parameters names
public static final enumeration Intention.Function
Function values for FUNCTION.
public static final enumeration Intention.Value
values for Intention.Field
Method Summary
Table 886: Methods in Intention
Methods
public boolean containsFieldValue (Field fieldId, String subString)
Check if the intention has the specified Intention.Field with the specified substring value.
HERE Android SDK Developer's Guide
API Reference
1412
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public String getDeducedText ()
Get the value for text after deduction, which may be different from the original text from getOriginalText().
public String getDomain ()
Get knowledge domain
public int getFieldCount ()
Get number of Intention.Field in the intention
public List getFieldValues (Field fieldId)
Get values for the specified Intention.Field.
public java.util.Set <Field> getFields ()
Get Intention.Fields in the intention
public java.util.List <Function> getFunctions ()
Get the value for FUNCTION
public String getLanguage ()
Get language of the NLP parser applied to the speech
public String getOriginalText ()
Get value of the original text
public String getVendor ()
Get the value for VENDOR from the deduced intention
public String getVersion ()
Get the value for VERSION from the deduced intention
public boolean has (Field fieldId)
Check if the intention has the specified Intention.Field
public boolean has (Field fieldId, String value)
Check if the intention has the specified Intention.Field with the specified string.
public boolean has (Field fieldId, Value valueId)
Check if the intention has the specified Intention.Field with the specified Intention.Value.
public boolean has (Function id)
Checks whether this intention has contains the specified function.
HERE Android SDK Developer's Guide
API Reference
1413
Methods
public boolean hasOnly (Field target)
Check if the intention only has the specified Intention.Field aside from the following:
VENDOR
VERSION
LANGUAGE
DOMAIN
DURATION
FUNCTION
TEXT
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Natural language processor intention object, an abstract description of an operation from voice input. This
object is represented in a formalized JSON, for example:
{
"vendor":["HERE"],
"version":["1.0.2"],
"language":["eng"],
"duration":["0ms"],
"text":["Where is Seattle?"],
"func":["POI"],
"target":["Seattle"]
}
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean containsFieldValue (Field fieldId, String subString)
Check if the intention has the specified Intention.Field with the specified substring value. For example,
checking "kilometer" against "kilometers" will result in true.
Parameters:
fieldId
enum in Intention.Field
subString
Substring to find in the array of values for Intention.Field
Returns:
true if the intention has the specified Intention.Field with the specified substring.
HERE Android SDK Developer's Guide
API Reference
1414
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public String getDeducedText ()
Get the value for text after deduction, which may be different from the original text from getOriginalText().
Returns:
the value for TEXT, all in lower case.
public String getDomain ()
Get knowledge domain
Returns:
the value for DOMAIN. null if it does not exist.
public int getFieldCount ()
Get number of Intention.Field in the intention
Returns:
the number of Intention.Field in the intention
public List getFieldValues (Field fieldId)
Get values for the specified Intention.Field.
Parameters:
fieldId
Intention.Field to retrieve
Returns:
An array of value corresponding to the specified Intention.Field name; null if no match found or if it doesn't
contain any value.
public java.util.Set <Field> getFields ()
Get Intention.Fields in the intention
Returns:
a set of enums in Intention.Field
HERE Android SDK Developer's Guide
API Reference
1415
public java.util.List <Function> getFunctions ()
Get the value for FUNCTION
Returns:
an array of enums in Intention.Function
public String getLanguage ()
Get language of the NLP parser applied to the speech
Returns:
the value for LANGUAGE. null if it does not exist.
public String getOriginalText ()
Get value of the original text
Returns:
the value of the original text. null if it does not exist.
public String getVendor ()
Get the value for VENDOR from the deduced intention
Returns:
the value for VENDOR. null if it does not exist.
public String getVersion ()
Get the value for VERSION from the deduced intention
Returns:
the value for VERSION. null if it does not exist.
public boolean has (Field fieldId)
Check if the intention has the specified Intention.Field
Parameters:
fieldId
enum in Intention.Field
Returns:
HERE Android SDK Developer's Guide
API Reference
1416
true if the intention has the specified Intention.Field; otherwise false.
public boolean has (Field fieldId, String value)
Check if the intention has the specified Intention.Field with the specified string.
Parameters:
fieldId
enum in Intention.Field
value
string to be matched
Returns:
true if the intention has the specified Intention.Field with the specified string.
public boolean has (Field fieldId, Value valueId)
Check if the intention has the specified Intention.Field with the specified Intention.Value.
Parameters:
fieldId
enum in Intention.Field
valueId
enum in Intention.Value
Returns:
true if the intention has the specified Intention.Field with the specified Intention.Value.
public boolean has (Function id)
Checks whether this intention has contains the specified function. e.g. intention.has(Function.POI)
Parameters:
id
a Intention.Function enum value
Returns:
true if this intention has the specified function; otherwise false.
public boolean hasOnly (Field target)
Check if the intention only has the specified Intention.Field aside from the following:
VENDOR
VERSION
HERE Android SDK Developer's Guide
API Reference
1417
LANGUAGE
DOMAIN
DURATION
FUNCTION
TEXT
Parameters:
target
Intention.Field to be checked
Returns:
true if this intention has only the specified Intention.Field aside from the ones noted; false otherwise.
public int hashCode ()
For documentation, see java.lang.Object
Field
The enumeration Field is a member of com.here.android.mpa.nlp.Intention.
Enumeration Summary
public static final enumeration Intention.Field
extends java.lang.Enum, java.lang.Object
Intention parameters names
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 887: Enum Constants in Field
Fields
public static final Field VENDOR
Vendor which generated this intent.
public static final Field VERSION
Version of the deduced intention.
public static final Field LANGUAGE
Language used for deduction.
public static final Field DOMAIN
Knowledge domain.
HERE Android SDK Developer's Guide
API Reference
1418
Fields
public static final Field DURATION
Request processing time for your information only.
public static final Field FUNCTION
Function of the intent.
public static final Field TEXT
Sentence that produced this intention.
public static final Field OPTIMIZE
Optimize the route by reordering stops on the route for the following intents and may not always be present:
ADD_STOPOVER
ROUTE_FROM_TO
public static final Field REROUTE
Determines whether an alternative route should be requested in in ROUTE_FROM_TO intent and may not always be present.
public static final Field ARRIVAL_TIME
Arrival time for the following intents and may not always be present:
TIME_FROM_TO
POI
public static final Field ARRIVAL_TIME_VALUE
Arrival time value for the following intents and may not always be present:
TIME_FROM_TO
POI
public static final Field TIME_SUFFIX
AM/PM time suffix for the following intents and may not always be present:
TIME_FROM_TO
POI
public static final Field REPLY
Proposed talk back response for the following intents and may not always be present:
ELEVATION
NOTHING
POI
Q_A
RELOAD
RESET
ROUTE_FROM_TO
SAVE_PHONE_NUMBER
SET_PARAM
START_TALKING
STOP_TALKING
SYS_BATTERY
HERE Android SDK Developer's Guide
API Reference
1419
Fields
public static final Field SEARCH_COUNT
Search results count for the following intents:
POI
SEARCH_RESULT_LIMIT
public static final Field RADIUS
Search radius for the following intents and may not always be present:
POI
ROUTE_FROM_TO
public static final Field TYPE
Subcategorization of intents.
public static final Field ROUTE_TYPE
Route type for the following intents and may not always be present:
ROUTE_FROM_TO
DISTANCE_FROM_TO
public static final Field RATING
Place rating for POI intent and may not always be present.
public static final Field MEASURE
Measure system for the following intents and may not always be present:
POI
ELEVATION
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field ERROR
Error occurred on the deduction server (e.g.
public static final Field EXCEPTION
Exclusion for the following intents and may not always be present:
POI
ROUTE_FROM_TO
public static final Field WHERE
Search criteria for destination for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
HERE Android SDK Developer's Guide
API Reference
1420
Fields
public static final Field NEAR
Search criteria for destinaton for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field STOPOVER_WHERE
Search criteria for stopover for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field STOPOVER_NEAR
Search criteria for stopover for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field DEPARTURE_WHERE
Search criteria for departure for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field DEPARTURE_NEAR
Search criteria for departure for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
public static final Field FROM
Used to indicate the source for the intent.
public static final Field TARGET
Use to indicate the target for the intent.
HERE Android SDK Developer's Guide
API Reference
1421
Fields
public static final Field STOPOVER
Used to indicate a stopover for the following intents and may not always be present:
ADD_STOPOVER
DISTANCE_FROM_TO
ROUTE_FROM_TO
TIME_FROM_TO
public static final Field BY_NUMBER
Indicates whether value provided for TARGET in CALL_NUMBER intent is a phone number to be used for making a call.
public static final Field MESSAGE
Text of the message for SEND_MESSAGE intent.
public static final Field TOGGLE
To turn a feature on/off for the following intents:
COMPASS_MODE
DELAY_NAVIGATION_START
REPEAT_AFTER_ME
SPEED_WARNING
TRACK_GPS
TRAFFIC
public static final Field BY
Transport indicator for the following intents and may not always be present:
DISTANCE_FROM_TO
ROUTE_FROM_TO
TIME_FROM_TO
public static final Field COLLECTION_NAME
Collection name for the following intents and may not always be present:
CHECK_COLLECTION
COLLECT_LOCATION
LIST_COLLECTION
REMOVE_FROM_COLLECTION
public static final Field COLLECTION_ITEM
Collected item for the following intents and may not always be present:
COPY_COLLECTION
RENAME_COLLECTION
public static final Field CONTACT
Contact name for the following intents and may not always be present:
REMOVE_FROM_CONTACTS
SAVE_PHONE_NUMBER
HERE Android SDK Developer's Guide
API Reference
1422
Fields
public static final Field CATEGORY
Category for the following intents and may not always be present:
COLLECT_LOCATION
POI
public static final Field WHEN
Time reference for the following intents and may not always be present:
POI
ROUTE_FROM_TO
TRAFFIC
WEATHER
public static final Field CONVERSATION
Asking user for more info.
public static final Field USE_LAST_INTENT
Indicates whether to use previous intent for context for POI intent and may not always be present.
public static final Field ONLINE_DEDUCTION
Indicates whether to use remote backend vs local NLP database for deduction.
public static final Field WAKEUP_WORDS
Whether to use wakeup words for SET_PARAM intent and may not always be present.
public static final Field DISTANCE_MEASURE
Distance measurement for SET_PARAM intent and may not always be present.
public static final Field SHOW_ROUTE_ONLY
Indicate whether to just show the route without starting navigation for the following intents and may not always be present:
ROUTE_FROM_TO
public static final Field SIMULATE
Indicates whether to start guidance simulation for ROUTE_FROM_TO intent and may not always be present.
public static final Field ALTERNATIVE_ROUTE
Indicates whether to calculate a route for ROUTE_FROM_TO intent and may not always be present.
public static final Field FIRST_OPERAND
First operand of an arithmetic expression for MATH intent and it's always present.
public static final Field SECOND_OPERAND
Second operand of an arithmetic expression for MATH intent and it's always present.
public static final Field OPERATOR
Operator of an arithmetic expression for MATH intent and it's always present.
HERE Android SDK Developer's Guide
API Reference
1423
Method Summary
Table 888: Methods in Field
Methods
public static Field get (String name)
Retrieve enum value from the given string.
public String getName ()
Retrieve string value for the enum, e.g.
public static Field valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Intention.Field[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Intention parameters names
Enum Constant Details
public static final Field VENDOR
Vendor which generated this intent. This is applicable for all intents and is always present. Its value is array
with one string. e.g. "vendor":["HERE"]
public static final Field VERSION
Version of the deduced intention. This is applicable for all intents and is always present.Its value is an array
with one string in the format of major.minor.build. e.g. "version":["1.0.2"]
public static final Field LANGUAGE
Language used for deduction. This is applicable for all intents and is always present. Its value is an array that
contains one of the following:
ENGLISH
e.g. "language":["eng"]
public static final Field DOMAIN
Knowledge domain. e.g. "domain":["map.routing"]. This is not currently returned in any intent.
public static final Field DURATION
HERE Android SDK Developer's Guide
API Reference
1424
Request processing time for your information only. This is applicable for all intents and is always present.
e.g. "duration":["0ms"]
public static final Field FUNCTION
Function of the intent. This is applicable for all intents and is always present. Its value is an array that
contains at least one of the values defined in Intention.Function. e.g. "func":["ROUTE_FROM_TO"] e.g. "func":
["START_TALKING","DISTANCE_FROM_TO"]
public static final Field TEXT
Sentence that produced this intention. This is applicable for all intents and is always present. Its value a
array of one string. e.g. "text":["where am i"]
public static final Field OPTIMIZE
Optimize the route by reordering stops on the route for the following intents and may not always be present:
ADD_STOPOVER
ROUTE_FROM_TO
Its values is an array that contains one of the following:
TRUE
FALSE
e.g. "optimize":["false_"]
public static final Field REROUTE
Determines whether an alternative route should be requested in in ROUTE_FROM_TO intent and may not
always be present. Its value is an array that contains one of the following values:
ON
OFF
e.g. "reroute":["on_"]
Note that REROUTE means to stop using the existing route and get a new route to the same destination.
On the other hand, ALTERNATIVE_ROUTE means to stop using the existing route and get a new route to an
alternative destination.
public static final Field ARRIVAL_TIME
Arrival time for the following intents and may not always be present:
TIME_FROM_TO
POI
Its value is an array that contains one string.
HERE Android SDK Developer's Guide
API Reference
1425
e.g. "I have to be in seattle by 5" --> "arrival_time":["5"]
e.g. "I have to be in seattle by 5pm" --> "arrival_time":["5pm"]
This is the concatenation of the values for ARRIVAL_TIME_VALUE and TIME_SUFFIX if TIME_SUFFIX exists.
public static final Field ARRIVAL_TIME_VALUE
Arrival time value for the following intents and may not always be present:
TIME_FROM_TO
POI
Its value is an array that contains one string that represents the arrival time without am/pm suffix.
e.g. "I have to be in seattle by 5" --> "arrival_time_value":["5"]
e.g. "I have to be in seattle by 5pm" --> "arrival_time_value":["5"]
public static final Field TIME_SUFFIX
AM/PM time suffix for the following intents and may not always be present:
TIME_FROM_TO
POI
Its value is an array that contains one of the following:
AM
PM
e.g. "I have to be in seattle by 5" --> not present
e.g. "I have to be in seattle by 5pm" --> "time_suffix":["pm"]
public static final Field REPLY
Proposed talk back response for the following intents and may not always be present:
ELEVATION
NOTHING
POI
Q_A
RELOAD
RESET
ROUTE_FROM_TO
SAVE_PHONE_NUMBER
SET_PARAM
START_TALKING
STOP_TALKING
SYS_BATTERY
Its value is an array that contains one string. e.g. "reply":["sure"]
HERE Android SDK Developer's Guide
API Reference
1426
public static final Field SEARCH_COUNT
Search results count for the following intents:
POI
SEARCH_RESULT_LIMIT
This may not always be present for POI but is always present for SEARCH_RESULT_LIMIT.
Its value is an array that contains one string. e.g. "search_count":["5"]
public static final Field RADIUS
Search radius for the following intents and may not always be present:
POI
ROUTE_FROM_TO
Its value is an array that contains one string. e.g. "radius":["5"]
public static final Field TYPE
Subcategorization of intents.
For the following intents:
ROUTE_FROM_TO
DISTANCE_FROM_TO
it may not always be present and its value is an array that contains one of the following:
FINE
MID
CHEAP
For POI intent, it may not always be present and its value is an array that contains one of the following:
FINE
MID
CHEAP
BUS
CAR
WALK
TAXI
FERRY
FLIGHT
For PLACE_INFO intent, it may not always be present and its value is an array that contains one of the
following:
HOURS
For REPORT_GEO_EVENT intent, it's always present and its value is an array that contains one of the following:
EVENT_CRIME
HERE Android SDK Developer's Guide
API Reference
1427
EVENT_HEALTH
EVENT_TRAFFIC
For TRAFFIC intent, it may not always be present and its value is an array that contains one of the following:
ROUTE_OBJ
For NUMBER_OF intent, it's always present and its value is an array that contains one of the following:
COLLECTION_OBJ
public static final Field ROUTE_TYPE
Route type for the following intents and may not always be present:
ROUTE_FROM_TO
DISTANCE_FROM_TO
Its value is an array that contains one of the following:
FASTEST
SHORTEST
OPTIMAL
public static final Field RATING
Place rating for POI intent and may not always be present. Its value is an array that contains one of the
following values:
GOOD
BAD
POPULAR
a numeric string
public static final Field MEASURE
Measure system for the following intents and may not always be present:
POI
ELEVATION
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains one of the following:
ABBREVIATED_KILOMETER
KILOMETER
ABBREVIATED_METER
METER
MILE
YARD
FEET
HERE Android SDK Developer's Guide
API Reference
1428
MINUTES
HOURS
DAYS
public static final Field ERROR
Error occurred on the deduction server (e.g. HTTP request fails as a result of a version mismatch). This field
may not always be present.
Its value is an array that contains at least one string.
public static final Field EXCEPTION
Exclusion for the following intents and may not always be present:
POI
ROUTE_FROM_TO
Its value is an array that contains at least one string.
public static final Field WHERE
Search criteria for destination for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one string.
public static final Field NEAR
Search criteria for destinaton for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one string.
public static final Field STOPOVER_WHERE
Search criteria for stopover for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
HERE Android SDK Developer's Guide
API Reference
1429
Its value is an array that contains at least one string.
public static final Field STOPOVER_NEAR
Search criteria for stopover for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one string.
public static final Field DEPARTURE_WHERE
Search criteria for departure for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one string.
public static final Field DEPARTURE_NEAR
Search criteria for departure for the following intents and may not always be present:
POI
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one string.
public static final Field FROM
Used to indicate the source for the intent. For the following intents, it may not always be present:
ROUTE_FROM_TO
DISTANCE_FROM_TO
TIME_FROM_TO
Its value is an array that contains one of the following:
a string indicating a location
COLLECTION_OBJ
For the following intents, it's always present:
COPY_COLLECTION
RENAME_COLLECTION
HERE Android SDK Developer's Guide
API Reference
1430
Its value is an array that contains one string.
For POI intent, it may not always be present and its value is an array that contains COLLECTION_OBJ.
public static final Field TARGET
Use to indicate the target for the intent.
For CALL_NUMBER intent, it's always present and its value is an array that contains one of the following:
HOME
WORK
a string that represents a contact name
a string that contains a phone number
a string that represents a search category
For CHANGE_MAP_CENTER intent, it's always present and its value is an array that contains one of the
following:
ORIGIN
a string that indicates a location
For CHECK_COLLECTION intent, it's always present and its value is an array that contains one of the following:
HOME
WORK
a string that indicates a location
For the following intents, it's always present:
COPY_COLLECTION
RENAME_COLLECTION
Its value is an array that contains one string representing the target collection.
For DOWNLOAD intent, it's always present and its value is an array that contains one string that indicates a
location.
For REMOVE intent, it's always present and its value is an array that contains one of the following:
IT_OR_THERE
DESTINATION_OBJ
STOPOVER_OBJ
a string that represents the item to be removed
For REMOVE_FROM_CONTACTS intent, it's always present and its value is an array that contains a string
representing the contact to be removed.
For REMOVE_FROM_MAP, it's always present and its value is an array that contains one of the following:
ALL_OBJ
ROUTE_OBJ
STOPOVER_OBJ
a string that presents the ordinal of the objects on the map
a string that presents a category of the objects on the map
a string that presents the object on the map
HERE Android SDK Developer's Guide
API Reference
1431
For SEND_MESSAGE intent, it's always present and its value is an array that contains one of the following:
MYSELF
FACEBOOK
TWITTER
a string that reprents a contact name
For TALK_SPEED intent, it's always present and its value is an array that contains one of the following:
LESS
MORE
NORMAL
MINIMUM
MAXIMUM
For VOLUME intent, it's always present and its value is an array that contains one of the following:
LESS
MORE
MINIMUM
MAXIMUM
a number string that represents a percentage, e.g. 50 for 50%.
For WEB_SEARCH intent, it's always present and its value is an array that contains a search topic.
For ZOOM intent, it's always present and its value is an array that contains one of the following:
LESS
MORE
For ADD_STOPOVER intent, it may not always be present and its value is an array that contains a string that
indicates a category for the search.
For ADDRESS intent, it may not always be present and its value is an array that contains one of the following:
DESTINATION_OBJ
NEXT_MANEUVER_OBJ
STOPOVER_OBJ
HOME
WORK
For ELEVATION intent, it may not always be present and its value is an array that contains one of the
following:
HOME
WORK
a string that indicates a location
For COLLECT_LOCATION intent, it may not always be present and its value is an array that contains one of the
following value:
HOME
WORK
CAR
a string that indicates the name for the location to be collected.
For POI intent, it may not always be present and its value is an array that contains one of the following:
HERE Android SDK Developer's Guide
API Reference
1432
a string that indicates a category for the search, e.g. restaurant.
a string that indicates a place name, e.g. starbucks.
a string that indicates an address.
COLLECTION_OBJ
IT_OR_THERE
For the following intents, it may not always be present:
DISTANCE_FROM_TO
PLACE_INFO
ROUTE_FROM_TO
TIME_FROM_TO
Its value is an array that contains one of the folliwing value:
DESTINATION_OBJ
STOPOVER_OBJ
NEXT_MANEUVER_OBJ
ORIGIN
IT_OR_THERE
HOME
WORK
a string that indicates a category, e.g. restaurant.
a string that indicates a place name, e.g. starbucks.
a string that indicates an address.
For the following intents, it may not always be present:
REMOVE_FROM_COLLECTION
REMOVE_FROM_ROUTE
Its value is an array that contains on of the following:
ALL_OBJ
IT_OR_THERE
a string that indicates the ordinal of the object to be removed.
a string that indicates a category of objects to be removed.
a string that indicates the object to be removed.
For REPORT_GEO_EVENT intent, it may not always be present and its value is an array that contains one string
that presents the event, e.g. crime, hear attack, road accident, ...etc.
For SAVE_PHONE_NUMBER intent, it may not always be present and its value is an array that contains a
phone number string.
For SEND_LOCATION intent, it may not always be present and its value is an array that contains one of the
following:
MYSELF
FACEBOOK
TWITTER
a string that reprents a contact name
a string that contains a phone number
For SYS_TIME intent, it may not always be present and its value is an array that contains one of the following:
HERE Android SDK Developer's Guide
API Reference
1433
ORIGIN
IT_OR_THERE
HOME
WORK
a string that indicates a location
For TRAFFIC intent, it may not always be present and its value is an array that contains one of the following:
ROUTE_OBJ
ORIGIN
IT_OR_THERE
HOME
WORK
a string that indicates a location
For the following intents, it may not always be present:
USE_FIRST
USE_LAST
USE_NEXT
USE_PREV
Its value is an array that contains one of the following:
ROUTE_OBJ
a string that indicates a search topic
For USE_LANGUAGE intent, it may not always be present and its value is an array that contains one of the
following string:
NONE
ENGLISH
FRENCH
GERMAN
public static final Field STOPOVER
Used to indicate a stopover for the following intents and may not always be present:
ADD_STOPOVER
DISTANCE_FROM_TO
ROUTE_FROM_TO
TIME_FROM_TO
Its value is an array that contains at least one of the following:
IT_OR_THERE
HOME
WORK
a string that indicates a category for the stopover
a string that represents a location
a string that represents a collected place
HERE Android SDK Developer's Guide
API Reference
1434
public static final Field BY_NUMBER
Indicates whether value provided for TARGET in CALL_NUMBER intent is a phone number to be used for
making a call. Its value is an array of one of the following:
TRUE
FALSE
This may not always be present. When not present, it's assumed that the value provided for TARGET is not a
phone number.
public static final Field MESSAGE
Text of the message for SEND_MESSAGE intent. This may not always be present. Its value is an array of one
string that indicates the message to be sent.
public static final Field TOGGLE
To turn a feature on/off for the following intents:
COMPASS_MODE
DELAY_NAVIGATION_START
REPEAT_AFTER_ME
SPEED_WARNING
TRACK_GPS
TRAFFIC
Its value is an array of one of the following:
ON
OFF
This will always be present except for TRAFFIC. For TRAFFIC intent, when it's absent, it's assumed to be ON.
public static final Field BY
Transport indicator for the following intents and may not always be present:
DISTANCE_FROM_TO
ROUTE_FROM_TO
TIME_FROM_TO
Its value is an array of one of the following:
BUS
CAR
FERRY
FLIGHT
TAXI
TRAIN
TRANSIT
WALK
HERE Android SDK Developer's Guide
API Reference
1435
public static final Field COLLECTION_NAME
Collection name for the following intents and may not always be present:
CHECK_COLLECTION
COLLECT_LOCATION
LIST_COLLECTION
REMOVE_FROM_COLLECTION
This will always be present for the following intents:
CREATE_COLLECTION
NUMBER_OF
Its value is an array that contains one string representing the name of the collection.
public static final Field COLLECTION_ITEM
Collected item for the following intents and may not always be present:
COPY_COLLECTION
RENAME_COLLECTION
Its value is an array that contains one of the following:
IT_OR_THERE
ALL_OBJ
a string that presents the name of the item in the collection
a string that presents the ordinal of the item in the collection
public static final Field CONTACT
Contact name for the following intents and may not always be present:
REMOVE_FROM_CONTACTS
SAVE_PHONE_NUMBER
Its value is an array that contains one string representing the name of the contact.
public static final Field CATEGORY
Category for the following intents and may not always be present:
COLLECT_LOCATION
POI
Its value is an array that contains one string representing a category, e.g. restaurant, parking, hotel, ...etc.
public static final Field WHEN
Time reference for the following intents and may not always be present:
HERE Android SDK Developer's Guide
API Reference
1436
POI
ROUTE_FROM_TO
TRAFFIC
WEATHER
Its value is an array that contains at least one of the following:
• today
• tomorrow
day after tomorrow
• now
time, e.g. 5pm
day of the week, e.g. Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday, weekend
date, 1st of January, January 1st
month, e.g. January, Feburary, March, ...etc.
public static final Field CONVERSATION
Asking user for more info. Conversation support for COLLECT_LOCATION intent and may not always be
present. Its value is an array that contains one of the following:
ON
When absent, it should be assumed to be OFF.
public static final Field USE_LAST_INTENT
Indicates whether to use previous intent for context for POI intent and may not always be present. Its value is
an array that contains one of the following:
ON
When absent, it should be assumed to be OFF.
public static final Field ONLINE_DEDUCTION
Indicates whether to use remote backend vs local NLP database for deduction. This is applicable for
SET_PARAM intent and may not always be present. Its value is an array that contains one of the following:
ON
OFF
public static final Field WAKEUP_WORDS
Whether to use wakeup words for SET_PARAM intent and may not always be present. Its value is an array that
contains one of the following:
ON
OFF
HERE Android SDK Developer's Guide
API Reference
1437
public static final Field DISTANCE_MEASURE
Distance measurement for SET_PARAM intent and may not always be present. Its value is an array that
contains one of the following:
ABBREVIATED_KILOMETER
MILE
public static final Field SHOW_ROUTE_ONLY
Indicate whether to just show the route without starting navigation for the following intents and may not
always be present:
ROUTE_FROM_TO
Its value is an array that contains one of the following:
TRUE
FALSE
public static final Field SIMULATE
Indicates whether to start guidance simulation for ROUTE_FROM_TO intent and may not always be present.
Its value is an array that contains one of the following:
ON
OFF
When absent, it should be assumed to be OFF.
public static final Field ALTERNATIVE_ROUTE
Indicates whether to calculate a route for ROUTE_FROM_TO intent and may not always be present. Its value is
an array that contains one of the following:
TRUE
FALSE
When absent, it should be assumed to be FALSE.
Note that ALTERNATIVE_ROUTE means to stop using the existing route and get a new route to an alternative
destination. E.g. instead of the current route to the closest Startbucks, show route to a different Startbucks.
On the other hand, REROUTE means to stop using the existing route and get a new route to the same
destination.
public static final Field FIRST_OPERAND
First operand of an arithmetic expression for MATH intent and it's always present. Its value is an array of one
numeric string.
HERE Android SDK Developer's Guide
API Reference
1438
public static final Field SECOND_OPERAND
Second operand of an arithmetic expression for MATH intent and it's always present. Its value is an array of
one numeric string.
public static final Field OPERATOR
Operator of an arithmetic expression for MATH intent and it's always present. Its value is an array that
contains one of the following:
• +
• -
• *
• /
Method Details
public static Field get (String name)
Retrieve enum value from the given string. e.g. Field.get("vendor"); returns Field.VENDOR .
Parameters:
name
string to be matched
Returns:
null if there is no enum with the specified name
public String getName ()
Retrieve string value for the enum, e.g. Field.VENDOR.getName(); returns "vendor" .
Returns:
String value for the enum
public static Field valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Intention.Field[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1439
Function
The enumeration Function is a member of com.here.android.mpa.nlp.Intention.
Enumeration Summary
public static final enumeration Intention.Function
extends java.lang.Enum, java.lang.Object
Function values for FUNCTION.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 889: Enum Constants in Function
Fields
public static final Function NO_ACTION
No deduction has been attempted.
public static final Function NOTHING
A deduction is attempted, but failed.
public static final Function USE_LANGUAGE
Set language for navigation.
public static final Function VOLUME
Set Text to speech volume.
public static final Function SPEED_WARNING
Set speed warning for navigation.
public static final Function CHECK_SPEED
Check current speed.
public static final Function CHANGE_MAP_CENTER
Change map center.
public static final Function POI
Search for the Point of Interest or use the specified Point of Interest to provide context for the next operation.
public static final Function WEB_SEARCH
Search google for the subject.
public static final Function WEATHER
Weather request.
HERE Android SDK Developer's Guide
API Reference
1440
Fields
public static final Function TIME_FROM_TO
Time "from" "to".
public static final Function DISTANCE_FROM_TO
Distance "from" "to".
public static final Function ROUTE_FROM_TO
Routing "from" "to".
public static final Function ADD_STOPOVER
Add location to the route calculation.
public static final Function PLACE_INFO
Provide info about a POI.
public static final Function CREATE_COLLECTION
Create collection.
public static final Function COLLECT_LOCATION
Save the POI into collection.
public static final Function COPY_COLLECTION
Copy collection places.
public static final Function RENAME_COLLECTION
Rename collection places.
public static final Function LIST_COLLECTION
To list the collection places.
public static final Function CHECK_COLLECTION
Check whether a collection place exists.
public static final Function LIST_ROUTE
To list route stops.
public static final Function LIST_SEARCH_RESULTS
To list search results.
public static final Function TRAFFIC
Traffic report.
public static final Function ADDRESS
Get current or destination address based on the context.
public static final Function GPS_LOCATION
Get current GPS coordinates.
public static final Function ELEVATION
Get current elevation.
HERE Android SDK Developer's Guide
API Reference
1441
Fields
public static final Function SEARCH_RESULT_LIMIT
Set maximum number of results.
public static final Function SYS_TIME
Check system time.
public static final Function SYS_BATTERY
Check system battery.
public static final Function START_TALKING
Start talking.
public static final Function STOP_TALKING
Stop talking.
public static final Function REPEAT_AFTER_ME
Repeat ASR result.
public static final Function REPEAT
Playback the last spoken statement.
public static final Function ZOOM
Zoom in/out the map.
public static final Function DOWNLOAD
Download map data package(s).
public static final Function DAY_MODE
Set map to day mode.
public static final Function NIGHT_MODE
Set map to night mode.
public static final Function SAT_MODE
Set map to satellite mode.
public static final Function TALK_SPEED
Set talk back speed to slow, slower, fast, faster, or normal.
public static final Function USE_FIRST
Scroll to the first item of the search result.
public static final Function USE_LAST
Scroll to the last item of the search result.
public static final Function USE_PREV
Scroll to the previous item of the search result.
public static final Function USE_NEXT
Scroll to the next item of the search result.
HERE Android SDK Developer's Guide
API Reference
1442
Fields
public static final Function MORE
More of previous intent.
public static final Function LESS
Less of previous intent.
public static final Function PAUSE
Pause an operation that may have been executed from previous intent.
public static final Function RESUME
Resume an operation that may have been executed from previous intent.
public static final Function STOP
Stop an operation that may have been executed from previous intent.
public static final Function RESET
Reset any cached data.
public static final Function DELAY_NAVIGATION_START
Delay navigation.
public static final Function ACCOUNT_NAME
Account name.
public static final Function CALL_NUMBER
Make a call.
public static final Function SAVE_PHONE_NUMBER
Save the phone number.
public static final Function SEND_LOCATION
Send location information to SMS, Facebook, email, etc.
public static final Function SEND_MESSAGE
Send a text message.
public static final Function COMPASS_MODE
Enable/disable compass mode.
public static final Function TRACK_GPS
Enable/disable map tracking.
public static final Function REPORT_GEO_EVENT
Reporting Geo tagged event: crime, health, traffic.
public static final Function REMOVE
Remove based on context.
public static final Function REMOVE_FROM_MAP
Remove object(s) from the map.
HERE Android SDK Developer's Guide
API Reference
1443
Fields
public static final Function REMOVE_FROM_COLLECTION
Remove collection place(s).
public static final Function REMOVE_FROM_ROUTE
Remove a stopover from the route.
public static final Function REMOVE_FROM_CONTACTS
Remove a contact.
public static final Function RELOAD
Reload NLP database.
public static final Function NUMBER_OF
Retrieve the number items.
public static final Function Q_A
Non-functional related conversation with the end user to keep him/her engaged.
public static final Function Q_YES
Positive response to a question.
public static final Function Q_NO
Negative response to a question.
public static final Function SET_PARAM
Set system-wide parameters for DISTANCE_MEASURE, WAKEUP_WORDS , or ONLINE_DEDUCTION.
public static final Function MATH
Evaluate a simple mathmatical equation which adds, subtracts, multiplies, or divide 2 numbers.
public static final Function TEACHING
Teach the system about oneself for personalization.
public static final Function NEG_FEEDBACK
Negative feedback about incorrect NLP deduction or search/routing result does not meet user's expectation.
Method Summary
Table 890: Methods in Function
Methods
public static Function get (String name)
Retrieve enum value from the given string.
public String getName ()
Retrieve string value for the enum, e.g.
public static Function valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1444
Methods
public static Intention.Function[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Function values for FUNCTION.
Enum Constant Details
public static final Function NO_ACTION
No deduction has been attempted.
public static final Function NOTHING
A deduction is attempted, but failed. e.g.
{
"text":["what's the meaning of life"],
"func":["NOTHING"],
"reply":["Come again"]
}
public static final Function USE_LANGUAGE
Set language for navigation. e.g.
{
:
"text":["use english for navigation"],
"func":["USE_LANGUAGE"],
"target":["english"]
}
public static final Function VOLUME
Set Text to speech volume. e.g.
{
:
"text":["turn down the volume"],
"func":["VOLUME"],
"target":["less"]
}
public static final Function SPEED_WARNING
HERE Android SDK Developer's Guide
API Reference
1445
Set speed warning for navigation. e.g.
{
:
"text":["stop speed warning"],
"func":["SPEED_WARNING"],
"toggle":["off_"]
}
public static final Function CHECK_SPEED
Check current speed. e.g.
{
:
"text":["what's my speed"],
"func":["CHECK_SPEED"]
}
public static final Function CHANGE_MAP_CENTER
Change map center. e.g.
{
:
"text":["change map center to seattle"],
"func":["CHANGE_MAP_CENTER"],
"target":["seattle"]
}
public static final Function POI
Search for the Point of Interest or use the specified Point of Interest to provide context for the next
operation. e.g
{
:
"text":["Where is Seattle?"],
"func":["POI"],
"target":["Seattle"]
}
This is an intent to search for the point of interest specified by TARGET.
For another example, assuming there is an intent to search for "Starbucks" prior to user saying "second one".
{
:
"text":["second one"],
"func":["POI"],
"target":["2"]
HERE Android SDK Developer's Guide
API Reference
1446
}
This is an intent to use the second search result for the next operation.
public static final Function WEB_SEARCH
Search google for the subject. e.g.
{
:
"text":["google seattle"],
"func":["WEB_SEARCH"],
"target":["seattle"]
}
public static final Function WEATHER
Weather request. e.g.
{
:
"text":["what's the weather in seattle today"],
"func":["WEATHER"],
"when":["today"],
"where":["seattle"]
}
public static final Function TIME_FROM_TO
Time "from" "to". e.g.
{
:
"text":["how long does it take to go from vancouver to
seattle?"],
"func":["TIME_FROM_TO"],
"from":["vancouver"],
"target":["seattle"]
}
public static final Function DISTANCE_FROM_TO
Distance "from" "to". e.g.
{
:
"text":["how far is it from vancouver to seattle?"],
"func":["DISTANCE_FROM_TO"],
"from":["vancouver"],
"target":["seattle"]
HERE Android SDK Developer's Guide
API Reference
1447
}
public static final Function ROUTE_FROM_TO
Routing "from" "to". e.g.
{
:
"text":["Show me the route from vancouver to seattle."],
"func":["ROUTE_FROM_TO"],
"from":["vancouver"],
"target":["seattle"]
}
public static final Function ADD_STOPOVER
Add location to the route calculation. e.g.
{
:
"text":["stop at gas station in seattle"],
"func":["ADD_STOPOVER"],
"optimize":["false_"],
"stopover":["gas station"],
"where_s":["seattle"]
}
public static final Function PLACE_INFO
Provide info about a POI. e.g.
{
:
"text":["tell me about seattle"],
"func":["PLACE_INFO"],
"target":["seattle"]
}
public static final Function CREATE_COLLECTION
Create collection. e.g.
{
:
"text":["create favorites"],
"func":["CREATE_COLLECTION"]
}
HERE Android SDK Developer's Guide
API Reference
1448
public static final Function COLLECT_LOCATION
Save the POI into collection. e.g.
{
:
"text":["save abc"],
"func":["COLLECT_LOCATION"],
"target":["abc"]
}
public static final Function COPY_COLLECTION
Copy collection places. e.g.
{
:
"text":["copy collection foo to bar"],
"func":["COPY_COLLECTION"],
"from":["foo"],
"target":["bar"]
}
public static final Function RENAME_COLLECTION
Rename collection places. e.g.
{
:
"text":["rename collection foo to bar"],
"func":["RENAME_COLLECTION"],
"from":["foo"],
"target":["bar"]
}
public static final Function LIST_COLLECTION
To list the collection places. e.g.
{
:
"text":["list favorites collection"],
"func":["LIST_COLLECTION"]
}
public static final Function CHECK_COLLECTION
Check whether a collection place exists. e.g.
HERE Android SDK Developer's Guide
API Reference
1449
{
:
"text":["do i have home in my collection?"],
"func":["CHECK_COLLECTION"],
"target":["home"]
}
public static final Function LIST_ROUTE
To list route stops. e.g.
{
:
"text":["what are my stops"],
"func":["LIST_ROUTE"]
}
public static final Function LIST_SEARCH_RESULTS
To list search results. e.g.
{
:
"text":["list all found places"],
"func":["LIST_SEARCH_RESULTS"]
}
public static final Function TRAFFIC
Traffic report. e.g.
{
:
"text":["how is the traffic in seattle"],
"func":["TRAFFIC"],
"where":["seattle"]
}
public static final Function ADDRESS
Get current or destination address based on the context. e.g.
{
:
"text":["what is the address of space needle"],
"func":["ADDRESS"],
"target":["space needle"]
}
HERE Android SDK Developer's Guide
API Reference
1450
public static final Function GPS_LOCATION
Get current GPS coordinates. e.g.
{
:
"text":["what are my coordinates"],
"func":["GPS_LOCATION"]
}
public static final Function ELEVATION
Get current elevation. e.g.
{
:
"text":["what is my current elevation"],
"func":["ELEVATION"]
}
public static final Function SEARCH_RESULT_LIMIT
Set maximum number of results. e.g.
{
:
"text":["limit search results to 5"],
"func":["SEARCH_RESULT_LIMIT"],
"search_count":["5"]
}
public static final Function SYS_TIME
Check system time. e.g.
{
:
"text":["what time is it"],
"func":["SYS_TIME"]
}
public static final Function SYS_BATTERY
Check system battery. e.g.
{
:
"text":["how much battery left"],
"func":["SYS_BATTERY"]
HERE Android SDK Developer's Guide
API Reference
1451
}
public static final Function START_TALKING
Start talking. e.g.
{
:
"text":["tell me in kilometers"],
"func":["START_TALKING","SET_PARAM"],
"distance_measure":["km"],
"reply":["sure"]
}
public static final Function STOP_TALKING
Stop talking. e.g.
{
:
"text":["stop talking"],
"func":["STOP_TALKING"],
"reply":["sure"]
}
public static final Function REPEAT_AFTER_ME
Repeat ASR result. e.g.
{
:
"text":["repeat what i say"],
"func":["REPEAT_AFTER_ME"],
"toggle":["on_"]
}
public static final Function REPEAT
Playback the last spoken statement. e.g.
{
:
"text":["say that again"],
"func":["REPEAT"]
}
public static final Function ZOOM
HERE Android SDK Developer's Guide
API Reference
1452
Zoom in/out the map. e.g.
{
:
"text":["zoom in"],
"func":["ZOOM"],
"target":["more"]
}
public static final Function DOWNLOAD
Download map data package(s). e.g.
{
:
"text":["download british columbia"],
"func":["DOWNLOAD"],
"target":["british columbia"]
}
public static final Function DAY_MODE
Set map to day mode. e.g.
{
:
"text":["use day mode"],
"func":["DAY_MODE"]
}
public static final Function NIGHT_MODE
Set map to night mode. e.g.
{
:
"text":["use night mode"],
"func":["NIGHT_MODE"]
}
public static final Function SAT_MODE
Set map to satellite mode. e.g.
{
:
"text":["use satellite mode"],
"func":["SAT_MODE"]
HERE Android SDK Developer's Guide
API Reference
1453
}
public static final Function TALK_SPEED
Set talk back speed to slow, slower, fast, faster, or normal. e.g.
{
:
"text":["talk fast"],
"func":["TALK_SPEED"],
"target":["max"]
}
public static final Function USE_FIRST
Scroll to the first item of the search result. e.g.
{
:
"text":["use first"],
"func":["USE_FIRST"]
}
public static final Function USE_LAST
Scroll to the last item of the search result. e.g.
{
:
"text":["use last"],
"func":["USE_LAST"]
}
public static final Function USE_PREV
Scroll to the previous item of the search result. e.g.
{
:
"text":["use previous"],
"func":["USE_PREV"]
}
public static final Function USE_NEXT
HERE Android SDK Developer's Guide
API Reference
1454
Scroll to the next item of the search result. e.g.
{
:
"text":["use next"],
"func":["USE_NEXT"]
}
public static final Function MORE
More of previous intent. e.g. if zoom in was the previous intent, this intent is to zoom in further.
{
:
"text":["more"],
"func":["MORE"]
}
public static final Function LESS
Less of previous intent. e.g. if zoom in was the previous intent, this intent is to zoom out a little.
{
:
"text":["less"],
"func":["LESS"]
}
public static final Function PAUSE
Pause an operation that may have been executed from previous intent. e.g. if navigation was started prior to
this, this intent will be to pause navigation.
{
:
"text":["pause"],
"func":["PAUSE"]
}
public static final Function RESUME
Resume an operation that may have been executed from previous intent. e.g. if navigation was paused prior
to this, this intent will be to resume navigation.
{
:
"text":["continue"],
"func":["RESUME"]
HERE Android SDK Developer's Guide
API Reference
1455
}
public static final Function STOP
Stop an operation that may have been executed from previous intent. e.g. if navigation was started prior to
this, this intent will be to stop navigation.
{
:
"text":["stop"],
"func":["STOP"]
}
public static final Function RESET
Reset any cached data. e.g.
{
:
"text":["reset"],
"func":["RESET"],
"reply":["sure"]
}
public static final Function DELAY_NAVIGATION_START
Delay navigation. The intent is not to automatically start navigation for "take me to McDonalds", but to show
the route only. e.g.
{
:
"text":["don't start navigation right away"],
"func":["DELAY_NAVIGATION_START"],
"toggle":["on_"]
}
public static final Function ACCOUNT_NAME
Account name. e.g.
{
:
"text":["what is my account name"],
"func":["ACCOUNT_NAME"]
}
public static final Function CALL_NUMBER
HERE Android SDK Developer's Guide
API Reference
1456
Make a call. e.g.
{
:
"text":["call emergency"],
"func":["CALL_NUMBER"],
"by_number":["true"],
"target":["911"]
}
public static final Function SAVE_PHONE_NUMBER
Save the phone number. e.g.
{
:
"text":["save 911 as emergency"],
"func":["SAVE_PHONE_NUMBER"],
"contact":["emergency"],
"target":["911"]
}
public static final Function SEND_LOCATION
Send location information to SMS, Facebook, email, etc. e.g.
{
:
"text":["publish my location on facebook"],
"func":["SEND_LOCATION"],
"target":["facebook"]
}
public static final Function SEND_MESSAGE
Send a text message. e.g.
{
:
"text":["send a message to my wife that i will be late for
dinner"],
"func":["SEND_MESSAGE"],
"message":["i will be late for dinner"],
"target":["wife"]
}
public static final Function COMPASS_MODE
HERE Android SDK Developer's Guide
API Reference
1457
Enable/disable compass mode. When enabled, map will be shown with north up. e.g.
{
:
"text":["enable compass"],
"func":["COMPASS_MODE"],
"toggle":["on_"]
}
public static final Function TRACK_GPS
Enable/disable map tracking. When enabled, current location will always be visible at the center of the map.
e.g.
{
:
"text":["center the map to my current location"],
"func":["TRACK_GPS"],
"toggle":["on_"]
}
public static final Function REPORT_GEO_EVENT
Reporting Geo tagged event: crime, health, traffic. e.g.
{
:
"text":["i just saw a car accident here"],
"func":["REPORT_GEO_EVENT"],
"target":["accident"],
"type":["event_traffic"]
}
public static final Function REMOVE
Remove based on context. Context for this may be provided through previous intent and/or additional
parameters of the intent. e.g. if there is a stopover added on the route prior to this, this intent will be to
remove the stopover from the route.
{
:
"text":["remove it"],
"func":["REMOVE"],
"target":["it_there"]
}
public static final Function REMOVE_FROM_MAP
HERE Android SDK Developer's Guide
API Reference
1458
Remove object(s) from the map. e.g.
{
:
"text":["remove markers from the map"],
"func":["REMOVE_FROM_MAP"],
"target":["markers"]
}
public static final Function REMOVE_FROM_COLLECTION
Remove collection place(s). e.g.
{
:
"text":["remove foo from bar collection"],
"func":["REMOVE_FROM_COLLECTION"],
"col_name":["bar"],
"target":["foo"]
}
public static final Function REMOVE_FROM_ROUTE
Remove a stopover from the route. e.g.
{
:
"text":["remove gas station from the route"],
"func":["REMOVE_FROM_ROUTE"],
"target":["gas station"]
}
public static final Function REMOVE_FROM_CONTACTS
Remove a contact. e.g.
{
:
"text":["remove bob smith from phone list"],
"func":["REMOVE_FROM_CONTACTS"],
"target":["bob smith"]
}
public static final Function RELOAD
Reload NLP database. e.g.
{
"text":["reload database"],
HERE Android SDK Developer's Guide
API Reference
1459
"func":["RELOAD"],
"reply":["Database reloaded"]
}
public static final Function NUMBER_OF
Retrieve the number items. e.g.
{
"text":["how many items is in my all collections"],
"func":["NUMBER_OF"],
"col_name":["all_obj"],
"type":["obj_collection"]
}
public static final Function Q_A
Non-functional related conversation with the end user to keep him/her engaged. e.g.
{
:
"text":["what are you doing"],
"func":["Q_A"],
"reply":["Trying to sleep"]
}
public static final Function Q_YES
Positive response to a question. e.g.
{
:
"text":["yes"],
"func":["Q_YES"]
}
public static final Function Q_NO
Negative response to a question. e.g.
{
:
"text":["no"],
"func":["Q_NO"]
}
public static final Function SET_PARAM
HERE Android SDK Developer's Guide
API Reference
1460
Set system-wide parameters for DISTANCE_MEASURE, WAKEUP_WORDS , or ONLINE_DEDUCTION. e.g.
{
:
"text":["use imperial system from now on"],
"func":["SET_PARAM"],
"distance_measure":["mile"]
}
public static final Function MATH
Evaluate a simple mathmatical equation which adds, subtracts, multiplies, or divide 2 numbers. e.g.
{
:
"text":["what is 5 plus 6"],
"func":["MATH"],
"arg1":["5"],
"arg2":["6"],
"op":["+"]
}
public static final Function TEACHING
Teach the system about oneself for personalization. e.g.
{
:
"text":["my name is bob"],
"func":["TEACHING"],
"your_name":["bob"]
}
public static final Function NEG_FEEDBACK
Negative feedback about incorrect NLP deduction or search/routing result does not meet user's expectation.
e.g.
{
:
"text":["this is not what i meant"],
"func":["NEG_FEEDBACK"],
"reply":["Sorry"]
}
Method Details
public static Function get (String name)
HERE Android SDK Developer's Guide
API Reference
1461
Retrieve enum value from the given string. e.g. Function.get("POI"); returns Function.POI .
Parameters:
name
string to be matched
Returns:
null if there is no enum with the specified name
public String getName ()
Retrieve string value for the enum, e.g. Function.POI.getName(); returns "POI" .
Returns:
String value for the enum
public static Function valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Intention.Function[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Value
The enumeration Value is a member of com.here.android.mpa.nlp.Intention.
Enumeration Summary
public static final enumeration Intention.Value
extends java.lang.Enum, java.lang.Object
values for Intention.Field
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1462
Enum Constant Summary
Table 891: Enum Constants in Value
Fields
public static final Value NONE
Explicit no value
public static final Value HERE
Value for VENDOR
public static final Value MAP
Map domain
public static final Value ENGLISH
English Language
public static final Value GERMAN
German Language
public static final Value FRENCH
French Language
public static final Value ORIGIN
Current geo location
public static final Value IT_OR_THERE
It or there
public static final Value EVENT_TRAFFIC
Traffic event for TYPE for REPORT_GEO_EVENT intent.
public static final Value EVENT_HEALTH
Health event for TYPE for REPORT_GEO_EVENT intent.
public static final Value EVENT_CRIME
Crime event for TYPE for REPORT_GEO_EVENT intent.
public static final Value FASTEST
Fastest route type.
public static final Value SHORTEST
Shortest route type.
public static final Value OPTIMAL
Optimal route type.
public static final Value NORMAL
Normal talk speed.
public static final Value ON
Constant for on.
HERE Android SDK Developer's Guide
API Reference
1463
Fields
public static final Value OFF
Constant for off.
public static final Value TRUE
Constant for true.
public static final Value FALSE
Constant for false.
public static final Value MORE
Increase the value for volume, talk speed, or zoom.
public static final Value LESS
Decrease the value for volume, talk speed, or zoom.
public static final Value MAXIMUM
Maximum value
public static final Value MINIMUM
Minimum value
public static final Value ABBREVIATED_KILOMETER
Measurement value indicating kilometer or metric measurement system.
public static final Value KILOMETER
Measurement value indicating kilometer or metric measurement system.
public static final Value ABBREVIATED_METER
Measurement value for meter or metric measurement system.
public static final Value METER
Measurement value for meter or metric measurement system.
public static final Value FEET
Measurement value for feet or imperial measurement system.
public static final Value YARD
Measurement value for yard or imperial measurement system.
public static final Value MILE
Measurement value for mile or imperial measurement system.
public static final Value MINUTES
Time measurement value
public static final Value HOURS
Time measurement value
public static final Value DAYS
Time measurement value
HERE Android SDK Developer's Guide
API Reference
1464
Fields
public static final Value BUS
Transportation type
public static final Value CAR
Transportation type
public static final Value WALK
Transportation type
public static final Value TAXI
Transportation type
public static final Value FERRY
Transportation type
public static final Value FLIGHT
Transportation type
public static final Value TRAIN
Transportation type
public static final Value TRANSIT
Transportation type
public static final Value TRANSPORT
Transportation type
public static final Value FACEBOOK
Publish destinations for SEND_LOCATION intent.
public static final Value TWITTER
Publish destinations for SEND_LOCATION intent.
public static final Value HOME
Home
public static final Value WORK
Work
public static final Value PLACE_OBJ
A place
public static final Value ROUTE_OBJ
A route
public static final Value ALTINATIVE_ROUTE_OBJ
An alternative route to the same destination
public static final Value COLLECTION_OBJ
A collection
HERE Android SDK Developer's Guide
API Reference
1465
Fields
public static final Value STOPOVER_OBJ
A stopover
public static final Value DESTINATION_OBJ
A destination
public static final Value NEXT_MANEUVER_OBJ
The next maneuver
public static final Value PHONE_OBJ
A phone number
public static final Value ALL_OBJ
All objects
public static final Value MYSELF
Used to indicate the owner.
public static final Value AM
AM time suffix
public static final Value PM
PM time suffix
public static final Value FINE
Subcategorization for search, e.g.
public static final Value MID
Subcategorization for search, e.g.
public static final Value CHEAP
Subcategorization for search, e.g.
public static final Value GOOD
Rating for a place
public static final Value BAD
Rating for a place
public static final Value POPULAR
Rating for a place
Method Summary
Table 892: Methods in Value
Methods
public static Value get (String name)
Retrieve enum value from the given string.
HERE Android SDK Developer's Guide
API Reference
1466
Methods
public String getName ()
Retrieve string value for the enum, e.g.
public static Value valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Intention.Value[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
values for Intention.Field
Enum Constant Details
public static final Value NONE
Explicit no value
public static final Value HERE
Value for VENDOR
public static final Value MAP
Map domain
public static final Value ENGLISH
English Language
public static final Value GERMAN
German Language
public static final Value FRENCH
French Language
public static final Value ORIGIN
Current geo location
HERE Android SDK Developer's Guide
API Reference
1467
public static final Value IT_OR_THERE
It or there
public static final Value EVENT_TRAFFIC
Traffic event for TYPE for REPORT_GEO_EVENT intent.
public static final Value EVENT_HEALTH
Health event for TYPE for REPORT_GEO_EVENT intent.
public static final Value EVENT_CRIME
Crime event for TYPE for REPORT_GEO_EVENT intent.
public static final Value FASTEST
Fastest route type.
public static final Value SHORTEST
Shortest route type.
public static final Value OPTIMAL
Optimal route type.
public static final Value NORMAL
Normal talk speed.
public static final Value ON
Constant for on.
public static final Value OFF
Constant for off.
public static final Value TRUE
Constant for true.
HERE Android SDK Developer's Guide
API Reference
1468
public static final Value FALSE
Constant for false.
public static final Value MORE
Increase the value for volume, talk speed, or zoom.
public static final Value LESS
Decrease the value for volume, talk speed, or zoom.
public static final Value MAXIMUM
Maximum value
public static final Value MINIMUM
Minimum value
public static final Value ABBREVIATED_KILOMETER
Measurement value indicating kilometer or metric measurement system.
public static final Value KILOMETER
Measurement value indicating kilometer or metric measurement system.
public static final Value ABBREVIATED_METER
Measurement value for meter or metric measurement system.
public static final Value METER
Measurement value for meter or metric measurement system.
public static final Value FEET
Measurement value for feet or imperial measurement system.
public static final Value YARD
HERE Android SDK Developer's Guide
API Reference
1469
Measurement value for yard or imperial measurement system.
public static final Value MILE
Measurement value for mile or imperial measurement system.
public static final Value MINUTES
Time measurement value
public static final Value HOURS
Time measurement value
public static final Value DAYS
Time measurement value
public static final Value BUS
Transportation type
public static final Value CAR
Transportation type
public static final Value WALK
Transportation type
public static final Value TAXI
Transportation type
public static final Value FERRY
Transportation type
public static final Value FLIGHT
Transportation type
HERE Android SDK Developer's Guide
API Reference
1470
public static final Value TRAIN
Transportation type
public static final Value TRANSIT
Transportation type
public static final Value TRANSPORT
Transportation type
public static final Value FACEBOOK
Publish destinations for SEND_LOCATION intent.
public static final Value TWITTER
Publish destinations for SEND_LOCATION intent.
public static final Value HOME
Home
public static final Value WORK
Work
public static final Value PLACE_OBJ
A place
public static final Value ROUTE_OBJ
A route
public static final Value ALTINATIVE_ROUTE_OBJ
An alternative route to the same destination
public static final Value COLLECTION_OBJ
A collection
HERE Android SDK Developer's Guide
API Reference
1471
public static final Value STOPOVER_OBJ
A stopover
public static final Value DESTINATION_OBJ
A destination
public static final Value NEXT_MANEUVER_OBJ
The next maneuver
public static final Value PHONE_OBJ
A phone number
public static final Value ALL_OBJ
All objects
public static final Value MYSELF
Used to indicate the owner. Test: send my location to "me"
public static final Value AM
AM time suffix
public static final Value PM
PM time suffix
public static final Value FINE
Subcategorization for search, e.g. fine dinning.
public static final Value MID
Subcategorization for search, e.g. mid priced restaurant
public static final Value CHEAP
HERE Android SDK Developer's Guide
API Reference
1472
Subcategorization for search, e.g. cheap restaurant
public static final Value GOOD
Rating for a place
public static final Value BAD
Rating for a place
public static final Value POPULAR
Rating for a place
Method Details
public static Value get (String name)
Retrieve enum value from the given string. e.g. Value.get("eng"); returns Value.ENGLISH .
Parameters:
name
string to be matched
Returns:
null if there is no enum with the specified name
public String getName ()
Retrieve string value for the enum, e.g. Value.ENGLISH.getName(); returns "eng" .
Returns:
String value for the enum
public static Value valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Intention.Value[] values ()
HERE Android SDK Developer's Guide
API Reference
1473
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Nlp
The class Nlp is a member of com.here.android.mpa.nlp .
Class Summary
public final class Nlp
extends java.lang.Object
This is the Natural Language Processor interface.
[For complete information, see the section Class Details]
Nested Class Summary
Table 893: Nested Classes in Nlp
Nested Classes
public static abstract interface Nlp.ListenerBase
Base event listener interface
public static abstract interface Nlp.OnBatteryLevelListener
The remaining battery level event listener interface
public static abstract interface Nlp.OnClearListener
Listener interface for clearing objects from the map.
public static abstract interface Nlp.OnCurrentAddressListener
Address at the current geo location is ready event listener interface.
public static abstract interface Nlp.OnCurrentTimeListener
The current time event listener interface
public static abstract interface Nlp.OnInitializationListener
Represents a listener to provide notification of the Nlp status upon completion of initialization.
public static abstract interface Nlp.OnIntentListener
Intention is ready event listener interface.
public static abstract interface Nlp.OnMapSchemeChangedListener
Map.Scheme of the Map object has been changed event listener interface.
public static abstract interface Nlp.OnNavigationListener
Navigation listener interface
public static abstract interface Nlp.OnParameterListener
Parameter event listener interface
HERE Android SDK Developer's Guide
API Reference
1474
Nested Classes
public static abstract interface Nlp.OnPlaceFocusChangedListener
Listener for a client focus change to another place
public static abstract interface Nlp.OnRemoveFromRouteListener
Listener interface to notify user that a stopover is removed from the route
public static abstract interface Nlp.OnResetListener
Listener interface to notify that user wants to do the reset.
public static abstract interface Nlp.OnRouteListener
Route object is available event interface.
public static abstract interface Nlp.OnRouteResultsAddedListener
Listener interface for adding route results from the application to NLP.
public static abstract interface Nlp.OnSearchListener
Search listener interface.
public static abstract interface Nlp.OnSendLocationListener
The send location event listener interface
public static abstract interface Nlp.OnSendSMSListener
The send SMS event listener interface
public static abstract interface Nlp.OnSpeedListener
The speed value event listener interface
public static abstract interface Nlp.OnSpeedWarningSwitchListener
The speed warning mode during navigation event listener interface
public static abstract interface Nlp.OnTrafficModeListener
The traffic mode changed event listener interface
public static abstract interface Nlp.OnTravelDistanceListener
The travel distance to specified location event listener interface
public static abstract interface Nlp.OnTravelTimeListener
The travel time to specified location event listener interface
public static final enumeration Nlp.Reply
Client's responses on the events triggered by NLP
HERE Android SDK Developer's Guide
API Reference
1475
Method Summary
Table 894: Methods in Nlp
Methods
public void addListener (ListenerBase listener)
Adds an event listener to Nlp Nlp.OnBatteryLevelListener Nlp.OnCurrentAddressListener Nlp.OnCurrentTimeListener
Nlp.OnIntentListener Nlp.OnMapSchemeChangedListener Nlp.OnNavigationListener Nlp.OnPlaceFocusChangedListener
Nlp.OnRouteListener Nlp.OnSearchListener Nlp.OnSendLocationListener Nlp.OnSendSMSListener Nlp.OnSpeedListener
Nlp.OnSpeedWarningSwitchListener Nlp.OnTrafficModeListener Nlp.OnTravelDistanceListener Nlp.OnTravelTimeListener
Nlp.OnClearListener Nlp.OnRemoveFromRouteListener Nlp.OnParameterListener Nlp.OnResetListener
public static Nlp getInstance ()
Returns the Nlp singleton: creates it or returns the already created one.
public java.util.List <Place> getRoutePlaces (Route route)
Get the Places of the Route.
public int getSpeechVolume ()
Get the current speech volume percentage.
public void init (Context context, MapFragment mapFragment, CollectionProvider collectionProvider,
SpeechToTextProvider speechToTextProvider, OnInitializationListener listener)
Asynchronously initialize Nlp .
public void init (Context context, Map map, MapGesture mapGesture, CollectionProvider
collectionProvider, SpeechToTextProvider speechToTextProvider, OnInitializationListener listener)
Asynchronously initialize Nlp .
public static boolean isInitialized ()
Gets the initialization state of Nlp .
public boolean isLocationTrackingEnabled ()
Check if automatic location tracking is enabled.
public boolean isMetricSystemEnabled ()
Check if metric measurement system is enabled.
public boolean isOnlineDeductionEnabled ()
Check if online deduction is enabled
public boolean isRepeatAfterMeEnabled ()
Check if repeat-after-me is enabled
public boolean isTalkBackEnabled ()
Check if talk-back is enabled
public void pause ()
Pause NLP
HERE Android SDK Developer's Guide
API Reference
1476
Methods
public void removeListener (ListenerBase listener)
Removes an event listener from Nlp Nlp.OnBatteryLevelListener Nlp.OnCurrentAddressListener Nlp.OnCurrentTimeListener
Nlp.OnIntentListener Nlp.OnMapSchemeChangedListener Nlp.OnNavigationListener Nlp.OnPlaceFocusChangedListener
Nlp.OnRouteListener Nlp.OnSearchListener Nlp.OnSendLocationListener Nlp.OnSendSMSListener Nlp.OnSpeedListener
Nlp.OnSpeedWarningSwitchListener Nlp.OnTrafficModeListener Nlp.OnTravelDistanceListener Nlp.OnTravelTimeListener
Nlp.OnClearListener Nlp.OnRemoveFromRouteListener Nlp.OnParameterListener Nlp.OnResetListener
public void reset ()
Resets Nlp cache (search results or route results.
public void resume (Context context)
Resume NLP
public void setFocusToPlace (int index)
Client application to notify NLP that "it" would refer to the provided PlaceLink.
public void setFocusToPlace (PlaceLink place)
Client application to notify NLP that "it" would refer to the provided PlaceLink.
public void setFocusToPlace (String name, GeoCoordinate coordinate)
Client application tells NLP to focus on place specified by name and GeoCoordinate.
public void setLocationTrackingEnabled (boolean enabled)
Enable or disable automatic location tracking.
public void setMap (Map map)
Set Map to be associated with this NLP instance if it's changed since initialization.
public void setMapFragment (MapFragment mapFragment)
Set MapFragment to be associated with this NLP instance if it's changed since initialization.
public void setMapGesture (MapGesture mapGesture)
Sets the MapGesture to be associated with this NLP instance if it is instantiated through (Context, Map)
public void setMetricSystemEnabled (boolean enable)
Controls whether NLP should use metric measurement system or imperial.
public void setOnlineDeductionEnabled (boolean enable)
Controls whether NLP deduction happens on the back-end server or on the client side.
public void setPreferredRoute (Route route)
Client application tells NLP to use a preferred Route for navigation purposes.
public void setRepeatAfterMeEnabled (boolean enable)
Set repeat-after-me to true lets user to hear the results of voice recognition.
public void setRouteResult (Route route, List waypointNames)
Set the externally-generated Route result with an optional list of names and aliases of the waypoints in the route.
public void setSearchResults (CategoryFilter filter, java.util.ArrayList <PlaceLink> results)
Set the search results in NLP
HERE Android SDK Developer's Guide
API Reference
1477
Methods
public void setSearchResults (GeoCoordinate location, Address address)
Set the search results in NLP
public void setSearchResults (String searchSubject, java.util.ArrayList <PlaceLink> results)
Set the search results in NLP
public void setSpeechVolume (int percentage)
Set speech volume percentage.
public void setTalkBackEnabled (boolean enable)
Enable/disable talk-back on a spoken user request
public void speak (String text)
Speaks the text
public void startListening ()
Inform Nlp to start listening for the voice input using the Speech Recognizer passed in the initialization phase.
public void stopListening ()
Stop listening for the voice input.
public boolean understand (String utterance)
"Understand" the text and produce formalized Intention through onIntent(Intention).
Class Details
This is the Natural Language Processor interface. This controls voice operations for the SDK. Note: The
application is responsible for downloading voice skins prior to using Navigation features otherwise no voice
will be heard during navigation.
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Method Details
public void addListener (ListenerBase listener)
Adds an event listener to Nlp Nlp.OnBatteryLevelListener Nlp.OnCurrentAddressListener
Nlp.OnCurrentTimeListener Nlp.OnIntentListener Nlp.OnMapSchemeChangedListener
Nlp.OnNavigationListener Nlp.OnPlaceFocusChangedListener Nlp.OnRouteListener Nlp.OnSearchListener
Nlp.OnSendLocationListener Nlp.OnSendSMSListener Nlp.OnSpeedListener Nlp.OnSpeedWarningSwitchListener
Nlp.OnTrafficModeListener Nlp.OnTravelDistanceListener Nlp.OnTravelTimeListener Nlp.OnClearListener
Nlp.OnRemoveFromRouteListener Nlp.OnParameterListener Nlp.OnResetListener
Parameters:
listener
A Nlp.ListenerBase to add to the Nlp
HERE Android SDK Developer's Guide
API Reference
1478
public static Nlp getInstance ()
Returns the Nlp singleton: creates it or returns the already created one.
Once the Nlp instance is available, it must be initialized through one of the following methods before it can
be used:
Nlp.init(Context, MapFragment, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
Nlp.init(Context, Map, MapGesture, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
Returns:
Nlp instance
public java.util.List <Place> getRoutePlaces (Route route)
Get the Places of the Route.
Parameters:
route
The Route, either returned by NLP as a result of a voice query via onComplete(Error, Route, List, String,
List) or provided externally by the client using setRouteResult(Route, List)
Returns:
List of Places included into the route in the correct order. Will return null if Nlp has not yet been initialized.
public int getSpeechVolume ()
Get the current speech volume percentage.
Note this value may be subjected to rounding and may not reflect the original percentage set by
setSpeechVolume(int)
Returns:
int representing the volume percentage ranging from 0 to 100. If speech volume has not yet been set using
setSpeechVolume(int), current android.media.AudioManager#STREAM_MUSIC volume of the device will be
returned. If Nlp has not yet been initialized, default volume percentage of 10 will be returned.
See also:
setSpeechVolume(int)
public void init (Context context, MapFragment mapFragment, CollectionProvider
collectionProvider, SpeechToTextProvider speechToTextProvider,
OnInitializationListener listener)
Asynchronously initialize Nlp . Nlp cannot be used until it has been initialized successfully. Note: multiple
calls to this API will only result on a callback saying initialization was successful. New parameters would be
ignored.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1479
context
context to be used during initialization. Must not be null.
mapFragment
MapFragment to be associated with this NLP instance. Must not be null.
collectionProvider
CollectionProvider for collection handling. null if application does not support collections.
speechToTextProvider
SpeechToTextProvider for Speech Recognition. If null, some features will not be available (NLP asking
questions and automatically listening for answers for example).
listener
Nlp.OnInitializationListener to provide information when Nlp initialization completes. If null, completion
callback will not be received.
public void init (Context context, Map map, MapGesture mapGesture,
CollectionProvider collectionProvider, SpeechToTextProvider speechToTextProvider,
OnInitializationListener listener)
Asynchronously initialize Nlp . Nlp cannot be used until it has been initialized successfully. Note: multiple
calls to this API will only result on a callback saying initialization was successful. New parameters would be
ignored.
Parameters:
context
context to be used during initialization. Must not be null.
map
Map to be associated with this NLP instance. Must not be null.
mapGesture
MapGesture Gesture handler for the Map, if available.
collectionProvider
CollectionProvider for collection handling. Null if application does not support collections.
speechToTextProvider
SpeechToTextProvider for Speech Recognition. If null, some features will not be available (NLP asking
questions and automatically listening for answers for example).
listener
Nlp.OnInitializationListener to provide information when Nlp initialization completes. If null, completion
callback will not be received.
public static boolean isInitialized ()
Gets the initialization state of Nlp .
Returns:
HERE Android SDK Developer's Guide
API Reference
1480
true if Nlp is initialized and ready for service.
public boolean isLocationTrackingEnabled ()
Check if automatic location tracking is enabled.
Returns:
true if enabled or if Nlp has not yet been initialized; false otherwise.
public boolean isMetricSystemEnabled ()
Check if metric measurement system is enabled.
Returns:
true if enabled or if Nlp has not yet been initialized; false otherwise.
public boolean isOnlineDeductionEnabled ()
Check if online deduction is enabled
Returns:
true if enabled or if Nlp has not yet been initialized; false otherwise.
public boolean isRepeatAfterMeEnabled ()
Check if repeat-after-me is enabled
Returns:
true if enabled, false otherwise or Nlp has not yet been initialized. Default value is false.
public boolean isTalkBackEnabled ()
Check if talk-back is enabled
Returns:
true if enabled, false if disabled or Nlp has not yet been initialized. Default value is false.
public void pause ()
Pause NLP
public void removeListener (ListenerBase listener)
HERE Android SDK Developer's Guide
API Reference
1481
Removes an event listener from Nlp Nlp.OnBatteryLevelListener Nlp.OnCurrentAddressListener
Nlp.OnCurrentTimeListener Nlp.OnIntentListener Nlp.OnMapSchemeChangedListener
Nlp.OnNavigationListener Nlp.OnPlaceFocusChangedListener Nlp.OnRouteListener Nlp.OnSearchListener
Nlp.OnSendLocationListener Nlp.OnSendSMSListener Nlp.OnSpeedListener Nlp.OnSpeedWarningSwitchListener
Nlp.OnTrafficModeListener Nlp.OnTravelDistanceListener Nlp.OnTravelTimeListener Nlp.OnClearListener
Nlp.OnRemoveFromRouteListener Nlp.OnParameterListener Nlp.OnResetListener
Parameters:
listener
A Nlp.ListenerBase to remove from the Nlp
public void reset ()
Resets Nlp cache (search results or route results. It will also stop any ongoing navigation.
public void resume (Context context)
Resume NLP
Parameters:
context
Context to be used. This context may be different from the context passed during initialization. Must not
be null.
public void setFocusToPlace (int index)
Client application to notify NLP that "it" would refer to the provided PlaceLink. User may browse among
searched places using user interface and then say "Take me there". In order to accommodate this
functionality NLP needs to know the place your should refer as "it" or "there".
Parameters:
index
Index of the place in the last search results that should be referred as "it" or "there". Example: "Take me
there"
public void setFocusToPlace (PlaceLink place)
Client application to notify NLP that "it" would refer to the provided PlaceLink. User may browse among
searched places using user interface and then say "Take me there". In order to accommodate this
functionality NLP needs to know the place your should refer as "it" or "there".
Parameters:
place
Place that should be referred as "it" or "there". Example: "Take me there"
HERE Android SDK Developer's Guide
API Reference
1482
public void setFocusToPlace (String name, GeoCoordinate coordinate)
Client application tells NLP to focus on place specified by name and GeoCoordinate. User may refer to that
place as "it" or "there".
Parameters:
name
Place's name
coordinate
Place's GeoCoordinate
public void setLocationTrackingEnabled (boolean enabled)
Enable or disable automatic location tracking.
Parameters:
enabled
If true, the map will be automatically centered on the user's location. Default is true.
public void setMap (Map map)
Set Map to be associated with this NLP instance if it's changed since initialization.
setMapGesture(MapGesture) should also be called after Map is changed.
Parameters:
map
Map to be associated with this NLP instance.
See also:
init(Context, Map, MapGesture, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
setMapGesture(MapGesture)
public void setMapFragment (MapFragment mapFragment)
Set MapFragment to be associated with this NLP instance if it's changed since initialization.
Parameters:
mapFragment
MapFragment to be associated with this NLP instance.
See also:
init(Context, MapFragment, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
HERE Android SDK Developer's Guide
API Reference
1483
public void setMapGesture (MapGesture mapGesture)
Sets the MapGesture to be associated with this NLP instance if it is instantiated through (Context, Map)
Parameters:
mapGesture
Gesture handler for the Map.
public void setMetricSystemEnabled (boolean enable)
Controls whether NLP should use metric measurement system or imperial.
This may be set by user, please refer to the following for more information: onParameterChanged(Error,
Intention.Field, Intention.Value)
Parameters:
enable
When true, metric system will be used; when false, imperial system will be used. Default is true.
public void setOnlineDeductionEnabled (boolean enable)
Controls whether NLP deduction happens on the back-end server or on the client side. This may be set
by user, please refer to the following for more information: onParameterChanged(Error, Intention.Field,
Intention.Value)
Parameters:
enable
When true, NLP deduction happens on the back-end server. When false, NLP deduction happens on the
device. Default is true.
public void setPreferredRoute (Route route)
Client application tells NLP to use a preferred Route for navigation purposes. Only one Route can be chosen
at a time. By default, the preferred route is the route returned in onComplete(Error, Route, List, String, List)
Parameters:
route
The preferred Route, either returned by NLP as a result of a voice query via onComplete(Error, Route, List,
String, List) or provided externally by the client using setRouteResult(Route, List)
public void setRepeatAfterMeEnabled (boolean enable)
Set repeat-after-me to true lets user to hear the results of voice recognition. When talk-back is enabled, user
will hear the voice statement back, before processing the request. See #setTalkBackEnabled.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1484
enable
If true, user will hear back the result of the voice recognition. If false, user spoken request will be
processed immediately.
public void setRouteResult (Route route, List waypointNames)
Set the externally-generated Route result with an optional list of names and aliases of the waypoints in the
route. If the waypoint name array does not match the waypoints in the route, the route place names are
resolved internally by NLP, if possible.
The application will receive a onRouteResultsAdded(Error, Route) callback when the Route has been added to
NLP or when there is an error. If there is no error, the application can choose to call setPreferredRoute(Route)
to set the Route as the preferred route in NLP.
The waypoint name aliases allow the application to specify the alias in a voice query (e.g. instead of saying
"remove stopover", voice query can be "remove Starbucks", if "Starbucks" is the alias)
Parameters:
route
Route generated externally by the application
waypointNames
A list of the names and aliases of the waypoints in the route, including the start
public void setSearchResults (CategoryFilter filter, java.util.ArrayList
<PlaceLink> results)
Set the search results in NLP
Parameters:
filter
Search category. See CategoryFilter
results
List of discovered places generated externally by the application
public void setSearchResults (GeoCoordinate location, Address address)
Set the search results in NLP
Parameters:
location
Search center GeoCoordinate
address
Address of discovered place Address provided by the application
HERE Android SDK Developer's Guide
API Reference
1485
public void setSearchResults (String searchSubject, java.util.ArrayList
<PlaceLink> results)
Set the search results in NLP
Parameters:
searchSubject
Search subject name. Example: "hotels"
results
List of discovered places generated externally by the application
public void setSpeechVolume (int percentage)
Set speech volume percentage.
Parameters:
percentage
Volume percentage [0..100]. If less than 0, a default minimum volume percentage will be used instead. If
greater than 100, it's clipped to 100.
public void setTalkBackEnabled (boolean enable)
Enable/disable talk-back on a spoken user request
Parameters:
enable
If true, user will hear back all the responses on the spoken request. If false, the responses will be shown
as toast messages.
public void speak (String text)
Speaks the text
Parameters:
text
Text to speak
public void startListening ()
Inform Nlp to start listening for the voice input using the Speech Recognizer passed in the initialization
phase. Using that API to start the ASR is recommended because it allows Nlp to interrupt any other voice/
instructions being spoken (from Navigation instructions for example). If other voices are not stopped, the
ASR might pick them up and misunderstand the utterance.
HERE Android SDK Developer's Guide
API Reference
1486
public void stopListening ()
Stop listening for the voice input.
public boolean understand (String utterance)
"Understand" the text and produce formalized Intention through onIntent(Intention).
Typically, this is done automatically after startListening() is called; thereafter, user can speak and his/her
speech is processed by automatic speech recognizer (ASR) and the output from ASR is fed into this function.
Moreover, if application has a different source for the text, this API can be used to pass ASR. When deduction
is complete, application will receive onIntent(Intention) callback and application can chose to handle the
Intention by replying CONSUMED or instruct SDK to handle the Intention by replying PROCEED.
Parameters:
utterance
input for deduction
Returns:
true if it can proceed with deduction; false otherwise or if Nlp has not yet been initialized.
ListenerBase
The interface ListenerBase is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.ListenerBase
Base event listener interface
[For complete information, see the section Interface Details]
Interface Details
Base event listener interface
OnBatteryLevelListener
The interface OnBatteryLevelListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnBatteryLevelListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The remaining battery level event listener interface
HERE Android SDK Developer's Guide
API Reference
1487
[For complete information, see the section Interface Details]
Method Summary
Table 895: Methods in OnBatteryLevelListener
Methods
public abstract void onBatteryLevel (Error error, int level)
A callback with the device battery level in percentage.
Interface Details
The remaining battery level event listener interface
Method Details
public abstract void onBatteryLevel (Error error, int level)
A callback with the device battery level in percentage. e.g. "What is my battery level"
Parameters:
error
NONE if battery level can be determined; otherwise FAILED
level
The battery level percentage of the remaining charge, [0..100] if error is NONE; otherwise -1.
OnClearListener
The interface OnClearListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnClearListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Listener interface for clearing objects from the map.
[For complete information, see the section Interface Details]
Method Summary
Table 896: Methods in OnClearListener
Methods
public abstract void onClear (Route route)
A callback for clearing the current route.
HERE Android SDK Developer's Guide
API Reference
1488
Methods
public abstract void onClear (java.util.List <PlaceLink> places)
A callback for clearing the current search results.
public abstract void onClear ()
A callback for a generic clear request without specifying specific target.
Interface Details
Listener interface for clearing objects from the map. When a particular callback is received, the application is
responsible for clearing the map objects, if desired.
Method Details
public abstract void onClear (Route route)
A callback for clearing the current route. e.g. "Clear current route"
Parameters:
route
The Route object to clear from the map.
public abstract void onClear (java.util.List <PlaceLink> places)
A callback for clearing the current search results. e.g. "Clear search"
Parameters:
places
The search result PlaceLink objects to clear from the map.
public abstract void onClear ()
A callback for a generic clear request without specifying specific target. e.g. "Clear everything"
OnCurrentAddressListener
The interface OnCurrentAddressListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnCurrentAddressListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Address at the current geo location is ready event listener interface.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
1489
Method Summary
Table 897: Methods in OnCurrentAddressListener
Methods
public abstract void onCurrentAddress (Error error, Address address)
A callback indicating that the current address is ready.
Interface Details
Address at the current geo location is ready event listener interface.
Method Details
public abstract void onCurrentAddress (Error error, Address address)
A callback indicating that the current address is ready. e.g. "Where am I"
Parameters:
error
Error status getting the current address
address
The current Address
OnCurrentTimeListener
The interface OnCurrentTimeListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnCurrentTimeListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The current time event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 898: Methods in OnCurrentTimeListener
Methods
public abstract void onCurrentTime (Error error, String time)
A callback with the current system time.
HERE Android SDK Developer's Guide
API Reference
1490
Interface Details
The current time event listener interface
Method Details
public abstract void onCurrentTime (Error error, String time)
A callback with the current system time. e.g. "What time is it"
Parameters:
error
NONE if current time can be determined; otherwise FAILED
time
Current device time in "hh:mm aa" format, e.g. "12:00 AM", "08:05 AM" or "12:00 PM", "01:00 PM" if error is
NONE; otherwise null;
See also:
java.text.SimpleDateFormat
OnInitializationListener
The interface OnInitializationListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnInitializationListener
Represents a listener to provide notification of the Nlp status upon completion of initialization.
[For complete information, see the section Interface Details]
See also:
init(Context, MapFragment, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
init(Context, Map, MapGesture, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
Method Summary
Table 899: Methods in OnInitializationListener
Methods
public abstract void onComplete (Error error)
A callback indicating that that Nlp initialization has completed.
Interface Details
Represents a listener to provide notification of the Nlp status upon completion of initialization.
HERE Android SDK Developer's Guide
API Reference
1491
See also:
init(Context, MapFragment, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
init(Context, Map, MapGesture, CollectionProvider, SpeechToTextProvider, OnInitializationListener)
Method Details
public abstract void onComplete (Error error)
A callback indicating that that Nlp initialization has completed.
Parameters:
error
If Nlp initialized successfully, returns NONE. Otherwise, FAILED with a message indicating the reason of
initialization failure.
OnIntentListener
The interface OnIntentListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnIntentListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Intention is ready event listener interface.
[For complete information, see the section Interface Details]
Method Summary
Table 900: Methods in OnIntentListener
Methods
public abstract Reply onIntent (Intention intention)
A callback indicating that Intention is ready
Interface Details
Intention is ready event listener interface.
Method Details
public abstract Reply onIntent (Intention intention)
A callback indicating that Intention is ready
Parameters:
HERE Android SDK Developer's Guide
API Reference
1492
intention
Intention object, the result of the voice input deduction.
Returns:
Application should return PROCEED to instruct SDK to act on the Intention. Application should return
CONSUMED to indicate that the Intention was consumed.
OnMapSchemeChangedListener
The interface OnMapSchemeChangedListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnMapSchemeChangedListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Map.Scheme of the Map object has been changed event listener interface.
[For complete information, see the section Interface Details]
Method Summary
Table 901: Methods in OnMapSchemeChangedListener
Methods
public abstract void onMapSchemeChanged (String scheme)
A callback indicating that the Map scheme has been changed.
Interface Details
Map.Scheme of the Map object has been changed event listener interface.
Method Details
public abstract void onMapSchemeChanged (String scheme)
A callback indicating that the Map scheme has been changed. e.g. "Use satellite"
Parameters:
scheme
The Map.Scheme
OnNavigationListener
The interface OnNavigationListener is a member of com.here.android.mpa.nlp.Nlp.
HERE Android SDK Developer's Guide
API Reference
1493
Interface Summary
public static abstract interface Nlp.OnNavigationListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Navigation listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 902: Methods in OnNavigationListener
Methods
public abstract void onStart (Error error, java.util.List <Route> routes, String
startingPointName, java.util.List <Place> routePlaces)
A callback with the calculated route and the list of Places.
public abstract void onStop ()
A callback for notifying user to stop navigation.
Interface Details
Navigation listener interface
Method Details
public abstract void onStart (Error error, java.util.List <Route> routes,
String startingPointName, java.util.List <Place> routePlaces)
A callback with the calculated route and the list of Places. e.g. "Start navigation"
Parameters:
error
Error information for starting navigation
routes
The list of Routes
startingPointName
The starting point name
routePlaces
Array of Places included into the route, excluding the starting point.
public abstract void onStop ()
A callback for notifying user to stop navigation. e.g. "Stop navigation"
HERE Android SDK Developer's Guide
API Reference
1494
OnParameterListener
The interface OnParameterListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnParameterListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Parameter event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 903: Methods in OnParameterListener
Methods
public abstract void onParameterChanged (Error error, Field parameter, Value value)
A callback with the parameter and its value set by the user.
Interface Details
Parameter event listener interface
Method Details
public abstract void onParameterChanged (Error error, Field parameter, Value
value)
A callback with the parameter and its value set by the user. Supported values are as follow:
ONLINE_DEDUCTION:
if ON, NLP will process deduction online. e.g. "use backend"
if OFF, NLP will process deduction offline. e.g. "don't use backend"
See also setOnlineDeductionEnabled(boolean) and isOnlineDeductionEnabled().
DISTANCE_MEASURE:
if KILOMETER, NLP will use metric measurement system. e.g. "use metric system", "use kilometers",
"tell me in meters".
if MILE, NLP will use imperial measurement system. e.g. "use imperial system", "use miles", "tell me
in yards", "tell me in feet".
Please note that user may temporarily override the measurement system by explicitly specifying the
measurement in the utterance.
e.g. "Tell me how far McDonalds is in metric".
See also setMetricSystemEnabled(boolean) and isMetricSystemEnabled()
Parameters:
HERE Android SDK Developer's Guide
API Reference
1495
error
NONE if user requested parameter is successfully set to the requested value; otherwise FAILED
parameter
The parameter that has been changed if error is NONE; otherwise this represents the parameter user
wants to change.
value
The new value of the parameter if error is NONE; otherwise this represents the value user wants to
change the parameter to.
OnPlaceFocusChangedListener
The interface OnPlaceFocusChangedListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnPlaceFocusChangedListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Listener for a client focus change to another place
[For complete information, see the section Interface Details]
Method Summary
Table 904: Methods in OnPlaceFocusChangedListener
Methods
public abstract void onPlaceFocusChanged (PlaceLink place)
A callback with the PlaceLink to notify application that focus is moved to this place.
Interface Details
Listener for a client focus change to another place
Method Details
public abstract void onPlaceFocusChanged (PlaceLink place)
A callback with the PlaceLink to notify application that focus is moved to this place. e.g. "Next location"
Parameters:
place
PlaceLink object currently in focus
HERE Android SDK Developer's Guide
API Reference
1496
OnRemoveFromRouteListener
The interface OnRemoveFromRouteListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnRemoveFromRouteListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Listener interface to notify user that a stopover is removed from the route
[For complete information, see the section Interface Details]
Method Summary
Table 905: Methods in OnRemoveFromRouteListener
Methods
public abstract void onRemovedFromRoute (Error error, PlaceLink stopover)
A callback after a stopover is removed from the preferred route.
Interface Details
Listener interface to notify user that a stopover is removed from the route
Method Details
public abstract void onRemovedFromRoute (Error error, PlaceLink stopover)
A callback after a stopover is removed from the preferred route. e.g. "Remove stopover" When the callback is
received, the application is responsible for removing the stopover from the route display, if desired.
Parameters:
error
Error status for removing the stopover from the route
stopover
PlaceLink object of the stopover removed from the route
OnResetListener
The interface OnResetListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnResetListener
HERE Android SDK Developer's Guide
API Reference
1497
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Listener interface to notify that user wants to do the reset.
[For complete information, see the section Interface Details]
Method Summary
Table 906: Methods in OnResetListener
Methods
public abstract void onComplete ()
A callback indicates nlp reset is completed.
Interface Details
Listener interface to notify that user wants to do the reset. Reset operation implies cleaning the short term
memory and stopping all pending map operations (routing, navigation, ...etc.)
Method Details
public abstract void onComplete ()
A callback indicates nlp reset is completed. e.g. "Reset"
OnRouteListener
The interface OnRouteListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnRouteListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Route object is available event interface.
[For complete information, see the section Interface Details]
Method Summary
Table 907: Methods in OnRouteListener
Methods
public abstract void onComplete (Error error, Route preferredRoute, java.util.List <Place>
preferredRoutePlaces, String startingPointName, java.util.List <Route> routes)
A callback with the preferred calculated route, the list of Routes to all destinations, and the list of Places.
HERE Android SDK Developer's Guide
API Reference
1498
Methods
public abstract void onStart ()
A callback when start calculating route.
Interface Details
Route object is available event interface.
Method Details
public abstract void onComplete (Error error, Route preferredRoute,
java.util.List <Place> preferredRoutePlaces, String startingPointName,
java.util.List <Route> routes)
A callback with the preferred calculated route, the list of Routes to all destinations, and the list of Places. e.g.
"Create a route from Vancouver to Seattle" When the callback is received, the application is responsible for
displaying the route results, if desired.
Parameters:
error
Error status for routing
preferredRoute
The preferred Route from among the list of Routes to all found destinations
preferredRoutePlaces
Array of Places included into the preferred route, excluding the starting point.
startingPointName
The starting point name
routes
The list of Routes to all found destinations, including the preferred route.
public abstract void onStart ()
A callback when start calculating route. e.g. "Create a route from Vancouver to Seattle"
OnRouteResultsAddedListener
The interface OnRouteResultsAddedListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnRouteResultsAddedListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
HERE Android SDK Developer's Guide
API Reference
1499
Listener interface for adding route results from the application to NLP.
[For complete information, see the section Interface Details]
Method Summary
Table 908: Methods in OnRouteResultsAddedListener
Methods
public abstract void onRouteResultsAdded (Error error, Route route)
Interface Details
Listener interface for adding route results from the application to NLP.
Method Details
public abstract void onRouteResultsAdded (Error error, Route route)
Parameters:
error
route
OnSearchListener
The interface OnSearchListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnSearchListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
Search listener interface.
[For complete information, see the section Interface Details]
Method Summary
Table 909: Methods in OnSearchListener
Methods
public abstract void onComplete (Error error, String searchString, String whereString, String
nearString, java.util.List <PlaceLink> places)
A callback with the resulting list of PlaceLink when a particular search request is complete.
public abstract void onStart (CategoryFilter filter, GeoBoundingBox box)
A callback with the requested category filter for the specified bounding box area
HERE Android SDK Developer's Guide
API Reference
1500
Methods
public abstract void onStart (GeoCoordinate location)
A callback with requested reverse geocoding search location GeoCoordinate.
public abstract void onStart (String subject, GeoBoundingBox box)
A callback with the requested search string for the specified bounding box area.
Interface Details
Search listener interface.
Method Details
public abstract void onComplete (Error error, String searchString, String
whereString, String nearString, java.util.List <PlaceLink> places)
A callback with the resulting list of PlaceLink when a particular search request is complete. e.g. "Find a
coffee shop" When the callback is received, the application is responsible for displaying the search results, if
desired.
Parameters:
error
Error status for search request
searchString
The searched string
whereString
The whereabouts of the searched string. Example: "in Seattle"
nearString
The whereabouts of the searched string. Example: "close to the Space Needle"
places
List of PlaceLink objects, the result of the voice search.
public abstract void onStart (CategoryFilter filter, GeoBoundingBox box)
A callback with the requested category filter for the specified bounding box area
Parameters:
filter
Search category filter
box
Bounding box for the search
public abstract void onStart (GeoCoordinate location)
HERE Android SDK Developer's Guide
API Reference
1501
A callback with requested reverse geocoding search location GeoCoordinate. e.g. "Where am I"
Parameters:
location
The GeoCoordinate of the place we need to get address for.
public abstract void onStart (String subject, GeoBoundingBox box)
A callback with the requested search string for the specified bounding box area. e.g. "Find a coffee shop"
Parameters:
subject
Search subject
box
Bounding box for the search
OnSendLocationListener
The interface OnSendLocationListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnSendLocationListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The send location event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 910: Methods in OnSendLocationListener
Methods
public abstract void onSendLocation (Error error, GeoCoordinate location, String recipient)
A callback with the current location to be sent to the specified recipient or requesting the specified recipient for his/her
current location through SMS.
Interface Details
The send location event listener interface
HERE Android SDK Developer's Guide
API Reference
1502
Method Details
public abstract void onSendLocation (Error error, GeoCoordinate location,
String recipient)
A callback with the current location to be sent to the specified recipient or requesting the specified recipient
for his/her current location through SMS. e.g. "Send my location to mom", "where is my mom" Notes:
This feature requires Contacts, Location, and SMS permissions from the users.
Contacts are loaded once during NLP initialization into memory. Any changes made thereafter will not be
reflected until the next startup.
Contact's display name and nickname are used for recipient lookup. For example, for "send my location
to mom" use case to work, user needs have a contact with display name "mom" or nickname "mom".
Levenshtein distance is used for recipient lookup with fault tolerance of 1 character. For example, if a
contact has nickname, "mum", it will be matched to recipient "mom".
If the specified recipient is matched to multiple contacts, the first matched contact will be used and the
first match may not be the best match. For example, first match is "mum" and second match is "mom"
and the specified recipient is "mom", the first match will be used even though it's not the best match.
Recipient lookup is limited to contacts on the device. For utterances like "publish my location to
facebook" or "publish my location to twitter" will result in an attempt to send location through SMS to a
contact named "facebook" or "twitter" respectively. For another example, "send my location to myself"
will result in an attempt to send a SMS to a contact named "myself".
Parameters:
error
NONE if location information is successfully sent/requested; otherwise FAILED
location
The current location for sending request; otherwise null.
recipient
Recipient of the SMS.
OnSendSMSListener
The interface OnSendSMSListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnSendSMSListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The send SMS event listener interface
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
1503
Method Summary
Table 911: Methods in OnSendSMSListener
Methods
public abstract void onSendSMS (Error error, String message, String recipient)
A callback with the message to be sent to the specified recipient through SMS.
Interface Details
The send SMS event listener interface
Method Details
public abstract void onSendSMS (Error error, String message, String
recipient)
A callback with the message to be sent to the specified recipient through SMS. Notes:
This feature requires Contacts, and SMS permissions from the users.
Contacts are loaded once during NLP initialization into memory. Any changes made thereafter will not be
reflected until the next startup.
Contact's display name and nickname are used for recipient lookup. For example, for "send my location
to mom" use case to work, user needs have a contact with display name "mom" or nickname "mom".
Levenshtein distance is used for recipient lookup with fault tolerance of 1 character. For example, if a
contact has nickname, "mum", it will be matched to recipient "mom".
If the specified recipient is matched to multiple contacts, the first matched contact will be used and the
first match may not be the best match. For example, first match is "mum" and second match is "mom"
and the specified recipient is "mom", the first match will be used even though it's not the best match.
Parameters:
error
NONE if SMS is successfully sent; otherwise FAILED
message
The message for sending request; otherwise null.
recipient
Recipient of the SMS.
OnSpeedListener
The interface OnSpeedListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnSpeedListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
HERE Android SDK Developer's Guide
API Reference
1504
The speed value event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 912: Methods in OnSpeedListener
Methods
public abstract void onSpeed (Error error, int kph)
A callback with the average speed.
Interface Details
The speed value event listener interface
Method Details
public abstract void onSpeed (Error error, int kph)
A callback with the average speed. e.g. "What is my speed"
Parameters:
error
Error information for calculating average speed. If FAILED, speed value of less than 0 will be returned.
kph
Kilometers per hour
OnSpeedWarningSwitchListener
The interface OnSpeedWarningSwitchListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnSpeedWarningSwitchListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The speed warning mode during navigation event listener interface
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
1505
Method Summary
Table 913: Methods in OnSpeedWarningSwitchListener
Methods
public abstract void onSpeedWarningSwitch (Error error, boolean on)
A callback indicating that the speed warning was switched on or off.
Interface Details
The speed warning mode during navigation event listener interface
Method Details
public abstract void onSpeedWarningSwitch (Error error, boolean on)
A callback indicating that the speed warning was switched on or off. e.g. "Turn on/off speed warning"
Parameters:
error
Error information for switching speed warning. If FAILED, speed warning will not be switched.
on
If true, speed warning is enabled
OnTrafficModeListener
The interface OnTrafficModeListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnTrafficModeListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The traffic mode changed event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 914: Methods in OnTrafficModeListener
Methods
public abstract void onTrafficMode (Error error, boolean on, String whereLocation)
A callback indicating that the traffic mode was switched on or off.
HERE Android SDK Developer's Guide
API Reference
1506
Interface Details
The traffic mode changed event listener interface
Method Details
public abstract void onTrafficMode (Error error, boolean on, String
whereLocation)
A callback indicating that the traffic mode was switched on or off. e.g. "Turn on/off traffic"
Parameters:
error
Error status of retrieving traffic mode, FAILED if traffic request fails or permission is not allowed.
on
If true, traffic mode is enabled
whereLocation
The string location where to check the traffic
OnTravelDistanceListener
The interface OnTravelDistanceListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnTravelDistanceListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The travel distance to specified location event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 915: Methods in OnTravelDistanceListener
Methods
public abstract void onTravelDistance (Error error, Place from, Place to, int distanceM)
A callback with the travel distance in meters to the specified location.
Interface Details
The travel distance to specified location event listener interface
HERE Android SDK Developer's Guide
API Reference
1507
Method Details
public abstract void onTravelDistance (Error error, Place from, Place to, int
distanceM)
A callback with the travel distance in meters to the specified location. e.g. "What is the distance between
Vancouver and Seattle".
Parameters:
error
Error information for calculating travel distance. If FAILED, distance of less than 0 will be returned.
from
"From" Place. If null, current position is implied
to
"To" Place.
distanceM
Distance in meters
OnTravelTimeListener
The interface OnTravelTimeListener is a member of com.here.android.mpa.nlp.Nlp.
Interface Summary
public static abstract interface Nlp.OnTravelTimeListener
extends com.here.android.mpa.nlp.Nlp.ListenerBase
The travel time to specified location event listener interface
[For complete information, see the section Interface Details]
Method Summary
Table 916: Methods in OnTravelTimeListener
Methods
public abstract void onTravelTime (Error error, Place from, Place to, int timeSec)
A callback with the travel time in seconds to the specified location.
Interface Details
The travel time to specified location event listener interface
HERE Android SDK Developer's Guide
API Reference
1508
Method Details
public abstract void onTravelTime (Error error, Place from, Place to, int
timeSec)
A callback with the travel time in seconds to the specified location. e.g. "How long does it take to drive from
Vancouver to Seattle".
Parameters:
error
Error information for calculating travel time
from
"From" Place. If null, current position is implied
to
"To" Place.
timeSec
Time in seconds. If traffic is enabled on Map, the calculated travel time will reflect the current traffic.
Reply
The enumeration Reply is a member of com.here.android.mpa.nlp.Nlp.
Enumeration Summary
public static final enumeration Nlp.Reply
extends java.lang.Enum, java.lang.Object
Client's responses on the events triggered by NLP
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 917: Enum Constants in Reply
Fields
public static final Reply PROCEED
Client ignores event, default NLP actions will be performed.
public static final Reply CONSUMED
Client consumed event, no further actions will be performed by NLP.
HERE Android SDK Developer's Guide
API Reference
1509
Method Summary
Table 918: Methods in Reply
Methods
public static Reply valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Nlp.Reply[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Client's responses on the events triggered by NLP
Enum Constant Details
public static final Reply PROCEED
Client ignores event, default NLP actions will be performed.
public static final Reply CONSUMED
Client consumed event, no further actions will be performed by NLP.
Method Details
public static Reply valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Nlp.Reply[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
OnCollectionListener
The interface OnCollectionListener is a member of com.here.android.mpa.nlp .
HERE Android SDK Developer's Guide
API Reference
1510
Interface Summary
public abstract interface OnCollectionListener
Collection listener for the following operations: 1) Adding, removing, or renaming a collection.
[For complete information, see the section Interface Details]
See also:
CollectionProvider
Method Summary
Table 919: Methods in OnCollectionListener
Methods
public abstract void onComplete (Error error)
A callback when a collection operation is completed.
Interface Details
Collection listener for the following operations: 1) Adding, removing, or renaming a collection. 2) Adding or
removing a place to/from a collection.
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
See also:
CollectionProvider
Method Details
public abstract void onComplete (Error error)
A callback when a collection operation is completed.
Parameters:
error
Error indicating whether the operation is successful.
Place
The class Place is a member of com.here.android.mpa.nlp .
Class Summary
public final class Place
implements java.io.Serializable
HERE Android SDK Developer's Guide
API Reference
1511
extends java.lang.Object
Information about a place required by NLP.
[For complete information, see the section Class Details]
Constructor Summary
Table 920: Constructors in Place
Constructors
Place (String name, GeoCoordinate coordinate)
Constructor
Place (Place other)
Copy constructor
Method Summary
Table 921: Methods in Place
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public Address getAddress ()
Get address of the place
public GeoCoordinate getCoordinate ()
Get coordinate of the place
public String getName ()
Get name of the place
public PlaceLink getPlaceLink ()
Get PlaceLink of the place
public int hashCode ()
For documentation, see java.lang.Object
public Place setAddress (Address address)
Set address of the place
public Place setCoordinate (GeoCoordinate coordinate)
Set coordinates of the place
public Place setName (String name)
Set name of the place
public Place setPlaceLink (PlaceLink placeLink)
Set PlaceLink of the place
HERE Android SDK Developer's Guide
API Reference
1512
Class Details
Information about a place required by NLP. Information may be obtained from search or other sources and
transformed into this by application.
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Constructor Details
Place (String name, GeoCoordinate coordinate)
Constructor
Parameters:
name
The place name, must not be null or empty
coordinate
The Geo-Coordinates of the place, must not null and must be valid
Place (Place other)
Copy constructor
Parameters:
other
Place to copy from
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public Address getAddress ()
Get address of the place
Returns:
The place address
public GeoCoordinate getCoordinate ()
HERE Android SDK Developer's Guide
API Reference
1513
Get coordinate of the place
Returns:
The coordinate of the place
public String getName ()
Get name of the place
Returns:
The place name
public PlaceLink getPlaceLink ()
Get PlaceLink of the place
Returns:
The place PlaceLink
public int hashCode ()
For documentation, see java.lang.Object
public Place setAddress (Address address)
Set address of the place
Parameters:
address
address of the place
Returns:
Place
public Place setCoordinate (GeoCoordinate coordinate)
Set coordinates of the place
Parameters:
coordinate
GeoCoordinate of the place
Returns:
Place
HERE Android SDK Developer's Guide
API Reference
1514
public Place setName (String name)
Set name of the place
Parameters:
name
The place name
Returns:
Place
public Place setPlaceLink (PlaceLink placeLink)
Set PlaceLink of the place
Parameters:
placeLink
PlaceLink of the place
Returns:
Place
SpeechToTextProvider
The interface SpeechToTextProvider is a member of com.here.android.mpa.nlp .
Interface Summary
public abstract interface SpeechToTextProvider
Speech to text interface for start or stop listening for voice commands, cancel, pause, resume or destroy the
Speech recognition service.
[For complete information, see the section Interface Details]
Method Summary
Table 922: Methods in SpeechToTextProvider
Methods
public abstract void cancel ()
Cancel the speech recognition.
public abstract void destroy ()
Destroy the speech recognizer object.
HERE Android SDK Developer's Guide
API Reference
1515
Methods
public abstract boolean isListening ()
Return whether the ASR is currently listening to speech.
public abstract void pause ()
Pause ASR functionality (when Activity onPause event is called and pause() is used.
public abstract void resume (Context context)
Resume ASR functionality (when Activity onResume event is called) and resume(Context) is used.
public abstract void start ()
Start listening for speech.
public abstract boolean stop ()
Stop listening for speech.
Interface Details
Speech to text interface for start or stop listening for voice commands, cancel, pause, resume or destroy
the Speech recognition service. If this interface is not implemented, the speech recognition service is
entirely the responsibility of the application. Calling Speech recognition service APIs like startListening()
or stopListening() would not do anything and Nlp would not be able to make sure no other voice is
playing (e.g. navigation instructions) while the ASR is listening. To achieve better user experience, it's
highly recommended that the application implements this interface and uses Nlp APIs: startListening(),
stopListening(), resume(Context), pause().
IMPORTANT: Natural language processor is a Beta feature. The related classes are subject to change without
notice.
Method Details
public abstract void cancel ()
Cancel the speech recognition.
public abstract void destroy ()
Destroy the speech recognizer object.
public abstract boolean isListening ()
Return whether the ASR is currently listening to speech. It is listening if ASR was started and results haven't
been received yet.
Returns:
boolean: true of the ASR is currently listening to speech false otherwise.
HERE Android SDK Developer's Guide
API Reference
1516
public abstract void pause ()
Pause ASR functionality (when Activity onPause event is called and pause() is used.
public abstract void resume (Context context)
Resume ASR functionality (when Activity onResume event is called) and resume(Context) is used.
Parameters:
context
The application context set via init(Context, MapFragment, CollectionProvider, SpeechToTextProvider,
Nlp.OnInitializationListener) or init(Context, Map, MapGesture, CollectionProvider, SpeechToTextProvider,
Nlp.OnInitializationListener)
public abstract void start ()
Start listening for speech.
public abstract boolean stop ()
Stop listening for speech.
odml
The package odml is a member of com.here.android.mpa.
Package Summary
odml
The ODML (On Device Map Loader) package provides classes, interfaces and enumerations which facilitate
the download of map data for offline use.
Package Details
The ODML (On Device Map Loader) package provides classes, interfaces and enumerations which facilitate
the download of map data for offline use.
Some key classes and interfaces in this package are:
MapLoader
MapPackage
MapLoader
HERE Android SDK Developer's Guide
API Reference
1517
The MapLoader class is a singleton which provides access to all of the operations required to view,
download, uninstall and update offline map data packages.
MapPackage
The MapPackage class serves as a model object for map packages managed by the MapLoader. The
identifiers provided by the getId() API are used to uniquely identify a particular package for use with
MapLoader.
For more information on using this feature, please consult the "Offline Maps" section in the HERE SDK for
Android Developer's Guide.
MapLoader
The class MapLoader is a member of com.here.android.mpa.odml .
Class Summary
public final class MapLoader
extends java.lang.Object
Facilitates the use of offline map data.
[For complete information, see the section Class Details]
Nested Class Summary
Table 923: Nested Classes in MapLoader
Nested Classes
public static abstract interface MapLoader.Listener
Represents a listener interface for receiving notifications from the MapLoader.
public static abstract interface MapLoader.MapPackageAtCoordinateListener
Represents a listener interface with a callback which gets invoked upon package retrieval.
public static final enumeration MapLoader.ResultCode
Represents values describing the status of a MapLoader operation.
Method Summary
Table 924: Methods in MapLoader
Methods
public void addListener (Listener listener)
Adds a MapLoader.Listener for the MapLoader .
public void addMapPackageAtCoordinateListener (MapPackageAtCoordinateListener listener)
Adds a MapLoader.MapPackageAtCoordinateListener for the MapLoader .
HERE Android SDK Developer's Guide
API Reference
1518
Methods
public boolean cancelCurrentOperation ()
Cancels the current MapLoader operation.
public boolean checkForMapDataUpdate ()
Checks for the availability of an updated version of map data.
public void deselectDataGroup (SelectableDataGroup dataGroup)
Deselects a map data group for installation when using an isolated disk cache.
public static MapLoader getInstance ()
Gets the MapLoader shared instance.
public boolean getMapPackageAtCoordinate (GeoCoordinate coordinate)
This method will try to find a map package based on a map location.
public boolean getMapPackages ()
Returns the list of available MapPackage hierarchies.
public boolean installMapPackages (List packageIdList)
Installs the MapPackage hierarchies whose IDs are contained within the specified List of Integer objects.
public boolean performMapDataUpdate ()
Updates the version of map data if an update is available.
public void removeListener (Listener listener)
Removes a MapLoader.Listener for the MapLoader .
public void removeMapPackageAtCoordinateListener (MapPackageAtCoordinateListener listener)
Removes a MapLoader.MapPackageAtCoordinateListener for the MapLoader .
public void selectDataGroup (SelectableDataGroup dataGroup)
Selects a map data group for installation when using an isolated disk cache.
public boolean uninstallMapPackages (List packageIdList)
Uninstalls the MapPackage hierarchies whose IDs are contained within the specified List of Integer objects.
Class Details
Facilitates the use of offline map data.
MapLoader is a singleton which must be obtained by calling getInstance(). Method calls are asynchronous,
returning results by way of the MapLoader.Listener interface.
All operations of a MapLoader are mutually exclusive. If, for example, method XYZ is called before the
callback for method ABC has returned a result, method XYZ will return false to indicate that the MapLoader
is busy with another operation.
MapLoader requires an internet connection to perform operations (with the exception of getMapPackages()
and uninstallMapPackages(List)). If a MapLoader operation is attempted when no internet connection is
available, NO_CONNECTIVITY will be returned.
Incremental Updates
HERE Android SDK Developer's Guide
API Reference
1519
MapLoader exposes the ability to update the version of the map and provide the user with the freshest map
data available. The map version applies not only to map data pre-installed using the MapLoader , but also
to data which are retrieved dynamically by browsing the map in areas where map data has not been pre-
installed.
The map version is consistent for all map data, downloaded or not, across the entire system. It is not
possible to have some data from one map version and other data from another map version concurrent in
the database. It is important, therefore, to keep the map version of the system up to date, which fortunately
does not require re-downloading everything. Only incremental changes need to be downloaded, making
typical updates small and quick. Map version updating is exposed through the checkForMapDataUpdate() and
performMapDataUpdate() methods.
Method Details
public void addListener (Listener listener)
Adds a MapLoader.Listener for the MapLoader .
Parameters:
listener
A MapLoader.Listener for returning results from MapLoader operations
public void addMapPackageAtCoordinateListener (MapPackageAtCoordinateListener
listener)
Adds a MapLoader.MapPackageAtCoordinateListener for the MapLoader .
Parameters:
listener
A MapLoader.MapPackageAtCoordinateListener for returning results from MapLoader operations
public boolean cancelCurrentOperation ()
Cancels the current MapLoader operation.
Note: cancellation is deemed complete once the onComplete callback for the current operation has been
made. If false is returned from this method, no callback will be made.
Returns:
True if the request has been made successfully (an operation was requested to cancel), false if there is no
ongoing MapLoader operation to cancel.
public boolean checkForMapDataUpdate ()
Checks for the availability of an updated version of map data. The result is obtained by way of the
MapLoader.Listener.onCheckForUpdateComplete(boolean, String, String, ResultCode) callback.
HERE Android SDK Developer's Guide
API Reference
1520
For more information about updating map data versions, refer to the Incremental Updates section of the
detailed description for this interface.
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
public void deselectDataGroup (SelectableDataGroup dataGroup)
Deselects a map data group for installation when using an isolated disk cache. This method will not perform
any action when using a shared disk cache.
As with MapLoader#selectDataGroup(SelectableDataGroup) , changes will not take place until the
map data is updated. Furthermore, note that if you are deselecting a data group that is already installed,
you must uninstall the preloaded map packages prior to removing an existing data group to ensure the
unneeded data group is removed from storage.
Parameters:
dataGroup
com.here.android.mpa.MapPackage.SelectableDataGroup to deselect.
See also:
setIsolatedDiskCacheRootPath(String, String)
public static MapLoader getInstance ()
Gets the MapLoader shared instance.
Returns:
The shared MapLoader
public boolean getMapPackageAtCoordinate (GeoCoordinate coordinate)
This method will try to find a map package based on a map location. If it can be identified, the smallest
package containing the point is returned. For some input coordinates a larger package will be returned, but it
should never be higher than country level (i.e. continental packages will not be returned).
Parameters:
coordinate
The coordinates used to locate the package.
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
or given coordinate was not valid.
HERE Android SDK Developer's Guide
API Reference
1521
public boolean getMapPackages ()
Returns the list of available MapPackage hierarchies. The list of available packages is returned in the
MapLoader.Listener.onGetMapPackagesComplete(MapPackage, ResultCode) callback.
This operation can be performed offline if it has been performed online at least once before. Otherwise,
when trying to perform this operation offline NO_CONNECTIVITY will be returned by way of the Listener .
Note: the returned list of MapPackage hierarchies only represents a snapshot of the current map data state.
State information is not updated dynamically for a MapPackage instance, so any operation which modifies
the map data (install/uninstall/update) will invalidate pre-existing MapPackage instances.
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
public boolean installMapPackages (List packageIdList)
Installs the MapPackage hierarchies whose IDs are contained within the specified List of Integer objects.
Notes on installing map packages:
When installation starts, a summary of package sizes can be obtained through the
onInstallationSize(long, long) callback.
During installation, progress can be monitored via onProgress(int) callbacks.
When installation is complete, notification will be sent by way of the
onInstallMapPackagesComplete(MapPackage, MapLoader.ResultCode) callback.
If device connectivity is lost during installation, installation will halt and resume once connectivity is
restored. No callback will be produced until installation has finished.
Parameters:
packageIdList
A List of MapPackage IDs to install (if an invalid ID value is contained within the list, or the list is
empty, or null is passed, INVALID_PARAMETERS will be returned in the callback)
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
See also:
getId()
public boolean performMapDataUpdate ()
Updates the version of map data if an update is available. An application might check first for available
updates by calling checkForMapDataUpdate().
Notes on updating map data:
When the update starts, a summary of the update's size can be obtained through the
onInstallationSize(long, long) callback.
During the update, progress can be monitored via onProgress(int) callbacks.
HERE Android SDK Developer's Guide
API Reference
1522
When the update is complete, notification will be sent by way of the
onPerformMapDataUpdateComplete(MapPackage, MapLoader.ResultCode) callback.
If device connectivity is lost while updating, updating will halt and resume once connectivity is restored.
No callback will be produced until updating has finished.
For more information about updating map data versions, refer to the Incremental Updates section of the
detailed description for this interface.
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
public void removeListener (Listener listener)
Removes a MapLoader.Listener for the MapLoader .
Parameters:
listener
A MapLoader.Listener to be removed
public void removeMapPackageAtCoordinateListener
(MapPackageAtCoordinateListener listener)
Removes a MapLoader.MapPackageAtCoordinateListener for the MapLoader .
Parameters:
listener
A MapLoader.MapPackageAtCoordinateListener to be removed
public void selectDataGroup (SelectableDataGroup dataGroup)
Selects a map data group for installation when using an isolated disk cache. This method will not perform
any action when using a shared disk cache. Each map package is divided into several data groups. When
using an isolated disk cache, some of these groups may be optionally selected for installation if needed
by the application. Conversely, data groups which may be selected by default can be deselected by the
application if not needed, saving disk space.
Changes to the data group selection are only reflected in subsequent installations. To add data groups to
previously installed packages, call performMapDataUpdate() after changing the group selection.
Parameters:
dataGroup
com.here.android.mpa.MapPackage.SelectableDataGroup to select.
See also:
setIsolatedDiskCacheRootPath(String, String)
HERE Android SDK Developer's Guide
API Reference
1523
public boolean uninstallMapPackages (List packageIdList)
Uninstalls the MapPackage hierarchies whose IDs are contained within the specified List of Integer
objects.
Notes on uninstalling map packages:
Uninstalling MapPackage s can be done while offline.
During uninstallation, progress can be monitored via onProgress(int) callbacks.
When uninstallation is complete, notification will be sent by way of the
onUninstallMapPackagesComplete(MapPackage, MapLoader.ResultCode) callback.
Parameters:
packageIdList
A List of MapPackage IDs to uninstall (if an invalid ID value is contained within the list, or the list is
empty, or null is passed, INVALID_PARAMETERS will be returned in the callback)
Returns:
True if the request has been made successfully, false if the MapLoader is busy processing another request
See also:
getId()
Listener
The interface Listener is a member of com.here.android.mpa.odml.MapLoader.
Interface Summary
public static abstract interface MapLoader.Listener
Represents a listener interface for receiving notifications from the MapLoader.
[For complete information, see the section Interface Details]
Nested Class Summary
Table 925: Nested Classes in Listener
Nested Classes
public static abstract class MapLoader.Listener.Adapter
Default implementation for the MapLoader.Listener interface.
HERE Android SDK Developer's Guide
API Reference
1524
Method Summary
Table 926: Methods in Listener
Methods
public abstract void onCheckForUpdateComplete (boolean updateAvailable, String
currentMapVersion, String newestMapVersion, ResultCode resultCode)
A callback indicating that the checkForMapDataUpdate() method has completed its operation.
public abstract void onGetMapPackagesComplete (MapPackage rootMapPackage, ResultCode resultCode)
A callback indicating that the getMapPackages() method has completed its operation.
public abstract void onInstallMapPackagesComplete (MapPackage rootMapPackage, ResultCode
resultCode)
A callback indicating that the installMapPackages(List) method has completed its operation.
public abstract void onInstallationSize (long diskSize, long networkSize)
A callback triggered during certain MapLoader operations to indicate the size, in KB, of the map data which is to be
downloaded and stored for that particular operation.
public abstract void onPerformMapDataUpdateComplete (MapPackage rootMapPackage, ResultCode
resultCode)
A callback indicating that the performMapDataUpdate() method has completed its operation.
public abstract void onProgress (int progress)
A callback triggered during certain MapLoader operations to indicate the progress for that particular operation, a
percentage value in the [0..100] range.
public abstract void onUninstallMapPackagesComplete (MapPackage rootMapPackage, ResultCode
resultCode)
A callback indicating that the uninstallMapPackages(List) method has completed its operation.
Interface Details
Represents a listener interface for receiving notifications from the MapLoader.
Method Details
public abstract void onCheckForUpdateComplete (boolean updateAvailable,
String currentMapVersion, String newestMapVersion, ResultCode resultCode)
A callback indicating that the checkForMapDataUpdate() method has completed its operation.
Parameters:
updateAvailable
A boolean specifying whether an update is available
currentMapVersion
The current map data version, in the form "Major.Minor.Feature.Build" where each section is an unsigned
integer
newestMapVersion
HERE Android SDK Developer's Guide
API Reference
1525
The newest map data version, in the form "Major.Minor.Feature.Build" where each section is an unsigned
integer
resultCode
A ResultCode for the operation
public abstract void onGetMapPackagesComplete (MapPackage rootMapPackage,
ResultCode resultCode)
A callback indicating that the getMapPackages() method has completed its operation.
Parameters:
rootMapPackage
A root MapPackage (other map packages can be obtained by accessing its children). Can be null if the
ResultCode does not indicate success.
resultCode
A ResultCode for the operation
public abstract void onInstallMapPackagesComplete (MapPackage
rootMapPackage, ResultCode resultCode)
A callback indicating that the installMapPackages(List) method has completed its operation.
Parameters:
rootMapPackage
A root MapPackage (other map packages can be obtained by accessing its children). Can be null if the
ResultCode does not indicate success.
resultCode
A ResultCode for the operation
public abstract void onInstallationSize (long diskSize, long networkSize)
A callback triggered during certain MapLoader operations to indicate the size, in KB, of the map data which is
to be downloaded and stored for that particular operation.
Parameters:
diskSize
Amount of disk storage needed for the current operation
networkSize
Amount of network traffic to be used for the current operation
public abstract void onPerformMapDataUpdateComplete (MapPackage
rootMapPackage, ResultCode resultCode)
HERE Android SDK Developer's Guide
API Reference
1526
A callback indicating that the performMapDataUpdate() method has completed its operation.
Parameters:
rootMapPackage
A root MapPackage (other map packages can be obtained by accessing its children). Can be null if the
ResultCode does not indicate success.
resultCode
A ResultCode for the operation
public abstract void onProgress (int progress)
A callback triggered during certain MapLoader operations to indicate the progress for that particular
operation, a percentage value in the [0..100] range.
Parameters:
progress
Progress completion percentage
public abstract void onUninstallMapPackagesComplete (MapPackage
rootMapPackage, ResultCode resultCode)
A callback indicating that the uninstallMapPackages(List) method has completed its operation.
Parameters:
rootMapPackage
A root MapPackage (other map packages can be obtained by accessing its children). Can be null if the
ResultCode does not indicate success.
resultCode
A ResultCode for the operation
Adapter
The class Adapter is a member of com.here.android.mpa.odml.MapLoader.Listener.
Class Summary
public static abstract class MapLoader.Listener.Adapter
implements com.here.android.mpa.odml.MapLoader.Listener
extends java.lang.Object
Default implementation for the MapLoader.Listener interface.
[For complete information, see the section Class Details]
See also:
HERE Android SDK Developer's Guide
API Reference
1527
MapLoader.Listener
Constructor Summary
Table 927: Constructors in Adapter
Constructors
Adapter ()
Method Summary
Table 928: Methods in Adapter
Methods
public void onCheckForUpdateComplete (boolean updateAvailable, String currentMapVersion, String
newestMapVersion, ResultCode resultCode)
A callback indicating that the checkForMapDataUpdate() method has completed its operation.
This method overrides odml.MapLoader.Listener.onCheckForUpdateComplete(boolean, String, String, MapLoader,
ResultCode)
public void onGetMapPackagesComplete (MapPackage rootMapPackage, ResultCode resultCode)
A callback indicating that the getMapPackages() method has completed its operation.
This method overrides odml.MapLoader.Listener.onGetMapPackagesComplete(MapPackage, MapLoader, ResultCode)
public void onInstallMapPackagesComplete (MapPackage rootMapPackage, ResultCode resultCode)
A callback indicating that the installMapPackages(List) method has completed its operation.
This method overrides odml.MapLoader.Listener.onInstallMapPackagesComplete(MapPackage, MapLoader, ResultCode)
public void onInstallationSize (long diskSize, long networkSize)
A callback triggered during certain MapLoader operations to indicate the size, in KB, of the map data which is to be
downloaded and stored for that particular operation.
This method overrides odml.MapLoader.Listener.onInstallationSize(long, long)
public void onPerformMapDataUpdateComplete (MapPackage rootMapPackage, ResultCode resultCode)
A callback indicating that the performMapDataUpdate() method has completed its operation.
This method overrides odml.MapLoader.Listener.onPerformMapDataUpdateComplete(MapPackage, MapLoader, ResultCode)
public void onProgress (int progress)
A callback triggered during certain MapLoader operations to indicate the progress for that particular operation, a
percentage value in the [0..100] range.
This method overrides odml.MapLoader.Listener.onProgress(int)
public void onUninstallMapPackagesComplete (MapPackage rootMapPackage, ResultCode resultCode)
A callback indicating that the uninstallMapPackages(List) method has completed its operation.
This method overrides odml.MapLoader.Listener.onUninstallMapPackagesComplete(MapPackage, MapLoader, ResultCode)
HERE Android SDK Developer's Guide
API Reference
1528
Class Details
Default implementation for the MapLoader.Listener interface. Clients may use this abstract class and
overload specific methods to have a smaller code footprint.
See also:
MapLoader.Listener
Constructor Details
Adapter ()
Method Details
public void onCheckForUpdateComplete (boolean updateAvailable, String
currentMapVersion, String newestMapVersion, ResultCode resultCode)
A callback indicating that the checkForMapDataUpdate() method has completed its operation.
This method overrides odml.MapLoader.Listener.onCheckForUpdateComplete(boolean, String, String,
MapLoader, ResultCode)
Parameters:
updateAvailable
currentMapVersion
newestMapVersion
resultCode
public void onGetMapPackagesComplete (MapPackage rootMapPackage, ResultCode
resultCode)
A callback indicating that the getMapPackages() method has completed its operation.
This method overrides odml.MapLoader.Listener.onGetMapPackagesComplete(MapPackage, MapLoader,
ResultCode)
Parameters:
rootMapPackage
resultCode
public void onInstallMapPackagesComplete (MapPackage rootMapPackage,
ResultCode resultCode)
A callback indicating that the installMapPackages(List) method has completed its operation.
This method overrides odml.MapLoader.Listener.onInstallMapPackagesComplete(MapPackage, MapLoader,
ResultCode)
HERE Android SDK Developer's Guide
API Reference
1529
Parameters:
rootMapPackage
resultCode
public void onInstallationSize (long diskSize, long networkSize)
A callback triggered during certain MapLoader operations to indicate the size, in KB, of the map data which is
to be downloaded and stored for that particular operation.
This method overrides odml.MapLoader.Listener.onInstallationSize(long, long)
Parameters:
diskSize
networkSize
public void onPerformMapDataUpdateComplete (MapPackage rootMapPackage,
ResultCode resultCode)
A callback indicating that the performMapDataUpdate() method has completed its operation.
This method overrides odml.MapLoader.Listener.onPerformMapDataUpdateComplete(MapPackage,
MapLoader, ResultCode)
Parameters:
rootMapPackage
resultCode
public void onProgress (int progress)
A callback triggered during certain MapLoader operations to indicate the progress for that particular
operation, a percentage value in the [0..100] range.
This method overrides odml.MapLoader.Listener.onProgress(int)
Parameters:
progress
public void onUninstallMapPackagesComplete (MapPackage rootMapPackage,
ResultCode resultCode)
A callback indicating that the uninstallMapPackages(List) method has completed its operation.
This method overrides odml.MapLoader.Listener.onUninstallMapPackagesComplete(MapPackage,
MapLoader, ResultCode)
Parameters:
rootMapPackage
resultCode
HERE Android SDK Developer's Guide
API Reference
1530
MapPackageAtCoordinateListener
The interface MapPackageAtCoordinateListener is a member of com.here.android.mpa.odml.MapLoader.
Interface Summary
public static abstract interface MapLoader.MapPackageAtCoordinateListener
Represents a listener interface with a callback which gets invoked upon package retrieval.
[For complete information, see the section Interface Details]
Method Summary
Table 929: Methods in MapPackageAtCoordinateListener
Methods
public abstract void onGetMapPackageAtCoordinateComplete (MapPackage mapPackage, GeoCoordinate
coordinate, ResultCode resultCode)
A callback indicating that the getMapPackageAtCoordinate(GeoCoordinate) method has completed its operation.
Interface Details
Represents a listener interface with a callback which gets invoked upon package retrieval.
Method Details
public abstract void onGetMapPackageAtCoordinateComplete (MapPackage
mapPackage, GeoCoordinate coordinate, ResultCode resultCode)
A callback indicating that the getMapPackageAtCoordinate(GeoCoordinate) method has completed its
operation.
Parameters:
mapPackage
The found MapPackage. Can be null if the ResultCode does not indicate success.
coordinate
The coordinates used to locate the package.
resultCode
A ResultCode for the operation
ResultCode
The enumeration ResultCode is a member of com.here.android.mpa.odml.MapLoader.
HERE Android SDK Developer's Guide
API Reference
1531
Enumeration Summary
public static final enumeration MapLoader.ResultCode
extends java.lang.Enum, java.lang.Object
Represents values describing the status of a MapLoader operation.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 930: Enum Constants in ResultCode
Fields
public static final ResultCode OPERATION_SUCCESSFUL
The MapLoader operation completed without error.
public static final ResultCode INVALID_PARAMETERS
The MapLoader operation was called with invalid parameters.
public static final ResultCode NO_CONNECTIVITY
The MapLoader operation could not be performed due to lack of Internet connectivity.
public static final ResultCode NO_UPDATE_TO_PERFORM
The performMapDataUpdate() operation was invoked but there is no update to perform.
public static final ResultCode NOT_ENOUGH_DISK_SPACE
The disk does not have the space required to perform the requested MapLoader operation.
public static final ResultCode OPERATION_CANCELLED
The MapLoader operation was cancelled by a call to cancelCurrentOperation().
public static final ResultCode SERVER_NOT_RESPONDING
The MapLoader operation could not be completed because the map data server is not responding.
public static final ResultCode UNEXPECTED_ERROR
An unexpected error occurred while processing the MapLoader request.
public static final ResultCode FATAL_ERROR
An error which is non-recoverable in the current process instance has occurred.
public static final ResultCode OPERATION_BUSY
The MapLoader operation could not be completed because either the map data server or the MapLoader is busy with an
operation in another process.
public static final ResultCode OPERATION_NOT_ALLOWED
Access to this operation is denied.
HERE Android SDK Developer's Guide
API Reference
1532
Method Summary
Table 931: Methods in ResultCode
Methods
public static ResultCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapLoader.ResultCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the status of a MapLoader operation. Each status is returned through the
MapLoader.Listener interface.
Enum Constant Details
public static final ResultCode OPERATION_SUCCESSFUL
The MapLoader operation completed without error.
public static final ResultCode INVALID_PARAMETERS
The MapLoader operation was called with invalid parameters.
public static final ResultCode NO_CONNECTIVITY
The MapLoader operation could not be performed due to lack of Internet connectivity.
public static final ResultCode NO_UPDATE_TO_PERFORM
The performMapDataUpdate() operation was invoked but there is no update to perform.
public static final ResultCode NOT_ENOUGH_DISK_SPACE
The disk does not have the space required to perform the requested MapLoader operation.
public static final ResultCode OPERATION_CANCELLED
The MapLoader operation was cancelled by a call to cancelCurrentOperation().
public static final ResultCode SERVER_NOT_RESPONDING
HERE Android SDK Developer's Guide
API Reference
1533
The MapLoader operation could not be completed because the map data server is not responding. The user
should verify internet connectivity (e.g. by browsing to a webpage) and try again later.
public static final ResultCode UNEXPECTED_ERROR
An unexpected error occurred while processing the MapLoader request.
public static final ResultCode FATAL_ERROR
An error which is non-recoverable in the current process instance has occurred. To recover it may be
necessary to have the user restart the process (swipe, force quit, ...)
public static final ResultCode OPERATION_BUSY
The MapLoader operation could not be completed because either the map data server or the MapLoader is
busy with an operation in another process. Please retry the operation.
public static final ResultCode OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
Method Details
public static ResultCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapLoader.ResultCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MapPackage
The class MapPackage is a member of com.here.android.mpa.odml .
Class Summary
public final class MapPackage
HERE Android SDK Developer's Guide
API Reference
1534
extends java.lang.Object
Represents a model for obtaining information about offline map packages that can be installed using a
MapLoader.
[For complete information, see the section Class Details]
Nested Class Summary
Table 932: Nested Classes in MapPackage
Nested Classes
public static final enumeration MapPackage.InstallationState
Represents values describing the installation state of the MapPackage
public static final enumeration MapPackage.SelectableDataGroup
The data groups which may be optionally selected for offline map downloads.
Method Summary
Table 933: Methods in MapPackage
Methods
public java.util.List <MapPackage> getChildren ()
Gets the children of the MapPackage , if it has any.
public String getEnglishTitle ()
Gets the English title of the MapPackage .
public int getId ()
Gets the unique identifier for the MapPackage , used for MapLoader operations involving installation or uninstallation.
public InstallationState getInstallationState ()
Gets the current installation state of the MapPackage on the device
public MapPackage getParent ()
Gets the parent of the MapPackage , if it has one.
public long getSize ()
Gets the maximum size, in KB, of the MapPackage , representing the maximum amount of space it will take up on disk.
public String getTitle ()
Gets the title of the MapPackage .
Class Details
Represents a model for obtaining information about offline map packages that can be installed using a
MapLoader. Map packages are arranged in a tree hierarchy, which is represented in the parent and children
data of the MapPackage model.
HERE Android SDK Developer's Guide
API Reference
1535
Note: the root map package is the world map. If a MapPackage having children is installed, each child will
also be installed, allowing the installation of entire regions.
Method Details
public java.util.List <MapPackage> getChildren ()
Gets the children of the MapPackage , if it has any. The returned List is unmodifiable.
Returns:
The java.util.Collections#unmodifiableList(List) of MapPackage children if any exist, an
empty list otherwise.
public String getEnglishTitle ()
Gets the English title of the MapPackage .
Returns:
The title in English.
public int getId ()
Gets the unique identifier for the MapPackage , used for MapLoader operations involving installation or
uninstallation.
Returns:
The ID for the MapPackage
See also:
installMapPackages(List<Integer>)
uninstallMapPackages(List<Integer>)
public InstallationState getInstallationState ()
Gets the current installation state of the MapPackage on the device
Returns:
MapPackage.InstallationState
public MapPackage getParent ()
Gets the parent of the MapPackage , if it has one.
Returns:
The MapPackage parent if one exists, null otherwise
HERE Android SDK Developer's Guide
API Reference
1536
public long getSize ()
Gets the maximum size, in KB, of the MapPackage , representing the maximum amount of space it will take
up on disk.
Note: If this is the first MapPackage installed, it will take up the amount of disk space returned by this
method. However, if other MapPackage s have already been installed, the amount of disk space this
package will take up is considerably less than the size value returned by this method. This is because
there is common data between MapPackage s which will be installed upon first installation. To get an
accurate representation of the disk space which will be used for a given installation operation use the
onInstallationSize(long, long) callback.
Returns:
The MapPackage size
public String getTitle ()
Gets the title of the MapPackage .
Returns:
The title (the specific language depends on the device Locale )
InstallationState
The enumeration InstallationState is a member of com.here.android.mpa.odml.MapPackage.
Enumeration Summary
public static final enumeration MapPackage.InstallationState
extends java.lang.Enum, java.lang.Object
Represents values describing the installation state of the MapPackage
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 934: Enum Constants in InstallationState
Fields
public static final InstallationState INSTALLED
The MapPackage is installed
public static final InstallationState PARTIALLY_INSTALLED
The MapPackage is partially installed when not all the required data is present.
HERE Android SDK Developer's Guide
API Reference
1537
Fields
public static final InstallationState NOT_INSTALLED
The MapPackage is not installed
Method Summary
Table 935: Methods in InstallationState
Methods
public static InstallationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapPackage.InstallationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the installation state of the MapPackage
Enum Constant Details
public static final InstallationState INSTALLED
The MapPackage is installed
public static final InstallationState PARTIALLY_INSTALLED
The MapPackage is partially installed when not all the required data is present. Installing the missing data
can be achieved by way of the performMapDataUpdate() or installMapPackages(List) APIs.
public static final InstallationState NOT_INSTALLED
The MapPackage is not installed
Method Details
public static InstallationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
1538
public static MapPackage.InstallationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SelectableDataGroup
The enumeration SelectableDataGroup is a member of com.here.android.mpa.odml.MapPackage.
Enumeration Summary
public static final enumeration MapPackage.SelectableDataGroup
extends java.lang.Enum, java.lang.Object
The data groups which may be optionally selected for offline map downloads.
[For complete information, see the section Enumeration Details]
See also:
selectDataGroup(SelectableDataGroup)
Enum Constant Summary
Table 936: Enum Constants in SelectableDataGroup
Fields
public static final SelectableDataGroup LinkGDBIdPvid
Mapping between GDBId and PVId.
public static final SelectableDataGroup PhoneticNames
Phonemes used for TTS guidance.
public static final SelectableDataGroup RealisticViews16x9
Images for used with the navigation realistic view feature, with 16x9 aspect ratio.
public static final SelectableDataGroup RealisticViews3x5
Images for used with the navigation realistic view feature, with 3x5 aspect ratio.
public static final SelectableDataGroup RealisticViews4x3
Images for used with the navigation realistic view feature, with 4x3 aspect ratio.
public static final SelectableDataGroup RealisticViews5x3
Images for used with the navigation realistic view feature, with 5x3 aspect ratio.
public static final SelectableDataGroup ADAS
Height curvature and slope of shape points.
HERE Android SDK Developer's Guide
API Reference
1539
Method Summary
Table 937: Methods in SelectableDataGroup
Methods
public int getId ()
Unique identifier of the data group guaranteed to stay the same throughout map updates.
public static SelectableDataGroup valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static MapPackage.SelectableDataGroup[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The data groups which may be optionally selected for offline map downloads. The default data
group selection state is: Group Selected PhoneticNames yes RealisticViews16x9 yes
RealisticViews3x5 yes RealisticViews4x3 yes RealisticViews5x3 yes LinkGDBIdPvid
yes ADAS no Data groups not selected if access to this operation is denied. Contact your HERE
representative for more information.
See also:
selectDataGroup(SelectableDataGroup)
Enum Constant Details
public static final SelectableDataGroup LinkGDBIdPvid
Mapping between GDBId and PVId.
public static final SelectableDataGroup PhoneticNames
Phonemes used for TTS guidance.
public static final SelectableDataGroup RealisticViews16x9
Images for used with the navigation realistic view feature, with 16x9 aspect ratio.
public static final SelectableDataGroup RealisticViews3x5
Images for used with the navigation realistic view feature, with 3x5 aspect ratio.
public static final SelectableDataGroup RealisticViews4x3
Images for used with the navigation realistic view feature, with 4x3 aspect ratio.
HERE Android SDK Developer's Guide
API Reference
1540
public static final SelectableDataGroup RealisticViews5x3
Images for used with the navigation realistic view feature, with 5x3 aspect ratio.
public static final SelectableDataGroup ADAS
Height curvature and slope of shape points.
Method Details
public int getId ()
Unique identifier of the data group guaranteed to stay the same throughout map updates.
Returns:
id of the MapPackage.SelectableDataGroup
public static SelectableDataGroup valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static MapPackage.SelectableDataGroup[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
pde
The package pde is a member of com.here.android.mpa.
Package Summary
pde
The package pde (Platform Data Extension) provides classes, interfaces, and enumerations that allow your
application to easily access Platform Data Extension REST API.
Package Details
HERE Android SDK Developer's Guide
API Reference
1541
The package pde (Platform Data Extension) provides classes, interfaces, and enumerations that allow your
application to easily access Platform Data Extension REST API.
PlatformDataItem
The class PlatformDataItem is a member of com.here.android.mpa.pde .
Class Summary
public class PlatformDataItem
implements java.util.Map
extends java.lang.Object
Single record from the Platform Data Extension request for a given layer.
[For complete information, see the section Class Details]
Nested Class Summary
Table 938: Nested Classes in PlatformDataItem
Nested Classes
public static final enumeration PlatformDataItem.ConditionType
Type of the condition entity as described by the CONDITION_TYPE field.
public static final enumeration PlatformDataItem.VehicleType
The possible vehicle types that are allowed on a link as described by the VEHICLE_TYPES field.
Method Summary
Table 939: Methods in PlatformDataItem
Methods
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean containsKey (Object key)
Returns whether this PlatformDataItem contains the specified key.
public boolean containsValue (Object value)
Returns whether this PlatformDataItem contains the specified value.
public Set entrySet ()
Returns a Set containing all of the mappings in this PlatformDataItem .
public boolean equals (Object o)
Compares the argument to the receiver, and returns true if the specified object is a PlatformDataItem and both
PlatformDataItem s contain the same mappings.
HERE Android SDK Developer's Guide
API Reference
1542
Methods
public Map extract ()
Extracts the underlying raw data to a regular Map object.
public String get (Object key)
Returns the value of the mapping with the specified key.
public int getAverageHeight ()
DTM_AVG_HEIGHT data.
public ConditionType getConditionType ()
CONDITION_TYPE data.
public java.util.List <GeoCoordinate> getCoordinates ()
LAT and LON data.
public String getLinkId ()
LINK_ID data.
public String[] getLinkIds ()
LINK_IDS data.
public float getLinkLength ()
LINK_LENGTH data.
public java.util.EnumSet <VehicleType> getVehicleTypes ()
VEHICLE_TYPES data.
public int hashCode ()
Returns an integer hash code for the receiver.
public boolean isEmpty ()
Returns whether this item is empty.
public Set keySet ()
Returns a set of the keys contained in this PlatformDataItem .
public String put (String key, String value)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public void putAll (Map map)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public String remove (Object key)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public int size ()
Returns the number of mappings in this PlatformDataItem .
HERE Android SDK Developer's Guide
API Reference
1543
Methods
public Collection values ()
Returns a Collection of the values contained in this PlatformDataItem .
Class Details
Single record from the Platform Data Extension request for a given layer. Implements Map interface, where
the key is the attribute name and the value is the value of that attribute. This class is immutable.
To avoid overhead when dealing with large data sets, all the items returned by this class are dynamically
created on demand. Due to that fact this object keeps reference to its parent object. If you require normal
Java behavior, you can obtain regular Java collection of underlying data with extract() method.
Method Details
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
public boolean containsKey (Object key)
Returns whether this PlatformDataItem contains the specified key.
Parameters:
key
the key to search for.
Returns:
true if this item contains the specified key, false otherwise.
public boolean containsValue (Object value)
Returns whether this PlatformDataItem contains the specified value.
Parameters:
value
the value to search for.
Returns:
true if this item contains the specified value, false otherwise.
public Set entrySet ()
Returns a Set containing all of the mappings in this PlatformDataItem . Each mapping is an instance of
Map.Entry.
HERE Android SDK Developer's Guide
API Reference
1544
Returns:
a set of the mappings
public boolean equals (Object o)
Compares the argument to the receiver, and returns true if the specified object is a PlatformDataItem
and both PlatformDataItem s contain the same mappings.
Parameters:
o
the Object to compare with this Object.
Returns:
boolean true if the Object is the same as this Object false if it is different from this Object.
See also:
hashCode()
entrySet()
public Map extract ()
Extracts the underlying raw data to a regular Map object.
All the items returned by this class are dynamically created on demand. Due to that fact this object keeps
reference to its parent object. If you require normal Java behavior, you can convert this class to regular Java
collection with this method.
Returns:
Content of the PlatformDataItem converted to regular Java collection.
public String get (Object key)
Returns the value of the mapping with the specified key.
Parameters:
key
the key.
Returns:
the value of the mapping with the specified key, or null if no mapping for the specified key is found.
public int getAverageHeight ()
DTM_AVG_HEIGHT data.
The average height [centimeters above WGS84 ellipsoid] along the link.
HERE Android SDK Developer's Guide
API Reference
1545
Returns:
Average height in centimeters. Integer.MIN_VALUE if not available.
public ConditionType getConditionType ()
CONDITION_TYPE data.
Returns traffic sign condition type. Valid only for TRAFFIC_SIGN_FCx layer data.
Returns:
ConditionType instance.
public java.util.List <GeoCoordinate> getCoordinates ()
LAT and LON data.
Latitude and longitude coordinates [10^-5 degree WGS84] along the polyline or of the reference node and the
non reference node. Comma separated. Each value is relative to the previous.
Returns:
List containing parsed coordinates.
public String getLinkId ()
LINK_ID data.
Positive 64 bit Integer that globally identifies the road link, also across map releases. Link IDs are never
reused.
Returns:
String value of the link ID.
public String[] getLinkIds ()
LINK_IDS data.
Comma separated list of Permanent link IDs that describe a route path. A negative sign means that this link
was driven towards reference node. If the list contains only one link, then a 'B' prefix tells that it applies
for both driving directions. Each link ID is a positive 64 bit Integer that globally identifies the road link, also
across map releases. Link IDs are never reused.
Returns:
Array of link IDS or null if not available.
public float getLinkLength ()
LINK_LENGTH data.
HERE Android SDK Developer's Guide
API Reference
1546
The link length in meters. This method returns the whole link length, no matter whether the link spans across
several tiles. The link length is computed by straight lines between subsequent shape points, no splines or
other smoothing functions or geodesic computations are used.
Returns:
Link length in meters. Float.MIN_VALUE if not available.
public java.util.EnumSet <VehicleType> getVehicleTypes ()
VEHICLE_TYPES data.
Access Characteristics that identify the vehicle types that are allowed on a link, allowed on a lane or to which
condition applies.
Returns:
Set of allowed vehicle types, null if not available.
public int hashCode ()
Returns an integer hash code for the receiver. Object s which are equal return the same value for this
method.
Returns:
the receiver's hash.
See also:
equals(Object)
public boolean isEmpty ()
Returns whether this item is empty.
Returns:
true if this item has no elements, false otherwise.
See also:
size()
public Set keySet ()
Returns a set of the keys contained in this PlatformDataItem .
Returns:
a set of the keys.
public String put (String key, String value)
HERE Android SDK Developer's Guide
API Reference
1547
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
key
ignored
value
ignored
public void putAll (Map map)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
map
ignored
public String remove (Object key)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
key
ignored
public int size ()
Returns the number of mappings in this PlatformDataItem .
Returns:
the number of mappings in this PlatformDataItem.
public Collection values ()
Returns a Collection of the values contained in this PlatformDataItem .
Returns:
a collection of the values contained in this item.
HERE Android SDK Developer's Guide
API Reference
1548
ConditionType
The enumeration ConditionType is a member of com.here.android.mpa.pde.PlatformDataItem.
Enumeration Summary
public static final enumeration PlatformDataItem.ConditionType
extends java.lang.Enum, java.lang.Object
Type of the condition entity as described by the CONDITION_TYPE field.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 940: Enum Constants in ConditionType
Fields
public static final ConditionType UNDEFINED
Condition type is undefined.
public static final ConditionType TOLL_STRUCTURE
Indicates toll structure (applicable to TOLL_BOOTH_FCx and TURN_RESTR_FCx layers).
public static final ConditionType CONSTRUCTION_STATUS_CLOSED
Indicates construction status closed (applicable to TURN_RESTR_FCx layer).
public static final ConditionType GATES
Indicates gates (applicable to TURN_RESTR_FCx layer).
public static final ConditionType DIRECTION_OF_TRAVEL
Indicates direction of travel (applicable to TURN_RESTR_FCx layer).
public static final ConditionType RESTRICTED_DRIVING_MANOEUVRE
Indicates restricted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType ACCESS_RESTRICTION
Indicates access restriction (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SPECIAL_EXPLICATION
Indicates special explication (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SPECIAL_SPEED_SITUATION
Indicates special speed situation (applicable to TURN_RESTR_FCx layer).
public static final ConditionType VARIABLE_SPEED_SIGN
Indicates variable speed sign (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType USAGE_FEE_REQUIRED
Indicates usage fee required (applicable to TOLL_LINK_FCx and TURN_RESTR_FCx layers).
HERE Android SDK Developer's Guide
API Reference
1549
Fields
public static final ConditionType LANE_TRAVERSAL
Indicates lane traversal (applicable to TURN_RESTR_FCx layer).
public static final ConditionType THROUGH_ROUTE
Indicates through route (applicable to TURN_RESTR_FCx layer).
public static final ConditionType TRAFFIC_SIGNAL
Indicates traffic signal (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRAFFIC_SIGN
Indicates traffic sign (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType RAILWAY_CROSSING
Indicates railway crossing (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType NO_OVERTAKING
Indicates no overtaking (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType JUNCTION_VIEW
Indicates junction view (applicable to TURN_RESTR_FCx layer).
public static final ConditionType PROTECTED_OVERTAKING
Indicates protected overtaking (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType EVACUATION_ROUTE
Indicates evacuation route (applicable to TURN_RESTR_FCx layer).
public static final ConditionType TRANSPORT_ACCESS_RESTRICTION
Indicates transport access restriction (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_SPECIAL_SPEED_SITUATION
Indicates transport special speed situation (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_RDM
Indicates transport RDM (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_PREFERRED_ROUTE
Indicates transport preferred route (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType CALCULATED_RESTRICTED_DRIVING_MANOEUVRE
Indicates calculated restricted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType PARKING_INFORMATION
Indicates parking information (applicable to TURN_RESTR_FCx layer).
public static final ConditionType ENVIRONMENTAL_ZONE
Indicates environmental zone (applicable to TURN_RESTR_FCx layer).
public static final ConditionType BLACKSPOT
Indicates blackspot (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
HERE Android SDK Developer's Guide
API Reference
1550
Fields
public static final ConditionType PERMITTED_DRIVING_MANOEUVRE
Indicates permitted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType VARIABLE_SPEED_LIMIT
Indicates variable speed limit (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SHORT_CONSTRUCTION_WARNING
Indicates short construction warning (applicable to TURN_RESTR_FCx layer).
Method Summary
Table 941: Methods in ConditionType
Methods
public static ConditionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PlatformDataItem.ConditionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Type of the condition entity as described by the CONDITION_TYPE field.
Enum Constant Details
public static final ConditionType UNDEFINED
Condition type is undefined.
public static final ConditionType TOLL_STRUCTURE
Indicates toll structure (applicable to TOLL_BOOTH_FCx and TURN_RESTR_FCx layers).
public static final ConditionType CONSTRUCTION_STATUS_CLOSED
Indicates construction status closed (applicable to TURN_RESTR_FCx layer).
public static final ConditionType GATES
Indicates gates (applicable to TURN_RESTR_FCx layer).
public static final ConditionType DIRECTION_OF_TRAVEL
Indicates direction of travel (applicable to TURN_RESTR_FCx layer).
HERE Android SDK Developer's Guide
API Reference
1551
public static final ConditionType RESTRICTED_DRIVING_MANOEUVRE
Indicates restricted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType ACCESS_RESTRICTION
Indicates access restriction (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SPECIAL_EXPLICATION
Indicates special explication (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SPECIAL_SPEED_SITUATION
Indicates special speed situation (applicable to TURN_RESTR_FCx layer).
public static final ConditionType VARIABLE_SPEED_SIGN
Indicates variable speed sign (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType USAGE_FEE_REQUIRED
Indicates usage fee required (applicable to TOLL_LINK_FCx and TURN_RESTR_FCx layers).
public static final ConditionType LANE_TRAVERSAL
Indicates lane traversal (applicable to TURN_RESTR_FCx layer).
public static final ConditionType THROUGH_ROUTE
Indicates through route (applicable to TURN_RESTR_FCx layer).
public static final ConditionType TRAFFIC_SIGNAL
Indicates traffic signal (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRAFFIC_SIGN
Indicates traffic sign (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType RAILWAY_CROSSING
HERE Android SDK Developer's Guide
API Reference
1552
Indicates railway crossing (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType NO_OVERTAKING
Indicates no overtaking (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType JUNCTION_VIEW
Indicates junction view (applicable to TURN_RESTR_FCx layer).
public static final ConditionType PROTECTED_OVERTAKING
Indicates protected overtaking (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType EVACUATION_ROUTE
Indicates evacuation route (applicable to TURN_RESTR_FCx layer).
public static final ConditionType TRANSPORT_ACCESS_RESTRICTION
Indicates transport access restriction (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_SPECIAL_SPEED_SITUATION
Indicates transport special speed situation (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_RDM
Indicates transport RDM (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType TRANSPORT_PREFERRED_ROUTE
Indicates transport preferred route (applicable to TRUCK_RESTR_FCx and TURN_RESTR_FCx layers).
public static final ConditionType CALCULATED_RESTRICTED_DRIVING_MANOEUVRE
Indicates calculated restricted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType PARKING_INFORMATION
Indicates parking information (applicable to TURN_RESTR_FCx layer).
HERE Android SDK Developer's Guide
API Reference
1553
public static final ConditionType ENVIRONMENTAL_ZONE
Indicates environmental zone (applicable to TURN_RESTR_FCx layer).
public static final ConditionType BLACKSPOT
Indicates blackspot (applicable to TRAFFIC_SIGN_FCx and TURN_RESTR_FCx layers).
public static final ConditionType PERMITTED_DRIVING_MANOEUVRE
Indicates permitted driving manoeuvre (applicable to TURN_RESTR_FCx layer).
public static final ConditionType VARIABLE_SPEED_LIMIT
Indicates variable speed limit (applicable to TURN_RESTR_FCx layer).
public static final ConditionType SHORT_CONSTRUCTION_WARNING
Indicates short construction warning (applicable to TURN_RESTR_FCx layer).
Method Details
public static ConditionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PlatformDataItem.ConditionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VehicleType
The enumeration VehicleType is a member of com.here.android.mpa.pde.PlatformDataItem.
Enumeration Summary
public static final enumeration PlatformDataItem.VehicleType
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1554
The possible vehicle types that are allowed on a link as described by the VEHICLE_TYPES field.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 942: Enum Constants in VehicleType
Fields
public static final VehicleType UNDEFINED
Undefined.
public static final VehicleType AUTOMOBILES
Automobiles (aka cars).
public static final VehicleType BUSES
Buses.
public static final VehicleType TAXIS
Taxis (aka cabs).
public static final VehicleType CARPOOLS
Carpools (as in car sharing, not pools in cars).
public static final VehicleType PEDESTRIANS
Pedestrians (aka human beings).
public static final VehicleType TRUCKS
Trucks.
public static final VehicleType DELIVERIES
Deliveries (aka vehicles that deliver stuff).
public static final VehicleType EMERGENCY_VEHICLES
Emergency vehicles.
public static final VehicleType THROUGH_TRAFFIC
Through traffic.
public static final VehicleType MOTORCYCLES
Motorcycles.
public static final VehicleType ROAD_TRAINS
Road trains (aka not actual trains).
HERE Android SDK Developer's Guide
API Reference
1555
Method Summary
Table 943: Methods in VehicleType
Methods
public static VehicleType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PlatformDataItem.VehicleType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The possible vehicle types that are allowed on a link as described by the VEHICLE_TYPES field.
Enum Constant Details
public static final VehicleType UNDEFINED
Undefined.
public static final VehicleType AUTOMOBILES
Automobiles (aka cars).
public static final VehicleType BUSES
Buses.
public static final VehicleType TAXIS
Taxis (aka cabs).
public static final VehicleType CARPOOLS
Carpools (as in car sharing, not pools in cars).
public static final VehicleType PEDESTRIANS
Pedestrians (aka human beings).
public static final VehicleType TRUCKS
Trucks.
HERE Android SDK Developer's Guide
API Reference
1556
public static final VehicleType DELIVERIES
Deliveries (aka vehicles that deliver stuff).
public static final VehicleType EMERGENCY_VEHICLES
Emergency vehicles.
public static final VehicleType THROUGH_TRAFFIC
Through traffic.
public static final VehicleType MOTORCYCLES
Motorcycles.
public static final VehicleType ROAD_TRAINS
Road trains (aka not actual trains).
Method Details
public static VehicleType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PlatformDataItem.VehicleType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
PlatformDataItemCollection
The class PlatformDataItemCollection is a member of com.here.android.mpa.pde .
Class Summary
public class PlatformDataItemCollection
implements java.util.List
HERE Android SDK Developer's Guide
API Reference
1557
extends java.lang.Object
Collection of PlatformDataItem items.
[For complete information, see the section Class Details]
Method Summary
Table 944: Methods in PlatformDataItemCollection
Methods
public void add (int location, PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean add (PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean addAll (int location, java.util.Collection <? extends
com.here.android.mpa.pde.PlatformDataItem> collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean addAll (java.util.Collection <? extends
com.here.android.mpa.pde.PlatformDataItem> collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean contains (Object object)
Tests whether this PlatformDataItemCollection contains the specified object.
public boolean containsAll (Collection collection)
Tests whether this PlatformDataItemCollection contains all objects contained in the specified collection.
public boolean equals (Object o)
Compares the argument to the receiver, and returns true if the specified object is a PlatformDataItemCollection and
both PlatformDataItemCollection s contain the same mappings.
public List extract ()
Extracts the underlying raw data to a List of Map objects, each of which corresponds to a single record returned by Platform
Data Extension request, which maps attribute name to its value.
public PlatformDataItem get (int location)
Returns the element at the specified location in this PlatformDataItemCollection .
public int hashCode ()
Returns an integer hash code for the receiver.
HERE Android SDK Developer's Guide
API Reference
1558
Methods
public int indexOf (Object object)
Searches this PlatformDataItemCollection for the specified object and returns the index of the first occurrence.
public boolean isEmpty ()
Returns whether this PlatformDataItemCollection contains no elements.
public java.util.Iterator <PlatformDataItem> iterator ()
Returns an iterator on the elements of this PlatformDataItemCollection .
public int lastIndexOf (Object object)
Searches this PlatformDataItemCollection for the specified object and returns the index of the last occurrence.
public java.util.ListIterator <PlatformDataItem> listIterator ()
Returns a PlatformDataItemCollection iterator on the elements of this PlatformDataItemCollection .
public java.util.ListIterator <PlatformDataItem> listIterator (int location)
Returns a list iterator on the elements of this PlatformDataItemCollection .
public PlatformDataItem remove (int location)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean remove (Object object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean removeAll (Collection collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean retainAll (Collection collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public PlatformDataItem set (int location, PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public int size ()
Returns the number of elements in this PlatformDataItemCollection .
public java.util.List <PlatformDataItem> subList (int start, int end)
Returns a PlatformDataItemCollection of the specified portion of this PlatformDataItemCollection from the
given start index to the end index minus one.
public Object[] toArray ()
Returns an array containing all elements contained in this PlatformDataItemCollection .
public T[] toArray (T[] array)
Returns an array containing all elements contained in this PlatformDataItemCollection .
HERE Android SDK Developer's Guide
API Reference
1559
Class Details
Collection of PlatformDataItem items. This class implements List interface. Additionally contains
methods useful for manipulating the data (filtering, combining etc.).
To avoid overhead when dealing with large data sets, all the items returned by this class and its children are
dynamically created on demand. Due to that fact this object and the child objects keep references to their
parent object. If you require normal Java behavior, you can obtain regular Java collection of underlying data
with extract() method.
Method Details
public void add (int location, PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
location
ignored
object
ignored
public boolean add (PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
object
ignored
public boolean addAll (int location, java.util.Collection <? extends
com.here.android.mpa.pde.PlatformDataItem> collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
location
ignored
collection
ignored
HERE Android SDK Developer's Guide
API Reference
1560
public boolean addAll (java.util.Collection <? extends
com.here.android.mpa.pde.PlatformDataItem> collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
collection
ignored
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
public boolean contains (Object object)
Tests whether this PlatformDataItemCollection contains the specified object.
Parameters:
object
the object to search for.
Returns:
true if object is an element of this PlatformDataItemCollection, false otherwise
public boolean containsAll (Collection collection)
Tests whether this PlatformDataItemCollection contains all objects contained in the specified
collection.
Parameters:
collection
the collection of objects
Returns:
true if all objects in the specified collection are elements of this PlatformDataItemCollection, false
otherwise.
public boolean equals (Object o)
Compares the argument to the receiver, and returns true if the specified object is a
PlatformDataItemCollection and both PlatformDataItemCollection s contain the same mappings.
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
1561
the Object to compare with this Object.
Returns:
boolean true if the Object is the same as this Object false if it is different from this Object.
See also:
hashCode()
public List extract ()
Extracts the underlying raw data to a List of Map objects, each of which corresponds to a single record
returned by Platform Data Extension request, which maps attribute name to its value.
All the items returned by this class and its children are dynamically created on demand. Due to that fact this
object and the child objects keep references to their parent object. If you require normal Java behavior, you
can convert this class to regular Java collection with this method.
Returns:
Content of the PlatformDataItemCollection converted to regular Java collection.
public PlatformDataItem get (int location)
Returns the element at the specified location in this PlatformDataItemCollection .
Parameters:
location
the index of the element to return.
Returns:
the element at the specified location.
Throws:
IndexOutOfBoundsException
if location is smaller than 0 or location is greater or equal to size()
public int hashCode ()
Returns an integer hash code for the receiver. Object s which are equal return the same value for this
method.
Returns:
the receiver's hash.
See also:
equals(Object)
HERE Android SDK Developer's Guide
API Reference
1562
public int indexOf (Object object)
Searches this PlatformDataItemCollection for the specified object and returns the index of the first
occurrence.
Parameters:
object
the object to search for.
Returns:
the index of the first occurrence of the object or -1 if the object was not found.
public boolean isEmpty ()
Returns whether this PlatformDataItemCollection contains no elements.
Returns:
true if this PlatformDataItemCollection has no elements, false otherwise.
See also:
size()
public java.util.Iterator <PlatformDataItem> iterator ()
Returns an iterator on the elements of this PlatformDataItemCollection . The elements are iterated in
the same order as they occur in the PlatformDataItemCollection .
Returns:
an iterator on the elements of this PlatformDataItemCollection.
See also:
java.util.Iterator
public int lastIndexOf (Object object)
Searches this PlatformDataItemCollection for the specified object and returns the index of the last
occurrence.
Parameters:
object
the object to search for.
Returns:
the index of the last occurrence of the object, or -1 if the object was not found.
HERE Android SDK Developer's Guide
API Reference
1563
public java.util.ListIterator <PlatformDataItem> listIterator ()
Returns a PlatformDataItemCollection iterator on the elements of this
PlatformDataItemCollection . The elements are iterated in the same order that they occur in the
PlatformDataItemCollection .
Returns:
a PlatformDataItemCollection iterator on the elements of this PlatformDataItemCollection
See also:
java.util.ListIterator
public java.util.ListIterator <PlatformDataItem> listIterator (int location)
Returns a list iterator on the elements of this PlatformDataItemCollection . The elements are iterated
in the same order as they occur in the PlatformDataItemCollection . The iteration starts at the
specified location.
Parameters:
location
the index at which to start the iteration.
Returns:
a list iterator on the elements of this PlatformDataItemCollection.
Throws:
IndexOutOfBoundsException
if location is less than 0 or greater than list size.
See also:
java.util.ListIterator
public PlatformDataItem remove (int location)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
location
ignored
public boolean remove (Object object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
HERE Android SDK Developer's Guide
API Reference
1564
Parameters:
object
ignored
public boolean removeAll (Collection collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
collection
ignored
public boolean retainAll (Collection collection)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
collection
ignored
public PlatformDataItem set (int location, PlatformDataItem object)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
location
ignored
object
ignored
Throws:
UnsupportedOperationException
public int size ()
Returns the number of elements in this PlatformDataItemCollection .
Returns:
the number of elements in this PlatformDataItemCollection.
HERE Android SDK Developer's Guide
API Reference
1565
public java.util.List <PlatformDataItem> subList (int start, int end)
Returns a PlatformDataItemCollection of the specified portion of this
PlatformDataItemCollection from the given start index to the end index minus one.
Parameters:
start
the index at which to start the sublist.
end
the index one past the end of the sublist.
Returns:
a list of a portion of this PlatformDataItemCollection.
Throws:
IndexOutOfBoundsException
if start is smaller than 0 and start is grater than end, or if end greater than size()
public Object[] toArray ()
Returns an array containing all elements contained in this PlatformDataItemCollection .
Returns:
an array of the elements from this PlatformDataItemCollection.
public T[] toArray (T[] array)
Returns an array containing all elements contained in this PlatformDataItemCollection . If the
specified array is large enough to hold the elements, the specified array is used, otherwise an array of the
same type is created. If the specified array is used and is larger than this PlatformDataItemCollection ,
the array element following the collection elements is set to null.
Parameters:
array
the array.
Returns:
an array of the elements from this PlatformDataItemCollection.
Throws:
ArrayStoreException
if the type of an element in this PlatformDataItemCollection cannot be stored in the type of the
specified array.
HERE Android SDK Developer's Guide
API Reference
1566
PlatformDataRequest
The class PlatformDataRequest is a member of com.here.android.mpa.pde .
Class Summary
public final class PlatformDataRequest
extends java.lang.Object
Runs the Platform Data Extension request with the given parameters.
[For complete information, see the section Class Details]
Nested Class Summary
Table 945: Nested Classes in PlatformDataRequest
Nested Classes
public static class PlatformDataRequest.Error
Represents error reported by the Platform Data Extension server.
public static abstract interface PlatformDataRequest.Listener
Represents an event listener that reports information about the completion of a request.
Method Summary
Table 946: Methods in PlatformDataRequest
Methods
public static PlatformDataRequest createBoundingBoxRequest (Set layers, GeoBoundingBox
geoBoundingBox)
Creates a data request with the specified layers and GeoBoundingBox instance.
public static PlatformDataRequest createLinkIdsRequest (Set layers, Set linkIds)
Creates a data request with the specified layers and permanent link ids (see RoadElement).
public static PlatformDataRequest createStaticLayerRequest (String layer)
Creates a data request with the specified static layer.
public void execute (Listener<PlatformDataResult> listener)
Invokes the data request with the specified listener.
Class Details
Runs the Platform Data Extension request with the given parameters.
HERE Android SDK Developer's Guide
API Reference
1567
Method Details
public static PlatformDataRequest createBoundingBoxRequest (Set layers,
GeoBoundingBox geoBoundingBox)
Creates a data request with the specified layers and GeoBoundingBox instance.
Parameters:
layers
Names of layers from which the data should be fetched.
geoBoundingBox
Area for which the data should be fetched.
Returns:
PlatformDataRequest instance.
Throws:
IllegalArgumentException
in case of invalid arguments.
public static PlatformDataRequest createLinkIdsRequest (Set layers, Set
linkIds)
Creates a data request with the specified layers and permanent link ids (see RoadElement).
Parameters:
layers
Names of layers from which the data should be fetched.
linkIds
The permanent link ids to be searched in the layers specifed.
Returns:
PlatformDataRequest instance.
Throws:
IllegalArgumentException
in case of invalid arguments.
public static PlatformDataRequest createStaticLayerRequest (String layer)
Creates a data request with the specified static layer. Note that a static layer doesn't require any bounding
box or link ids to collect data.
Parameters:
layer
HERE Android SDK Developer's Guide
API Reference
1568
The name of the static layer.
Returns:
If the parameter is valid, an PlatformDataRequest object configured with the parameter and null otherwise.
Throws:
IllegalArgumentException
in case of invalid arguments.
public void execute (Listener<PlatformDataResult> listener)
Invokes the data request with the specified listener.
Parameters:
listener
Listener to which the result will be passed.
Error
The class Error is a member of com.here.android.mpa.pde.PlatformDataRequest.
Class Summary
public static class PlatformDataRequest.Error
extends java.lang.Object
Represents error reported by the Platform Data Extension server.
[For complete information, see the section Class Details]
See also:
PlatformDataRequest
Nested Class Summary
Table 947: Nested Classes in Error
Nested Classes
public static final enumeration PlatformDataRequest.Error.Type
HERE Android SDK Developer's Guide
API Reference
1569
Method Summary
Table 948: Methods in Error
Methods
public String getFaultCode ()
public String getMessage ()
public String getResponseCode ()
public Type getType ()
Class Details
Represents error reported by the Platform Data Extension server.
See also:
PlatformDataRequest
Method Details
public String getFaultCode ()
Returns:
fault code for this error.
public String getMessage ()
Returns:
human readable description of this error.
public String getResponseCode ()
Returns:
server's response code.
public Type getType ()
Returns:
type of this error.
Type
The enumeration Type is a member of com.here.android.mpa.pde.PlatformDataRequest.Error.
HERE Android SDK Developer's Guide
API Reference
1570
Enumeration Summary
public static final enumeration PlatformDataRequest.Error.Type
extends java.lang.Enum, java.lang.Object
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 949: Enum Constants in Type
Fields
public static final Type INVALID_PARAMETERS
Invalid parameters were provided.
public static final Type NO_PERMISSION
No permission to use the API.
public static final Type CONNECTION_ERROR
Could not reach the server.
public static final Type SERVER_ERROR
Successfully connected to the server, but server responded with error.
Method Summary
Table 950: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static PlatformDataRequest.Error.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final Type INVALID_PARAMETERS
Invalid parameters were provided.
public static final Type NO_PERMISSION
No permission to use the API.
HERE Android SDK Developer's Guide
API Reference
1571
public static final Type CONNECTION_ERROR
Could not reach the server.
public static final Type SERVER_ERROR
Successfully connected to the server, but server responded with error.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static PlatformDataRequest.Error.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Listener<T>
The interface Listener<T> is a member of com.here.android.mpa.pde.PlatformDataRequest.
Type Parameters:
T
Listener data type
Interface Summary
public static abstract interface PlatformDataRequest.Listener
Represents an event listener that reports information about the completion of a request.
[For complete information, see the section Interface Details]
Method Summary
Table 951: Methods in Listener<T>
Methods
public abstract void onCompleted (T data, Error error)
A callback indicating that a request operation has completed.
HERE Android SDK Developer's Guide
API Reference
1572
Interface Details
Represents an event listener that reports information about the completion of a request.
Method Details
public abstract void onCompleted (T data, Error error)
A callback indicating that a request operation has completed.
Parameters:
data
Search results (can be null if no results were found or an error was encountered). E.g. if there is no map
data due to working offline, null is returned.
error
An PlatformDataError representing an appropriate error.
PlatformDataResult
The class PlatformDataResult is a member of com.here.android.mpa.pde .
Class Summary
public final class PlatformDataResult
implements java.util.Map
extends java.lang.Object
Result of the Platform Data Extension request.
[For complete information, see the section Class Details]
See also:
PlatformDataItemCollection
Method Summary
Table 952: Methods in PlatformDataResult
Methods
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public boolean containsKey (Object key)
Returns whether this Map contains the specified key.
HERE Android SDK Developer's Guide
API Reference
1573
Methods
public boolean containsValue (Object value)
Returns whether this Map contains the specified value.
public java.util.Set <java.util.Map.Entry<java.lang.String<,
com.here.android.mpa.pde.PlatformDataItemCollection>> entrySet ()
Returns a Set containing all of the mappings in this Map .
public boolean equals (Object o)
Compares the argument to the receiver, and returns true if the specified object is a PlatformDataResult and both
PlatformDataResult s contain the same mappings.
public Map extract ()
All the items returned by this class and its children are dynamically created on demand.
public PlatformDataItemCollection get (Object key)
Returns the value of the mapping with the specified key.
public int hashCode ()
Returns an integer hash code for the receiver.
public boolean isEmpty ()
Returns whether this map is empty.
public Set keySet ()
Returns a set of the keys contained in this Map .
public PlatformDataItemCollection put (String key, PlatformDataItemCollection value)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public void putAll (java.util.Map <? extends java.lang.String, ? extends
com.here.android.mpa.pde.PlatformDataItemCollection> map)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public PlatformDataItemCollection remove (Object key)
Since this class is immutable, this method only throws UnsupportedOperationException and does not do anything
else.
public int size ()
Returns the number of mappings in this Map .
public java.util.Collection <PlatformDataItemCollection> values ()
Returns a Collection of the values contained in this Map .
Class Details
Result of the Platform Data Extension request. Implements Map interface, where the key is the layer name
and the value is the PlatformDataItemCollection object, which is a collection of the retrieved items (
PlatformDataItem ) for the given layer. This class is immutable.
HERE Android SDK Developer's Guide
API Reference
1574
The PlatformDataItemCollection objects returned by this class keep reference to PlatformDataResult
instance.
See also:
PlatformDataItemCollection
Method Details
public void clear ()
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
public boolean containsKey (Object key)
Returns whether this Map contains the specified key.
Parameters:
key
the key to search for.
Returns:
true if this map contains the specified key, false otherwise.
public boolean containsValue (Object value)
Returns whether this Map contains the specified value.
Parameters:
value
the value to search for.
Returns:
true if this map contains the specified value, false otherwise.
public java.util.Set <java.util.Map.Entry<java.lang.String<,
com.here.android.mpa.pde.PlatformDataItemCollection>> entrySet ()
Returns a Set containing all of the mappings in this Map . Each mapping is an instance of Map.Entry.
Returns:
a set of the mappings
public boolean equals (Object o)
HERE Android SDK Developer's Guide
API Reference
1575
Compares the argument to the receiver, and returns true if the specified object is a PlatformDataResult
and both PlatformDataResult s contain the same mappings.
Parameters:
o
the Object to compare with this Object.
Returns:
boolean true if the Object is the same as this Object false if it is different from this Object.
See also:
hashCode()
entrySet()
public Map extract ()
All the items returned by this class and its children are dynamically created on demand. Due to that fact the
child objects keep references to their parent object. If you require normal Java behavior, you can convert this
class to regular Java collection with this method.
Returns:
Content of the @{code PlatformDataResult converted to regular Java collection.
public PlatformDataItemCollection get (Object key)
Returns the value of the mapping with the specified key.
Parameters:
key
the key.
Returns:
the value of the mapping with the specified key, or null if no mapping for the specified key is found.
public int hashCode ()
Returns an integer hash code for the receiver. Object s which are equal return the same value for this
method.
Returns:
the receiver's hash.
See also:
equals(Object)
HERE Android SDK Developer's Guide
API Reference
1576
public boolean isEmpty ()
Returns whether this map is empty.
Returns:
true if this map has no elements, false otherwise.
See also:
size()
public Set keySet ()
Returns a set of the keys contained in this Map .
Returns:
a set of the keys.
public PlatformDataItemCollection put (String key, PlatformDataItemCollection value)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
key
ignored
value
ignored
public void putAll (java.util.Map <? extends java.lang.String, ? extends
com.here.android.mpa.pde.PlatformDataItemCollection> map)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
map
ignored
public PlatformDataItemCollection remove (Object key)
Since this class is immutable, this method only throws UnsupportedOperationException and does not
do anything else.
Parameters:
key
HERE Android SDK Developer's Guide
API Reference
1577
ignored
public int size ()
Returns the number of mappings in this Map .
Returns:
the number of mappings in this Map.
public java.util.Collection <PlatformDataItemCollection> values ()
Returns a Collection of the values contained in this Map .
Returns:
a collection of the values contained in this map.
routing
The package routing is a member of com.here.android.mpa.
Package Summary
routing
This package provides classes, interfaces, and enumerations for route calculation and route description
(directions).
Package Details
This package provides classes, interfaces, and enumerations for route calculation and route description
(directions).
Note: the CoreRouter class provides access to the route calculation functionality.
To calculate a route, you need:
a parameter list containing at least two waypoints for the start and end of the route - this is an instance
of RoutePlan
a set of routing options to control route calculation features - this is an instance of RouteOptions
an event listener for listening to CoreRouter events - this is an instance of CoreRouter.Listener
Note that to use transit and truck route calculation feature, your application must include the google-gson
library (release 2.2.4 or a compatible version) on its class path. This library can be downloaded from the
google-gson project website at http://code.google.com/p/google-gson/. Attempting to use to use transit
and truck route calculation features without adding this library will cause runtime errors.
HERE Android SDK Developer's Guide
API Reference
1578
For more information on how to use the CoreRouter, please see the "Directions" section in the HERE SDK for
Android Developer's Guide
ConsumptionParameters
The class ConsumptionParameters is a member of com.here.android.mpa.routing .
Class Summary
public final class ConsumptionParameters
extends java.lang.Object
Stores information about consumption parameters of vehicle.
[For complete information, see the section Class Details]
Nested Class Summary
Table 953: Nested Classes in ConsumptionParameters
Nested Classes
public static final class ConsumptionParameters.ConsumptionForSpeed
Specifies consumption per meter for different travel speeds.
public static final class ConsumptionParameters.TrafficScale
Defines the traffic speed/free-flow speed adjustment scale.
Constructor Summary
Table 954: Constructors in ConsumptionParameters
Constructors
ConsumptionParameters ()
Default Constructor
Method Summary
Table 955: Methods in ConsumptionParameters
Methods
public static ConsumptionParameters createDefaultConsumptionParameters ()
Creates consumption parameters with default values.
public double getAccelerationMultiplier ()
Gets the acceleration multiplier.
public double getAscentMultiplier ()
Gets the ascent multiplier.
HERE Android SDK Developer's Guide
API Reference
1579
Methods
public double getAuxiliaryConsumption ()
Gets the auxiliary consumption.
public double getDecelerationMultiplier ()
Gets the deceleration multiplier.
public double getDescentMultiplier ()
Gets the descent multiplier.
public boolean getHighSpeedConsumptionEnabled ()
Gets "high speed consumption" mode state.
public int getHighSpeedConsumptionThresholdKmh ()
Gets free flow speed threshold [kmh] for a link to satisfy "high speed consumption" conditions.
public java.util.List <ConsumptionForSpeed> getSpeedParameters ()
Gets consumption per meter for different travel speeds.
public java.util.List <TrafficScale> getTrafficScales ()
Gets the traffic scaling coefficients.
public java.util.List <ConsumptionForSpeed> getTrafficSpeedParameters ()
Gets consumption per meter for different travel speeds for heavy traffic.
public double getTurnTimeMultiplier ()
Gets the turn time multiplier.
public int hashCode ()
For documentation, see java.lang.Object
public void setAccelerationMultiplier (double multiplier)
Sets acceleration multiplier.
public void setAscentMultiplier (double multiplier)
Sets the ascent multiplier.
public void setAuxiliaryConsumption (double auxiliaryConsumption)
Sets auxiliary consumption per second.
public void setDecelerationMultiplier (double multiplier)
Sets deceleration multiplier.
public void setDescentMultiplier (double multiplier)
Sets descent multiplier.
public void setHighSpeedConsumptionEnabled (boolean enabled)
Enables/disables "high speed consumption" mode.
public void setHighSpeedConsumptionThresholdKmh (int speedConsumptionThresholdKmh)
Sets free flow speed threshold [kmh] for a link to satisfy "high speed consumption" conditions.
HERE Android SDK Developer's Guide
API Reference
1580
Methods
public void setSpeedParameters (java.util.List <ConsumptionForSpeed> consumptionForSpeedList)
Sets consumption per meter according to travel speeds.
public void setTrafficScale (java.util.List <TrafficScale> trafficScales)
Sets the traffic scaling coefficients.
public void setTrafficSpeedParameters (java.util.List <ConsumptionForSpeed>
consumptionForSpeedList)
Sets consumption per meter for different travel speeds for heavy traffic.
public void setTurnTimeMultiplier (double multiplier)
Sets turn time multiplier.
Class Details
Stores information about consumption parameters of vehicle. Consumption parameters are used for
consumption calculation (See Route and RouteConsumption).
Consumption describes the usage rate of a resource that is used by the vehicle, such as electrical energy,
over a period of time.
IMPORTANT: Consumption calculation is a Beta feature. The related classes are subject to change without
notice.
Constructor Details
ConsumptionParameters ()
Default Constructor
Method Details
public static ConsumptionParameters createDefaultConsumptionParameters ()
Creates consumption parameters with default values.
Returns:
ConsumptionParameters object.
public double getAccelerationMultiplier ()
Gets the acceleration multiplier.
Returns:
The multiplier
public double getAscentMultiplier ()
HERE Android SDK Developer's Guide
API Reference
1581
Gets the ascent multiplier.
Returns:
The multiplier
public double getAuxiliaryConsumption ()
Gets the auxiliary consumption.
Returns:
The consumption value
public double getDecelerationMultiplier ()
Gets the deceleration multiplier.
Returns:
The multiplier
public double getDescentMultiplier ()
Gets the descent multiplier.
Returns:
The multiplier
public boolean getHighSpeedConsumptionEnabled ()
Gets "high speed consumption" mode state.
Returns:
True if "high speed consumption" mode is on, false otherwise.
public int getHighSpeedConsumptionThresholdKmh ()
Gets free flow speed threshold [kmh] for a link to satisfy "high speed consumption" conditions. See
setHighSpeedConsumptionEnabled(boolean)
Returns:
High speed consumption threshold.
public java.util.List <ConsumptionForSpeed> getSpeedParameters ()
Gets consumption per meter for different travel speeds.
Returns:
HERE Android SDK Developer's Guide
API Reference
1582
List of ConsumptionParameters.ConsumptionForSpeed instances or null if none are available.
public java.util.List <TrafficScale> getTrafficScales ()
Gets the traffic scaling coefficients.
Returns:
List of ConsumptionParameters.TrafficScale instances or null if none are available.
public java.util.List <ConsumptionForSpeed> getTrafficSpeedParameters ()
Gets consumption per meter for different travel speeds for heavy traffic.
Returns:
List of ConsumptionParameters.ConsumptionForSpeed instances or null if none are available.
public double getTurnTimeMultiplier ()
Gets the turn time multiplier.
Returns:
The multiplier
public int hashCode ()
For documentation, see java.lang.Object
public void setAccelerationMultiplier (double multiplier)
Sets acceleration multiplier.
During speed up, this parameter is used to model capacity expenditure in capacity units per km/h^2 of
acceleration. A higher value corresponds to greater capacity expenditure while the vehicle is accelerating.
Parameters:
multiplier
The acceleration multiplier
public void setAscentMultiplier (double multiplier)
Sets the ascent multiplier. Ascent multiplier models capacity expenditure during ascent in capacity units per
meter of ascent. A higher value corresponds to greater capacity expenditure while driving up-hill.
Parameters:
multiplier
HERE Android SDK Developer's Guide
API Reference
1583
The ascent multiplier
public void setAuxiliaryConsumption (double auxiliaryConsumption)
Sets auxiliary consumption per second.
Auxiliary consumption is used to account for the consumption by items such as lights, air conditioner, or
stereo. A higher value corresponds to greater capacity expenditure over time.
Parameters:
auxiliaryConsumption
The combined auxiliary consumption value
public void setDecelerationMultiplier (double multiplier)
Sets deceleration multiplier.
During slowdown, this parameter is used to model capacity gain in capacity units per km/h^2 of
deceleration. A higher value corresponds to greater capacity gain while the vehicle is decelerating.
Parameters:
multiplier
The deceleration multiplier
public void setDescentMultiplier (double multiplier)
Sets descent multiplier.
Descent multiplier is the model's capacity gained during descent, in capacity units per meter of descent. A
higher value corresponds to greater capacity gain while driving down-hill.
Parameters:
multiplier
The descent multiplier
public void setHighSpeedConsumptionEnabled (boolean enabled)
Enables/disables "high speed consumption" mode.
Link satisfies "high speed consumption" mode conditions when it:
is a highway;
has no speed limit;
has no time-aware speed limit;
has no dynamic speed limit;
has free flow speed above threshold get_high_speed_consumption_threshold_kmh.
HERE Android SDK Developer's Guide
API Reference
1584
When "high speed consumption" mode is enabled and link satisfies its conditions, then consumption for
this link is calculated not based on its free flow speed, but based on the highest consumption provided by
get_speed_parameters.
The idea is to better predict consumption for drivers going on considerably higher speed than free flow
values, eg. in sport mode.
Parameters:
enabled
If true, "high speed consumption" mode is enabled.
public void setHighSpeedConsumptionThresholdKmh (int
speedConsumptionThresholdKmh)
Sets free flow speed threshold [kmh] for a link to satisfy "high speed consumption" conditions. See
setHighSpeedConsumptionEnabled(boolean)
Parameters:
speedConsumptionThresholdKmh
The speed consumption threshold.
public void setSpeedParameters (java.util.List <ConsumptionForSpeed>
consumptionForSpeedList)
Sets consumption per meter according to travel speeds.
Setting only this value is sufficient to perform basic consumption calculation.
This list is made up of pairs of values representing the speed (in km/h) and the consumption per meter in
the capacity unit.
Consider a simple consumption table for a sample electric vehicle where the consumption unit is kilowatt
hours (kWh):
0 - 30 km/h - 38.82 kWh
31 - 90 km/h - 18.20 kWh
More than 90 km/h - 27.41 kWh
The speeds should be set with the upper bound of each speed range:
List<ConsumptionParameters.ConsumptionForSpeed>
speedParameters = Arrays.asList(
new ConsumptionParameters.ConsumptionForSpeed(30, 38.82),
new ConsumptionParameters.ConsumptionForSpeed(90, 18.20),
new ConsumptionParameters.ConsumptionForSpeed(250,
27.41));
Note: Default values are assigned when the object is instantiated.
Parameters:
consumptionForSpeedList
HERE Android SDK Developer's Guide
API Reference
1585
List of ConsumptionParameters.ConsumptionForSpeed instances.
Throws:
IllegalArgumentException
if consumptionForSpeedList is null or empty.
public void setTrafficScale (java.util.List <TrafficScale> trafficScales)
Sets the traffic scaling coefficients. Traffic Scale coefficients specifies a piece-wise linear scaling between
the traffic speed parameters and the speed parameters. For a given traffic value (calculated as 1 - traffic
speed/free-flow speed) this mapping is applied to determine the interpolation point between free-
flow consumption and traffic consumption for the traffic speed defined by the speed parameters (see
getSpeedParameters()) and traffic speed parameters (see getTrafficSpeedParameters()).
Parameters:
trafficScales
List of ConsumptionParameters.TrafficScale instances.
Throws:
IllegalArgumentException
if trafficScales is null or empty.
public void setTrafficSpeedParameters (java.util.List <ConsumptionForSpeed>
consumptionForSpeedList)
Sets consumption per meter for different travel speeds for heavy traffic. The exact consumption per meter
that is used will be an interpolated value between the standard consumption for speed and the traffic
consumption for speed, depending on the amount of traffic along each part of the route. The interpolation
can be configured with setTrafficScale(List).
Note: This is an advanced consumption calculation feature. For more information, please contact your HERE
representative.
This list is made up of pairs of values representing the speed (in km/h) and the consumption per meter in
the capacity unit. See setSpeedParameters(List) for more details on how the values should be filled in.
Parameters:
consumptionForSpeedList
List of ConsumptionParameters.ConsumptionForSpeed instances.
Throws:
IllegalArgumentException
if consumptionForSpeedList is null or empty.
public void setTurnTimeMultiplier (double multiplier)
HERE Android SDK Developer's Guide
API Reference
1586
Sets turn time multiplier.
Capacity expenditure while turning, in capacity units per second of travel time. A higher value corresponds to
greater capacity expenditure while the vehicle is turning.
Parameters:
multiplier
The turn time multiplier
ConsumptionForSpeed
The class ConsumptionForSpeed is a member of com.here.android.mpa.routing.ConsumptionParameters.
Class Summary
public static final class ConsumptionParameters.ConsumptionForSpeed
extends java.lang.Object
Specifies consumption per meter for different travel speeds.
[For complete information, see the section Class Details]
Constructor Summary
Table 956: Constructors in ConsumptionForSpeed
Constructors
ConsumptionForSpeed (int speedInKmH, double consumptionPerMeter)
Default constructor.
Method Summary
Table 957: Methods in ConsumptionForSpeed
Methods
public boolean equals (Object o)
For documentation, see java.lang.Object
public double getConsumptionPerMeter ()
Gets the consumption per meter value.
public int getSpeedInKmH ()
Gets the speed in Kh per hour.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1587
Class Details
Specifies consumption per meter for different travel speeds.
Constructor Details
ConsumptionForSpeed (int speedInKmH, double consumptionPerMeter)
Default constructor.
Parameters:
speedInKmH
The speed in Km per hour
consumptionPerMeter
The consumption per meter
Method Details
public boolean equals (Object o)
For documentation, see java.lang.Object
Parameters:
o
public double getConsumptionPerMeter ()
Gets the consumption per meter value.
Returns:
The consumption value
public int getSpeedInKmH ()
Gets the speed in Kh per hour.
Returns:
The speed value
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1588
TrafficScale
The class TrafficScale is a member of com.here.android.mpa.routing.ConsumptionParameters.
Class Summary
public static final class ConsumptionParameters.TrafficScale
extends java.lang.Object
Defines the traffic speed/free-flow speed adjustment scale.
[For complete information, see the section Class Details]
Constructor Summary
Table 958: Constructors in TrafficScale
Constructors
TrafficScale (double ratio, double coefficient)
Method Summary
Table 959: Methods in TrafficScale
Methods
public boolean equals (Object o)
public double getCoefficient ()
Gets coefficient that will be used to adjust consumption according to the traffic_speed/free_flow_speed ratio
public double getRatio ()
Gets the ratio between traffic_speed and free_flow_speed
public int hashCode ()
Class Details
Defines the traffic speed/free-flow speed adjustment scale. Scale will be used when calculating consumption
for a segment that contains traffic information. Setting this scale allows the definition of how the
ratio between the speed parameters (see getSpeedParameters()) and traffic speed parameters (see
getTrafficSpeedParameters()) influence the consumption.
Constructor Details
TrafficScale (double ratio, double coefficient)
Parameters:
ratio
HERE Android SDK Developer's Guide
API Reference
1589
coefficient
Method Details
public boolean equals (Object o)
Parameters:
o
public double getCoefficient ()
Gets coefficient that will be used to adjust consumption according to the traffic_speed/free_flow_speed
ratio
Returns:
coefficient
public double getRatio ()
Gets the ratio between traffic_speed and free_flow_speed
Returns:
ratio between traffic_speed and free_flow_speed
public int hashCode ()
CoreRouter
The class CoreRouter is a member of com.here.android.mpa.routing .
Class Summary
public final class CoreRouter
implements com.here.android.mpa.routing.Router
extends java.lang.Object
Route calculation executor handling core routing types (Car, Truck, Pedestrian).
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1590
Nested Class Summary
Table 960: Nested Classes in CoreRouter
Nested Classes
public static final enumeration CoreRouter.Connectivity
The possible types of connectivity for route calculation
public static abstract interface CoreRouter.Listener
Represents a listener to provide information about route calculation events.
Constructor Summary
Table 961: Constructors in CoreRouter
Constructors
CoreRouter ()
Default constructor with DEFAULT.
Method Summary
Table 962: Methods in CoreRouter
Methods
public void calculateRoute (RoutePlan routePlan, Listener<RouteResult, RoutingError> listener)
Invokes an asynchronous route calculation.
public void cancel ()
public Connectivity getConnectivity ()
Gets the connectivity to be used for route calculation.
public DynamicPenalty getDynamicPenalty ()
Get the different penalties which is responsible to change the routing conditions.
public boolean isBusy ()
public CoreRouter setConnectivity (Connectivity connectivity)
Determines whether route is calculated online or offline.
public CoreRouter setDynamicPenalty (DynamicPenalty penalty)
Sets the dynamic penalty that should be applied to route calculations.
Class Details
Route calculation executor handling core routing types (Car, Truck, Pedestrian). Defines concrete calculation
method and response listener for core routing types.
HERE Android SDK Developer's Guide
API Reference
1591
Constructor Details
CoreRouter ()
Default constructor with DEFAULT. Multiple CoreRouter s can be created to calculate multiple routes in
parallel.
Method Details
public void calculateRoute (RoutePlan routePlan, Listener<RouteResult, RoutingError>
listener)
Invokes an asynchronous route calculation. Upon completion of the request, the Listener will be invoked
regardless if the request is completed successfully or not.
Parameters:
routePlan
listener
A Listener for the CoreRouter As of 3.2.2, This method will notify listeners with INVALID_PARAMETERS
and a route will not be calculated if calculating a route with TRACK since calculating a route in track
mode is no longer supported. This method returns INVALID_PARAMETERS and a route will not be
calculated if calculating a route with PUBLIC_TRANSPORT and routePlan contains more than 2 waypoints.
public void cancel ()
public Connectivity getConnectivity ()
Gets the connectivity to be used for route calculation.
Returns:
CoreRouter.Connectivity to be used for route calculation
public DynamicPenalty getDynamicPenalty ()
Get the different penalties which is responsible to change the routing conditions.
Returns:
DynamicPenalty used for route calculation
public boolean isBusy ()
public CoreRouter setConnectivity (Connectivity connectivity)
HERE Android SDK Developer's Guide
API Reference
1592
Determines whether route is calculated online or offline. Default is DEFAULT. If set to offline, it will attempt
to calculate the route offline regardless of the routing type and regardless of whether there is enough map
data for the route calculation, if fails, it will not make another attempt online. If set to online, it will attempt
to calculate the route online regardless of the routing type and regardless of the current device connectivity.
If it fails, it will not make another attempt offline. If this is changed after calling calculateRoute, the change
will not take effect for the current route calculation. \note An example of the usage is as follows: e.g. An
app wishes to try online first and falls back to offline if online fails. Such app will set connectivity to ONLINE
before calculating a route, if this fails, it will change connectivity to OFFLINE before another route calculation
attempt.
Parameters:
connectivity
The CoreRouter.Connectivity to set
Returns:
This CoreRouter to be used for route calculation
public CoreRouter setDynamicPenalty (DynamicPenalty penalty)
Sets the dynamic penalty that should be applied to route calculations. Penalties can be applied in the form
of restricting roads, areas and setting different traffic modes.
Note: Passing null will set the default penalties.
Parameters:
penalty
DynamicPenalty penalty used for route calculation
Returns:
This CoreRouter
Connectivity
The enumeration Connectivity is a member of com.here.android.mpa.routing.CoreRouter.
Enumeration Summary
public static final enumeration CoreRouter.Connectivity
extends java.lang.Enum, java.lang.Object
The possible types of connectivity for route calculation
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1593
Enum Constant Summary
Table 963: Enum Constants in Connectivity
Fields
public static final Connectivity DEFAULT
Route is calculated based on the current MapEngine online status, which depends on the current network access and could
be forced to offline using setOnline(boolean).
public static final Connectivity OFFLINE
Attempts offline routing regardless whether there is enough map data on the device.
public static final Connectivity ONLINE
Attempts online routing regardless whether device is online or whether the HERE SDK is allowed to access network.
Method Summary
Table 964: Methods in Connectivity
Methods
public int getValue ()
public static Connectivity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CoreRouter.Connectivity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The possible types of connectivity for route calculation
Enum Constant Details
public static final Connectivity DEFAULT
Route is calculated based on the current MapEngine online status, which depends on the current network
access and could be forced to offline using setOnline(boolean). If the MapEngine status is set to online,
then an online routing will be made. If the MapEngine status is offline, then an offline route calculation is
performed.
public static final Connectivity OFFLINE
Attempts offline routing regardless whether there is enough map data on the device. If there is not enough
map data the request might fail. If it fails, it will not try online.
public static final Connectivity ONLINE
HERE Android SDK Developer's Guide
API Reference
1594
Attempts online routing regardless whether device is online or whether the HERE SDK is allowed to access
network. If the device is offline, the request will fail. If it fails, it will not try offline.
Method Details
public int getValue ()
public static Connectivity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CoreRouter.Connectivity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Listener
The interface Listener is a member of com.here.android.mpa.routing.CoreRouter.
Interface Summary
public static abstract interface CoreRouter.Listener
extends com.here.android.mpa.routing.Router.Listener
Represents a listener to provide information about route calculation events.
[For complete information, see the section Interface Details]
See also:
calculateRoute(RoutePlan, Listener<List<RouteResult>, RoutingError>)
Method Summary
Table 965: Methods in Listener
Methods
public abstract void onCalculateRouteFinished (java.util.List <RouteResult> results, RoutingError
error)
A callback indicating that a route calculation operation has finished.
HERE Android SDK Developer's Guide
API Reference
1595
Interface Details
Represents a listener to provide information about route calculation events.
See also:
calculateRoute(RoutePlan, Listener<List<RouteResult>, RoutingError>)
Method Details
public abstract void onCalculateRouteFinished (java.util.List <RouteResult>
results, RoutingError error)
A callback indicating that a route calculation operation has finished. In the case of VIOLATES_OPTIONS, one
or more RouteResult in the returned list contains a list of violated RouteOptions. For other RoutingError, the
list size of RouteResult will be 0. You may also receive an error in the offline case where only cached data
(not downloaded map data) is available. There is no guarantee that a route is returned in this case. Only one
result will be returned for routes with more than two RouteWaypoint.
Parameters:
results
A List of RouteResult
error
A RoutingError indicating the error code for the route calculation (could be NONE).
See also:
getViolatedOptions()
DrivingDirection
The enumeration DrivingDirection is a member of com.here.android.mpa.routing .
Enumeration Summary
public final enumeration DrivingDirection
extends java.lang.Enum, java.lang.Object
Enumeration for driving direction.
[For complete information, see the section Enumeration Details]
See also:
addRoadPenalty(RoadElement, DrivingDirection, int)
HERE Android SDK Developer's Guide
API Reference
1596
Enum Constant Summary
Table 966: Enum Constants in DrivingDirection
Fields
public static final DrivingDirection DIR_BOTH
Both direction.
public static final DrivingDirection DIR_FORWARD
Forward direction
public static final DrivingDirection DIR_BACKWARD
Backward direction.
Method Summary
Table 967: Methods in DrivingDirection
Methods
public int value ()
public static DrivingDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static DrivingDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enumeration for driving direction. This can be used to specify the direction of driving.
See also:
addRoadPenalty(RoadElement, DrivingDirection, int)
Enum Constant Details
public static final DrivingDirection DIR_BOTH
Both direction. Forward as well as backward
public static final DrivingDirection DIR_FORWARD
Forward direction
public static final DrivingDirection DIR_BACKWARD
Backward direction.
HERE Android SDK Developer's Guide
API Reference
1597
Method Details
public int value ()
public static DrivingDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static DrivingDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
DynamicPenalty
The class DynamicPenalty is a member of com.here.android.mpa.routing .
Class Summary
public final class DynamicPenalty
extends java.lang.Object
This class represents a policy containing road, area, and traffic restriction factors that are taken into account
while calculating routes.
[For complete information, see the section Class Details]
See also:
Route.TrafficPenaltyMode
Constructor Summary
Table 968: Constructors in DynamicPenalty
Constructors
DynamicPenalty ()
Default constructor.
HERE Android SDK Developer's Guide
API Reference
1598
Method Summary
Table 969: Methods in DynamicPenalty
Methods
public void addBannedArea (GeoPolygon area)
Sets a banned area which is excluded from the routing calculation.
public void addRoadPenalty (RoadElement element, DrivingDirection direction, int newSpeed)
Sets a penalty for a road segment.
public void clearAllAreaPenalties ()
Removes all previously-added areas and their penalty from this policy.
public void clearAllRoadPenalties ()
Removes all previously-added road penalties.
public TrafficPenaltyMode getTrafficPenaltyMode ()
Retrieves the traffic penalty mode for route calculations.
public void removeBannedArea (GeoPolygon area)
Removes a banned area, if added previously.
public void removeRoadPenalty (RoadElement element)
Remove a road segment from the penalty policy.
public void setTrafficPenaltyMode (TrafficPenaltyMode mode)
Sets whether route calculation should take traffic into account.
Class Details
This class represents a policy containing road, area, and traffic restriction factors that are taken into account
while calculating routes. These restriction factors are also known as penalties. For example, you can use this
class to set an area penalty to indicate that the travel speed in an area is 50% slower than the legal speed
limit.
DynamicPenalty must be set with setDynamicPenalty(DynamicPenalty) for its restrictions to be in effect.
See also:
Route.TrafficPenaltyMode
Constructor Details
DynamicPenalty ()
Default constructor.
Method Details
public void addBannedArea (GeoPolygon area)
HERE Android SDK Developer's Guide
API Reference
1599
Sets a banned area which is excluded from the routing calculation.
A banned area is defined in terms of GeoPolygon.
Parameters:
area
area to with penalty is being added.
Throws:
NullPointerException
if area is null
public void addRoadPenalty (RoadElement element, DrivingDirection direction,
int newSpeed)
Sets a penalty for a road segment. Road penalties are defined as a speed that overrides the original speed of
the road segment.
Road penalties are in kilometers per hour and must be between 0 and 254. A penalty of 0 blocks the
road segment from route calculations altogether.
Segments can be blocked in the forward, backward, or both directions. If a road segment is excluded in the
backward direction, it can still be accessed in the forward direction. If you want to completely exclude the
segment, block both directions.
Parameters:
element
RoadElement to identify the road segment.
direction
The road's direction represented by DrivingDirection to be used to apply penalty.
newSpeed
New Speed for the segment in kilometers per hour. Must be in between 0 to 254.
Throws:
IllegalArgumentException
if newSpeed is less than 0 or greater than 254
NullPointerException
if the RoadElement is null
public void clearAllAreaPenalties ()
Removes all previously-added areas and their penalty from this policy.
public void clearAllRoadPenalties ()
HERE Android SDK Developer's Guide
API Reference
1600
Removes all previously-added road penalties.
public TrafficPenaltyMode getTrafficPenaltyMode ()
Retrieves the traffic penalty mode for route calculations.
Returns:
The Route.TrafficPenaltyMode used for calculations
public void removeBannedArea (GeoPolygon area)
Removes a banned area, if added previously.
Area is defined in terms of GeoPolygon.
Parameters:
area
area to be removed from penalty policy
public void removeRoadPenalty (RoadElement element)
Remove a road segment from the penalty policy. This will remove penalties for every DrivingDirection
Parameters:
element
RoadElement to identify the road segment.
public void setTrafficPenaltyMode (TrafficPenaltyMode mode)
Sets whether route calculation should take traffic into account. By default, traffic penalty mode is DISABLED.
Parameters:
mode
A TrafficPenaltyMode indicating whether to take traffic into account.
Maneuver
The class Maneuver is a member of com.here.android.mpa.routing .
Class Summary
public class Maneuver
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1601
Represents the action required to leave one street segment and enter the next in the chain of directions that
comprises a calculated Route.
[For complete information, see the section Class Details]
Nested Class Summary
Table 970: Nested Classes in Maneuver
Nested Classes
public static final enumeration Maneuver.Action
Represents values describing the possible actions of a Maneuver.
public static final enumeration Maneuver.Icon
Represents values describing types of Maneuver icons.
public static final enumeration Maneuver.TrafficDirection
Represents values describing possible traffic directions, the side of road on which one must drive.
public static final enumeration Maneuver.Turn
Represents values describing possible turns within a Maneuver.
Method Summary
Table 971: Methods in Maneuver
Methods
public Action getAction ()
Gets the Maneuver.Action required to complete the maneuver.
public int getAngle ()
Gets the angle of the maneuver.
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the maneuver, which is a group of GeoCoordinates forming a polygon
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of the maneuver.
public int getDistanceFromPreviousManeuver ()
Gets the distance from the previous maneuver to the current maneuver, in meters.
public int getDistanceFromStart ()
Gets the distance from the start of the route to the maneuver, in meters.
public int getDistanceToNextManeuver ()
Gets the distance to the next maneuver from the current maneuver, in meters.
public Icon getIcon ()
Gets the Maneuver.Icon enum that represents the icon that should be displayed for this maneuver.
HERE Android SDK Developer's Guide
API Reference
1602
Methods
public java.util.List <GeoCoordinate> getManeuverGeometry ()
Puts all points of the maneuvers polyline in the right order into the given collection.
public int getMapOrientation ()
Gets the map orientation at the start of the maneuver, in degrees.
public Image getNextRoadImage ()
Gets the image of the road this maneuver leads to.
public String getNextRoadName ()
Gets the name of the road to which the maneuver leads.
public String getNextRoadNumber ()
Gets the road number to which the maneuver leads.
public java.util.List <RoadElement> getRoadElements ()
Returns a list of RoadElements within the maneuver.
public String getRoadName ()
Gets the name of the road on which the maneuver takes place.
public String getRoadNumber ()
Gets the road number on which the maneuver takes place.
public java.util.List <RouteElement> getRouteElements ()
Returns a list of RouteElement within the maneuver
public Signpost getSignpost ()
Gets the Signpost for this maneuver.
public Date getStartTime ()
Gets the (estimated) time at which the maneuver starts.
public TrafficDirection getTrafficDirection ()
Return traffic direction.
public TransportMode getTransportMode ()
Gets the RouteOptions.TransportMode used for the maneuver.
public Turn getTurn ()
Gets the Maneuver.Turn required to complete the maneuver.
Class Details
Represents the action required to leave one street segment and enter the next in the chain of directions that
comprises a calculated Route.
Method Details
public Action getAction ()
HERE Android SDK Developer's Guide
API Reference
1603
Gets the Maneuver.Action required to complete the maneuver.
Returns:
The Maneuver.Action
public int getAngle ()
Gets the angle of the maneuver.
Returns:
The angle in degrees from end of the start road to the start of the end road. Angle has a value from 0, 360,
north is up, clockwise. For some roundabouts, this angle is an approximation from the entry to the exit point
of the roundabout, which may be used for customization of the roundabout icon.
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the maneuver, which is a group of GeoCoordinates forming a polygon
Returns:
The GeoBoundingBox
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of the maneuver.
Returns:
The GeoCoordinate
public int getDistanceFromPreviousManeuver ()
Gets the distance from the previous maneuver to the current maneuver, in meters.
Returns:
The distance
public int getDistanceFromStart ()
Gets the distance from the start of the route to the maneuver, in meters.
Returns:
The distance
public int getDistanceToNextManeuver ()
Gets the distance to the next maneuver from the current maneuver, in meters.
HERE Android SDK Developer's Guide
API Reference
1604
Returns:
The distance
public Icon getIcon ()
Gets the Maneuver.Icon enum that represents the icon that should be displayed for this maneuver.
Returns:
The Maneuver.Icon
public java.util.List <GeoCoordinate> getManeuverGeometry ()
Puts all points of the maneuvers polyline in the right order into the given collection.
Returns:
a collection of GeoCoordinates.
public int getMapOrientation ()
Gets the map orientation at the start of the maneuver, in degrees.
Note: a returned value of zero represents true-north, with increasing values representing a clockwise
progression of map orientation.
Returns:
The orientation
public Image getNextRoadImage ()
Gets the image of the road this maneuver leads to.
Returns:
The Image for the next road (may be null).
public String getNextRoadName ()
Gets the name of the road to which the maneuver leads.
Next road name is provided if available for a given Maneuver . If not provided, it should be left blank. It's
erroneous to assume that it is the same as prior maneuvers.
Returns:
The next road name
public String getNextRoadNumber ()
HERE Android SDK Developer's Guide
API Reference
1605
Gets the road number to which the maneuver leads.
Returns:
The road number of the next road element
public java.util.List <RoadElement> getRoadElements ()
Returns a list of RoadElements within the maneuver.
Returns:
a collection of RoadElements.
public String getRoadName ()
Gets the name of the road on which the maneuver takes place.
Road name is provided if available for a given Maneuver . If not provided, it should be left blank. It's
erroneous to assume that it is the same as prior maneuvers.
Returns:
The road name
public String getRoadNumber ()
Gets the road number on which the maneuver takes place. The road number is a short label for the road or
highway, such as "5" for Interstate 5.
If the road number is unknown, this method will return an empty string.
Returns:
The road number
public java.util.List <RouteElement> getRouteElements ()
Returns a list of RouteElement within the maneuver
Returns:
a collection of RouteElement.
public Signpost getSignpost ()
Gets the Signpost for this maneuver. If the signpost is not valid, null is returned.
Returns:
A Signpost object if a valid one exists. Otherwise, returns null.
HERE Android SDK Developer's Guide
API Reference
1606
public Date getStartTime ()
Gets the (estimated) time at which the maneuver starts.
If no departure time was set for the RouteOptions associated with the maneuver, then the time is relative
to the system time when the route calculation took place. Otherwise, the times are relative to the specified
departure time.
Returns:
The start time, or null if not available
See also:
setTime(Date, TimeType)
public TrafficDirection getTrafficDirection ()
Return traffic direction.
Returns:
LEFT, if left side traffic, RIGHT if right side traffic.
public TransportMode getTransportMode ()
Gets the RouteOptions.TransportMode used for the maneuver. This might differ from the
RouteOptions.TransportMode used when calculating the Route with which the particular maneuver is
associated. For example, in the case where a Route is calculated using PUBLIC_TRANSPORT, the overall route
is a public transport route, but some individual maneuvers may be pedestrian (for example, walking to a bus
stop, or transfers which involve walking to a new stop).
Returns:
The RouteOptions.TransportMode
public Turn getTurn ()
Gets the Maneuver.Turn required to complete the maneuver.
Returns:
The Maneuver.Turn
Action
The enumeration Action is a member of com.here.android.mpa.routing.Maneuver.
Enumeration Summary
public static final enumeration Maneuver.Action
HERE Android SDK Developer's Guide
API Reference
1607
extends java.lang.Enum, java.lang.Object
Represents values describing the possible actions of a Maneuver.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 972: Enum Constants in Action
Fields
public static final Action UNDEFINED
An undefined action (the default), avoided for real maneuvers.
public static final Action NO_ACTION
An indication that there is no action associated with the maneuver.
public static final Action END
An action that indicates the end of a route.
public static final Action STOPOVER
An action that indicates a stopover.
public static final Action JUNCTION
An action that indicates a junction.
public static final Action ROUNDABOUT
An action that indicates a roundabout.
public static final Action UTURN
An action that indicates a u-turn.
public static final Action ENTER_HIGHWAY_FROM_RIGHT
An action that indicates entering a highway from the right.
public static final Action ENTER_HIGHWAY_FROM_LEFT
An action that indicates entering a highway from the left.
public static final Action ENTER_HIGHWAY
An action that indicates entering a highway.
public static final Action LEAVE_HIGHWAY
An action that indicates leaving a highway.
public static final Action CHANGE_HIGHWAY
An action that indicates changing from one highway to another.
public static final Action CONTINUE_HIGHWAY
An action that indicates continuing along a highway.
public static final Action FERRY
An action that indicates boarding a ferry.
HERE Android SDK Developer's Guide
API Reference
1608
Fields
public static final Action PASS_JUNCTION
An action that indicates passing a junction.
public static final Action HEAD_TO
An action that indicates heading.
public static final Action PASS_STATION
An action that indicates passing a station.
public static final Action CHANGE_LINE
An action that indicates transit line change.
public static final Action INVALID
An invalid action.
Method Summary
Table 973: Methods in Action
Methods
public int value ()
public static Action valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.Action[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the possible actions of a Maneuver.
Enum Constant Details
public static final Action UNDEFINED
An undefined action (the default), avoided for real maneuvers.
public static final Action NO_ACTION
An indication that there is no action associated with the maneuver.
public static final Action END
An action that indicates the end of a route.
HERE Android SDK Developer's Guide
API Reference
1609
public static final Action STOPOVER
An action that indicates a stopover.
public static final Action JUNCTION
An action that indicates a junction.
public static final Action ROUNDABOUT
An action that indicates a roundabout.
public static final Action UTURN
An action that indicates a u-turn.
public static final Action ENTER_HIGHWAY_FROM_RIGHT
An action that indicates entering a highway from the right.
public static final Action ENTER_HIGHWAY_FROM_LEFT
An action that indicates entering a highway from the left.
public static final Action ENTER_HIGHWAY
An action that indicates entering a highway.
public static final Action LEAVE_HIGHWAY
An action that indicates leaving a highway.
public static final Action CHANGE_HIGHWAY
An action that indicates changing from one highway to another.
public static final Action CONTINUE_HIGHWAY
An action that indicates continuing along a highway.
public static final Action FERRY
An action that indicates boarding a ferry.
HERE Android SDK Developer's Guide
API Reference
1610
public static final Action PASS_JUNCTION
An action that indicates passing a junction.
public static final Action HEAD_TO
An action that indicates heading.
public static final Action PASS_STATION
An action that indicates passing a station.
public static final Action CHANGE_LINE
An action that indicates transit line change.
public static final Action INVALID
An invalid action.
Method Details
public int value ()
public static Action valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Maneuver.Action[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Icon
The enumeration Icon is a member of com.here.android.mpa.routing.Maneuver.
HERE Android SDK Developer's Guide
API Reference
1611
Enumeration Summary
public static final enumeration Maneuver.Icon
extends java.lang.Enum, java.lang.Object
Represents values describing types of Maneuver icons.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 974: Enum Constants in Icon
Fields
public static final Icon UNDEFINED
An undefined icon.
public static final Icon GO_STRAIGHT
An icon that indicates a straight course.
public static final Icon UTURN_RIGHT
An icon that indicates a right u-turn.
public static final Icon UTURN_LEFT
An icon that indicates a left u-turn.
public static final Icon KEEP_RIGHT
An icon that indicates keeping to the right.
public static final Icon LIGHT_RIGHT
An icon that indicates a light right turn.
public static final Icon QUITE_RIGHT
An icon that indicates a normal right turn.
public static final Icon HEAVY_RIGHT
An icon that indicates a heavy right turn.
public static final Icon KEEP_MIDDLE
Keep middle line.
public static final Icon KEEP_LEFT
An icon that indicates keeping to the left.
public static final Icon LIGHT_LEFT
An icon that indicates a light left turn.
public static final Icon QUITE_LEFT
An icon that indicates a normal left turn.
public static final Icon HEAVY_LEFT
An icon that indicates a heavy left turn.
HERE Android SDK Developer's Guide
API Reference
1612
Fields
public static final Icon ENTER_HIGHWAY_RIGHT_LANE
An icon that indicates entering a highway into the right lane.
public static final Icon ENTER_HIGHWAY_LEFT_LANE
An icon that indicates entering a highway into the left lane.
public static final Icon LEAVE_HIGHWAY_RIGHT_LANE
An icon that indicates leaving a highway from the right lane.
public static final Icon LEAVE_HIGHWAY_LEFT_LANE
An icon that indicates leaving a highway from the left lane.
public static final Icon HIGHWAY_KEEP_RIGHT
An icon that indicates keeping to the right-hand lane of a highway.
public static final Icon HIGHWAY_KEEP_LEFT
An icon that indicates keeping to the left-hand lane of a highway.
public static final Icon ROUNDABOUT_1
An icon that indicates using the first exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_2
An icon that indicates using the second exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_3
An icon that indicates using the third exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_4
An icon that indicates using the fourth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_5
An icon that indicates using the fifth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_6
An icon that indicates using the sixth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_7
An icon that indicates using the seventh exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_8
An icon that indicates using the eighth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_9
An icon that indicates using the ninth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_10
An icon that indicates using the tenth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_11
An icon that indicates using the eleventh exit encountered while navigating a roundabout in a counter-clockwise direction.
HERE Android SDK Developer's Guide
API Reference
1613
Fields
public static final Icon ROUNDABOUT_12
An icon that indicates using the twelfth exit encountered while navigating a roundabout in a counter-clockwise direction.
public static final Icon ROUNDABOUT_1_LH
An icon that indicates using the first exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_2_LH
An icon that indicates using the second exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_3_LH
An icon that indicates using the third exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_4_LH
An icon that indicates using the fourth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_5_LH
An icon that indicates using the fifth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_6_LH
An icon that indicates using the sixth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_7_LH
An icon that indicates using the seventh exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_8_LH
An icon that indicates using the eighth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_9_LH
An icon that indicates using the ninth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_10_LH
An icon that indicates using the tenth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_11_LH
An icon that indicates using the eleventh exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_12_LH
An icon that indicates using the twelfth exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon START
An icon that indicates the start point (displayed when route navigation has not yet begun).
public static final Icon END
An icon that indicates the destination point.
public static final Icon FERRY
An icon that indicates boarding a ferry.
public static final Icon PASS_STATION
An icon that indicates passing a station.
HERE Android SDK Developer's Guide
API Reference
1614
Fields
public static final Icon HEAD_TO
Leaving public transit station.
public static final Icon CHANGE_LINE
Changing public transit line.
Method Summary
Table 975: Methods in Icon
Methods
public int value ()
public static Icon valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.Icon[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing types of Maneuver icons.
Note that this enum is only provided as a convenience to easily retrieve the maneuver instruction. You must
provide your own icon images and implement your own icon-drawing code.
Enum Constant Details
public static final Icon UNDEFINED
An undefined icon.
public static final Icon GO_STRAIGHT
An icon that indicates a straight course.
public static final Icon UTURN_RIGHT
An icon that indicates a right u-turn.
public static final Icon UTURN_LEFT
An icon that indicates a left u-turn.
public static final Icon KEEP_RIGHT
HERE Android SDK Developer's Guide
API Reference
1615
An icon that indicates keeping to the right.
public static final Icon LIGHT_RIGHT
An icon that indicates a light right turn.
public static final Icon QUITE_RIGHT
An icon that indicates a normal right turn.
public static final Icon HEAVY_RIGHT
An icon that indicates a heavy right turn.
public static final Icon KEEP_MIDDLE
Keep middle line.
public static final Icon KEEP_LEFT
An icon that indicates keeping to the left.
public static final Icon LIGHT_LEFT
An icon that indicates a light left turn.
public static final Icon QUITE_LEFT
An icon that indicates a normal left turn.
public static final Icon HEAVY_LEFT
An icon that indicates a heavy left turn.
public static final Icon ENTER_HIGHWAY_RIGHT_LANE
An icon that indicates entering a highway into the right lane.
public static final Icon ENTER_HIGHWAY_LEFT_LANE
An icon that indicates entering a highway into the left lane.
HERE Android SDK Developer's Guide
API Reference
1616
public static final Icon LEAVE_HIGHWAY_RIGHT_LANE
An icon that indicates leaving a highway from the right lane.
public static final Icon LEAVE_HIGHWAY_LEFT_LANE
An icon that indicates leaving a highway from the left lane.
public static final Icon HIGHWAY_KEEP_RIGHT
An icon that indicates keeping to the right-hand lane of a highway.
public static final Icon HIGHWAY_KEEP_LEFT
An icon that indicates keeping to the left-hand lane of a highway.
public static final Icon ROUNDABOUT_1
An icon that indicates using the first exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_2
An icon that indicates using the second exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_3
An icon that indicates using the third exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_4
An icon that indicates using the fourth exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_5
An icon that indicates using the fifth exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_6
HERE Android SDK Developer's Guide
API Reference
1617
An icon that indicates using the sixth exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_7
An icon that indicates using the seventh exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_8
An icon that indicates using the eighth exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_9
An icon that indicates using the ninth exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_10
An icon that indicates using the tenth exit encountered while navigating a roundabout in a counter-clockwise
direction.
public static final Icon ROUNDABOUT_11
An icon that indicates using the eleventh exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_12
An icon that indicates using the twelfth exit encountered while navigating a roundabout in a counter-
clockwise direction.
public static final Icon ROUNDABOUT_1_LH
An icon that indicates using the first exit encountered while navigating a roundabout in a clockwise direction.
public static final Icon ROUNDABOUT_2_LH
An icon that indicates using the second exit encountered while navigating a roundabout in a clockwise
direction.
HERE Android SDK Developer's Guide
API Reference
1618
public static final Icon ROUNDABOUT_3_LH
An icon that indicates using the third exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_4_LH
An icon that indicates using the fourth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_5_LH
An icon that indicates using the fifth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_6_LH
An icon that indicates using the sixth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_7_LH
An icon that indicates using the seventh exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_8_LH
An icon that indicates using the eighth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_9_LH
An icon that indicates using the ninth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_10_LH
An icon that indicates using the tenth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon ROUNDABOUT_11_LH
An icon that indicates using the eleventh exit encountered while navigating a roundabout in a clockwise
direction.
HERE Android SDK Developer's Guide
API Reference
1619
public static final Icon ROUNDABOUT_12_LH
An icon that indicates using the twelfth exit encountered while navigating a roundabout in a clockwise
direction.
public static final Icon START
An icon that indicates the start point (displayed when route navigation has not yet begun).
public static final Icon END
An icon that indicates the destination point.
public static final Icon FERRY
An icon that indicates boarding a ferry.
public static final Icon PASS_STATION
An icon that indicates passing a station.
public static final Icon HEAD_TO
Leaving public transit station.
public static final Icon CHANGE_LINE
Changing public transit line.
Method Details
public int value ()
public static Icon valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
1620
public static Maneuver.Icon[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficDirection
The enumeration TrafficDirection is a member of com.here.android.mpa.routing.Maneuver.
Enumeration Summary
public static final enumeration Maneuver.TrafficDirection
extends java.lang.Enum, java.lang.Object
Represents values describing possible traffic directions, the side of road on which one must drive.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 976: Enum Constants in TrafficDirection
Fields
public static final TrafficDirection LEFT
Traffic flows on the left side of the road, as in the UK.
public static final TrafficDirection RIGHT
Traffic flows on the right side of the road, as in the USA.
Method Summary
Table 977: Methods in TrafficDirection
Methods
public int value ()
public static TrafficDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.TrafficDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible traffic directions, the side of road on which one must drive.
Enum Constant Details
public static final TrafficDirection LEFT
HERE Android SDK Developer's Guide
API Reference
1621
Traffic flows on the left side of the road, as in the UK.
public static final TrafficDirection RIGHT
Traffic flows on the right side of the road, as in the USA.
Method Details
public int value ()
public static TrafficDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Maneuver.TrafficDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Turn
The enumeration Turn is a member of com.here.android.mpa.routing.Maneuver.
Enumeration Summary
public static final enumeration Maneuver.Turn
extends java.lang.Enum, java.lang.Object
Represents values describing possible turns within a Maneuver.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 978: Enum Constants in Turn
Fields
public static final Turn UNDEFINED
An undefined turn.
HERE Android SDK Developer's Guide
API Reference
1622
Fields
public static final Turn NO_TURN
Indicates that no turn is necessary.
public static final Turn KEEP_MIDDLE
A turn that indicates keeping to the middle when a road forks.
public static final Turn KEEP_RIGHT
A turn that indicates keeping to the right when a road forks.
public static final Turn LIGHT_RIGHT
A turn that indicates making a light right turn.
public static final Turn QUITE_RIGHT
A turn that indicates making a normal right turn.
public static final Turn HEAVY_RIGHT
A turn that indicates making a heavy right turn.
public static final Turn KEEP_LEFT
A turn that indicates keeping to the left when a road forks.
public static final Turn LIGHT_LEFT
A turn that indicates making a light left turn.
public static final Turn QUITE_LEFT
A turn that indicates making a normal left turn.
public static final Turn HEAVY_LEFT
A turn that indicates making a heavy left turn.
public static final Turn RETURN
A turn that indicates turning around or making a U-turn.
public static final Turn ROUNDABOUT_1
A turn that indicates taking the first exit in a roundabout.
public static final Turn ROUNDABOUT_2
A turn that indicates taking the second exit in a roundabout.
public static final Turn ROUNDABOUT_3
A turn that indicates taking the third exit in a roundabout.
public static final Turn ROUNDABOUT_4
A turn that indicates taking the fourth exit in a roundabout.
public static final Turn ROUNDABOUT_5
A turn that indicates taking the fifth exit in a roundabout.
public static final Turn ROUNDABOUT_6
A turn that indicates taking the sixth exit in a roundabout.
HERE Android SDK Developer's Guide
API Reference
1623
Fields
public static final Turn ROUNDABOUT_7
A turn that indicates taking the seventh exit in a roundabout.
public static final Turn ROUNDABOUT_8
A turn that indicates taking the eighth exit in a roundabout.
public static final Turn ROUNDABOUT_9
A turn that indicates taking the ninth exit in a roundabout.
public static final Turn ROUNDABOUT_10
A turn that indicates taking the tenth exit in a roundabout.
public static final Turn ROUNDABOUT_11
A turn that indicates taking the eleventh exit in a roundabout.
public static final Turn ROUNDABOUT_12
A turn that indicates taking the twelfth exit in a roundabout.
Method Summary
Table 979: Methods in Turn
Methods
public int value ()
public static Turn valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.Turn[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible turns within a Maneuver.
Enum Constant Details
public static final Turn UNDEFINED
An undefined turn.
public static final Turn NO_TURN
Indicates that no turn is necessary.
public static final Turn KEEP_MIDDLE
A turn that indicates keeping to the middle when a road forks.
HERE Android SDK Developer's Guide
API Reference
1624
public static final Turn KEEP_RIGHT
A turn that indicates keeping to the right when a road forks.
public static final Turn LIGHT_RIGHT
A turn that indicates making a light right turn.
public static final Turn QUITE_RIGHT
A turn that indicates making a normal right turn.
public static final Turn HEAVY_RIGHT
A turn that indicates making a heavy right turn.
public static final Turn KEEP_LEFT
A turn that indicates keeping to the left when a road forks.
public static final Turn LIGHT_LEFT
A turn that indicates making a light left turn.
public static final Turn QUITE_LEFT
A turn that indicates making a normal left turn.
public static final Turn HEAVY_LEFT
A turn that indicates making a heavy left turn.
public static final Turn RETURN
A turn that indicates turning around or making a U-turn.
public static final Turn ROUNDABOUT_1
A turn that indicates taking the first exit in a roundabout.
public static final Turn ROUNDABOUT_2
HERE Android SDK Developer's Guide
API Reference
1625
A turn that indicates taking the second exit in a roundabout.
public static final Turn ROUNDABOUT_3
A turn that indicates taking the third exit in a roundabout.
public static final Turn ROUNDABOUT_4
A turn that indicates taking the fourth exit in a roundabout.
public static final Turn ROUNDABOUT_5
A turn that indicates taking the fifth exit in a roundabout.
public static final Turn ROUNDABOUT_6
A turn that indicates taking the sixth exit in a roundabout.
public static final Turn ROUNDABOUT_7
A turn that indicates taking the seventh exit in a roundabout.
public static final Turn ROUNDABOUT_8
A turn that indicates taking the eighth exit in a roundabout.
public static final Turn ROUNDABOUT_9
A turn that indicates taking the ninth exit in a roundabout.
public static final Turn ROUNDABOUT_10
A turn that indicates taking the tenth exit in a roundabout.
public static final Turn ROUNDABOUT_11
A turn that indicates taking the eleventh exit in a roundabout.
public static final Turn ROUNDABOUT_12
A turn that indicates taking the twelfth exit in a roundabout.
HERE Android SDK Developer's Guide
API Reference
1626
Method Details
public int value ()
public static Turn valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Maneuver.Turn[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Route
The class Route is a member of com.here.android.mpa.routing .
Class Summary
public class Route
extends java.lang.Object
Represents a distinct path connecting two or more waypoints GeoCoordinate .
[For complete information, see the section Class Details]
See also:
RouteResult
Nested Class Summary
Table 980: Nested Classes in Route
Nested Classes
public static abstract interface Route.DeserializationCallback
Callback interface for when deserialization is done, passed to deserializeAsync.
public static class Route.DeserializationResult
Represents the result of a Route de-serialization
public static final enumeration Route.EtaValidity
Enumeration used for calculating the estimated time of arrival(ETA).
HERE Android SDK Developer's Guide
API Reference
1627
Nested Classes
public static abstract interface Route.SerializationCallback
Callback interface for when serialization is done, passed to serializeAsync.
public static class Route.SerializationResult
Represents the result of a Route serialization
public static final enumeration Route.SerializerError
Represents values describing possible route serialization errors.
public static final enumeration Route.TrafficPenaltyMode
Defines the possible traffic penalty modes used for route calculation and traffic event handling.
Field Summary
Table 981: Fields in Route
Fields
public static final int WHOLE_ROUTE
See Route.getTta(TrafficPenaltyMode, int).
Method Summary
Table 982: Methods in Route
Methods
public static DeserializationResult deserialize (byte[] buffer)
Deprecated: Deprecated as of release 3.4.
Deserialize a route given a byte buffer
public static void deserializeAsync (byte[] buffer, DeserializationCallback callback)
Asynchronously serialize a Route data structure to a data buffer
public boolean equals (Object obj)
Compare with other Route using hash code
public java.util.List <RouteIntersection> getAllIntersectionsAfter (RoadElement roadElement, int
minDistance, int maxDistance)
This function returns all intersections found after the road element.
public GeoBoundingBox getBoundingBox ()
Gets the smallest GeoBoundingBox that contains the entire route.
public RouteConsumption getConsumption (ConsumptionParameters consumptionParameters, DynamicPenalty
dynamicPenalty)
Return the anticipated energy consumption for driving this route
public GeoCoordinate getDestination ()
Gets the destination coordinate for the route.
HERE Android SDK Developer's Guide
API Reference
1628
Methods
public RouteIntersection getFirstIntersectionAfter (RoadElement roadElement, int minDistance, int
maxDistance)
This function returns the first intersection found after the road element.
public Maneuver getFirstManeuver ()
Returns the first Maneuver.
public GeoCoordinate getLastReachablePosition (RouteConsumption routeConsumption, int
energyCapacity)
The last reachable waypoint given a specific consumption model The RouteConsumption passed to this method shoud
have been previously obtained from the getConsumption method.
public int getLength ()
Gets the length of the route, in meters.
public java.util.List <Maneuver> getManeuvers ()
Gets the list of all maneuvers that travelers will encounter along the route.
public List getPermanentDirectedLinkIds ()
Returns list of permanent link ids of the RouteElement objects contained in this route with their travel directions.
public List getPermanentLinkIds ()
Returns list of permanent link ids of the RouteElement objects contained in this route.
public RouteElements getRouteElements ()
Returns all RouteElements in this route.
public RouteElements getRouteElements (Maneuver maneuver)
Gets the RouteElements belonging to this Maneuver.
public RouteElements getRouteElementsFromDuration (long duration)
Gets the RouteElements for a given duration (in seconds) from the start of the route.
public RouteElements getRouteElementsFromDuration (long start, long duration)
Gets the RouteElements for a given duration (in seconds) within the route.
public RouteElements getRouteElementsFromLength (int length)
Gets the RouteElements for a given distance (in meters) within the route.
public RouteElements getRouteElementsFromLength (int start, int length)
Gets the RouteElements for a given distance (in meters) within the route.
public java.util.List <GeoCoordinate> getRouteGeometry ()
Gets the list of all GeoCoordinate values representing, in order, the polyline of the route.
public java.util.List <GeoCoordinate> getRouteGeometryWithElevationData ()
Gets the list of all GeoCoordinate values representing, in order, the polyline of the route with elevation data (if available).
public RoutePlan getRoutePlan ()
Returns the route plan for defining a route with one or more route legs.
HERE Android SDK Developer's Guide
API Reference
1629
Methods
public java.util.List <RouteWaypoint> getRouteWaypoints ()
Gets the list of all waypoints for the route.
public GeoCoordinate getStart ()
Gets the starting coordinate for the route.
public int getSublegCount ()
Returns the number of sub-legs the route has.
public TransitRouteSourceAttribution getTransitRouteSourceAttribution ()
In certain cases, data provided by Transit Agencies cannot be used without displaying copyright notices to the end user.
public RouteTta getTta (TrafficPenaltyMode mode, int subleg)
Gets the estimated time to arrival with current traffic conditions.
public java.util.List <GeoCoordinate> getWaypoints ()
Gets the list of all waypoints for the route.
public int hashCode ()
For documentation, see java.lang.Object
public static SerializationResult serialize (Route route)
Deprecated: Deprecated as of release 3.4.
Serialize a Route data structure to a data buffer
public static void serializeAsync (Route route, SerializationCallback callback)
Asynchronously serialize a Route data structure to a data buffer
Class Details
Represents a distinct path connecting two or more waypoints GeoCoordinate . A Route consists of a list of
maneuvers and route links.
See also:
RouteResult
Field Details
public static final int WHOLE_ROUTE
See Route.getTta(TrafficPenaltyMode, int).
Method Details
public static DeserializationResult deserialize (byte[] buffer)
Deprecated: Deprecated as of release 3.4.
Use deserializeAsync(byte[], Route.DeserializationCallback) instead.
HERE Android SDK Developer's Guide
API Reference
1630
Deserialize a route given a byte buffer
When deserializing a route with many waypoints, use an android.os.android.os.AsyncTask to avoid
blockage on the main thread
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Parameters:
buffer
Data buffer containing the route.
Returns:
Route.DeserializationResult object.
public static void deserializeAsync (byte[] buffer, DeserializationCallback
callback)
Asynchronously serialize a Route data structure to a data buffer
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Parameters:
buffer
Data buffer containing the route.
callback
DeserializationCallback callback which runs on the GUI thread when route deserialization is done.
public boolean equals (Object obj)
Compare with other Route using hash code
Parameters:
obj
public java.util.List <RouteIntersection> getAllIntersectionsAfter (RoadElement
roadElement, int minDistance, int maxDistance)
This function returns all intersections found after the road element. This API is not supported for reset route,
e.g. truck routing, online timetable routing.
Parameters:
roadElement
road element on the route from which search should be started
minDistance
The minimum distance from the given roadElement to the intersection
maxDistance
HERE Android SDK Developer's Guide
API Reference
1631
The maximum distance from the given roadElement to the intersection
Returns:
a List of RouteIntersections.
public GeoBoundingBox getBoundingBox ()
Gets the smallest GeoBoundingBox that contains the entire route.
Returns:
The GeoBoundingBox
public RouteConsumption getConsumption (ConsumptionParameters
consumptionParameters, DynamicPenalty dynamicPenalty)
Return the anticipated energy consumption for driving this route
IMPORTANT: Consumption calculation is a Beta feature. The related classes and methods are subject to
change without notice.
Parameters:
consumptionParameters
Consumption parameters specific to the vehicle that is to drive the route
dynamicPenalty
Restriction factors for a given area that will influence consumption
Returns:
a RouteConsumption instance containing data about the route consumption, or null if the route type
doesn't support consumption information (e.g. a transit route)
public GeoCoordinate getDestination ()
Gets the destination coordinate for the route.
Returns:
The destination GeoCoordinate
public RouteIntersection getFirstIntersectionAfter (RoadElement roadElement,
int minDistance, int maxDistance)
This function returns the first intersection found after the road element. If the road element provided ends
on the intersection this intersection will be returned. This API is not supported for reset route, e.g. truck
routing, online timetable routing.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1632
roadElement
road element on the route from which search should be started
minDistance
The minimum distance from the given roadElement to the intersection
maxDistance
The maximum distance from the given roadElement to the intersection
Returns:
a RouteIntersection if found, otherwise null if no intersection is found
public Maneuver getFirstManeuver ()
Returns the first Maneuver.
Returns:
the first Maneuver, null if there are no maneuvers
public GeoCoordinate getLastReachablePosition (RouteConsumption
routeConsumption, int energyCapacity)
The last reachable waypoint given a specific consumption model The RouteConsumption passed to
this method shoud have been previously obtained from the getConsumption method. In the case
that getConsumption was called with the default values provided by ConsumptionParameters , an
appropriate value for energyCapacity would be 300000. This would represent a vehicle with maximum
capacity. A lower value would correspond to a vehicle with lower remaining capacity which would not be able
to travel as far.
IMPORTANT: Consumption calculation is a Beta feature. The related classes and methods are subject to
change without notice.
Parameters:
routeConsumption
Specifies the parameters of consumption for a given vehicle.
energyCapacity
Available capacity at the beginning of the route
Returns:
the coordinates of the last reachable position.
public int getLength ()
Gets the length of the route, in meters.
Returns:
The route length in meters
HERE Android SDK Developer's Guide
API Reference
1633
public java.util.List <Maneuver> getManeuvers ()
Gets the list of all maneuvers that travelers will encounter along the route. If the
RouteOptions.TransportMode of the route is PUBLIC_TRANSPORT, cast the Maneuver objects to
TransitManeuver objects to get additional data about the transit route.
Returns:
The list of Maneuver objects
public List getPermanentDirectedLinkIds ()
Returns list of permanent link ids of the RouteElement objects contained in this route with their travel
directions. Will return empty list for offline calculated route or for public transport route.
Returns:
all permanent link ids
See also:
getPermanentLinkId()
getPermanentDirectedLinkId()
getPermanentLinkIds()
public List getPermanentLinkIds ()
Returns list of permanent link ids of the RouteElement objects contained in this route. Will return empty
list for offline calculated route or for public transport route.
Returns:
all permanent link ids
See also:
getPermanentLinkId()
getPermanentDirectedLinkId()
getPermanentDirectedLinkIds()
createLinkIdsRequest(Set<String>, Set<Long>)
public RouteElements getRouteElements ()
Returns all RouteElements in this route.
Returns:
all RouteElements
HERE Android SDK Developer's Guide
API Reference
1634
public RouteElements getRouteElements (Maneuver maneuver)
Gets the RouteElements belonging to this Maneuver.
Parameters:
maneuver
The Maneuver to get the RouteElements for.
Returns:
The RouteElements belonging to this Maneuver.
public RouteElements getRouteElementsFromDuration (long duration)
Gets the RouteElements for a given duration (in seconds) from the start of the route.
Parameters:
duration
The number of seconds from the beginning of the route.
Returns:
The RouteElements within the given duration.
public RouteElements getRouteElementsFromDuration (long start, long
duration)
Gets the RouteElements for a given duration (in seconds) within the route.
Parameters:
start
The number of seconds into the route to start getting RouteElements.
duration
The number of seconds from the given start of the route.
Returns:
The RouteElements within the given duration.
public RouteElements getRouteElementsFromLength (int length)
Gets the RouteElements for a given distance (in meters) within the route.
Parameters:
length
The number of meters from the beginning of the route.
Returns:
The RouteElements within the given distance.
HERE Android SDK Developer's Guide
API Reference
1635
public RouteElements getRouteElementsFromLength (int start, int length)
Gets the RouteElements for a given distance (in meters) within the route.
Parameters:
start
The number of meters into the route to start getting RouteElements.
length
The number of meters from the start parameter within this route.
Returns:
The RouteElements within the given distance.
public java.util.List <GeoCoordinate> getRouteGeometry ()
Gets the list of all GeoCoordinate values representing, in order, the polyline of the route. No elevation profile
of the route is returned. The getAltitude() always returns UNKNOWN_ALTITUDE.
Returns:
A list of GeoCoordinate values without elevation data
See also:
MapPolyline
public java.util.List <GeoCoordinate> getRouteGeometryWithElevationData ()
Gets the list of all GeoCoordinate values representing, in order, the polyline of the route with elevation
data (if available). An elevation profile of the route can be determined if the getAltitude() does not return
UNKNOWN_ALTITUDE.
Returns:
A list of GeoCoordinate values
See also:
MapPolyline
public RoutePlan getRoutePlan ()
Returns the route plan for defining a route with one or more route legs. Route legs are formed by a list of
stop overs in the route plan. Each route leg has it's own route options.
Returns:
The RoutePlan
HERE Android SDK Developer's Guide
API Reference
1636
public java.util.List <RouteWaypoint> getRouteWaypoints ()
Gets the list of all waypoints for the route.
Returns:
The list of RouteWaypoint objects.
public GeoCoordinate getStart ()
Gets the starting coordinate for the route.
Returns:
The starting GeoCoordinate
public int getSublegCount ()
Returns the number of sub-legs the route has. A sub leg is the part of a route between two stop waypoints
Returns:
number of sublegs
public TransitRouteSourceAttribution getTransitRouteSourceAttribution ()
In certain cases, data provided by Transit Agencies cannot be used without displaying copyright notices to
the end user. The copyright information is provided in the source attribution objects and must be displayed
together with a route. This requirement forms part of the terms and conditions of the API. This field will be
null for non transit routes.
Returns:
SourceAttribution Copyright info that must be displayed along with the route.
public RouteTta getTta (TrafficPenaltyMode mode, int subleg)
Gets the estimated time to arrival with current traffic conditions. If traffic is to be used, the caller is
recommended to obtain a traffic update for the route first (and wait for it to complete) to populate the traffic
database.
Parameters:
mode
The Route.TrafficPenaltyMode to be used for this calculation.
subleg
The subleg number to use or WHOLE_ROUTE for the whole route.
Returns:
The RouteTta of the subleg.
HERE Android SDK Developer's Guide
API Reference
1637
Throws:
IllegalArgumentException
if subleg is less than 0 or greater than or equal to getSublegCount().
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public java.util.List <GeoCoordinate> getWaypoints ()
Gets the list of all waypoints for the route.
Returns:
The list of GeoCoordinate objects
public int hashCode ()
For documentation, see java.lang.Object
public static SerializationResult serialize (Route route)
Deprecated: Deprecated as of release 3.4.
Use serializeAsync(Route, Route.SerializationCallback) instead.
Serialize a Route data structure to a data buffer
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Parameters:
route
Route object to serialize.
Returns:
Route.SerializationResult object.
public static void serializeAsync (Route route, SerializationCallback callback)
Asynchronously serialize a Route data structure to a data buffer
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Parameters:
route
Route object to serialize.
callback
SerializationCallback callback which runs on the GUI thread when route serialization is done.
HERE Android SDK Developer's Guide
API Reference
1638
DeserializationCallback
The interface DeserializationCallback is a member of com.here.android.mpa.routing.Route.
Interface Summary
public static abstract interface Route.DeserializationCallback
Callback interface for when deserialization is done, passed to deserializeAsync.
[For complete information, see the section Interface Details]
Method Summary
Table 983: Methods in DeserializationCallback
Methods
public abstract void onDeserializationComplete (DeserializationResult result)
Method called when deserialization is done.
Interface Details
Callback interface for when deserialization is done, passed to deserializeAsync.
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Method Details
public abstract void onDeserializationComplete (DeserializationResult result)
Method called when deserialization is done.
Parameters:
result
DeserializationResult results from deserialization.
DeserializationResult
The class DeserializationResult is a member of com.here.android.mpa.routing.Route.
Class Summary
public static class Route.DeserializationResult
extends java.lang.Object
Represents the result of a Route de-serialization
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1639
Constructor Summary
Table 984: Constructors in DeserializationResult
Constructors
DeserializationResult ()
Field Summary
Table 985: Fields in DeserializationResult
Fields
public SerializerError error
Route.SerializerError indicating the failure reason, if a failure occurred.
public Route route
A valid Route object or null if the deserialization fails.
Class Details
Represents the result of a Route de-serialization
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Constructor Details
DeserializationResult ()
Field Details
public SerializerError error
Route.SerializerError indicating the failure reason, if a failure occurred.
public Route route
A valid Route object or null if the deserialization fails. The deserialization fails when the map version from
which the route was serialized does not match current map version, the SDK version from which the route
was serialized is not compatible with current SDK version, or when the input data is empty or corrupted.
EtaValidity
The enumeration EtaValidity is a member of com.here.android.mpa.routing.Route.
HERE Android SDK Developer's Guide
API Reference
1640
Enumeration Summary
public static final enumeration Route.EtaValidity
extends java.lang.Enum, java.lang.Object
Enumeration used for calculating the estimated time of arrival(ETA).
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 986: Enum Constants in EtaValidity
Fields
public static final EtaValidity INVALID
Given route is not calculated or otherwise invalid.
public static final EtaValidity VALID
Estimated time of Arrival(ETA) is OK, route plan did not have Desired time of arrival(DTA).
public static final EtaValidity DTA_VALID
Desired time of arrival(DTA) is valid.
public static final EtaValidity DTA_LATE
Desired time of arrival(DTA) cannot be reached.
public static final EtaValidity DTA_IN_PAST
Desired time of arrival(DTA) is in the past.
Method Summary
Table 987: Methods in EtaValidity
Methods
public int value ()
public static EtaValidity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Route.EtaValidity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enumeration used for calculating the estimated time of arrival(ETA).
Enum Constant Details
public static final EtaValidity INVALID
Given route is not calculated or otherwise invalid.
HERE Android SDK Developer's Guide
API Reference
1641
public static final EtaValidity VALID
Estimated time of Arrival(ETA) is OK, route plan did not have Desired time of arrival(DTA).
public static final EtaValidity DTA_VALID
Desired time of arrival(DTA) is valid.
public static final EtaValidity DTA_LATE
Desired time of arrival(DTA) cannot be reached.
public static final EtaValidity DTA_IN_PAST
Desired time of arrival(DTA) is in the past.
Method Details
public int value ()
public static EtaValidity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Route.EtaValidity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SerializationCallback
The interface SerializationCallback is a member of com.here.android.mpa.routing.Route.
Interface Summary
public static abstract interface Route.SerializationCallback
Callback interface for when serialization is done, passed to serializeAsync.
HERE Android SDK Developer's Guide
API Reference
1642
[For complete information, see the section Interface Details]
Method Summary
Table 988: Methods in SerializationCallback
Methods
public abstract void onSerializationComplete (SerializationResult result)
Method called when serialization is done.
Interface Details
Callback interface for when serialization is done, passed to serializeAsync.
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Method Details
public abstract void onSerializationComplete (SerializationResult result)
Method called when serialization is done.
Parameters:
result
SerializationResult results from serialization.
SerializationResult
The class SerializationResult is a member of com.here.android.mpa.routing.Route.
Class Summary
public static class Route.SerializationResult
extends java.lang.Object
Represents the result of a Route serialization
[For complete information, see the section Class Details]
Constructor Summary
Table 989: Constructors in SerializationResult
Constructors
SerializationResult ()
HERE Android SDK Developer's Guide
API Reference
1643
Field Summary
Table 990: Fields in SerializationResult
Fields
public byte[] data
A byte array representing the serialized route or null if the operation failed
public SerializerError error
A Route.SerializerError indicating the failure reason, if a failure occurred.
Class Details
Represents the result of a Route serialization
When serializing a route with many waypoints, use an android.os.android.os.AsyncTask to avoid
blockage on the main thread
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Constructor Details
SerializationResult ()
Field Details
public byte[] data
A byte array representing the serialized route or null if the operation failed
public SerializerError error
A Route.SerializerError indicating the failure reason, if a failure occurred.
SerializerError
The enumeration SerializerError is a member of com.here.android.mpa.routing.Route.
Enumeration Summary
public static final enumeration Route.SerializerError
extends java.lang.Enum, java.lang.Object
Represents values describing possible route serialization errors.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1644
Enum Constant Summary
Table 991: Enum Constants in SerializerError
Fields
public static final SerializerError NONE
public static final SerializerError INVALID_PARAMETER
Parameter provided is invalid.
public static final SerializerError MAP_VERSION_MISMATCH
Map version from serialized route does not match current map version.
public static final SerializerError DATA_CORRUPTED
Data provided for de-serialization is corrupted.
public static final SerializerError TRANSPORT_MODE_NOT_SUPPORTED
Transport mode is not supported.
public static final SerializerError UNKNOWN
Generic error
Method Summary
Table 992: Methods in SerializerError
Methods
public int value ()
public static SerializerError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Route.SerializerError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible route serialization errors.
IMPORTANT: Route serialization is a Beta feature. The related classes are subject to change without notice.
Enum Constant Details
public static final SerializerError NONE
public static final SerializerError INVALID_PARAMETER
Parameter provided is invalid.
HERE Android SDK Developer's Guide
API Reference
1645
public static final SerializerError MAP_VERSION_MISMATCH
Map version from serialized route does not match current map version.
public static final SerializerError DATA_CORRUPTED
Data provided for de-serialization is corrupted.
public static final SerializerError TRANSPORT_MODE_NOT_SUPPORTED
Transport mode is not supported. Note: PUBLIC_TRANSPORT is currently not supported for route serialization.
public static final SerializerError UNKNOWN
Generic error
Method Details
public int value ()
public static SerializerError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Route.SerializerError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrafficPenaltyMode
The enumeration TrafficPenaltyMode is a member of com.here.android.mpa.routing.Route.
Enumeration Summary
public static final enumeration Route.TrafficPenaltyMode
extends java.lang.Enum, java.lang.Object
Defines the possible traffic penalty modes used for route calculation and traffic event handling.
HERE Android SDK Developer's Guide
API Reference
1646
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 993: Enum Constants in TrafficPenaltyMode
Fields
public static final TrafficPenaltyMode DISABLED
Do not consider real time traffic flow or long term road closures (usually due to construction work) when calculating a
route.
public static final TrafficPenaltyMode OPTIMAL
Create a single traffic optimized route that considers all available traffic information including real time traffic flow and
long term closures coming from real time traffic information.
public static final TrafficPenaltyMode AVOID_LONG_TERM_CLOSURES
Do NOT consider real time traffic flow but do consider long term closures coming from real time traffic information when
calculating a route.
Method Summary
Table 994: Methods in TrafficPenaltyMode
Methods
public int value ()
public static TrafficPenaltyMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Route.TrafficPenaltyMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines the possible traffic penalty modes used for route calculation and traffic event handling. Time
awareness (e.g. avoiding bridges that are closed for certain portion of a day) is not affected by traffic penalty
modes. See getTta(Route.TrafficPenaltyMode, int) .
Enum Constant Details
public static final TrafficPenaltyMode DISABLED
Do not consider real time traffic flow or long term road closures (usually due to construction work) when
calculating a route.
public static final TrafficPenaltyMode OPTIMAL
Create a single traffic optimized route that considers all available traffic information including real time
traffic flow and long term closures coming from real time traffic information.
HERE Android SDK Developer's Guide
API Reference
1647
public static final TrafficPenaltyMode AVOID_LONG_TERM_CLOSURES
Do NOT consider real time traffic flow but do consider long term closures coming from real time traffic
information when calculating a route.
Method Details
public int value ()
public static TrafficPenaltyMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Route.TrafficPenaltyMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RouteConsumption
The class RouteConsumption is a member of com.here.android.mpa.routing .
Class Summary
public final class RouteConsumption
extends java.lang.Object
Route consumptions.
[For complete information, see the section Class Details]
Constructor Summary
Table 995: Constructors in RouteConsumption
Constructors
RouteConsumption (List consumptionList, int firstAvailableConsumptionIndex)
Public constructor
HERE Android SDK Developer's Guide
API Reference
1648
Method Summary
Table 996: Methods in RouteConsumption
Methods
public int getConsumption (int elementIndex)
Provides the consumption for a route element.
public int getFirstAvailableConsumptionIndex ()
Provides the index of the first element with consumption available.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Route consumptions. Consumption describes the usage rate of a resource that is used by the vehicle, such as
electrical energy, over a period of time.
IMPORTANT: Consumption calculation is a Beta feature. The related classes are subject to change without
notice.
Constructor Details
RouteConsumption (List consumptionList, int firstAvailableConsumptionIndex)
Public constructor
Parameters:
consumptionList
The first element provides consumption for route element at first_available_consumption_index.
firstAvailableConsumptionIndex
First element for which consumption was calculated
Throws:
IllegalArgumentException
if consumptionList is null or empty.
Method Details
public int getConsumption (int elementIndex)
Provides the consumption for a route element. Returns zero when element_index is out of range or less then
first available consumption index getFirstAvailableConsumptionIndex()
Parameters:
elementIndex
Index of the route element
HERE Android SDK Developer's Guide
API Reference
1649
Returns:
Consumption value if available or '0' otherwise.
public int getFirstAvailableConsumptionIndex ()
Provides the index of the first element with consumption available. This index corresponds to the indexes in
the array of route elements returned by getRouteElements().
Returns:
Index of the route element
public int hashCode ()
For documentation, see java.lang.Object
RouteElement
The class RouteElement is a member of com.here.android.mpa.routing .
Class Summary
public final class RouteElement
extends java.lang.Object
Represents an element within a Route.
[For complete information, see the section Class Details]
See also:
Route
Maneuver
Nested Class Summary
Table 997: Nested Classes in RouteElement
Nested Classes
public static final enumeration RouteElement.Type
Represents values describing the possible types of a RouteElement.
HERE Android SDK Developer's Guide
API Reference
1650
Method Summary
Table 998: Methods in RouteElement
Methods
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of the route element.
public RoadElement getRoadElement ()
Returns the RoadElement associated with this RouteElement.
public TransitRouteElement getTransitElement ()
Returns the TransitRouteElement associated with this RouteElement
public Type getType ()
Gets the type of the RouteElement
Class Details
Represents an element within a Route. Please note that RouteElements are also associated with Maneuver
instances within a Route .
See also:
Route
Maneuver
Method Details
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of the route element. The geometry is a returned as a list of GeoCoordinate that can be
used to create a polyline.
Returns:
a list of GeoCoordinate
public RoadElement getRoadElement ()
Returns the RoadElement associated with this RouteElement. Each route element has an associated road
element.
Returns:
the associated RoadElement.
public TransitRouteElement getTransitElement ()
Returns the TransitRouteElement associated with this RouteElement
HERE Android SDK Developer's Guide
API Reference
1651
Returns:
the associated TransitRouteElement. null if getType() is not TRANSIT
public Type getType ()
Gets the type of the RouteElement
Returns:
type of the RouteElement
Type
The enumeration Type is a member of com.here.android.mpa.routing.RouteElement.
Enumeration Summary
public static final enumeration RouteElement.Type
extends java.lang.Enum, java.lang.Object
Represents values describing the possible types of a RouteElement.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 999: Enum Constants in Type
Fields
public static final Type TRANSIT
Type of RouteElement is transit.
public static final Type ROAD
Type of RouteElement is road.
public static final Type INVALID
Type of RouteElement is invalid.
Method Summary
Table 1000: Methods in Type
Methods
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1652
Methods
public static RouteElement.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the possible types of a RouteElement.
Enum Constant Details
public static final Type TRANSIT
Type of RouteElement is transit.
public static final Type ROAD
Type of RouteElement is road.
public static final Type INVALID
Type of RouteElement is invalid.
Method Details
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteElement.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RouteElements
The class RouteElements is a member of com.here.android.mpa.routing .
HERE Android SDK Developer's Guide
API Reference
1653
Class Summary
public final class RouteElements
extends java.lang.Object
Holds the list of RouteElement objects obtained from the Route class.
[For complete information, see the section Class Details]
See also:
getRouteElements()
getRouteElements(Maneuver)
getRouteElementsFromDuration(long)
getRouteElementsFromDuration(long, long)
getRouteElementsFromLength(int)
getRouteElementsFromLength(int, int)
Method Summary
Table 1001: Methods in RouteElements
Methods
public java.util.List <RouteElement> getElements ()
Returns the list of RouteElement.
public GeoPolyline getGeometry ()
Returns the GeoPolyline.
Class Details
Holds the list of RouteElement objects obtained from the Route class.
See also:
getRouteElements()
getRouteElements(Maneuver)
getRouteElementsFromDuration(long)
getRouteElementsFromDuration(long, long)
getRouteElementsFromLength(int)
getRouteElementsFromLength(int, int)
Method Details
public java.util.List <RouteElement> getElements ()
Returns the list of RouteElement.
HERE Android SDK Developer's Guide
API Reference
1654
Returns:
The list of RouteElement objects contained in this RouteElements object.
public GeoPolyline getGeometry ()
Returns the GeoPolyline. The points on the polyline represent the elements contained in this
RouteElements .
Returns:
The GeoPolyline associated with this RouteElements object.
RouteIntersection
The class RouteIntersection is a member of com.here.android.mpa.routing .
Class Summary
public final class RouteIntersection
extends java.lang.Object
This is the definition of the RouteIntersection class.
[For complete information, see the section Class Details]
Method Summary
Table 1002: Methods in RouteIntersection
Methods
public int getDistance ()
Gets the distance from the segment search started from to the intersection.
public GeoCoordinate getPosition ()
Gets the position of this intersection.
public int getRouteElementIndex ()
Gets the index of the route element before intersection
public java.util.List <RoadElement> getStreets ()
List of streets of the intersection.
Class Details
This is the definition of the RouteIntersection class. This class contains intersection on a route.
HERE Android SDK Developer's Guide
API Reference
1655
Method Details
public int getDistance ()
Gets the distance from the segment search started from to the intersection. The length of the first segment is
included.
Returns:
The distance
public GeoCoordinate getPosition ()
Gets the position of this intersection.
Returns:
The position
public int getRouteElementIndex ()
Gets the index of the route element before intersection
Returns:
The index of the route element
public java.util.List <RoadElement> getStreets ()
List of streets of the intersection. Streets which belongs to the route are not included.
Returns:
The list of RoadElement objects
RouteOptions
The class RouteOptions is a member of com.here.android.mpa.routing .
Class Summary
public class RouteOptions
extends java.lang.Object
This is the definition of the RouteOptions class.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1656
Nested Class Summary
Table 1003: Nested Classes in RouteOptions
Nested Classes
public static final enumeration RouteOptions.HazardousGoodType
Defines names for different types of hazardous goods that can be transported by a truck.
public static final enumeration RouteOptions.PublicTransportLinkFlag
Public Transport Link Flag.
public static final enumeration RouteOptions.TimeType
Ways that the time can be specified.
public static final enumeration RouteOptions.TransportMode
Represents values describing different mode of transportation a person will be using.
public static final enumeration RouteOptions.TruckRestrictionsMode
Defines way of handling road segments on which violated static truck restriction applies.
public static final enumeration RouteOptions.TruckType
Defines names for different types of trucks.
public static final enumeration RouteOptions.TunnelCategory
Specify the ADR tunnel category to restrict the truck route to.
public static final enumeration RouteOptions.Type
Represents different types of routing, such as by speed or by distance.
Constructor Summary
Table 1004: Constructors in RouteOptions
Constructors
RouteOptions ()
Public Constructor
RouteOptions (RouteOptions other)
Copy Constructor
RouteOptions (RouteOptionsImpl pimpl)
Private Constructor
Field Summary
Table 1005: Fields in RouteOptions
Fields
public static final int START_DIRECTION_ANY
Defines the value used to indicate routing may start in any direction
HERE Android SDK Developer's Guide
API Reference
1657
Fields
protected RouteOptionsImpl m_pimpl
Method Summary
Table 1006: Methods in RouteOptions
Methods
public boolean areCarShuttleTrainsAllowed ()
Checks whether Car Shuttle Trains are allowed.
public boolean areDirtRoadsAllowed ()
Checks whether Dirt Roads are allowed.
public boolean areFerriesAllowed ()
Checks whether Ferries are allowed.
public boolean areHighwaysAllowed ()
Checks whether Highways are allowed.
public boolean areParksAllowed ()
Checks whether Parks are allowed.
public boolean areTollRoadsAllowed ()
Checks whether Toll Roads are allowed.
public boolean areTunnelsAllowed ()
Checks whether Tunnels are allowed.
public boolean equals (Object obj)
public boolean getPublicTransportLinkFlag (PublicTransportLinkFlag flag)
Gets the given Public Transport Link Flag.
public int getRouteCount ()
Gets the current desired number of route
public Type getRouteType ()
Gets the Route Type, see RouteOptions.Type for valid values
public int getStartDirection ()
Returns the start direction.
public TimeType getTime (Date date)
Gets the arrival or departure time that has been set.
public int getTransitMaximumChanges ()
Gets the maximum number of vehicle changes allowed during the trip.
public int getTransitMinimumChangeTime ()
Gets transit minimum change time.
HERE Android SDK Developer's Guide
API Reference
1658
Methods
public float getTransitWalkTimeMultiplier ()
Gets a multiplier to use for walking times.
public TransportMode getTransportMode ()
Gets the Transport Mode, see RouteOptions.TransportMode for valid values
public float getTruckHeight ()
Gets the truck height in meters.
public float getTruckLength ()
Gets the truck length in meters.
public float getTruckLimitedWeight ()
Gets the limited truck weight in metric tons.
public TruckRestrictionsMode getTruckRestrictionsMode ()
Retrieves currently set RouteOptions.TruckRestrictionsMode.
public java.util.EnumSet <HazardousGoodType> getTruckShippedHazardousGoods ()
Gets the list of hazardous goods transported in the truck.
public int getTruckTrailersCount ()
Returns the number of trailers attached to the truck.
public TunnelCategory getTruckTunnelCategory ()
Gets the tunnel restrictions when calculating the truck route.
public TruckType getTruckType ()
Returns the truck type when calculating the truck route.
public float getTruckWeightPerAxle ()
Gets the truck weight per axle in metric tons.
public float getTruckWidth ()
Gets the truck width in meters.
public int hashCode ()
public boolean isCarpoolAllowed ()
Check if usage of HOV/Carpool roads is allowed.
public boolean isPublicTransportTypeAllowed (TransitType type)
Checks whether a Public Transport type is allowed.
public boolean isTruckDifficultTurnsAllowed ()
Checks whether a difficult turns are allowed.
public RouteOptions setCarShuttleTrainsAllowed (boolean value)
Sets whether Car Shuttle Trains are allowed.
public RouteOptions setCarpoolAllowed (boolean value)
Allow or disallow usage of HOV/Carpool roads.
HERE Android SDK Developer's Guide
API Reference
1659
Methods
public RouteOptions setDirtRoadsAllowed (boolean value)
Sets whether Dirt Roads are allowed.
public RouteOptions setFerriesAllowed (boolean value)
Sets whether Ferries are allowed.
public void setFetchElevationData (boolean fetchElevation)
Deprecated: As of SDK 3.3, this feature will no longer be supported.
When set, elevation data is returned with the route request.
public RouteOptions setHighwaysAllowed (boolean value)
Sets whether Highways are allowed.
public RouteOptions setParksAllowed (boolean value)
Sets whether Parks are allowed.
public RouteOptions setPublicTransportLinkFlag (PublicTransportLinkFlag flag, boolean value)
Sets the given Public Transport Link Flag.
public RouteOptions setPublicTransportTypeAllowed (TransitType type, boolean allow)
Sets whether a Public Transport Type is allowed.
public RouteOptions setRouteCount (int count)
Sets the desired number of route.
public RouteOptions setRouteType (Type routeType)
Sets the Route Type, see RouteOptions.Type for valid values
public RouteOptions setStartDirection (int dirInDegrees)
The direction that routing should start in.
public RouteOptions setTime (Date time, TimeType type)
Sets the arrival or departure time.
public RouteOptions setTollRoadsAllowed (boolean value)
Sets whether Toll Roads are allowed.
public RouteOptions setTransitMaximumChanges (int changes)
Sets the maximum number of vehicle changes allowed during the trip.
public RouteOptions setTransitMinimumChangeTime (int minutes)
Sets transit minimum change time.
public RouteOptions setTransitWalkTimeMultiplier (float value)
Sets a multiplier to use for walking times.
public RouteOptions setTransportMode (TransportMode mode)
Sets the Transport Mode.
public RouteOptions setTruckDifficultTurnsAllowed (boolean allow)
Sets whether difficult turns are allowed in result route.
HERE Android SDK Developer's Guide
API Reference
1660
Methods
public RouteOptions setTruckHeight (float meters)
Sets the truck height in meters.
public RouteOptions setTruckLength (float value)
Sets the truck length in meters.
public RouteOptions setTruckLimitedWeight (float tonnes)
Sets the limited truck weight in metric tons.
public void setTruckRestrictionsMode (TruckRestrictionsMode mode)
Sets truck restrictions handling mode.
public RouteOptions setTruckShippedHazardousGoods (java.util.EnumSet <HazardousGoodType> types)
Sets the list of hazardous goods transported in the truck.
public RouteOptions setTruckTrailersCount (int count)
Sets the number of trailers attached to the truck.
public RouteOptions setTruckTunnelCategory (TunnelCategory category)
Sets the ADR tunnel restrictions when calculating the truck route.
public RouteOptions setTruckType (TruckType truckType)
Truck type when calculating the truck route.
public RouteOptions setTruckWeightPerAxle (float tonnes)
Sets the truck weight per axle in metric tons.
public RouteOptions setTruckWidth (float value)
Sets the truck width in meters.
public RouteOptions setTunnelsAllowed (boolean value)
Sets whether Tunnels are allowed.
Class Details
This is the definition of the RouteOptions class. The class contains options for route calculation.
Constructor Details
RouteOptions ()
Public Constructor
RouteOptions (RouteOptions other)
Copy Constructor
Parameters:
other
HERE Android SDK Developer's Guide
API Reference
1661
RouteOptions to be copy from.
RouteOptions (RouteOptionsImpl pimpl)
Private Constructor
Parameters:
pimpl
The impl object to be constructed of.
Field Details
public static final int START_DIRECTION_ANY
Defines the value used to indicate routing may start in any direction
protected RouteOptionsImpl m_pimpl
Method Details
public boolean areCarShuttleTrainsAllowed ()
Checks whether Car Shuttle Trains are allowed.
Returns:
true if allowed otherwise false.
public boolean areDirtRoadsAllowed ()
Checks whether Dirt Roads are allowed.
Returns:
true if allowed otherwise false.
public boolean areFerriesAllowed ()
Checks whether Ferries are allowed.
Returns:
true if allowed otherwise false.
public boolean areHighwaysAllowed ()
HERE Android SDK Developer's Guide
API Reference
1662
Checks whether Highways are allowed.
Returns:
true if allowed otherwise false.
public boolean areParksAllowed ()
Checks whether Parks are allowed.
Returns:
true if allowed otherwise false.
public boolean areTollRoadsAllowed ()
Checks whether Toll Roads are allowed.
Returns:
true if allowed otherwise false.
public boolean areTunnelsAllowed ()
Checks whether Tunnels are allowed.
Returns:
true if allowed otherwise false.
public boolean equals (Object obj)
Parameters:
obj
public boolean getPublicTransportLinkFlag (PublicTransportLinkFlag flag)
Gets the given Public Transport Link Flag.
Parameters:
flag
one of RouteOptions.PublicTransportLinkFlag
Returns:
true if set, otherwise false.
public int getRouteCount ()
Gets the current desired number of route
HERE Android SDK Developer's Guide
API Reference
1663
Returns:
current desired number of route
public Type getRouteType ()
Gets the Route Type, see RouteOptions.Type for valid values
Returns:
The current Type.
public int getStartDirection ()
Returns the start direction. Defaults to RouteOptions::START_DIRECTION_ANY which means route in any
direction in order to obtain the shortest/fastest possible route.
Returns:
The start direction in degrees, in the range 0..359, or RouteOptions::START_DIRECTION_ANY to route in any
direction.
public TimeType getTime (Date date)
Gets the arrival or departure time that has been set.
Parameters:
date
Output parameter where the date will be set. This may be null if the caller is only interested in the
RouteOptions.TimeType.
Returns:
The TimeType of the parameter upon completion.
public int getTransitMaximumChanges ()
Gets the maximum number of vehicle changes allowed during the trip.
Returns:
number of vehicle changes
public int getTransitMinimumChangeTime ()
Gets transit minimum change time. Any connection time below this value will be bumped up to the minimum.
The default is zero.
Returns:
time in minutes
HERE Android SDK Developer's Guide
API Reference
1664
public float getTransitWalkTimeMultiplier ()
Gets a multiplier to use for walking times. A higher number means a slower walking speed. The default is 1.0.
Returns:
multiplier
public TransportMode getTransportMode ()
Gets the Transport Mode, see RouteOptions.TransportMode for valid values
Returns:
The TransportMode to be used for this RouteOptions.
public float getTruckHeight ()
Gets the truck height in meters. Applicable to truck routing only.
Returns:
The truck height in meters ( java.lang.Float#NaN if undefined).
public float getTruckLength ()
Gets the truck length in meters. Applicable to truck routing only.
Returns:
The truck length in meters ( java.lang.Float#NaN if undefined).
public float getTruckLimitedWeight ()
Gets the limited truck weight in metric tons. Applicable to truck routing only.
Returns:
The limited truck weight in metric tons ( java.lang.Float#NaN if undefined).
public TruckRestrictionsMode getTruckRestrictionsMode ()
Retrieves currently set RouteOptions.TruckRestrictionsMode.
Returns:
Truck restrictions mode.
HERE Android SDK Developer's Guide
API Reference
1665
public java.util.EnumSet <HazardousGoodType> getTruckShippedHazardousGoods
()
Gets the list of hazardous goods transported in the truck. Applicable to truck routing only.
Returns:
Set of RouteOptions.HazardousGoodTypes transported by the truck.
public int getTruckTrailersCount ()
Returns the number of trailers attached to the truck. Applicable to truck routing only.
Returns:
number of trailers attached to the truck.
public TunnelCategory getTruckTunnelCategory ()
Gets the tunnel restrictions when calculating the truck route. Applicable to truck routing only.
Returns:
ADR tunnel category.
public TruckType getTruckType ()
Returns the truck type when calculating the truck route. Applicable to truck routing only.
Returns:
truck type.
public float getTruckWeightPerAxle ()
Gets the truck weight per axle in metric tons. Applicable to truck routing only.
Returns:
The truck weight per axle in metric tons ( java.lang.Float#NaN if undefined).
public float getTruckWidth ()
Gets the truck width in meters. Applicable to truck routing only.
Returns:
The truck width in meters ( java.lang.Float#NaN if undefined).
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1666
public boolean isCarpoolAllowed ()
Check if usage of HOV/Carpool roads is allowed.
Returns:
true if allowed, otherwise false.
public boolean isPublicTransportTypeAllowed (TransitType type)
Checks whether a Public Transport type is allowed.
Parameters:
type
One of the public transport TransitType values to check if it is allowed.
Returns:
true if allowed, otherwise false.
public boolean isTruckDifficultTurnsAllowed ()
Checks whether a difficult turns are allowed.
Returns:
true if allowed, otherwise false.
public RouteOptions setCarShuttleTrainsAllowed (boolean value)
Sets whether Car Shuttle Trains are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
The modified RouteOptions itself.
public RouteOptions setCarpoolAllowed (boolean value)
Allow or disallow usage of HOV/Carpool roads.
Parameters:
value
Use true if allowed, otherwise false.
Returns:
HERE Android SDK Developer's Guide
API Reference
1667
The modified RouteOptions itself.
public RouteOptions setDirtRoadsAllowed (boolean value)
Sets whether Dirt Roads are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
The modified RouteOptions itself.
public RouteOptions setFerriesAllowed (boolean value)
Sets whether Ferries are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
The modified RouteOptions itself.
public void setFetchElevationData (boolean fetchElevation)
Deprecated: As of SDK 3.3, this feature will no longer be supported.
Elevation data will be requested for all routes automatically in online/offline modes. The data will be returned in the Route
geometry, when available.
When set, elevation data is returned with the route request. Elevation data returned as altitude and a part of
route geometry.
Parameters:
fetchElevation
true if data should be fetched
public RouteOptions setHighwaysAllowed (boolean value)
Sets whether Highways are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
HERE Android SDK Developer's Guide
API Reference
1668
The modified RouteOptions itself.
public RouteOptions setParksAllowed (boolean value)
Sets whether Parks are allowed.
Parameters:
value
Use true if allowed, otherwise false.
Returns:
The modified RouteOptions itself.
public RouteOptions setPublicTransportLinkFlag (PublicTransportLinkFlag flag,
boolean value)
Sets the given Public Transport Link Flag.
Parameters:
flag
one of RouteOptions.PublicTransportLinkFlag
value
true if set, otherwise false.
Returns:
The modified RouteOptions itself.
public RouteOptions setPublicTransportTypeAllowed (TransitType type, boolean
allow)
Sets whether a Public Transport Type is allowed. By default all types are allowed.
Parameters:
type
public transport type, see TransitType for valid values.
allow
a boolean to allow/disallow a transit type
Returns:
The modified RouteOptions itself.
public RouteOptions setRouteCount (int count)
Sets the desired number of route. The default is 1.
HERE Android SDK Developer's Guide
API Reference
1669
Values greater than 10 are ignored if RouteOptions.TransportMode is set to public transport and online
timetables are enabled. Only one route will be returned for routes with more than two RouteWaypoint.
NOTE: If UMRouter is used, then allowed range is [1, 6]. Using unsupported value will result error response in
route calculation.
Parameters:
count
route count
Returns:
The modified RouteOptions itself.
public RouteOptions setRouteType (Type routeType)
Sets the Route Type, see RouteOptions.Type for valid values
Parameters:
routeType
Type
Returns:
The modified RouteOptions itself.
public RouteOptions setStartDirection (int dirInDegrees)
The direction that routing should start in. Use values between 0..359. If a value greater than 359 is specified,
the modulus of 360 is used. Specify RouteOptions::START_DIRECTION_ANY (or greater) to route in any
direction.
Parameters:
dirInDegrees
Start direction in degrees. 0 is north, increases clockwise (ie. 90 is east).
Returns:
The modified RouteOptions itself.
public RouteOptions setTime (Date time, TimeType type)
Sets the arrival or departure time.
Parameters:
time
The time to set.
type
The type of time to set.
HERE Android SDK Developer's Guide
API Reference
1670
Returns:
The modified RouteOptions itself.
public RouteOptions setTollRoadsAllowed (boolean value)
Sets whether Toll Roads are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
The modified RouteOptions itself.
public RouteOptions setTransitMaximumChanges (int changes)
Sets the maximum number of vehicle changes allowed during the trip.
Note: For UMRouteOptions case maximum supported changes is 6.
Parameters:
changes
number of vehicle changes
Returns:
The modified RouteOptions itself.
public RouteOptions setTransitMinimumChangeTime (int minutes)
Sets transit minimum change time. Any connection time below this value will be bumped up to the minimum.
The default is zero.
Parameters:
minutes
time in minutes
Returns:
The modified RouteOptions itself.
public RouteOptions setTransitWalkTimeMultiplier (float value)
Sets a multiplier to use for walking times. A higher number means a slower walking speed. The default is 1.0.
Note: For UMRouteOptions case supported range is [0.5, 2.0].
Parameters:
HERE Android SDK Developer's Guide
API Reference
1671
value
multiplier
Returns:
The modified RouteOptions itself.
public RouteOptions setTransportMode (TransportMode mode)
Sets the Transport Mode.
Parameters:
mode
The desired RouteOptions.TransportMode to use.
Returns:
The modified RouteOptions itself.
public RouteOptions setTruckDifficultTurnsAllowed (boolean allow)
Sets whether difficult turns are allowed in result route. By default difficult turns are allowed.
Parameters:
allow
a boolean to allow/disallow difficult turns.
Returns:
The modified RouteOptions itself.
public RouteOptions setTruckHeight (float meters)
Sets the truck height in meters. Applicable to truck routing only.
Parameters:
meters
The truck height in meters. A value of Float#NaN will unset this option.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if height is not greater than zero.
public RouteOptions setTruckLength (float value)
HERE Android SDK Developer's Guide
API Reference
1672
Sets the truck length in meters. Applicable to truck routing only.
Parameters:
value
The truck length in meters. A value of Float#NaN will unset this option.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if length is not greater than zero.
public RouteOptions setTruckLimitedWeight (float tonnes)
Sets the limited truck weight in metric tons. Applicable to truck routing only.
Parameters:
tonnes
The limited truck weight in metric tons. A value of Float#NaN will unset this option.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if weight is not greater than zero.
public void setTruckRestrictionsMode (TruckRestrictionsMode mode)
Sets truck restrictions handling mode. If no mode is explicitly set then NO_VIOLATIONS option will be used.
Parameters:
mode
The truck restrictions mode.
public RouteOptions setTruckShippedHazardousGoods (java.util.EnumSet
<HazardousGoodType> types)
Sets the list of hazardous goods transported in the truck. Applicable to truck routing only.
Parameters:
types
Set of RouteOptions.HazardousGoodTypes transported by the truck.
Returns:
HERE Android SDK Developer's Guide
API Reference
1673
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if value is null.
public RouteOptions setTruckTrailersCount (int count)
Sets the number of trailers attached to the truck. Applicable to truck routing only.
Parameters:
count
The number of trailers attached to the truck.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if the count is negative.
public RouteOptions setTruckTunnelCategory (TunnelCategory category)
Sets the ADR tunnel restrictions when calculating the truck route. Applicable to truck routing only.
Parameters:
category
The ADR tunnel category.
Returns:
The modified RouteOptions itself.
public RouteOptions setTruckType (TruckType truckType)
Truck type when calculating the truck route. Applicable to truck routing only.
Parameters:
truckType
The truck type.
Returns:
The modified RouteOptions itself.
public RouteOptions setTruckWeightPerAxle (float tonnes)
HERE Android SDK Developer's Guide
API Reference
1674
Sets the truck weight per axle in metric tons. Applicable to truck routing only.
Parameters:
tonnes
The truck weight per axle in metric tons. A value of Float#NaN will unset this option.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if weight is not greater than zero.
public RouteOptions setTruckWidth (float value)
Sets the truck width in meters. Applicable to truck routing only.
Parameters:
value
The truck width in meters. A value of Float#NaN will unset this option.
Returns:
The modified RouteOptions itself.
Throws:
IllegalArgumentException
if width is not greater than zero.
public RouteOptions setTunnelsAllowed (boolean value)
Sets whether Tunnels are allowed.
Parameters:
value
true if allowed otherwise false.
Returns:
The modified RouteOptions itself.
HazardousGoodType
The enumeration HazardousGoodType is a member of com.here.android.mpa.routing.RouteOptions.
HERE Android SDK Developer's Guide
API Reference
1675
Enumeration Summary
public static final enumeration RouteOptions.HazardousGoodType
extends java.lang.Enum, java.lang.Object
Defines names for different types of hazardous goods that can be transported by a truck.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1007: Enum Constants in HazardousGoodType
Fields
public static final HazardousGoodType EXPLOSIVE
Explosive material
public static final HazardousGoodType GAS
Gas
public static final HazardousGoodType FLAMMABLE
Flammable material
public static final HazardousGoodType COMBUSTIBLE
Combustible material
public static final HazardousGoodType ORGANIC
Organic material
public static final HazardousGoodType POISON
Poison
public static final HazardousGoodType RADIOACTIVE
Radio-active material
public static final HazardousGoodType CORROSIVE
Corrosive material
public static final HazardousGoodType POISONOUS_INHALATION
Goods which are poisonous upon inhalation
public static final HazardousGoodType HARMFUL_TO_WATER
Goods which are harmful to water
public static final HazardousGoodType OTHER
Other types of hazardous goods
HERE Android SDK Developer's Guide
API Reference
1676
Method Summary
Table 1008: Methods in HazardousGoodType
Methods
public static HazardousGoodType getType (int value)
public int toInt ()
public static HazardousGoodType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.HazardousGoodType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines names for different types of hazardous goods that can be transported by a truck.
Enum Constant Details
public static final HazardousGoodType EXPLOSIVE
Explosive material
public static final HazardousGoodType GAS
Gas
public static final HazardousGoodType FLAMMABLE
Flammable material
public static final HazardousGoodType COMBUSTIBLE
Combustible material
public static final HazardousGoodType ORGANIC
Organic material
public static final HazardousGoodType POISON
Poison
public static final HazardousGoodType RADIOACTIVE
HERE Android SDK Developer's Guide
API Reference
1677
Radio-active material
public static final HazardousGoodType CORROSIVE
Corrosive material
public static final HazardousGoodType POISONOUS_INHALATION
Goods which are poisonous upon inhalation
public static final HazardousGoodType HARMFUL_TO_WATER
Goods which are harmful to water
public static final HazardousGoodType OTHER
Other types of hazardous goods
Method Details
public static HazardousGoodType getType (int value)
Parameters:
value
public int toInt ()
public static HazardousGoodType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.HazardousGoodType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1678
PublicTransportLinkFlag
The enumeration PublicTransportLinkFlag is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.PublicTransportLinkFlag
extends java.lang.Enum, java.lang.Object
Public Transport Link Flag.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1009: Enum Constants in PublicTransportLinkFlag
Fields
public static final PublicTransportLinkFlag ONLY_SLEEPER
Only return connections using sleeper wagon
public static final PublicTransportLinkFlag ONLY_BARRIER_FREE
Only return barrier-free connections
Method Summary
Table 1010: Methods in PublicTransportLinkFlag
Methods
public static PublicTransportLinkFlag valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.PublicTransportLinkFlag[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Public Transport Link Flag.
Enum Constant Details
public static final PublicTransportLinkFlag ONLY_SLEEPER
Only return connections using sleeper wagon
public static final PublicTransportLinkFlag ONLY_BARRIER_FREE
HERE Android SDK Developer's Guide
API Reference
1679
Only return barrier-free connections
Method Details
public static PublicTransportLinkFlag valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.PublicTransportLinkFlag[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TimeType
The enumeration TimeType is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.TimeType
extends java.lang.Enum, java.lang.Object
Ways that the time can be specified.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1011: Enum Constants in TimeType
Fields
public static final TimeType DEPARTURE
Departure time.
public static final TimeType ARRIVAL
Arrival time.
HERE Android SDK Developer's Guide
API Reference
1680
Method Summary
Table 1012: Methods in TimeType
Methods
public int value ()
public static TimeType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.TimeType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Ways that the time can be specified.
Enum Constant Details
public static final TimeType DEPARTURE
Departure time.
public static final TimeType ARRIVAL
Arrival time.
NOTE: ARRIVAL time type option is supported only for UMRouteOptions. Using this value in
RouteOptions.setTime(Date, TimeType), with unsupported RouteOptions , will result in
INVALID_PARAMETERS when requesting a route.
Method Details
public int value ()
public static TimeType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.TimeType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1681
TransportMode
The enumeration TransportMode is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.TransportMode
extends java.lang.Enum, java.lang.Object
Represents values describing different mode of transportation a person will be using.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1013: Enum Constants in TransportMode
Fields
public static final TransportMode CAR
A car is being used as the mode of transportation.
public static final TransportMode PEDESTRIAN
Walking is being used as the mode of transportation.
public static final TransportMode PUBLIC_TRANSPORT
Public transport is being used as the mode of transportation.
public static final TransportMode TRACK
Deprecated: As of SDK 3.3 TRACK mode is no longer supported and a route will not be calculated if using this mode.
Straight line connecting the waypoints of a route.
public static final TransportMode TRUCK
Enterprise truck routing mode.
public static final TransportMode BICYCLE
A bicycle is being used as the mode of transportation.
public static final TransportMode UNDEFINED
Routing mode unknown or unsupported
Method Summary
Table 1014: Methods in TransportMode
Methods
public static TransportMode getMode (int value)
public int value ()
HERE Android SDK Developer's Guide
API Reference
1682
Methods
public static TransportMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.TransportMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing different mode of transportation a person will be using. (for example, Car, or
Public Transit).
Enum Constant Details
public static final TransportMode CAR
A car is being used as the mode of transportation.
public static final TransportMode PEDESTRIAN
Walking is being used as the mode of transportation. When calculating a Route using PEDESTRIAN, Type will
be reset to FASTEST
public static final TransportMode PUBLIC_TRANSPORT
Public transport is being used as the mode of transportation. When calculating a Route using
PUBLIC_TRANSPORT, Type will be reset to FASTEST
Note: a transit route may not be found if the walking distance from the start to the first transit station, or
from the final transit station to the end, is greater than 3 kilometers.
To use this feature, your application must include the google-gson library (release 2.2.4 or a compatible
version) on its class path. This library can be downloaded from the google-gson project website at http://
code.google.com/p/google-gson/. Attempting to use this feature without adding this library will cause
runtime errors.
public static final TransportMode TRACK
Deprecated: As of SDK 3.3 TRACK mode is no longer supported and a route will not be calculated if using this mode.
Please see CoreRouter.calculateRoute for more information.
Straight line connecting the waypoints of a route.
public static final TransportMode TRUCK
Enterprise truck routing mode. When calculating a route using TRUCK mode, only FASTEST will be supported.
HERE Android SDK Developer's Guide
API Reference
1683
public static final TransportMode BICYCLE
A bicycle is being used as the mode of transportation. This is a BETA feature.
public static final TransportMode UNDEFINED
Routing mode unknown or unsupported
Method Details
public static TransportMode getMode (int value)
Parameters:
value
public int value ()
public static TransportMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.TransportMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TruckRestrictionsMode
The enumeration TruckRestrictionsMode is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.TruckRestrictionsMode
extends java.lang.Enum, java.lang.Object
Defines way of handling road segments on which violated static truck restriction applies.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1684
Enum Constant Summary
Table 1015: Enum Constants in TruckRestrictionsMode
Fields
public static final TruckRestrictionsMode NO_VIOLATIONS
In those mode violating road segments will not be part of the route.
public static final TruckRestrictionsMode PENALIZE_VIOLATIONS
In those mode violating road segments can be part of the route, if no other route can be calculated.
Method Summary
Table 1016: Methods in TruckRestrictionsMode
Methods
public static TruckRestrictionsMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.TruckRestrictionsMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines way of handling road segments on which violated static truck restriction applies. When mode is set
to NO_VIOLATIONS then such segments will not be part of the route. PENALIZE_VIOLATIONS is relaxed way
of handling restrictions. Streets where truck restrictions are violated will be avoided, but if there is no way
around route will go through restricted streets. WARNING: Route calculated with this option cannot be used
for navigation. Typical use case is route calculation with imprecise start/destination for planning purpose
when user wants to know some statistics data like estimated length, countries crossed. With this option route
will be calculated even if it starts/ends in restricted areas. When no mode is explicitly set NO_VIOLATIONS
mode is used for route calculation. This option does not affect time dependent truck restrictions.
Enum Constant Details
public static final TruckRestrictionsMode NO_VIOLATIONS
In those mode violating road segments will not be part of the route.
public static final TruckRestrictionsMode PENALIZE_VIOLATIONS
In those mode violating road segments can be part of the route, if no other route can be calculated.
Method Details
public static TruckRestrictionsMode valueOf (String name)
HERE Android SDK Developer's Guide
API Reference
1685
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.TruckRestrictionsMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TruckType
The enumeration TruckType is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.TruckType
extends java.lang.Enum, java.lang.Object
Defines names for different types of trucks.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1017: Enum Constants in TruckType
Fields
public static final TruckType TRUCK
TRUCK TYPE
public static final TruckType TRACTOR_TRUCK
TRACTOR TYPE
Method Summary
Table 1018: Methods in TruckType
Methods
public static TruckType getType (int value)
public int toInt ()
public static TruckType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1686
Methods
public static RouteOptions.TruckType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines names for different types of trucks.
Enum Constant Details
public static final TruckType TRUCK
TRUCK TYPE
public static final TruckType TRACTOR_TRUCK
TRACTOR TYPE
Method Details
public static TruckType getType (int value)
Parameters:
value
public int toInt ()
public static TruckType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.TruckType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TunnelCategory
The enumeration TunnelCategory is a member of com.here.android.mpa.routing.RouteOptions.
HERE Android SDK Developer's Guide
API Reference
1687
Enumeration Summary
public static final enumeration RouteOptions.TunnelCategory
extends java.lang.Enum, java.lang.Object
Specify the ADR tunnel category to restrict the truck route to.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1019: Enum Constants in TunnelCategory
Fields
public static final TunnelCategory B
ADR tunnel category B
public static final TunnelCategory C
ADR tunnel category C
public static final TunnelCategory D
ADR tunnel category D
public static final TunnelCategory E
ADR tunnel category D
public static final TunnelCategory UNDEFINED
Undefined tunnel category
Method Summary
Table 1020: Methods in TunnelCategory
Methods
public static TunnelCategory getCategory (int value)
public int toInt ()
public static TunnelCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.TunnelCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specify the ADR tunnel category to restrict the truck route to.
Enum Constant Details
public static final TunnelCategory B
HERE Android SDK Developer's Guide
API Reference
1688
ADR tunnel category B
public static final TunnelCategory C
ADR tunnel category C
public static final TunnelCategory D
ADR tunnel category D
public static final TunnelCategory E
ADR tunnel category D
public static final TunnelCategory UNDEFINED
Undefined tunnel category
Method Details
public static TunnelCategory getCategory (int value)
Parameters:
value
public int toInt ()
public static TunnelCategory valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.TunnelCategory[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1689
Type
The enumeration Type is a member of com.here.android.mpa.routing.RouteOptions.
Enumeration Summary
public static final enumeration RouteOptions.Type
extends java.lang.Enum, java.lang.Object
Represents different types of routing, such as by speed or by distance.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1021: Enum Constants in Type
Fields
public static final Type FASTEST
Search for the fastest route (minimizes travel time).
public static final Type SHORTEST
Search for the shortest route (minimizes travel distance).
public static final Type BALANCED
Search for balanced route, some travel time may be sacrificed in order to reduce the distance traveled.
Method Summary
Table 1022: Methods in Type
Methods
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteOptions.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents different types of routing, such as by speed or by distance.
Note: a Type has no effect on PEDESTRIAN or PUBLIC_TRANSPORT transport modes, since they always use
FASTEST (if SHORTEST is set as the Type when one of these TransportMode types is selected, it will be
reset to FASTEST when a Route is calculated). For TRUCK, however, using any Type other than FASTEST will
result in INVALID_PARAMETERS being returned when calculating a route.
HERE Android SDK Developer's Guide
API Reference
1690
Enum Constant Details
public static final Type FASTEST
Search for the fastest route (minimizes travel time).
public static final Type SHORTEST
Search for the shortest route (minimizes travel distance). Car Mode Only.
public static final Type BALANCED
Search for balanced route, some travel time may be sacrificed in order to reduce the distance traveled. It
calculates the optimal route based on time and distance combination. Car Mode Only.
Method Details
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteOptions.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RoutePlan
The class RoutePlan is a member of com.here.android.mpa.routing .
Class Summary
public final class RoutePlan
extends java.lang.Object
RoutePlan contains all information needed to calculate a Route.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1691
See also:
RouteWaypoint
Router
Constructor Summary
Table 1023: Constructors in RoutePlan
Constructors
RoutePlan ()
Public Constructor
RoutePlan (RoutePlan other)
Copy Constructor
Method Summary
Table 1024: Methods in RoutePlan
Methods
public RoutePlan addWaypoint (RouteWaypoint point)
Adds a waypoint to the plan.
public boolean equals (Object obj)
public RouteOptions getRouteOptions ()
Gets a copy of the current route options used with this RoutePlan .
public RouteWaypoint getWaypoint (int index)
Gets a waypoint at a specified index.
public int getWaypointCount ()
Gets the number of waypoints of the route plan.
public int hashCode ()
public RoutePlan insertWaypoint (RouteWaypoint point, int index)
Inserts a waypoint into a list of existing waypoints.
public RoutePlan removeAllWaypoints ()
Removes all waypoints of the route plan.
public RoutePlan removeWaypoint (int index)
Removes a waypoint at a specified index.
public RoutePlan setRouteOptions (RouteOptions options)
Sets the route options.
HERE Android SDK Developer's Guide
API Reference
1692
Class Details
RoutePlan contains all information needed to calculate a Route.
However, the first and last waypoints used for route calculation must be of
RouteWaypoint.Type.STOP_WAYPOINT type, otherwise, the error INVALID_PARAMETERS will be returned.
While there is no maximum limit imposed on how many waypoints is allowed for a route, increasing the
number of waypoints increases the probability that the route request will fail and a safe upper limit of 128 is
recommended.
See also:
RouteWaypoint
Router
Constructor Details
RoutePlan ()
Public Constructor
RoutePlan (RoutePlan other)
Copy Constructor
Parameters:
other
RoutePlan object to copy from.
Method Details
public RoutePlan addWaypoint (RouteWaypoint point)
Adds a waypoint to the plan.
The first and last waypoints used for route calculation must be of RouteWaypoint.Type.STOP_WAYPOINT
type.
NOTE: Urban Mobility supports only 2 waypoints. If UMRouter is used, then adding more than 2 waypoints will
result in getting an estimated Public Transport routes.
Parameters:
point
The RouteWaypoint representing the waypoint to add.
Returns:
This RoutePlan object
HERE Android SDK Developer's Guide
API Reference
1693
public boolean equals (Object obj)
Parameters:
obj
public RouteOptions getRouteOptions ()
Gets a copy of the current route options used with this RoutePlan . Any changes made to the RouteOptions
object returned by this method must be used to call setRouteOptions(RouteOptions) again for the changes to
be in effect.
Returns:
RouteOptions options associated with this plan.
public RouteWaypoint getWaypoint (int index)
Gets a waypoint at a specified index.
Parameters:
index
The zero-based index.
Returns:
the waypoint, null if the index submitted is out of bounds.
public int getWaypointCount ()
Gets the number of waypoints of the route plan.
Returns:
the number of waypoints.
public int hashCode ()
public RoutePlan insertWaypoint (RouteWaypoint point, int index)
Inserts a waypoint into a list of existing waypoints. The position of the new waypoint is according to the
specified index.
The first and last waypoints used for route calculation must be of RouteWaypoint.Type.STOP_WAYPOINT
type.
NOTE: Urban Mobility supports only 2 waypoints. If UMRouter is used, then adding more than 2 waypoints will
result in getting an estimated Public Transport routes.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1694
point
The waypoint to insert
index
The index in the range from 0 to the number of already existing waypoints.
Returns:
This RoutePlan object
public RoutePlan removeAllWaypoints ()
Removes all waypoints of the route plan.
Returns:
This RoutePlan object
public RoutePlan removeWaypoint (int index)
Removes a waypoint at a specified index.
The first and last waypoints used for route calculation must of be RouteWaypoint.Type.STOP_WAYPOINT
type.
Parameters:
index
The zero-based index.
Returns:
This RoutePlan object
public RoutePlan setRouteOptions (RouteOptions options)
Sets the route options. This method does not retain a reference to options . If the options object is
updated, then this method must be called again for the changes to be in effect.
Parameters:
options
The RouteOptions to set.
Returns:
This RoutePlan object
RouteResult
The class RouteResult is a member of com.here.android.mpa.routing .
HERE Android SDK Developer's Guide
API Reference
1695
Class Summary
public class RouteResult
extends java.lang.Object
This is the definition of the RouteResult class.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1025: Nested Classes in RouteResult
Nested Classes
public static final enumeration RouteResult.ViolatedOption
These are options which may be ignored by the routing engine; in such cases a list of violated options is returned in the
listener's on_end() method.
Method Summary
Table 1026: Methods in RouteResult
Methods
public Route getRoute ()
Returns the Route in the RouteResult.
public java.util.EnumSet <ViolatedOption> getViolatedOptions ()
Gets the violated options.
Class Details
This is the definition of the RouteResult class. It contains a Route as a result of route calculation and a list of
possible RouteResult.ViolatedOption
Method Details
public Route getRoute ()
Returns the Route in the RouteResult.
Returns:
The Route
public java.util.EnumSet <ViolatedOption> getViolatedOptions ()
Gets the violated options.
Returns:
Set of RouteResult.ViolatedOption
HERE Android SDK Developer's Guide
API Reference
1696
ViolatedOption
The enumeration ViolatedOption is a member of com.here.android.mpa.routing.RouteResult.
Enumeration Summary
public static final enumeration RouteResult.ViolatedOption
extends java.lang.Enum, java.lang.Object
These are options which may be ignored by the routing engine; in such cases a list of violated options is
returned in the listener's on_end() method.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1027: Enum Constants in ViolatedOption
Fields
public static final ViolatedOption AVOID_HIGHWAYS
The route uses highways although ALLOW_HIGHWAYS was false.
public static final ViolatedOption AVOID_TOLL_ROADS
The route uses toll roads although ALLOW_TOLLROADS was false.
public static final ViolatedOption AVOID_FERRIES
The route uses ferries although ALLOW_FERRIES was false.
public static final ViolatedOption AVOID_TUNNELS
The route uses tunnels although ALLOW_TUNNELS was false.
public static final ViolatedOption AVOID_DIRT_ROADS
The route uses dirt roads although ALLOW_DIRTROADS was false.
public static final ViolatedOption AVOID_CAR_SHUTTLE_TRAINS
The route uses rail ferries although AVOID_CARSHUTTLETRAINS was false.
public static final ViolatedOption AVOID_PARKS
The route uses paths through parks although ALLOW_PARKS was false.
public static final ViolatedOption BLOCKED_ROADS
The route uses roads which were blocked by dynamic penalties.
public static final ViolatedOption START_DIRECTION
The route's start direction is not as requested.
public static final ViolatedOption CARPOOL
The route uses CARPOOL streets even though it is disabled in the options
HERE Android SDK Developer's Guide
API Reference
1697
Fields
public static final ViolatedOption TIME_RESTRICTED_TURN
The route uses a time-restricted turn
public static final ViolatedOption PERMANENT_TRUCK_RESTRICTION
The route uses roads or turns which are permanently forbidden for given truck
Method Summary
Table 1028: Methods in ViolatedOption
Methods
public int value ()
public static ViolatedOption valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteResult.ViolatedOption[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
These are options which may be ignored by the routing engine; in such cases a list of violated options is
returned in the listener's on_end() method.
Enum Constant Details
public static final ViolatedOption AVOID_HIGHWAYS
The route uses highways although ALLOW_HIGHWAYS was false.
public static final ViolatedOption AVOID_TOLL_ROADS
The route uses toll roads although ALLOW_TOLLROADS was false.
public static final ViolatedOption AVOID_FERRIES
The route uses ferries although ALLOW_FERRIES was false.
public static final ViolatedOption AVOID_TUNNELS
The route uses tunnels although ALLOW_TUNNELS was false.
public static final ViolatedOption AVOID_DIRT_ROADS
The route uses dirt roads although ALLOW_DIRTROADS was false.
HERE Android SDK Developer's Guide
API Reference
1698
public static final ViolatedOption AVOID_CAR_SHUTTLE_TRAINS
The route uses rail ferries although AVOID_CARSHUTTLETRAINS was false.
public static final ViolatedOption AVOID_PARKS
The route uses paths through parks although ALLOW_PARKS was false.
public static final ViolatedOption BLOCKED_ROADS
The route uses roads which were blocked by dynamic penalties.
public static final ViolatedOption START_DIRECTION
The route's start direction is not as requested.
public static final ViolatedOption CARPOOL
The route uses CARPOOL streets even though it is disabled in the options
public static final ViolatedOption TIME_RESTRICTED_TURN
The route uses a time-restricted turn
public static final ViolatedOption PERMANENT_TRUCK_RESTRICTION
The route uses roads or turns which are permanently forbidden for given truck
Method Details
public int value ()
public static ViolatedOption valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
1699
public static RouteResult.ViolatedOption[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RouteTta
The class RouteTta is a member of com.here.android.mpa.routing .
Class Summary
public final class RouteTta
extends java.lang.Object
Describes Time To Arrival details for a given route.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1029: Nested Classes in RouteTta
Nested Classes
public static final enumeration RouteTta.Detail
Additional Time To Arrival Details
Method Summary
Table 1030: Methods in RouteTta
Methods
public java.util.EnumSet <Detail> getDetails ()
Details of the blockage (if any).
public int getDuration ()
Gets the duration in seconds.
public boolean isBlocked ()
Whether this time to arrival is blocked.
Class Details
Describes Time To Arrival details for a given route.
Method Details
public java.util.EnumSet <Detail> getDetails ()
Details of the blockage (if any).
HERE Android SDK Developer's Guide
API Reference
1700
Returns:
The set of all blockage details.
public int getDuration ()
Gets the duration in seconds.
Returns:
The duration in seconds.
public boolean isBlocked ()
Whether this time to arrival is blocked. Note that it is possible to get a valid duration when the route is
blocked. See getDetails() for more information.
Returns:
Whether this time to arrival is blocked.
Detail
The enumeration Detail is a member of com.here.android.mpa.routing.RouteTta.
Enumeration Summary
public static final enumeration RouteTta.Detail
extends java.lang.Enum, java.lang.Object
Additional Time To Arrival Details
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1031: Enum Constants in Detail
Fields
public static final Detail BLOCKED_ROAD
A blocked road is present.
public static final Detail CARPOOL
A carpool restricted lane is present.
public static final Detail RESTRICTED_TURN
A restricted turn is present.
HERE Android SDK Developer's Guide
API Reference
1701
Method Summary
Table 1032: Methods in Detail
Methods
public int getValue ()
public static Detail valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteTta.Detail[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Additional Time To Arrival Details
Enum Constant Details
public static final Detail BLOCKED_ROAD
A blocked road is present.
public static final Detail CARPOOL
A carpool restricted lane is present.
public static final Detail RESTRICTED_TURN
A restricted turn is present.
Method Details
public int getValue ()
public static Detail valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteTta.Detail[] values ()
HERE Android SDK Developer's Guide
API Reference
1702
This method retrieves an array of constants of the given enum type in the order in which they are declared.
RouteWaypoint
The class RouteWaypoint is a member of com.here.android.mpa.routing .
Class Summary
public final class RouteWaypoint
extends java.lang.Object
Represents a waypoint to be used in a route calculation.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1033: Nested Classes in RouteWaypoint
Nested Classes
public static class RouteWaypoint.RoadInfo
Exposes additional information about RouteWaypoint, mainly the side of the road it's on.
public static final enumeration RouteWaypoint.Type
Represents different types of waypoints.
public static final enumeration RouteWaypoint.WaypointDirection
Represents different waypoint direction.
Constructor Summary
Table 1034: Constructors in RouteWaypoint
Constructors
RouteWaypoint (GeoCoordinate coordinate)
The specified location coordinate is used to set the original position of this waypoint.
RouteWaypoint (GeoCoordinate coordinate, Type waypointType)
RouteWaypoint (GeoCoordinate coordinate, String identifier, WaypointDirection direction, Type
waypointType)
The specified location coordinate is used to set the original position of this waypoint.
HERE Android SDK Developer's Guide
API Reference
1703
Method Summary
Table 1035: Methods in RouteWaypoint
Methods
public boolean equals (Object obj)
public String getIdentifier ()
Gets the identifier.
public GeoCoordinate getNavigablePosition ()
Gets the navigable position.
public GeoCoordinate getOriginalPosition ()
Gets the original position of this waypoint.
public RoadInfo getRoadInfo ()
Gets additional information about this waypoint.
public WaypointDirection getWaypointDirection ()
Gets the direction for waypoint.
public Type getWaypointType ()
Gets the Waypoint Type, see RouteWaypoint.Type for valid values.
public int hashCode ()
public void setIdentifier (String identifier, WaypointDirection direction)
Sets the route identifier and direction for waypoint.
public RouteWaypoint setNavigablePosition (GeoCoordinate position)
Sets the waypoint's road position to be used for route calculation.
public RouteWaypoint setOriginalPosition (GeoCoordinate position)
Sets the original position, which identifies the off-the-road position of this waypoint, such as the exact location of a
building.
public RouteWaypoint setWaypointType (Type type)
Sets the waypoint type.
Class Details
Represents a waypoint to be used in a route calculation. A RouteWaypoint contains the GeoCoordinate
location, as well as additional information, such as the actual road position and whether it is a stop in the
route.
Constructor Details
RouteWaypoint (GeoCoordinate coordinate)
The specified location coordinate is used to set the original position of this waypoint.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1704
coordinate
The original position.
See also:
getOriginalPosition()
RouteWaypoint (GeoCoordinate coordinate, Type waypointType)
Parameters:
coordinate
waypointType
RouteWaypoint (GeoCoordinate coordinate, String identifier, WaypointDirection
direction, Type waypointType)
The specified location coordinate is used to set the original position of this waypoint. You can specify
waypoint direction to affect route calculation.
Parameters:
coordinate
The original position.
identifier
Identifier of road element.
direction
Direction of waypoint.
waypointType
See also:
getOriginalPosition()
setIdentifier(String, WaypointDirection)
Method Details
public boolean equals (Object obj)
Parameters:
obj
public String getIdentifier ()
Gets the identifier.
Returns:
HERE Android SDK Developer's Guide
API Reference
1705
identifier as String.
public GeoCoordinate getNavigablePosition ()
Gets the navigable position. The navigable position is used for route calculation.
Returns:
The navigable position
public GeoCoordinate getOriginalPosition ()
Gets the original position of this waypoint.
Returns:
The original position
public RoadInfo getRoadInfo ()
Gets additional information about this waypoint.
This is only available for waypoints that were matched to the route as part of route calculation. Which means
for waypoints obtained through a Route object, either by calling getRouteWaypoints() or by getting them from
a RoutePlan obtained by calling getRoutePlan().
Returns:
additional information about this waypoint, or null if none is available
public WaypointDirection getWaypointDirection ()
Gets the direction for waypoint.
Returns:
waypoint direction.
public Type getWaypointType ()
Gets the Waypoint Type, see RouteWaypoint.Type for valid values. By default, a RouteWaypoint is of
STOP_WAYPOINT type.
Returns:
The current Type.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1706
public void setIdentifier (String identifier, WaypointDirection direction)
Sets the route identifier and direction for waypoint. By default the waypoint direction is of ANY type.
Parameters:
identifier
Identifier of road element.
direction
Direction of waypoint.
public RouteWaypoint setNavigablePosition (GeoCoordinate position)
Sets the waypoint's road position to be used for route calculation.
For a waypoint that is not on a road, the navigable position acts as a road location hint for a route
calculation. However, there's no guarantee that any location can work as a navigable position. It is best to
only use a navigable position when you have a trusted source, such as from search results.
Working together with the navigable position, the original position is used by the HERE SDK for determining
the side of street during arrival, and to let the calculated route approach the correct side of street, especially
when there there is a physical or logical lane divider on the road.
By default, the navigable position is set to be the same as the geocoordinates provided to the
RouteWaypoint constructor.
Parameters:
position
to be set as the navigable position
Returns:
The modified RouteWaypoint itself.
See also:
Location
public RouteWaypoint setOriginalPosition (GeoCoordinate position)
Sets the original position, which identifies the off-the-road position of this waypoint, such as the exact
location of a building.
The original position is required for a route calculation. By default, it is set to be the same as the
geocoordinates provided to the RouteWaypoint constructor.
Working together with the navigable position, the original position is used by the HERE SDK for determining
the side of street during arrival, and to let the calculated route approach the correct side of street, especially
when there there is a physical or logical lane divider on the road.
Parameters:
position
HERE Android SDK Developer's Guide
API Reference
1707
to be set as the original position
Returns:
The modified RouteWaypoint itself.
See also:
Location
public RouteWaypoint setWaypointType (Type type)
Sets the waypoint type. By default the waypoint is of STOP_WAYPOINT type.
Parameters:
type
waypoint type, see RouteWaypoint.Type for valid values.
Returns:
The modified RouteWaypoint itself.
RoadInfo
The class RoadInfo is a member of com.here.android.mpa.routing.RouteWaypoint.
Class Summary
public static class RouteWaypoint.RoadInfo
extends java.lang.Object
Exposes additional information about RouteWaypoint, mainly the side of the road it's on.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1036: Nested Classes in RoadInfo
Nested Classes
public static final enumeration RouteWaypoint.RoadInfo.RoadSide
Represents side of the road, used to indicate position relative to a road, according to travel direction.
HERE Android SDK Developer's Guide
API Reference
1708
Method Summary
Table 1037: Methods in RoadInfo
Methods
public GeoCoordinate getMatchedCoordinate ()
Gets waypoint coordinates matched to the route.
public RoadSide getRoadSide ()
Gets road side of associated route waypoint.
Class Details
Exposes additional information about RouteWaypoint, mainly the side of the road it's on. This information is
populated during route calculation.
Method Details
public GeoCoordinate getMatchedCoordinate ()
Gets waypoint coordinates matched to the route.
Returns:
matched position
public RoadSide getRoadSide ()
Gets road side of associated route waypoint.
Returns:
which side of the road the waypoint is on
RoadSide
The enumeration RoadSide is a member of com.here.android.mpa.routing.RouteWaypoint.RoadInfo.
Enumeration Summary
public static final enumeration RouteWaypoint.RoadInfo.RoadSide
extends java.lang.Enum, java.lang.Object
Represents side of the road, used to indicate position relative to a road, according to travel direction.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1709
Enum Constant Summary
Table 1038: Enum Constants in RoadSide
Fields
public static final RoadSide UNKNOWN_LEFT
Indicates location that is geometrically on the left side of the road geometry, but whose distance from it is so small or so
large that the distinction might not be so obvious.
public static final RoadSide UNKNOWN_RIGHT
Indicates location that is geometrically on the right side of the road geometry, but whose distance from it is so small or so
large that the distinction might not be so obvious.
public static final RoadSide LEFT
Indicates location on the left side of the road, according to direction of travel.
public static final RoadSide RIGHT
Indicates location on the right side of the road, according to direction of travel.
public static final RoadSide UNDEFINED
Indicates that a position relative to the road is undefined.
Method Summary
Table 1039: Methods in RoadSide
Methods
public static RoadSide valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteWaypoint.RoadInfo.RoadSide[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents side of the road, used to indicate position relative to a road, according to travel direction.
Enum Constant Details
public static final RoadSide UNKNOWN_LEFT
Indicates location that is geometrically on the left side of the road geometry, but whose distance from it is so
small or so large that the distinction might not be so obvious.
public static final RoadSide UNKNOWN_RIGHT
Indicates location that is geometrically on the right side of the road geometry, but whose distance from it is
so small or so large that the distinction might not be so obvious.
HERE Android SDK Developer's Guide
API Reference
1710
public static final RoadSide LEFT
Indicates location on the left side of the road, according to direction of travel.
public static final RoadSide RIGHT
Indicates location on the right side of the road, according to direction of travel.
public static final RoadSide UNDEFINED
Indicates that a position relative to the road is undefined.
Method Details
public static RoadSide valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteWaypoint.RoadInfo.RoadSide[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Type
The enumeration Type is a member of com.here.android.mpa.routing.RouteWaypoint.
Enumeration Summary
public static final enumeration RouteWaypoint.Type
extends java.lang.Enum, java.lang.Object
Represents different types of waypoints.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1711
Enum Constant Summary
Table 1040: Enum Constants in Type
Fields
public static final Type STOP_WAYPOINT
A maneuver is generated for a STOP waypoint.
public static final Type VIA_WAYPOINT
No maneuver is generated for a VIA waypoint.
Method Summary
Table 1041: Methods in Type
Methods
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteWaypoint.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents different types of waypoints.
Enum Constant Details
public static final Type STOP_WAYPOINT
A maneuver is generated for a STOP waypoint. After the STOP waypoint, route is allowed to continue in the
opposite direction, i.e. to turn back.
During Guidance, "You have reached your stop-over" will be announced if
supported by the selected voice skin. Furthermore, this will trigger the following
callbacks: NavigationManager.ManeuverEventListener#onManeuverEvent and
NavigationManager.NavigationManagerEventListener#onStopoverReached.
The first and the last waypoint to be used for route calculation must be of
RouteWaypoint.Type.STOP_WAYPOINT type.
public static final Type VIA_WAYPOINT
No maneuver is generated for a VIA waypoint. After the VIA waypoint, route will continue in the same
direction as when it's approached.
Via waypoints will "force" the route to pass through them, but they will not cause any guidance,
announcement or maneuvers.
HERE Android SDK Developer's Guide
API Reference
1712
VIA waypoints are not considered during Guidance triggered re-routing nor do they trigger any callbacks
upon arrival at the waypoint.
This is only supported by RouteOptions.TransportMode.CAR . It's ignored for other transport modes.
Method Details
public int value ()
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteWaypoint.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
WaypointDirection
The enumeration WaypointDirection is a member of com.here.android.mpa.routing.RouteWaypoint.
Enumeration Summary
public static final enumeration RouteWaypoint.WaypointDirection
extends java.lang.Enum, java.lang.Object
Represents different waypoint direction.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1042: Enum Constants in WaypointDirection
Fields
public static final WaypointDirection ANY
Do not enforce direction, pick any.
public static final WaypointDirection POSITIVE
Enforce positive direction.
HERE Android SDK Developer's Guide
API Reference
1713
Fields
public static final WaypointDirection NEGATIVE
Enforce negative direction.
Method Summary
Table 1043: Methods in WaypointDirection
Methods
public static WaypointDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RouteWaypoint.WaypointDirection[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents different waypoint direction.
Enum Constant Details
public static final WaypointDirection ANY
Do not enforce direction, pick any.
public static final WaypointDirection POSITIVE
Enforce positive direction.
public static final WaypointDirection NEGATIVE
Enforce negative direction.
Method Details
public static WaypointDirection valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RouteWaypoint.WaypointDirection[] values ()
HERE Android SDK Developer's Guide
API Reference
1714
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Router<T, S extends Enum<?>>
The interface Router<T, S extends Enum<?>> is a member of com.here.android.mpa.routing .
Type Parameters:
T
S
Interface Summary
public abstract interface Router
Base interface for route calculation class.
[For complete information, see the section Interface Details]
Nested Class Summary
Table 1044: Nested Classes in Router<T, S extends Enum<?>>
Nested Classes
public static abstract interface Router.Listener
Method Summary
Table 1045: Methods in Router<T, S extends Enum<?>>
Methods
public abstract void calculateRoute (RoutePlan routePlan, Listener<T, > listener)
Invokes an asynchronous route calculation.
public abstract void cancel ()
Cancels the current route calculation.
public abstract boolean isBusy ()
Query whether the route calculation is ongoing.
Interface Details
Base interface for route calculation class. Represents controls for performing a type of routing request. It
defines routing type specific operations and listeners.
Method Details
public abstract void calculateRoute (RoutePlan routePlan, Listener<T, >
listener)
HERE Android SDK Developer's Guide
API Reference
1715
Invokes an asynchronous route calculation.
Parameters:
routePlan
The routePlan object used for calculation.
listener
A Listener for the route calculation request.
public abstract void cancel ()
Cancels the current route calculation. Note that this API is asynchronous as it takes some time cancel all
underlying operations. Use #isBusy() to check whether calculation is still ongoing or not.
public abstract boolean isBusy ()
Query whether the route calculation is ongoing.
Returns:
true if a route calculation is ongoing, false otherwise.
Listener<T, S extends Enum<?>>
The interface Listener<T, S extends Enum<?>> is a member of com.here.android.mpa.routing.Router.
Type Parameters:
T
S
Interface Summary
public static abstract interface Router.Listener
[For complete information, see the section Interface Details]
Method Summary
Table 1046: Methods in Listener<T, S extends Enum<?>>
Methods
public abstract void onCalculateRouteFinished (T response, S error)
A callback indicating that the route calculation operation has finished.
public abstract void onProgress (int percentage)
A callback indicating the progress level of the current route calculation operation, a percentage value within the range of
[0..100].
HERE Android SDK Developer's Guide
API Reference
1716
Interface Details
Method Details
public abstract void onCalculateRouteFinished (T response, S error)
A callback indicating that the route calculation operation has finished. You are free to re-use the Router to
perform another route calculation once this callback has been received.
Parameters:
response
The result of the route calculation operation
error
A response code indicating any issues encountered during route calculation
public abstract void onProgress (int percentage)
A callback indicating the progress level of the current route calculation operation, a percentage value within
the range of [0..100]. Note that in certain circumstances a recalculation is required and this percentage will
go from 100 to 0.
Parameters:
percentage
Progress completion percentage
RoutingError
The enumeration RoutingError is a member of com.here.android.mpa.routing .
Enumeration Summary
public final enumeration RoutingError
extends java.lang.Enum, java.lang.Object
Represents values describing possible route calculation errors.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1047: Enum Constants in RoutingError
Fields
public static final RoutingError NONE
There was no calculation error.
HERE Android SDK Developer's Guide
API Reference
1717
Fields
public static final RoutingError UNKNOWN
There was an unknown error preventing calculation.
public static final RoutingError OUT_OF_MEMORY
An out-of-memory error prevented calculation.
public static final RoutingError INVALID_PARAMETERS
Parameters passed were invalid.
public static final RoutingError INVALID_OPERATION
The operation is not allowed at this time because another request is in progress.
public static final RoutingError GRAPH_DISCONNECTED
No route was found.
public static final RoutingError GRAPH_DISCONNECTED_CHECK_OPTIONS
No route was found, one of the RouteOptions might be preventing calculation.
public static final RoutingError NO_START_POINT
No start point was found.
public static final RoutingError NO_END_POINT
No end point was found.
public static final RoutingError NO_END_POINT_CHECK_OPTIONS
The end point is unreachable, possibly due to one of the RouteOptions.
public static final RoutingError CANNOT_DO_PEDESTRIAN
A PEDESTRIAN transport mode was set but was not practical (possibly the route is too long).
public static final RoutingError ROUTING_CANCELLED
An application user cancelled the calculation.
public static final RoutingError VIOLATES_OPTIONS
A route was found but is invalid because it makes use of roads that were disabled by RouteOptions.
public static final RoutingError ROUTE_CORRUPTED
Could not decode the route as received from the server.
public static final RoutingError INVALID_CREDENTIALS
The route cannot be calculated because the HERE Developer credentials are invalid or were not provided.
public static final RoutingError REQUEST_TIMEOUT
Deprecated: As of SDK 3.3.
The online route calculation request has timed out because the server has not responded or the device system resources
have been exhausted.
public static final RoutingError OPERATION_NOT_ALLOWED
Access to this operation is denied.
HERE Android SDK Developer's Guide
API Reference
1718
Fields
public static final RoutingError NO_CONNECTIVITY
No internet connection is available.
public static final RoutingError INSUFFICIENT_MAP_DATA
The route cannot be calculated because there is not enough local map data to perform route calculation.
public static final RoutingError NETWORK_COMMUNICATION
The online route calculation request failed because of a networking error.
public static final RoutingError UNSUPPORTED_MAP_VERSION
The online routing server does not support the device downloaded map version as specified in the route request.
Method Summary
Table 1048: Methods in RoutingError
Methods
public int value ()
public static RoutingError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RoutingError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible route calculation errors.
Enum Constant Details
public static final RoutingError NONE
There was no calculation error. NOTE: do not rename; there is code that refers to "NONE" as a hard-coded
literal
public static final RoutingError UNKNOWN
There was an unknown error preventing calculation.
public static final RoutingError OUT_OF_MEMORY
An out-of-memory error prevented calculation.
public static final RoutingError INVALID_PARAMETERS
HERE Android SDK Developer's Guide
API Reference
1719
Parameters passed were invalid.
public static final RoutingError INVALID_OPERATION
The operation is not allowed at this time because another request is in progress.
public static final RoutingError GRAPH_DISCONNECTED
No route was found.
public static final RoutingError GRAPH_DISCONNECTED_CHECK_OPTIONS
No route was found, one of the RouteOptions might be preventing calculation.
public static final RoutingError NO_START_POINT
No start point was found.
public static final RoutingError NO_END_POINT
No end point was found.
public static final RoutingError NO_END_POINT_CHECK_OPTIONS
The end point is unreachable, possibly due to one of the RouteOptions.
public static final RoutingError CANNOT_DO_PEDESTRIAN
A PEDESTRIAN transport mode was set but was not practical (possibly the route is too long).
public static final RoutingError ROUTING_CANCELLED
An application user cancelled the calculation.
public static final RoutingError VIOLATES_OPTIONS
A route was found but is invalid because it makes use of roads that were disabled by RouteOptions.
public static final RoutingError ROUTE_CORRUPTED
Could not decode the route as received from the server.
HERE Android SDK Developer's Guide
API Reference
1720
public static final RoutingError INVALID_CREDENTIALS
The route cannot be calculated because the HERE Developer credentials are invalid or were not provided.
public static final RoutingError REQUEST_TIMEOUT
Deprecated: As of SDK 3.3.
Use NETWORK_COMMUNICATION.
The online route calculation request has timed out because the server has not responded or the device
system resources have been exhausted. The route calculation request should be retried.
public static final RoutingError OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final RoutingError NO_CONNECTIVITY
No internet connection is available.
public static final RoutingError INSUFFICIENT_MAP_DATA
The route cannot be calculated because there is not enough local map data to perform route calculation.
Client can re-download map data and calculate route again.
public static final RoutingError NETWORK_COMMUNICATION
The online route calculation request failed because of a networking error. The route calculation request
should be retried.
public static final RoutingError UNSUPPORTED_MAP_VERSION
The online routing server does not support the device downloaded map version as specified in the route
request. Clients must update the map version installed on the device.
Method Details
public int value ()
public static RoutingError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1721
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RoutingError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Signpost
The class Signpost is a member of com.here.android.mpa.routing .
Class Summary
public final class Signpost
extends java.lang.Object
This class stores signpost information along the Route.
[For complete information, see the section Class Details]
See also:
Maneuver
Nested Class Summary
Table 1049: Nested Classes in Signpost
Nested Classes
public static final class Signpost.LocalizedLabel
Signpost information can be used for navigation (both audible and graphical/textual navigation) and map display.
Method Summary
Table 1050: Methods in Signpost
Methods
public int getBackgroundColor ()
Return the background color of this signpost using ARGB (Alpha/Red/Green/Blue)
public java.util.List <LocalizedLabel> getExitDirections ()
Returns the directions on the Signpost.
public Image getExitIcon ()
Returns the exit Signpost icon.
HERE Android SDK Developer's Guide
API Reference
1722
Methods
public String getExitNumber ()
Returns the exit number on the Signpost
public String getExitText ()
Returns the exit text on the Signpost
public int getForegroundColor ()
Return the foreground/text color of this signpost using ARGB (Alpha/Red/Green/Blue)
Class Details
This class stores signpost information along the Route.
See also:
Maneuver
Method Details
public int getBackgroundColor ()
Return the background color of this signpost using ARGB (Alpha/Red/Green/Blue)
Returns:
The background color of this signpost
See also:
android.graphics.Color
public java.util.List <LocalizedLabel> getExitDirections ()
Returns the directions on the Signpost.
Returns:
a list of directions (empty list if none available).
public Image getExitIcon ()
Returns the exit Signpost icon.
Returns:
Image
public String getExitNumber ()
Returns the exit number on the Signpost
HERE Android SDK Developer's Guide
API Reference
1723
Returns:
string presentation of the exit number
public String getExitText ()
Returns the exit text on the Signpost
Returns:
exit text
public int getForegroundColor ()
Return the foreground/text color of this signpost using ARGB (Alpha/Red/Green/Blue)
Returns:
The foreground/text color of this signpost
See also:
android.graphics.Color
LocalizedLabel
The class LocalizedLabel is a member of com.here.android.mpa.routing.Signpost.
Class Summary
public static final class Signpost.LocalizedLabel
extends java.lang.Object
Signpost information can be used for navigation (both audible and graphical/textual navigation) and map
display.
[For complete information, see the section Class Details]
Method Summary
Table 1051: Methods in LocalizedLabel
Methods
public String getLanguage ()
Three letter MARC language tag.
public String getRouteDirection ()
Contains the cardinal direction.
HERE Android SDK Developer's Guide
API Reference
1724
Methods
public String getRouteName ()
Contains the route name/route number of the label.
public String getText ()
Usually it contains auxiliary information like city name or characteristic place (for example: "airport").
public String toString ()
For documentation, see java.lang.Object
Class Details
Signpost information can be used for navigation (both audible and graphical/textual navigation) and map
display. In Europe, the label Text is most relevant for guidance, while in the North America, both Route Name
and Direction information are most relevant.
Method Details
public String getLanguage ()
Three letter MARC language tag.
Returns:
A string representing the language.
public String getRouteDirection ()
Contains the cardinal direction.
Returns:
String with the direction.
public String getRouteName ()
Contains the route name/route number of the label. Since the origin data is not always consistent it is
advisable to concatenate the route name and route direction fields There are for example cases in which the
direction is already contained in the route name.
Returns:
String with the route name.
See also:
getRouteName()
getRouteDirection()
public String getText ()
HERE Android SDK Developer's Guide
API Reference
1725
Usually it contains auxiliary information like city name or characteristic place (for example: "airport").
Returns:
String with auxilary information.
public String toString ()
For documentation, see java.lang.Object
TransitManeuver
The class TransitManeuver is a member of com.here.android.mpa.routing .
Class Summary
public final class TransitManeuver
extends com.here.android.mpa.routing.Maneuver, java.lang.Object
Represents the transit specific action required to leave one street segment and enter the next in the chain of
directions that comprises a calculated Transit Route .
[For complete information, see the section Class Details]
Nested Class Summary
Table 1052: Nested Classes in TransitManeuver
Nested Classes
public static final enumeration TransitManeuver.TransitLineStyle
Represents values describing different line styles.
Method Summary
Table 1053: Methods in TransitManeuver
Methods
public String getArrivalStopName ()
Gets the arrival stop name for the TransitManeuver .
public String getDepartureStopName ()
Gets the departure stop name for the TransitManeuver .
public String getLineName ()
Gets the line name for the TransitManeuver .
HERE Android SDK Developer's Guide
API Reference
1726
Methods
public TransitLineStyle getLineStyle ()
Gets the TransitLineStyle that is typical of the way in which TransitManeuver lines are drawn on maps of the local
operator.
public int getPrimaryLineColor ()
Gets the primary color of the TransitManeuver in the local public transit operator's color scheme.
public int getSecondaryLineColor ()
Gets the secondary color of the TransitManeuver in the local public transit operator's color scheme.
public String getSystemInformalName ()
Gets the informal name of the system operating the TransitManeuver .
public String getSystemOfficialName ()
Gets the name of the system operating the TransitManeuver .
public String getSystemShortName ()
Gets the name, in a shorter or abbreviated version if available, of the system operating the TransitManeuver .
public String getTerminusStopName ()
Gets the terminus stop name for the TransitManeuver .
public java.util.List <TransitRouteElement> getTransitRouteElements ()
Gets a list of TransitRouteElement of the TransitManeuver.
public int getTransitTravelTime ()
Gets the transit travel time.
public TransitType getTransitType ()
Gets the TransitType of the transit system offering service for the TransitManeuver .
public String getTransitTypeName ()
Gets the transit type of the transit system offering service for the TransitManeuver , as a String in the transit operator's
local vocabulary.
public boolean hasPrimaryLineColor ()
Returns whether element's primary line color is available.
public boolean hasSecondaryLineColor ()
Returns whether element's secondary line color is available.
Class Details
Represents the transit specific action required to leave one street segment and enter the next in the chain of
directions that comprises a calculated Transit Route .
Method Details
public String getArrivalStopName ()
Gets the arrival stop name for the TransitManeuver .
HERE Android SDK Developer's Guide
API Reference
1727
Returns:
The arrival stop name
public String getDepartureStopName ()
Gets the departure stop name for the TransitManeuver .
Returns:
The departure stop name
public String getLineName ()
Gets the line name for the TransitManeuver .
Returns:
The line name
public TransitLineStyle getLineStyle ()
Gets the TransitLineStyle that is typical of the way in which TransitManeuver lines are drawn on
maps of the local operator.
Returns:
The TransitLineStyle
public int getPrimaryLineColor ()
Gets the primary color of the TransitManeuver in the local public transit operator's color scheme.
Returns:
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each color
component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
getPrimaryLineColor()
public int getSecondaryLineColor ()
Gets the secondary color of the TransitManeuver in the local public transit operator's color scheme.
Returns:
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each color
component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
HERE Android SDK Developer's Guide
API Reference
1728
See also:
getSecondaryLineColor()
public String getSystemInformalName ()
Gets the informal name of the system operating the TransitManeuver . if available
Returns:
The informal transit system name, e.g. "SMGN".
See also:
getSystemInformalName()
public String getSystemOfficialName ()
Gets the name of the system operating the TransitManeuver .
Returns:
The transit system name
See also:
getSystemOfficialName()
public String getSystemShortName ()
Gets the name, in a shorter or abbreviated version if available, of the system operating the
TransitManeuver .
Returns:
The transit system name in shortened form
See also:
getSystemShortName()
public String getTerminusStopName ()
Gets the terminus stop name for the TransitManeuver .
Returns:
The terminus stop name
public java.util.List <TransitRouteElement> getTransitRouteElements ()
Gets a list of TransitRouteElement of the TransitManeuver.
Returns:
HERE Android SDK Developer's Guide
API Reference
1729
a list of TransitRouteElement
public int getTransitTravelTime ()
Gets the transit travel time. Unit is seconds.
Returns:
transit travel time in seconds
public TransitType getTransitType ()
Gets the TransitType of the transit system offering service for the TransitManeuver .
Returns:
The TransitType
public String getTransitTypeName ()
Gets the transit type of the transit system offering service for the TransitManeuver , as a String in the
transit operator's local vocabulary.
Returns:
The transit type name
See also:
getTransitType()
public boolean hasPrimaryLineColor ()
Returns whether element's primary line color is available.
Returns:
true if color is available, false - otherwise
public boolean hasSecondaryLineColor ()
Returns whether element's secondary line color is available.
Returns:
true if color is available, false - otherwise
TransitLineStyle
The enumeration TransitLineStyle is a member of com.here.android.mpa.routing.TransitManeuver.
HERE Android SDK Developer's Guide
API Reference
1730
Enumeration Summary
public static final enumeration TransitManeuver.TransitLineStyle
extends java.lang.Enum, java.lang.Object
Represents values describing different line styles.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1054: Enum Constants in TransitLineStyle
Fields
public static final TransitLineStyle SOLID
A solid line.
public static final TransitLineStyle DOTTED
A dotted line.
public static final TransitLineStyle DASHED
A dashed line.
public static final TransitLineStyle UNDEFINED
An undefined line style.
Method Summary
Table 1055: Methods in TransitLineStyle
Methods
public int value ()
public static TransitLineStyle valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitManeuver.TransitLineStyle[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing different line styles. Used for expressing transit line styling information as
provided by the operator.
Enum Constant Details
public static final TransitLineStyle SOLID
A solid line.
HERE Android SDK Developer's Guide
API Reference
1731
public static final TransitLineStyle DOTTED
A dotted line.
public static final TransitLineStyle DASHED
A dashed line.
public static final TransitLineStyle UNDEFINED
An undefined line style.
Method Details
public int value ()
public static TransitLineStyle valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitManeuver.TransitLineStyle[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TransitRouteElement
The class TransitRouteElement is a member of com.here.android.mpa.routing .
Class Summary
public final class TransitRouteElement
extends java.lang.Object
Represents an element within a transit-specific Route.
[For complete information, see the section Class Details]
See also:
Route
HERE Android SDK Developer's Guide
API Reference
1732
getTransitElement()
getTransitRouteElements()
Method Summary
Table 1056: Methods in TransitRouteElement
Methods
public TransitRouteStop getArrivalStop ()
Gets the arrival station.
public Date getArrivalTime ()
Gets time of arrival at the station for the TransitRouteElement.
public TransitRouteStop getDepartureStop ()
Gets the departure station.
public Date getDepartureTime ()
Gets the time of departure from the station for the TransitRouteElement.
public String getDestination ()
Gets the destination name for the TransitRouteElement.
public int getDuration ()
Gets the total duration.
public java.util.List <GeoCoordinate> getGeometry ()
Gets the geometry of the TransitRouteElement.
public Identifier getId ()
Returns the transit route element identifier.
public java.util.List <GeoCoordinate> getLineGeometry ()
Gets the geometry of only the line part of the TransitRouteElement, excluding any positions of entrances.
public String getLineName ()
Gets the line name for the TransitRouteElement.
public TransitLineStyle getLineStyle ()
Gets the TransitManeuver.TransitLineStyle that is typical of the way in which TransitRouteElement lines are drawn on maps
of the local operator.
public int getPrimaryLineColor ()
Gets the primary color of the TransitRouteElement in the local public transit operator's color scheme.
public int getSecondaryLineColor ()
Gets the secondary color of the TransitRouteElement in the local public transit operator's color scheme.
public Image getSystemAccessLogo ()
Gets the transit system access logo if available, otherwise returns an invalid image.
HERE Android SDK Developer's Guide
API Reference
1733
Methods
public String getSystemInformalName ()
Gets the informal name of the system operating the TransitRouteElement.
public Image getSystemLogo ()
Gets the transit system logo if available, otherwise returns an invalid image.
public String getSystemOfficialName ()
Gets the name of the system operating the TransitRouteElement.
public String getSystemShortName ()
Gets the name, in a shorter or abbreviated version if available, of the system operating the TransitRouteElement.
public TransitType getTransitType ()
Gets the TransitType of the transit system offering service for the TransitRouteElement.
public String getTransitTypeName ()
Gets the transit type of the transit system offering service for the TransitRouteElement, as a String in the transit
operator's local vocabulary.
public int getVehicleTravelTime ()
Gets the vehicle travel time.
public boolean hasPrimaryLineColor ()
Returns whether element's primary line color is available.
public boolean hasSecondaryLineColor ()
Returns whether element's secondary line color is available.
Class Details
Represents an element within a transit-specific Route.
See also:
Route
getTransitElement()
getTransitRouteElements()
Method Details
public TransitRouteStop getArrivalStop ()
Gets the arrival station.
Returns:
arrival station
See also:
TransitRouteStop
HERE Android SDK Developer's Guide
API Reference
1734
public Date getArrivalTime ()
Gets time of arrival at the station for the TransitRouteElement.
Note: If no departure time was set for the RouteOptions associated with this TransitRouteElement ,
than the time is relative to the system time when the route calculation took place. Otherwise, the times are
relative to the specified departure time.
Returns:
The arrival time, or null if unavailable
See also:
setTime(Date, TimeType)
public TransitRouteStop getDepartureStop ()
Gets the departure station.
Returns:
departure station
See also:
TransitRouteStop
public Date getDepartureTime ()
Gets the time of departure from the station for the TransitRouteElement.
Note: If no departure time was set for the RouteOptions associated with this TransitRouteElement ,
than the time is relative to the system time when the route calculation took place. Otherwise, the times are
relative to the specified departure time.
Returns:
The departure time, or null if unavailable
See also:
setTime(Date, TimeType)
public String getDestination ()
Gets the destination name for the TransitRouteElement.
Returns:
The destination name
public int getDuration ()
HERE Android SDK Developer's Guide
API Reference
1735
Gets the total duration. Unit is seconds.
Note: when calculating transportation travel times for display to the user, this is generally the value to be
used.
Returns:
total duration in seconds
See also:
getVehicleTravelTime()
public java.util.List <GeoCoordinate> getGeometry ()
Gets the geometry of the TransitRouteElement. The geometry includes the line part of a
TransitRouteElement , plus positions of entrances.
Returns:
A List of GeoCoordinate objects
See also:
getLineGeometry()
public Identifier getId ()
Returns the transit route element identifier. TransitRouteElement. The id can be used to highlight the transit
line on a transit route.
Returns:
the unique object identifier.
See also:
highlightTransitLines(List<Identifier>)
public java.util.List <GeoCoordinate> getLineGeometry ()
Gets the geometry of only the line part of the TransitRouteElement, excluding any positions of entrances.
Returns:
A List of GeoCoordinate objects
See also:
getGeometry()
public String getLineName ()
Gets the line name for the TransitRouteElement.
HERE Android SDK Developer's Guide
API Reference
1736
Returns:
The line name
public TransitLineStyle getLineStyle ()
Gets the TransitManeuver.TransitLineStyle that is typical of the way in which TransitRouteElement lines are
drawn on maps of the local operator.
Returns:
The TransitLineStyle
public int getPrimaryLineColor ()
Gets the primary color of the TransitRouteElement in the local public transit operator's color scheme.
Returns:
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each color
component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
getPrimaryLineColor()
public int getSecondaryLineColor ()
Gets the secondary color of the TransitRouteElement in the local public transit operator's color scheme.
Returns:
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each color
component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
getSecondaryLineColor()
public Image getSystemAccessLogo ()
Gets the transit system access logo if available, otherwise returns an invalid image.
Returns:
An Image representing the transit system access logo
See also:
getSystemLogo()
HERE Android SDK Developer's Guide
API Reference
1737
public String getSystemInformalName ()
Gets the informal name of the system operating the TransitRouteElement. if available
Returns:
The informal transit system name, e.g. "SMGN".
See also:
getSystemInformalName()
public Image getSystemLogo ()
Gets the transit system logo if available, otherwise returns an invalid image.
Returns:
An Image, including letters next to it, representing the transit system logo
See also:
getSystemAccessLogo()
public String getSystemOfficialName ()
Gets the name of the system operating the TransitRouteElement.
Returns:
The transit system name
See also:
getSystemOfficialName()
public String getSystemShortName ()
Gets the name, in a shorter or abbreviated version if available, of the system operating the
TransitRouteElement.
Returns:
The transit system name in shortened form
See also:
getSystemShortName()
public TransitType getTransitType ()
Gets the TransitType of the transit system offering service for the TransitRouteElement.
Returns:
The TransitType
HERE Android SDK Developer's Guide
API Reference
1738
public String getTransitTypeName ()
Gets the transit type of the transit system offering service for the TransitRouteElement, as a String in the
transit operator's local vocabulary.
Returns:
The transit type name
See also:
getTransitType()
public int getVehicleTravelTime ()
Gets the vehicle travel time. Unit is seconds.
Note: Generally, when calculating transportation travel times for display to the user, use the value given by
getDuration() instead.
Returns:
vehicle travel time in seconds
See also:
getDuration()
public boolean hasPrimaryLineColor ()
Returns whether element's primary line color is available.
Returns:
true if color is available, false - otherwise
public boolean hasSecondaryLineColor ()
Returns whether element's secondary line color is available.
Returns:
true if color is available, false - otherwise
TransitRouteSourceAttribution
The class TransitRouteSourceAttribution is a member of com.here.android.mpa.routing .
Class Summary
public class TransitRouteSourceAttribution
HERE Android SDK Developer's Guide
API Reference
1739
extends java.lang.Object
This class contains copyright notices that must be displayed to the end user.
[For complete information, see the section Class Details]
See also:
Route
getTransitRouteSourceAttribution()
Method Summary
Table 1057: Methods in TransitRouteSourceAttribution
Methods
public String getAttribution ()
Gets the source attribution information as a html formatted string.
public java.util.List <TransitRouteSupplier> getSuppliers ()
Gets the structured information about source data suppliers
Class Details
This class contains copyright notices that must be displayed to the end user. Source attribution must be
displayed together with a route. This requirement forms part of the terms and conditions of the API.
See also:
Route
getTransitRouteSourceAttribution()
Method Details
public String getAttribution ()
Gets the source attribution information as a html formatted string. The code snippet below demonstrates
how to display the string in an Android TextView
TextView textView = (TextView)
findViewById(R.id.attributionText);textView.setText((Html.fromHtml(route.getTransitRouteSourceAttribution().getAttribution())));textView.setMovementMethod(LinkMovementMethod.getInstance());
Returns:
Html formatted attribution string
public java.util.List <TransitRouteSupplier> getSuppliers ()
Gets the structured information about source data suppliers
Returns:
HERE Android SDK Developer's Guide
API Reference
1740
List of transit route suppliers
TransitRouteStop
The class TransitRouteStop is a member of com.here.android.mpa.routing .
Class Summary
public final class TransitRouteStop
extends java.lang.Object
This is a public transit stop within a calculated transit Route.
[For complete information, see the section Class Details]
See also:
TransitManeuver
Nested Class Summary
Table 1058: Nested Classes in TransitRouteStop
Nested Classes
public static final enumeration TransitRouteStop.Attribute
Represents values describing different attributes for a TransitRouteStop.
Method Summary
Table 1059: Methods in TransitRouteStop
Methods
public java.util.EnumSet <Attribute> getAttributes ()
Gets the TransitRouteStop.Attribute values for the TransitRouteStop .
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of the TransitRouteStop .
public GeoCoordinate getEgressCoordinate ()
Gets the GeoCoordinate representing the coordinates of the entry/exit for the TransitRouteStop .
public Identifier getId ()
Gets the Identifier of the TransitRouteStop .
public String getName ()
Gets the name for the TransitRouteStop .
public GeoCoordinate getPlatformCoordinate ()
Gets the GeoCoordinate representing the coordinates of the platform for the TransitRouteStop .
HERE Android SDK Developer's Guide
API Reference
1741
Methods
public int getPlatformLevel ()
Gets the platform level for the TransitRouteStop , where 0 represents the ground level, -1 the first underground level, 1
the first elevated level, and so on.
Class Details
This is a public transit stop within a calculated transit Route.
See also:
TransitManeuver
Method Details
public java.util.EnumSet <Attribute> getAttributes ()
Gets the TransitRouteStop.Attribute values for the TransitRouteStop .
Returns:
The set of TransitRouteStop.Attribute values
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate of the TransitRouteStop .
Returns:
The GeoCoordinate
public GeoCoordinate getEgressCoordinate ()
Gets the GeoCoordinate representing the coordinates of the entry/exit for the TransitRouteStop .
Note: this method might return the same coordinates as the platform coordinates whenever:
the stop is part of a platform-to-platform change
there is no differentiation between platform and entrance (e.g. typical public bus stops along a street)
Returns:
The GeoCoordinate
See also:
getPlatformCoordinate()
public Identifier getId ()
Gets the Identifier of the TransitRouteStop . Identifier is not supported for public transport timetable
route stops
HERE Android SDK Developer's Guide
API Reference
1742
Returns:
The Identifier
public String getName ()
Gets the name for the TransitRouteStop .
Returns:
name
public GeoCoordinate getPlatformCoordinate ()
Gets the GeoCoordinate representing the coordinates of the platform for the TransitRouteStop .
Returns:
The GeoCoordinate
See also:
getEgressCoordinate()
public int getPlatformLevel ()
Gets the platform level for the TransitRouteStop , where 0 represents the ground level, -1 the first
underground level, 1 the first elevated level, and so on.
Returns:
The platform level
Attribute
The enumeration Attribute is a member of com.here.android.mpa.routing.TransitRouteStop.
Enumeration Summary
public static final enumeration TransitRouteStop.Attribute
extends java.lang.Enum, java.lang.Object
Represents values describing different attributes for a TransitRouteStop.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1743
Enum Constant Summary
Table 1060: Enum Constants in Attribute
Fields
public static final Attribute ELEVATOR
The stop features an elevator.
public static final Attribute ESCALATOR
The stop features an escalator.
public static final Attribute STAIRS
The stop features a set of stairs.
Method Summary
Table 1061: Methods in Attribute
Methods
public int value ()
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TransitRouteStop.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing different attributes for a TransitRouteStop.
Enum Constant Details
public static final Attribute ELEVATOR
The stop features an elevator.
public static final Attribute ESCALATOR
The stop features an escalator.
public static final Attribute STAIRS
The stop features a set of stairs.
HERE Android SDK Developer's Guide
API Reference
1744
Method Details
public int value ()
public static Attribute valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TransitRouteStop.Attribute[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TransitRouteSupplier
The class TransitRouteSupplier is a member of com.here.android.mpa.routing .
Class Summary
public class TransitRouteSupplier
extends java.lang.Object
This class contains structured information about a source data supplier.
[For complete information, see the section Class Details]
See also:
Route
getTransitRouteSourceAttribution()
getSuppliers()
Method Summary
Table 1062: Methods in TransitRouteSupplier
Methods
public java.util.List <TransitRouteSupplierNote> getNotes ()
Gets the notes giving additional information about the supplier This information has to be displayed to the user
public String getTitle ()
Gets the source data supplier's title
HERE Android SDK Developer's Guide
API Reference
1745
Methods
public String getUrl ()
Gets the link to the source data supplier's website
Class Details
This class contains structured information about a source data supplier. This additional information about
data supplier has to be exposed in the client application
See also:
Route
getTransitRouteSourceAttribution()
getSuppliers()
Method Details
public java.util.List <TransitRouteSupplierNote> getNotes ()
Gets the notes giving additional information about the supplier This information has to be displayed to the
user
Returns:
An array of TransitRouteSupplierNote objects
public String getTitle ()
Gets the source data supplier's title
Returns:
String representing the supplier title
public String getUrl ()
Gets the link to the source data supplier's website
Returns:
Supplier's website
TransitRouteSupplierNote
The class TransitRouteSupplierNote is a member of com.here.android.mpa.routing .
HERE Android SDK Developer's Guide
API Reference
1746
Class Summary
public class TransitRouteSupplierNote
extends java.lang.Object
This class contains giving additional information about the supplier.
[For complete information, see the section Class Details]
See also:
Route
getTransitRouteSourceAttribution()
getSuppliers()
getNotes()
Method Summary
Table 1063: Methods in TransitRouteSupplierNote
Methods
public String getText ()
Gets the note text.The text may contain HTML text and markup, including hyperlink elements.
public String getType ()
Gets the type of source supplier note
public String getUrl ()
Gets the URL, to which note is referring, if any
public String getUrlText ()
Gets the text, displayed with URL, to which note is referring, if any.
Class Details
This class contains giving additional information about the supplier. This additional information about data
supplier has to be exposed in the client application
See also:
Route
getTransitRouteSourceAttribution()
getSuppliers()
getNotes()
Method Details
public String getText ()
HERE Android SDK Developer's Guide
API Reference
1747
Gets the note text.The text may contain HTML text and markup, including hyperlink elements. The text will be
localized. The code snippet below demonstrates how to display the string in an Android TextView
TextView textView = (TextView) findViewById(R.id.noteText);
textView.setText((Html.fromHtml(note.getText()));
textView.setMovementMethod(LinkMovementMethod.getInstance());
Returns:
Note text
public String getType ()
Gets the type of source supplier note
Returns:
Supplier note type
public String getUrl ()
Gets the URL, to which note is referring, if any
Returns:
Note url
public String getUrlText ()
Gets the text, displayed with URL, to which note is referring, if any.
Returns:
Url text
UMCalculateResult
The class UMCalculateResult is a member of com.here.android.mpa.routing .
Class Summary
public class UMCalculateResult
extends java.lang.Object
Represents result of Urban Mobility route calculation.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1748
Nested Class Summary
Table 1064: Nested Classes in UMCalculateResult
Nested Classes
public static final enumeration UMCalculateResult.ViolatedOption
These are options which might not be taken into account when calculating the UMCalculateResult.
Method Summary
Table 1065: Methods in UMCalculateResult
Methods
public java.util.Collection <Alert> getAlerts ()
Get alerts and disruptions associated with found connections.
public ErrorCode getError ()
Gets error code.
public String getErrorMessage ()
Gets error message string.
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
public java.util.Collection <Operator> getOperators ()
Get the operators serving the found connections.
public java.util.List <UMRouteResult> getResults ()
Gets list of UMRouteResult.
public java.util.EnumSet <ViolatedOption> getViolatedOptions ()
Gets the violated options.
public boolean isSubsequentRouteSupported ()
Indicates if it's possible to calculate subsequent route for given result.
Class Details
Represents result of Urban Mobility route calculation.
Method Details
public java.util.Collection <Alert> getAlerts ()
Get alerts and disruptions associated with found connections.
Returns:
A Collection of Alerts.
HERE Android SDK Developer's Guide
API Reference
1749
public ErrorCode getError ()
Gets error code.
Returns:
A ErrorCode indicating the routing error.
public String getErrorMessage ()
Gets error message string.
Returns:
Error message, empty string or null.
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
Returns:
collection of Links
public java.util.Collection <Operator> getOperators ()
Get the operators serving the found connections.
Returns:
A Collection of Operators.
public java.util.List <UMRouteResult> getResults ()
Gets list of UMRouteResult. In the case of VIOLATES_OPTIONS, one or more RouteResult in the returned list
contains a list of violated RouteOptions.
Returns:
A List of UMRouteResult.
public java.util.EnumSet <ViolatedOption> getViolatedOptions ()
Gets the violated options.
Returns:
Set of UMCalculateResult.ViolatedOptions, or empty set if no options violated.
public boolean isSubsequentRouteSupported ()
HERE Android SDK Developer's Guide
API Reference
1750
Indicates if it's possible to calculate subsequent route for given result.
Returns:
True if result can be used to calculate subsequent routes, false otherwise.
See also:
calculateSubsequentRoute(UMCalculateResult, SubsequentRouteType, int, Listener<UMCalculateResult,
ErrorCode>)
ViolatedOption
The enumeration ViolatedOption is a member of com.here.android.mpa.routing.UMCalculateResult.
Enumeration Summary
public static final enumeration UMCalculateResult.ViolatedOption
extends java.lang.Enum, java.lang.Object
These are options which might not be taken into account when calculating the UMCalculateResult.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1066: Enum Constants in ViolatedOption
Fields
public static final ViolatedOption MAXIMUM_WALKING_DISTANCE
Indicates if setting maximum walking distance was considered.
public static final ViolatedOption WALKING_SPEED
Indicates if setting walking speed was considered.
public static final ViolatedOption MAXIMUM_CHANGES_COUNT
Indicates if setting maximum number of changes was considered.
public static final ViolatedOption RESTRICT_TRANSIT_TYPES
Indicates if restricting the TransitType was considered.
public static final ViolatedOption ESTIMATED_ROUTING
Indicates if response contains only estimated routing data, due to license limitation.
HERE Android SDK Developer's Guide
API Reference
1751
Method Summary
Table 1067: Methods in ViolatedOption
Methods
public static ViolatedOption valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static UMCalculateResult.ViolatedOption[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
These are options which might not be taken into account when calculating the UMCalculateResult. In other
words, route calculations may give results that violate the following options. Usually it depends on particular
regions/countries. By default all options are considered to be supported.
Enum Constant Details
public static final ViolatedOption MAXIMUM_WALKING_DISTANCE
Indicates if setting maximum walking distance was considered.
public static final ViolatedOption WALKING_SPEED
Indicates if setting walking speed was considered.
public static final ViolatedOption MAXIMUM_CHANGES_COUNT
Indicates if setting maximum number of changes was considered.
public static final ViolatedOption RESTRICT_TRANSIT_TYPES
Indicates if restricting the TransitType was considered.
public static final ViolatedOption ESTIMATED_ROUTING
Indicates if response contains only estimated routing data, due to license limitation.
Method Details
public static ViolatedOption valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1752
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static UMCalculateResult.ViolatedOption[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UMRoute
The class UMRoute is a member of com.here.android.mpa.routing .
Class Summary
public final class UMRoute
extends com.here.android.mpa.routing.Route, java.lang.Object
Route extension with Urban Mobility specifics like ticketing information or real-time data.
[For complete information, see the section Class Details]
Method Summary
Table 1068: Methods in UMRoute
Methods
public Arrival getArrival ()
Get information about this route's arrival.
public int getChangesCount ()
Get number of public transport changes (transfers) to make along this route.
public Departure getDeparture ()
Get information about this route's departure.
public long getDuration ()
Get the expected duration of this route in seconds.
public String getId ()
Get route ID which is unique within same UMCalculateResult.
public java.util.List <Maneuver> getManeuvers ()
Returns an empty list in an Urban Mobility route calculation.
public java.util.List <RouteSection> getSections ()
Get List of RouteSection objects which represent parts of this route with different means of transit.
public java.util.List <Tariff> getTariffs ()
Get List of Tariff objects each of which represent a different collection/alternative of Fares to cover this route.
HERE Android SDK Developer's Guide
API Reference
1753
Class Details
Route extension with Urban Mobility specifics like ticketing information or real-time data. Represents a
single route/connection within UMRouteResult.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public Arrival getArrival ()
Get information about this route's arrival. See Arrival for details.
Returns:
information about arrival
public int getChangesCount ()
Get number of public transport changes (transfers) to make along this route.
Returns:
number of changes, or -1 if not available
public Departure getDeparture ()
Get information about this route's departure. See Departure for details.
Returns:
information about departure
public long getDuration ()
Get the expected duration of this route in seconds.
Returns:
duration in seconds, or -1 if not available
public String getId ()
Get route ID which is unique within same UMCalculateResult.
Returns:
route ID, or null if not available
public java.util.List <Maneuver> getManeuvers ()
HERE Android SDK Developer's Guide
API Reference
1754
Returns an empty list in an Urban Mobility route calculation. Use getManeuvers() instead.
public java.util.List <RouteSection> getSections ()
Get List of RouteSection objects which represent parts of this route with different means of transit.
Returns:
list of route sections
public java.util.List <Tariff> getTariffs ()
Get List of Tariff objects each of which represent a different collection/alternative of Fares to cover this
route.
Returns:
list of alternative tariffs
UMRouteOptions
The class UMRouteOptions is a member of com.here.android.mpa.routing .
Class Summary
public class UMRouteOptions
extends com.here.android.mpa.routing.RouteOptions, java.lang.Object
The class contains Urban Mobility specific options for route calculation.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1069: Nested Classes in UMRouteOptions
Nested Classes
public static final enumeration UMRouteOptions.FilteringProfile
Specifies which filtering profile to use.
Constructor Summary
Table 1070: Constructors in UMRouteOptions
Constructors
UMRouteOptions ()
Public Constructor
HERE Android SDK Developer's Guide
API Reference
1755
Constructors
UMRouteOptions (RouteOptions other)
Copy Constructor
UMRouteOptions (UMRouteOptions other)
Copy Constructor
Method Summary
Table 1071: Methods in UMRouteOptions
Methods
public boolean equals (Object obj)
public int getTransitWalkMaxDistance ()
Gets maximum allowed walk distance in meters or -1 if not set.
public int hashCode ()
public boolean isStrictRouteCountEnabled ()
Checks whether specified route count is strict.
public UMRouteOptions setStrictRouteCountEnabled (boolean value)
Sets whether specified route count is strict.
public UMRouteOptions setTransitWalkMaxDistance (int value)
Sets maximum allowed walk distance in meters.
public String toString ()
Class Details
The class contains Urban Mobility specific options for route calculation.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Constructor Details
UMRouteOptions ()
Public Constructor
UMRouteOptions (RouteOptions other)
Copy Constructor
Parameters:
other
options to copy from.
HERE Android SDK Developer's Guide
API Reference
1756
UMRouteOptions (UMRouteOptions other)
Copy Constructor
Parameters:
other
options to copy from.
Method Details
public boolean equals (Object obj)
Parameters:
obj
public int getTransitWalkMaxDistance ()
Gets maximum allowed walk distance in meters or -1 if not set.
Returns:
maximum allowed walk distance in meters, or -1 if not set
public int hashCode ()
public boolean isStrictRouteCountEnabled ()
Checks whether specified route count is strict. The default is false.
Returns:
true if strict otherwise false
public UMRouteOptions setStrictRouteCountEnabled (boolean value)
HERE Android SDK Developer's Guide
API Reference
1757
Sets whether specified route count is strict. If route count is strict then result contains specified number of
routes or less; otherwise, the number of routes returned is not guaranteed. The default is false. NOTE: Do not
enable strict route count if you plan to use subsequent route requests.
Parameters:
value
true if strict otherwise false.
Returns:
The modified UMRouteOptions itself.
public UMRouteOptions setTransitWalkMaxDistance (int value)
Sets maximum allowed walk distance in meters. Allowed range is [0, 6000], or -1 to use default value. Using
unsupported value will result error response in route calculation. The default is 2000.
Parameters:
value
maximum allowed walk distance in meters
Returns:
The modified UMRouteOptions itself.
public String toString ()
FilteringProfile
The enumeration FilteringProfile is a member of com.here.android.mpa.routing.UMRouteOptions.
Enumeration Summary
public static final enumeration UMRouteOptions.FilteringProfile
extends java.lang.Enum, java.lang.Object
Specifies which filtering profile to use.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1758
Enum Constant Summary
Table 1072: Enum Constants in FilteringProfile
Fields
public static final FilteringProfile DEFAULT
All transports and operators are allowed by default.
public static final FilteringProfile RESTRICTED
All transports and operators are disabled except for ones explicitly allowed in request.
Method Summary
Table 1073: Methods in FilteringProfile
Methods
public static FilteringProfile valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static UMRouteOptions.FilteringProfile[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies which filtering profile to use.
Enum Constant Details
public static final FilteringProfile DEFAULT
All transports and operators are allowed by default.
public static final FilteringProfile RESTRICTED
All transports and operators are disabled except for ones explicitly allowed in request. Supported only by
Smart Mobility API.
Method Details
public static FilteringProfile valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
1759
public static UMRouteOptions.FilteringProfile[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
UMRouteResult
The class UMRouteResult is a member of com.here.android.mpa.routing .
Class Summary
public final class UMRouteResult
extends com.here.android.mpa.routing.RouteResult, java.lang.Object
Route result extension with Urban Mobility specifics.
[For complete information, see the section Class Details]
Method Summary
Table 1074: Methods in UMRouteResult
Methods
public UMRoute getUMRoute ()
Returns the UMRoute in the UMRouteResult if available.
Class Details
Route result extension with Urban Mobility specifics.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public UMRoute getUMRoute ()
Returns the UMRoute in the UMRouteResult if available. In other words UMRoute is available if result
represents online calculations. If instance represents offline fallback result, this method returns null (Use
getRoute() istead then.
Returns:
The UMRoute, or null if not available.
HERE Android SDK Developer's Guide
API Reference
1760
UMRouter
The class UMRouter is a member of com.here.android.mpa.routing .
Class Summary
public final class UMRouter
implements com.here.android.mpa.routing.Router
extends java.lang.Object
Urban Mobility-specific route calculation executor.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1075: Nested Classes in UMRouter
Nested Classes
public static abstract interface UMRouter.Listener
Represents a listener to provide information about route calculation events.
public static final enumeration UMRouter.SubsequentRouteType
Defines if earlier or later routes should be requested.
Constructor Summary
Table 1076: Constructors in UMRouter
Constructors
UMRouter ()
Default constructor.
Method Summary
Table 1077: Methods in UMRouter
Methods
public void calculateParkAndRideRoute (RoutePlan routePlan, Listener<UMCalculateResult, ErrorCode>
listener)
public void calculateRoute (RoutePlan routePlan, Listener<UMCalculateResult, ErrorCode> listener)
Invokes an asynchronous route calculation.
public void calculateSubsequentRoute (UMCalculateResult result, SubsequentRouteType type, int
routeCount, Listener<UMCalculateResult, ErrorCode> listener)
Invokes subsequent route calculation with respect to given UMCalculateResult.
HERE Android SDK Developer's Guide
API Reference
1761
Methods
public void cancel ()
public boolean isBusy ()
Class Details
Urban Mobility-specific route calculation executor. Defines Urban Mobility specific calculation methods and
response listener.
Urban Mobility provides Inter-modal and Multi-modal routes including Public Transit.
To use this feature, your application must include the google-gson library (release 2.2.4 or a compatible
version) on its class path. This library can be downloaded from the google-gson project website at http://
code.google.com/p/google-gson/. Attempting to use this feature without adding this library will cause
INVALID_OPERATION.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Constructor Details
UMRouter ()
Default constructor. Multiple UMRouter s can be created to calculate multiple routes in parallel.
Method Details
public void calculateParkAndRideRoute (RoutePlan routePlan,
Listener<UMCalculateResult, ErrorCode> listener)
Parameters:
routePlan
listener
public void calculateRoute (RoutePlan routePlan, Listener<UMCalculateResult,
ErrorCode> listener)
Invokes an asynchronous route calculation. Upon completion of the request, the Listener will be invoked
regardless if the request is completed successfully or not.
Parameters:
routePlan
A RoutePlan used to calculate the route. NOTE: Urban Mobility supports only 2 waypoints. If
RoutePlan contains more than 2 waypoints, error INVALID_PARAMETERS is returned.
listener
A Listener for the UMRouter
HERE Android SDK Developer's Guide
API Reference
1762
public void calculateSubsequentRoute (UMCalculateResult result,
SubsequentRouteType type, int routeCount, Listener<UMCalculateResult, ErrorCode>
listener)
Invokes subsequent route calculation with respect to given UMCalculateResult. Upon completion of the
request, the Listener will be invoked regardless if the request is completed successfully or not.
The UMCalculateResult stores all of the state necessary to perform the subsequent route request (e.g.
the RoutePlan ). No state is stored in the UMRouter instance. Therefore it is not required to use the same
UMRouter instance to perform the initial request and subsequent request. Because of this, it is possible to
issue multiple subsequent route requests in parallel by creating multiple instances of UMRouter .
NOTE: Do not enable strict route count if you plan to use subsequent route requests. See
setStrictRouteCountEnabled(boolean) for more details.
Parameters:
result
UMCalculateResult for which subsequent route should be calculated.
type
Type of subsequent route.
routeCount
Number of desired route. Given number is just suggestion and the number of route returned is not
guaranteed. Allowed range is [1, 6]. Using unsupported value will result error response in route
calculation.
listener
A Listener for the UMRouter.
public void cancel ()
public boolean isBusy ()
Listener
The interface Listener is a member of com.here.android.mpa.routing.UMRouter.
Interface Summary
public static abstract interface UMRouter.Listener
extends com.here.android.mpa.routing.Router.Listener
Represents a listener to provide information about route calculation events.
HERE Android SDK Developer's Guide
API Reference
1763
[For complete information, see the section Interface Details]
See also:
calculateRoute(RoutePlan, Listener<UMCalculateResult, ErrorCode>)
Method Summary
Table 1078: Methods in Listener
Methods
public abstract void onCalculateRouteFinished (UMCalculateResult response, ErrorCode error)
A callback indicating that Urban Mobility route calculation operation has finished.
Interface Details
Represents a listener to provide information about route calculation events.
See also:
calculateRoute(RoutePlan, Listener<UMCalculateResult, ErrorCode>)
Method Details
public abstract void onCalculateRouteFinished (UMCalculateResult response,
ErrorCode error)
A callback indicating that Urban Mobility route calculation operation has finished.
Parameters:
response
A UMCalculateResult contains Urban Mobility specific result and/or errors.
error
SubsequentRouteType
The enumeration SubsequentRouteType is a member of com.here.android.mpa.routing.UMRouter.
Enumeration Summary
public static final enumeration UMRouter.SubsequentRouteType
extends java.lang.Enum, java.lang.Object
Defines if earlier or later routes should be requested.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1764
Enum Constant Summary
Table 1079: Enum Constants in SubsequentRouteType
Fields
public static final SubsequentRouteType EARLIER
public static final SubsequentRouteType LATER
Method Summary
Table 1080: Methods in SubsequentRouteType
Methods
public static SubsequentRouteType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static UMRouter.SubsequentRouteType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Defines if earlier or later routes should be requested.
Enum Constant Details
public static final SubsequentRouteType EARLIER
public static final SubsequentRouteType LATER
Method Details
public static SubsequentRouteType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static UMRouter.SubsequentRouteType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1765
search
The package search is a member of com.here.android.mpa.
Package Summary
search
The search package provides classes for performing places and geocoder searches.
Package Details
The search package provides classes for performing places and geocoder searches.
com.here.android.mpa.search.RequestCreator.Places provides methods to create new
requests to search and explore places near a given position.
com.here.android.mpa.search.RequestCreator.Geocoder provides methods to create new
requests to perform address and reverse geocode searches.
The typical steps when perform a search are:
Implement the ResultListener interface to handle the completion of the search
Create a request using RequestCreator.Places or RequestCreator.Geocoder
Start the search by invoking execute(ResultListener)
When the search completes, the data returned in the ResultListener.onCompleted() callback is
triggered
To use this feature, your application must include the google-gson library (release 2.2.4 or a compatible
version) on its class path. This library can be downloaded from the google-gson project website at http://
code.google.com/p/google-gson/. Attempting to use this feature without adding this library will cause
runtime errors.
For more details on performing searches, please consult the "Places" section in the HERE SDK for Android
Developer's Guide.
Address
The class Address is a member of com.here.android.mpa.search .
Class Summary
public class Address
extends java.lang.Object
Provides textual address information for a Location.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1766
Constructor Summary
Table 1081: Constructors in Address
Constructors
Address ()
Default constructor.
Address (Address other)
Copy constructor.
Method Summary
Table 1082: Methods in Address
Methods
public void addAdditionalData (String key, String value)
Adds additional address data, one key-value pair per call.
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Map getAdditionalData ()
Gets additional address data.
public String getCity ()
Gets the current city name for the Address .
public String getCountryCode ()
Gets the current ISO 3166-1 (3-letter) country code for the Address .
public String getCountryName ()
Gets the current country name for the Address .
public String getCounty ()
Gets the current county name for the Address .
public String getDistrict ()
Gets the current district name for the Address .
public String getFloorNumber ()
Gets the current floor number (in a multi-story building) for the Address .
public String getHouseNumber ()
Gets the current house number for the Address .
public String getPostalCode ()
Gets the current postal code for the Address .
public String getState ()
Gets the current state name for the Address .
HERE Android SDK Developer's Guide
API Reference
1767
Methods
public String getStateCode ()
Gets the current state code (state abbreviation) for the Address .
public String getStreet ()
Gets the current street name for the Address .
public String getSuiteNumberOrName ()
Gets the current suite number or suite name for the Address .
public String getText ()
Gets a displayable, formatted rich text for the entire Address .
public int hashCode ()
For documentation, see java.lang.Object
public Address setCity (String city)
Sets a city name for the Address .
public Address setCountryCode (String countryCode)
Sets an ISO 3166-1 (3-letter) country code for the Address .
public Address setCountryName (String countryName)
Sets a country name for the Address .
public Address setCounty (String county)
Sets a county name for the Address .
public Address setDistrict (String district)
Sets a district name for the Address .
public Address setFloorNumber (String floorNumber)
Sets a floor number (in a multi-story building) for the Address .
public Address setHouseNumber (String houseNumber)
Sets a house number for the Address .
public Address setPostalCode (String postalCode)
Sets a postal code for the Address .
public Address setState (String state)
Sets a state name for the Address .
public Address setStateCode (String state)
Sets a state code (abbreviation) for the Address .
public Address setStreet (String street)
Sets a street name for the Address .
public Address setSuiteNumberOrName (String suiteNumberOrName)
Sets a suite number or suite name for the Address .
HERE Android SDK Developer's Guide
API Reference
1768
Methods
public Address setText (String text)
Sets text for the Address .
public String toString ()
For documentation, see java.lang.Object
Class Details
Provides textual address information for a Location. The information is divided among fields such as country,
street, postal code, and so on.
To retrieve a combined, formatted string of this address, use the getText() method.
Constructor Details
Address ()
Default constructor.
Address (Address other)
Copy constructor.
Parameters:
other
The other Address to copy.
Method Details
public void addAdditionalData (String key, String value)
Adds additional address data, one key-value pair per call.
Parameters:
key
The key for additional data (key-value pair).
value
The value for additional data (key-value pair).
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1769
public Map getAdditionalData ()
Gets additional address data.
Returns:
The java.util.Map of the additional data in key-value notation.
public String getCity ()
Gets the current city name for the Address .
Returns:
The current city name (could be empty)
public String getCountryCode ()
Gets the current ISO 3166-1 (3-letter) country code for the Address .
Returns:
The current country code (could be empty)
public String getCountryName ()
Gets the current country name for the Address .
Returns:
The current country name (could be empty)
public String getCounty ()
Gets the current county name for the Address .
Returns:
The current county name (could be empty)
public String getDistrict ()
Gets the current district name for the Address .
Returns:
The current district name (could be empty)
public String getFloorNumber ()
HERE Android SDK Developer's Guide
API Reference
1770
Gets the current floor number (in a multi-story building) for the Address .
Returns:
The current floor number (could be empty)
public String getHouseNumber ()
Gets the current house number for the Address .
Returns:
The current house number (could be empty)
public String getPostalCode ()
Gets the current postal code for the Address .
Returns:
The current postal code (could be empty)
public String getState ()
Gets the current state name for the Address .
Returns:
The current state name or abbreviation (could be empty)
public String getStateCode ()
Gets the current state code (state abbreviation) for the Address .
Returns:
The current state name or abbreviation (could be empty)
public String getStreet ()
Gets the current street name for the Address .
Returns:
The current street name (could be empty)
public String getSuiteNumberOrName ()
Gets the current suite number or suite name for the Address .
Returns:
HERE Android SDK Developer's Guide
API Reference
1771
The current suite number or name (could be empty)
public String getText ()
Gets a displayable, formatted rich text for the entire Address . For example, "22 Rue du Grenier
Saint-Lazare\n75003 Paris\nFrance"
Returns:
The current text (could be empty)
public int hashCode ()
For documentation, see java.lang.Object
public Address setCity (String city)
Sets a city name for the Address .
Parameters:
city
Desired city name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setCountryCode (String countryCode)
Sets an ISO 3166-1 (3-letter) country code for the Address .
Parameters:
countryCode
Desired ISO 3166-1 country code
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
IllegalArgumentException
Country code is not 3-letters
HERE Android SDK Developer's Guide
API Reference
1772
public Address setCountryName (String countryName)
Sets a country name for the Address .
Parameters:
countryName
Desired country name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setCounty (String county)
Sets a county name for the Address .
Parameters:
county
Desired county name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setDistrict (String district)
Sets a district name for the Address .
Parameters:
district
Desired district name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
HERE Android SDK Developer's Guide
API Reference
1773
public Address setFloorNumber (String floorNumber)
Sets a floor number (in a multi-story building) for the Address .
Parameters:
floorNumber
Desired floor number
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setHouseNumber (String houseNumber)
Sets a house number for the Address .
Parameters:
houseNumber
Desired house number
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setPostalCode (String postalCode)
Sets a postal code for the Address .
Parameters:
postalCode
Desired postal code
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
HERE Android SDK Developer's Guide
API Reference
1774
public Address setState (String state)
Sets a state name for the Address .
Parameters:
state
Desired state name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setStateCode (String state)
Sets a state code (abbreviation) for the Address .
Parameters:
state
Desired state name or abbreviation
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setStreet (String street)
Sets a street name for the Address .
Parameters:
street
Desired street name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
HERE Android SDK Developer's Guide
API Reference
1775
public Address setSuiteNumberOrName (String suiteNumberOrName)
Sets a suite number or suite name for the Address .
Parameters:
suiteNumberOrName
Desired suite number or name
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public Address setText (String text)
Sets text for the Address .
Parameters:
text
Desired text for the address
Returns:
The updated Address object itself.
Throws:
NullPointerException
Passed argument is null
public String toString ()
For documentation, see java.lang.Object
AroundRequest
The class AroundRequest is a member of com.here.android.mpa.search .
Class Summary
public class AroundRequest
extends com.here.android.mpa.search.DiscoveryRequest, com.here.android.mpa.search.Request,
java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1776
The AroundRequest represents sets of places within a specific location context, usually the location of the
user.
[For complete information, see the section Class Details]
Constructor Summary
Table 1083: Constructors in AroundRequest
Constructors
AroundRequest ()
Default constructor.
Method Summary
Table 1084: Methods in AroundRequest
Methods
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
public AroundRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
public AroundRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius.
public AroundRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the search area using a GeoBoundingBox .
public AroundRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Class Details
The AroundRequest represents sets of places within a specific location context, usually the location of the
user. This request is intended for applications that employ features such as augmented reality, where places
around the user's location are displayed on a device. It is intended to provide places that are likely to be
visible to the user as well as important places that are further away.
The AroundRequest allows users to request places near to a given location or area. The places around the
location context are returned in order of proximity.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate), a search area using setSearchArea(GeoCoordinate, int) or
setSearchArea(GeoBoundingBox) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
HERE Android SDK Developer's Guide
API Reference
1777
Constructor Details
AroundRequest ()
Default constructor.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate), a search area using setSearchArea(GeoCoordinate, int) or
setSearchArea(GeoBoundingBox) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Method Details
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public AroundRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
Parameters:
filter
A CategoryFilter representing the category filter. When a CategoryFilter is specified, the result
items will be limited to the categories defined in the filter.
Returns:
The AroundRequest.
public AroundRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius.
Parameters:
center
The GeoCoordinate representing the search area center location.
radius
The search area circle radius in meters.
Returns:
HERE Android SDK Developer's Guide
API Reference
1778
The AroundRequest.
public AroundRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the search area using a GeoBoundingBox .
Parameters:
boundingArea
The GeoBoundingBox representing the search area.
Returns:
The AroundRequest.
public AroundRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Parameters:
center
The GeoCoordinate representing the location context used to search for nearby places.
Returns:
The AroundRequest.
AutoSuggest
The class AutoSuggest is a member of com.here.android.mpa.search .
Class Summary
public abstract class AutoSuggest
extends java.lang.Object
Represents the base class for suggested places and searches.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1085: Nested Classes in AutoSuggest
Nested Classes
public static final enumeration AutoSuggest.Type
Represents values describing supported AutoSuggest types for a text suggestion.
HERE Android SDK Developer's Guide
API Reference
1779
Method Summary
Table 1086: Methods in AutoSuggest
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getHighlightedTitle ()
Gets the display title for this place, with HTML markup highlighting the parts of the string that were matched.
public String getTitle ()
Gets the display title for this place.
public Type getType ()
Gets the specialized AutoSuggest type.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents the base class for suggested places and searches.
The following specialized types might be available:
AutoSuggestPlace
AutoSuggestSearch
AutoSuggestQuery
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getHighlightedTitle ()
Gets the display title for this place, with HTML markup highlighting the parts of the string that were matched.
For example, if the user performs an AutoSuggest search with "Rest", the API will return the following:
title:Joey Restaurant
highlightedTitle:Joey Restaurant
Returns:
The hightlightedTitle
HERE Android SDK Developer's Guide
API Reference
1780
public String getTitle ()
Gets the display title for this place.
Returns:
The title
public Type getType ()
Gets the specialized AutoSuggest type.
Returns:
The type
public int hashCode ()
For documentation, see java.lang.Object
Type
The enumeration Type is a member of com.here.android.mpa.search.AutoSuggest.
Enumeration Summary
public static final enumeration AutoSuggest.Type
extends java.lang.Enum, java.lang.Object
Represents values describing supported AutoSuggest types for a text suggestion.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1087: Enum Constants in Type
Fields
public static final Type UNKNOWN
Unknown type.
public static final Type PLACE
Suggested Place.
public static final Type SEARCH
Suggested Search.
public static final Type QUERY
Suggested Query.
HERE Android SDK Developer's Guide
API Reference
1781
Method Summary
Table 1088: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static AutoSuggest.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing supported AutoSuggest types for a text suggestion.
Enum Constant Details
public static final Type UNKNOWN
Unknown type.
public static final Type PLACE
Suggested Place.
public static final Type SEARCH
Suggested Search.
public static final Type QUERY
Suggested Query.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static AutoSuggest.Type[] values ()
HERE Android SDK Developer's Guide
API Reference
1782
This method retrieves an array of constants of the given enum type in the order in which they are declared.
AutoSuggestPlace
The class AutoSuggestPlace is a member of com.here.android.mpa.search .
Class Summary
public class AutoSuggestPlace
extends com.here.android.mpa.search.AutoSuggest, java.lang.Object
Represents an AutoSuggestPlace which contains information about a suggested Place .
[For complete information, see the section Class Details]
Method Summary
Table 1089: Methods in AutoSuggestPlace
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place.
public String getCategory ()
Gets the category for the Place.
public PlaceRequest getPlaceDetailsRequest ()
Gets the request to retrieve the Place details.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the Place.
public String getVicinity ()
Gets the String description for the vicinity of the Place.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents an AutoSuggestPlace which contains information about a suggested Place .
Note: detailed Place information is retrieved by way of the PlaceRequest returned from a call to the
getPlaceDetailsRequest() method.
HERE Android SDK Developer's Guide
API Reference
1783
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place. Typically,
bounding boxes are associated with places such as cities and countries.
Note: bounding box information for a Place is optional, so a call to this method could return null .
Returns:
The GeoBoundingBox containing the Place (could be null)
public String getCategory ()
Gets the category for the Place.
As category information for a suggested search is optional, so a call to this method could return an empty
string.
Returns:
The Category.
public PlaceRequest getPlaceDetailsRequest ()
Gets the request to retrieve the Place details.
Returns:
The PlaceRequest to retrieve the Place details
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the Place.
Returns:
The GeoCoordinate
public String getVicinity ()
HERE Android SDK Developer's Guide
API Reference
1784
Gets the String description for the vicinity of the Place. Typically, this description is derived from the
Address, but could also contain any other description that helps a user understand where the Place is
located.
Note: vicinity information for a Place is optional, so a call to this method could return an empty string.
Returns:
The vicinity description (could be empty)
public int hashCode ()
For documentation, see java.lang.Object
AutoSuggestQuery
The class AutoSuggestQuery is a member of com.here.android.mpa.search .
Class Summary
public final class AutoSuggestQuery
extends com.here.android.mpa.search.AutoSuggest, java.lang.Object
Represents an AutoSuggest with suggested completion of the given string
[For complete information, see the section Class Details]
Method Summary
Table 1090: Methods in AutoSuggestQuery
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getQueryCompletion ()
Gets the completion for the query.
public TextAutoSuggestionRequest getRequest ()
Gets the request to retrieve the AutoSuggest list.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents an AutoSuggest with suggested completion of the given string
Note: List of AutoSuggest can be retrieved by call to the getRequest() method.
HERE Android SDK Developer's Guide
API Reference
1785
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getQueryCompletion ()
Gets the completion for the query.
Returns:
completion
public TextAutoSuggestionRequest getRequest ()
Gets the request to retrieve the AutoSuggest list.
Returns:
The TextAutoSuggestionRequest to retrieve the AutoSuggest list
public int hashCode ()
For documentation, see java.lang.Object
AutoSuggestSearch
The class AutoSuggestSearch is a member of com.here.android.mpa.search .
Class Summary
public class AutoSuggestSearch
extends com.here.android.mpa.search.AutoSuggest, java.lang.Object
Represents an AutoSuggestSearch which contains information about a refined search link.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1786
Method Summary
Table 1091: Methods in AutoSuggestSearch
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place.
public String getCategory ()
Gets the category for the suggested search.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the suggested search.
public DiscoveryRequest getSuggestedSearchRequest ()
Gets the request to perform a suggested search.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents an AutoSuggestSearch which contains information about a refined search link.
Note: DiscoveryResultPage is retrieved by way of the DiscoveryRequest returned from a call to the
getSuggestedSearchRequest() method.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place. Typically,
bounding boxes are associated with places such as cities and countries.
Note: bounding box information for a suggested search is optional, so a call to this method could return
null .
Returns:
The GeoBoundingBox
HERE Android SDK Developer's Guide
API Reference
1787
public String getCategory ()
Gets the category for the suggested search.
As category information for a suggested search is optional, so a call to this method could return an empty
string.
Returns:
The Category
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the suggested search.
Note: position information for a suggested search is optional, so a call to this method could return null .
Returns:
The GeoCoordinate
public DiscoveryRequest getSuggestedSearchRequest ()
Gets the request to perform a suggested search.
Returns:
The DiscoveryRequest to retrieve the DiscoveryResultPage
public int hashCode ()
For documentation, see java.lang.Object
Category
The class Category is a member of com.here.android.mpa.search .
Class Summary
public class Category
extends java.lang.Object
Represents a category with which a Place can be associated.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1788
Nested Class Summary
Table 1092: Nested Classes in Category
Nested Classes
public static final enumeration Category.Global
Represents a set of fixed category filters on the resources of the Places search service.
Method Summary
Table 1093: Methods in Category
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getIconUrl ()
Gets the URL to retrieve the icon for the Category .
public String getId ()
Gets the unique identifier for the Category .
public String getName ()
Gets the localized display name for the Category .
public Category getParent ()
Gets the parent Category for the Category .
public java.util.List <Category> getSubCategories ()
Gets the list of subcategories for the Category .
public static java.util.List <Category> globalCategories ()
Return the localized Global categories for Places search.
public static Category globalCategory (Global type)
Return the localized Global category for Places search.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a category with which a Place can be associated.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
HERE Android SDK Developer's Guide
API Reference
1789
obj
public String getIconUrl ()
Gets the URL to retrieve the icon for the Category .
Returns:
The icon URL
public String getId ()
Gets the unique identifier for the Category .
Returns:
The unique ID
public String getName ()
Gets the localized display name for the Category .
Returns:
Localized display name
public Category getParent ()
Gets the parent Category for the Category .
Note: The category can already be a parent Category , in which case this method would return itself.
Returns:
Parent Category
public java.util.List <Category> getSubCategories ()
Gets the list of subcategories for the Category .
Note: a Category might have no subcategories, in which case this method would return empty .
Returns:
The list of Category objects representing the subcategories (could be empty)
public static java.util.List <Category> globalCategories ()
Return the localized Global categories for Places search. Note: The list of categories is cached. The update
request to Places backend is made periodically and when device locale is changed. If there is no cache or
cache is being updated, an empty list is returned. User should try again later.
HERE Android SDK Developer's Guide
API Reference
1790
Returns:
A list of localized global Category instances if available, empty otherwise.
public static Category globalCategory (Global type)
Return the localized Global category for Places search. Note: The list of categories is cached. The update
request to Places backend is made periodically and when device locale is changed. If there is no cache or
cache is being updated, an empty list is returned. User should try again later.
Parameters:
type
The Global type.
Returns:
The localized Global Category instances.
public int hashCode ()
For documentation, see java.lang.Object
Global
The enumeration Global is a member of com.here.android.mpa.search.Category.
Enumeration Summary
public static final enumeration Category.Global
extends java.lang.Enum, java.lang.Object
Represents a set of fixed category filters on the resources of the Places search service.
[For complete information, see the section Enumeration Details]
See also:
globalCategories()
globalCategory(Global)
add(Global)
HERE Android SDK Developer's Guide
API Reference
1791
Enum Constant Summary
Table 1094: Enum Constants in Global
Fields
public static final Global ACCOMMODATION
The accommodation category.
public static final Global ADMINISTRATIVE_AREAS_BUILDINGS
The administrative-areas-buildings category.
public static final Global BUSINESS_SERVICES
The business-services category.
public static final Global EAT_DRINK
The eat-drink category.
public static final Global FACILITIES
The facilities category.
public static final Global GOING_OUT
The going-out category.
public static final Global LEISURE_OUTDOOR
The leisure-outdoor category.
public static final Global NATURAL_GEOGRAPHICAL
The natural-geographical category.
public static final Global SHOPPING
The shopping category.
public static final Global SIGHTS_MUSEUMS
The sights-museums category.
public static final Global TRANSPORT
The transport category.
Method Summary
Table 1095: Methods in Global
Methods
public String toString ()
Returns a stringified Category .
public static Global valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Category.Global[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1792
Enumeration Details
Represents a set of fixed category filters on the resources of the Places search service.
See also:
globalCategories()
globalCategory(Global)
add(Global)
Enum Constant Details
public static final Global ACCOMMODATION
The accommodation category.
public static final Global ADMINISTRATIVE_AREAS_BUILDINGS
The administrative-areas-buildings category.
public static final Global BUSINESS_SERVICES
The business-services category.
public static final Global EAT_DRINK
The eat-drink category.
public static final Global FACILITIES
The facilities category.
public static final Global GOING_OUT
The going-out category.
public static final Global LEISURE_OUTDOOR
The leisure-outdoor category.
public static final Global NATURAL_GEOGRAPHICAL
The natural-geographical category.
HERE Android SDK Developer's Guide
API Reference
1793
public static final Global SHOPPING
The shopping category.
public static final Global SIGHTS_MUSEUMS
The sights-museums category.
public static final Global TRANSPORT
The transport category.
Method Details
public String toString ()
Returns a stringified Category .
Returns:
The stringified Category
public static Global valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Category.Global[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CategoryFilter
The class CategoryFilter is a member of com.here.android.mpa.search .
Class Summary
public class CategoryFilter
extends java.lang.Object
Represents a filter used when performing a search for popular places within a specific geographic area.
HERE Android SDK Developer's Guide
API Reference
1794
[For complete information, see the section Class Details]
See also:
Category
Category.Global
Constructor Summary
Table 1096: Constructors in CategoryFilter
Constructors
CategoryFilter ()
Default constructor.
Method Summary
Table 1097: Methods in CategoryFilter
Methods
public CategoryFilter add (Global filter)
Adds a Category.Global to the CategoryFilter .
public CategoryFilter add (Category filter)
Adds a Category (retrieved from the results of a previous request) to the CategoryFilter .
public CategoryFilter add (String filter)
Adds a known category to the CategoryFilter as a String .
public boolean equals (Object obj)
For documentation, see java.lang.Object
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
Returns a stringified CategoryFilter , within which individual categories are separated by commas.
Class Details
Represents a filter used when performing a search for popular places within a specific geographic area. (This
type of search is otherwise known as "explore".) The filter limits search results to the specified categories.
A filter can include one or more of:
A Category
A Category.Global
A String indicating a known category
See also:
Category
HERE Android SDK Developer's Guide
API Reference
1795
Category.Global
Constructor Details
CategoryFilter ()
Default constructor.
Method Details
public CategoryFilter add (Global filter)
Adds a Category.Global to the CategoryFilter .
Parameters:
filter
A Category.Global filter
Returns:
The updated CategoryFilter object itself.
public CategoryFilter add (Category filter)
Adds a Category (retrieved from the results of a previous request) to the CategoryFilter .
Parameters:
filter
A Category filter
Returns:
The updated CategoryFilter object itself.
public CategoryFilter add (String filter)
Adds a known category to the CategoryFilter as a String .
Parameters:
filter
A String filter
Returns:
The updated CategoryFilter object itself.
public boolean equals (Object obj)
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1796
Parameters:
obj
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
Returns a stringified CategoryFilter , within which individual categories are separated by commas.
Returns:
The stringified CategoryFilter
ContactDetail
The class ContactDetail is a member of com.here.android.mpa.search .
Class Summary
public class ContactDetail
extends java.lang.Object
Represents detailed information about a contact for a Place.
[For complete information, see the section Class Details]
Method Summary
Table 1098: Methods in ContactDetail
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getLabel ()
Gets the localized label for the ContactDetail , describing the mechanism by which application users can contact the
Place.
public String getType ()
Gets the type (email, fax, phone, website, etc.) for the ContactDetail .
public String getValue ()
Gets the value corresponding to an associated contact mechanism label for the ContactDetail .
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1797
Class Details
Represents detailed information about a contact for a Place.
For example, if a Place has among its known contacts the phone number 555-1234, use this class to access
details about that particular contact's type ("phone") and value ("555-1234").
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getLabel ()
Gets the localized label for the ContactDetail , describing the mechanism by which application users can
contact the Place. (e.g. by "Phone").
Returns:
The label
See also:
getValue()
public String getType ()
Gets the type (email, fax, phone, website, etc.) for the ContactDetail .
Returns:
The type
public String getValue ()
Gets the value corresponding to an associated contact mechanism label for the ContactDetail .
For example, if the mechanism for contacting a Place is "phone" then a call to this method might return
"555-1234" as the corresponding value.
Returns:
The value
See also:
getLabel()
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1798
For documentation, see java.lang.Object
DiscoveryLink
The class DiscoveryLink is a member of com.here.android.mpa.search .
Class Summary
public class DiscoveryLink
extends com.here.android.mpa.search.DiscoveryResult, com.here.android.mpa.search.Link, java.lang.Object
Represents a discovery-related API link, used to retrieve a DiscoveryResultPage .
[For complete information, see the section Class Details]
Method Summary
Table 1099: Methods in DiscoveryLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
public DiscoveryRequest getRequest ()
Gets the DiscoveryRequest to perform the next discovery search.
public String getTitle ()
Gets the localized title for the resource to which the Link refers.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a discovery-related API link, used to retrieve a DiscoveryResultPage .
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
HERE Android SDK Developer's Guide
API Reference
1799
obj
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
Note: an icon URL for a linked object is optional, so a call to this method could return empty .
Returns:
The icon URL (could be empty)
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
Note: an ID for a linked object is optional, so a call to this method could return empty .
Returns:
The ID (could be empty)
public DiscoveryRequest getRequest ()
Gets the DiscoveryRequest to perform the next discovery search.
Returns:
The DiscoveryRequest
public String getTitle ()
Gets the localized title for the resource to which the Link refers. Client devices can display this title within
an application.
Note: a title for a linked object is optional, so a call to this method could return empty .
Returns:
The title (could be empty)
public int hashCode ()
For documentation, see java.lang.Object
DiscoveryRequest
The class DiscoveryRequest is a member of com.here.android.mpa.search .
HERE Android SDK Developer's Guide
API Reference
1800
Class Summary
public class DiscoveryRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve a DiscoveryResultPage object by way of Places search
services.
[For complete information, see the section Class Details]
See also:
ExploreRequest
HereRequest
SearchRequest
Constructor Summary
Table 1100: Constructors in DiscoveryRequest
Constructors
DiscoveryRequest ()
DiscoveryRequest (PlacesDiscoveryRequest impl)
Field Summary
Table 1101: Fields in DiscoveryRequest
Fields
protected CategoryFilter m_categoryFilter
protected List<android.util.Pair<java.lang.Integer, java.lang.Integer>> m_imageDimensions
protected GeoBoundingBox m_searchArea
protected GeoCoordinate m_searchCenter
protected int m_searchRadius
Method Summary
Table 1102: Methods in DiscoveryRequest
Methods
public void addImageDimensions (int width, int height)
Request Image Media with specific dimensions.
public DiscoveryRequest addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results.
HERE Android SDK Developer's Guide
API Reference
1801
Methods
public ErrorCode execute (ResultListener<DiscoveryResultPage> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
public int getCollectionSize ()
Gets the current collection size being used for request responses.
public List getReferences ()
This function returns the names of requested reference identifiers to be returned in the results.
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses.
protected DiscoveryRequest setCategoryFilter (CategoryFilter filter)
public DiscoveryRequest setCollectionSize (int value)
Sets a collection size to be used for request responses.
public DiscoveryRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public DiscoveryRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses.
protected DiscoveryRequest setSearchArea (GeoCoordinate coordinate, int radius)
protected DiscoveryRequest setSearchArea (GeoBoundingBox area)
protected DiscoveryRequest setSearchCenter (GeoCoordinate coordinate)
Class Details
Represents an extended Request used to retrieve a DiscoveryResultPage object by way of Places search
services.
See also:
ExploreRequest
HereRequest
SearchRequest
Constructor Details
DiscoveryRequest ()
DiscoveryRequest (PlacesDiscoveryRequest impl)
Parameters:
impl
HERE Android SDK Developer's Guide
API Reference
1802
Field Details
protected CategoryFilter m_categoryFilter
protected List<android.util.Pair<java.lang.Integer, java.lang.Integer>>
m_imageDimensions
protected GeoBoundingBox m_searchArea
protected GeoCoordinate m_searchCenter
protected int m_searchRadius
Method Details
public void addImageDimensions (int width, int height)
Request Image Media with specific dimensions. At least one of the sizes (width or height) needs to be valid
(greater than 0).
Parameters:
width
Image width (pass 0 for any width)
height
Image height (pass 0 for any height)
public DiscoveryRequest addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results.
For example, to retrieve an POI identifier (pvid), set this value to PVID_ID_REFERENCE_NAME.
Parameters:
name
Name of reference identifier to retrieve.
Returns:
True if name added, false otherwise.
See also:
HERE Android SDK Developer's Guide
API Reference
1803
PVID_ID_REFERENCE_NAME
VENUES_ID_REFERENCE_NAME
VENUES_CONTENT_ID_REFERENCE_NAME
VENUES_DESTINATION_ID_REFERENCE_NAME
VENUES_VENUE_ID_REFERENCE_NAME
public ErrorCode execute (ResultListener<DiscoveryResultPage> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
Parameters:
eventListener
public int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size
public List getReferences ()
This function returns the names of requested reference identifiers to be returned in the results.
Returns:
List of the names of reference identifiers to be returned in the result.
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses.
Returns:
The current RichTextFormatting type
protected DiscoveryRequest setCategoryFilter (CategoryFilter filter)
Parameters:
filter
public DiscoveryRequest setCollectionSize (int value)
HERE Android SDK Developer's Guide
API Reference
1804
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size per request.
Returns:
This Request object
Throws:
IllegalArgumentException
if size is out of range.
public DiscoveryRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Parameters:
mapViewport
The bounding box of the map area currently visible.
public DiscoveryRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses. The default formatting is HTML.
Parameters:
value
Desired RichTextFormatting
Returns:
This DiscoveryRequest object
protected DiscoveryRequest setSearchArea (GeoCoordinate coordinate, int radius)
Parameters:
coordinate
radius
protected DiscoveryRequest setSearchArea (GeoBoundingBox area)
Parameters:
HERE Android SDK Developer's Guide
API Reference
1805
area
protected DiscoveryRequest setSearchCenter (GeoCoordinate coordinate)
Parameters:
coordinate
DiscoveryResult
The class DiscoveryResult is a member of com.here.android.mpa.search .
Class Summary
public class DiscoveryResult
extends com.here.android.mpa.search.Link, java.lang.Object
Represents a base class for a DiscoveryResult found in a DiscoveryResultPage.
[For complete information, see the section Class Details]
See also:
DiscoveryLink
PlaceLink
Nested Class Summary
Table 1103: Nested Classes in DiscoveryResult
Nested Classes
public static final enumeration DiscoveryResult.ResultType
Represents values describing possible DiscoveryResult types.
Constructor Summary
Table 1104: Constructors in DiscoveryResult
Constructors
DiscoveryResult (PlacesLink impl)
HERE Android SDK Developer's Guide
API Reference
1806
Method Summary
Table 1105: Methods in DiscoveryResult
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
public ResultType getResultType ()
Gets the ResultType for the DiscoveryResult .
public String getTitle ()
Gets the localized title for the resource to which the Link refers.
public String getVicinity ()
Gets the String description for the vicinity of the Place.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a base class for a DiscoveryResult found in a DiscoveryResultPage.
See also:
DiscoveryLink
PlaceLink
Constructor Details
DiscoveryResult (PlacesLink impl)
Parameters:
impl
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1807
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
Note: an icon URL for a linked object is optional, so a call to this method could return empty .
Returns:
The icon URL (could be empty)
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
Note: an ID for a linked object is optional, so a call to this method could return empty .
Returns:
The ID (could be empty)
public ResultType getResultType ()
Gets the ResultType for the DiscoveryResult .
Returns:
The ResultType
public String getTitle ()
Gets the localized title for the resource to which the Link refers. Client devices can display this title within
an application.
Note: a title for a linked object is optional, so a call to this method could return empty .
Returns:
The title (could be empty)
public String getVicinity ()
Gets the String description for the vicinity of the Place. Typically, this description is derived from the
Address, but could also contain any other description that helps a user understand where the Place is
located.
Returns:
The vicinity description (could be empty)
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1808
For documentation, see java.lang.Object
ResultType
The enumeration ResultType is a member of com.here.android.mpa.search.DiscoveryResult.
Enumeration Summary
public static final enumeration DiscoveryResult.ResultType
extends java.lang.Enum, java.lang.Object
Represents values describing possible DiscoveryResult types.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1106: Enum Constants in ResultType
Fields
public static final ResultType UNKNOWN
The result type is unknown.
public static final ResultType PLACE
The DiscoveryResult represents a PlaceLink.
public static final ResultType DISCOVERY
The DiscoveryResult represents a DiscoveryLink.
Method Summary
Table 1107: Methods in ResultType
Methods
public static ResultType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static DiscoveryResult.ResultType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible DiscoveryResult types.
Enum Constant Details
public static final ResultType UNKNOWN
HERE Android SDK Developer's Guide
API Reference
1809
The result type is unknown. The DiscoveryResult does not represent a specialized result.
public static final ResultType PLACE
The DiscoveryResult represents a PlaceLink.
public static final ResultType DISCOVERY
The DiscoveryResult represents a DiscoveryLink.
Method Details
public static ResultType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static DiscoveryResult.ResultType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
DiscoveryResultPage
The class DiscoveryResultPage is a member of com.here.android.mpa.search .
Class Summary
public class DiscoveryResultPage
extends java.lang.Object
Represents a paginated collection of results from a DiscoveryRequest search, explore, or here request.
[For complete information, see the section Class Details]
See also:
ExploreRequest
HereRequest
SearchRequest
HERE Android SDK Developer's Guide
API Reference
1810
Method Summary
Table 1108: Methods in DiscoveryResultPage
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public java.util.List <DiscoveryLink> getDiscoveryLinks ()
Gets the list of DiscoveryLink items for the DiscoveryResultPage .
public java.util.List <DiscoveryResult> getItems ()
Gets the list of DiscoveryResult items for the DiscoveryResultPage .
public DiscoveryRequest getNextPageRequest ()
Gets the DiscoveryRequest for requesting the next page of the DiscoveryResultPage .
public int getOffsetCount ()
Gets the result offset count for the current page of the DiscoveryResultPage .
public java.util.List <PlaceLink> getPlaceLinks ()
Gets the list of PlaceLink items for the DiscoveryResultPage .
public DiscoveryRequest getPreviousPageRequest ()
Gets the DiscoveryRequest for requesting the previous page of the DiscoveryResultPage .
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a paginated collection of results from a DiscoveryRequest search, explore, or here request.
The collection contains DiscoveryResult objects, each of which represents either a PlaceLink or another
DiscoveryLink.
See also:
ExploreRequest
HereRequest
SearchRequest
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1811
public java.util.List <DiscoveryLink> getDiscoveryLinks ()
Gets the list of DiscoveryLink items for the DiscoveryResultPage .
Returns:
The list of DiscoveryLink objects (could be empty)
public java.util.List <DiscoveryResult> getItems ()
Gets the list of DiscoveryResult items for the DiscoveryResultPage .
Returns:
The list of DiscoveryResult objects (could be empty)
public DiscoveryRequest getNextPageRequest ()
Gets the DiscoveryRequest for requesting the next page of the DiscoveryResultPage .
Returns:
The DiscoveryRequest
public int getOffsetCount ()
Gets the result offset count for the current page of the DiscoveryResultPage .
For the first page of results, the offset count is 0. Following any call to getNextPageRequest(), the offset count
will be greater than 0.
Returns:
The result offset count
public java.util.List <PlaceLink> getPlaceLinks ()
Gets the list of PlaceLink items for the DiscoveryResultPage .
Returns:
The list of PlaceLink objects (could be empty)
public DiscoveryRequest getPreviousPageRequest ()
Gets the DiscoveryRequest for requesting the previous page of the DiscoveryResultPage .
Returns:
The DiscoveryRequest
HERE Android SDK Developer's Guide
API Reference
1812
public int hashCode ()
For documentation, see java.lang.Object
EditorialMedia
The class EditorialMedia is a member of com.here.android.mpa.search .
Class Summary
public class EditorialMedia
extends com.here.android.mpa.search.Media, java.lang.Object
Represents editorial content about a Place.
[For complete information, see the section Class Details]
See also:
getEditorials()
Method Summary
Table 1109: Methods in EditorialMedia
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getDescription ()
Gets the String representation of the description for the editorial.
public String getIsoLanguageCode ()
Gets the ISO language code for the editorial content.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents editorial content about a Place.
See also:
getEditorials()
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1813
Parameters:
obj
public String getDescription ()
Gets the String representation of the description for the editorial.
Returns:
The description
public String getIsoLanguageCode ()
Gets the ISO language code for the editorial content.
Note: a language code for an editorial content type is optional, so a call to this method could return empty .
Returns:
The language code (could be empty)
public int hashCode ()
For documentation, see java.lang.Object
ErrorCode
The enumeration ErrorCode is a member of com.here.android.mpa.search .
Enumeration Summary
public final enumeration ErrorCode
extends java.lang.Enum, java.lang.Object
Represents values describing possible search request errors.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1110: Enum Constants in ErrorCode
Fields
public static final ErrorCode NONE
No error was encountered.
public static final ErrorCode GENERAL
There was a general error.
HERE Android SDK Developer's Guide
API Reference
1814
Fields
public static final ErrorCode NOT_FOUND
No appropriate response to the query request could be found.
public static final ErrorCode NOT_INITIALIZED
The search service was not properly initialized.
public static final ErrorCode INCOMPLETE
The results of the query request were incomplete.
public static final ErrorCode NETWORK_REQUIRED
The query request could not be completed while offline.
public static final ErrorCode OUT_OF_MEMORY
There was insufficient memory to complete the query request.
public static final ErrorCode UNKNOWN
There was an unknown error.
public static final ErrorCode INVALID_PARAMETERS
The request contains invalid parameters.
public static final ErrorCode CANCEL
The query request was cancelled.
public static final ErrorCode BUSY
The search service was busy with another request.
public static final ErrorCode INVALID_STATE
The search service was in an invalid state.
public static final ErrorCode SERVER_CONNECTION
There was a problem with the server connection.
public static final ErrorCode INVALID_OPERATION
The query request triggered an invalid operation.
public static final ErrorCode BAD_LOCATION
The query request contained bad location data.
public static final ErrorCode INDEX_FAILURE
There was an search service index failure.
public static final ErrorCode CANCELLED
The query request was cancelled.
public static final ErrorCode CREATED
The response to the query request was created.
public static final ErrorCode ACCEPTED
The query request was accepted, though not yet processed.
HERE Android SDK Developer's Guide
API Reference
1815
Fields
public static final ErrorCode NO_CONTENT
The response to the query request contained no content.
public static final ErrorCode SERVER_INTERNAL
There was an internal server error.
public static final ErrorCode SERVICE_UNAVAILABLE
The search service was unavailable.
public static final ErrorCode MOVED_PERMANENTLY
The requested resource has moved permanently.
public static final ErrorCode BAD_REQUEST
The query request was malformed and will not be processed.
public static final ErrorCode UNAUTHORIZED
The query request did not contain necessary authentication information.
public static final ErrorCode FORBIDDEN
Access to the requested resource was forbidden.
public static final ErrorCode OPERATION_NOT_ALLOWED
Access to this operation is denied.
public static final ErrorCode NOT_ACCEPTABLE
The response to the query request was not in a format that is acceptable to the client.
public static final ErrorCode RESOURCE_GONE
The resource no longer exists at the requested server location.
public static final ErrorCode QUERY_ADDRESS_MISSING
The query request was missing an address parameter.
public static final ErrorCode QUERY_LOCATION_CONTEXT_INVALID
The query location context was invalid.
public static final ErrorCode QUERY_LOCATION_CONTEXT_MISSING
The query request was missing a location context parameter.
public static final ErrorCode QUERY_NO_NEXT_PAGE
No further paginated results exist.
public static final ErrorCode QUERY_TEXT_MISSING
The query request was missing a search text parameter.
public static final ErrorCode QUERY_URI_MISSING
The query request was missing a link URI.
public static final ErrorCode SEARCH_RESULT_ITEM_MISSING
The place details query was missing a search result item parameter.
HERE Android SDK Developer's Guide
API Reference
1816
Fields
public static final ErrorCode INVALID_PARAMETER
A query request parameter was invalid.
public static final ErrorCode NETWORK_COMMUNICATION
There was a network communications error.
public static final ErrorCode NETWORK_BAD_URI
The HTTP request URI was invalid or malformed.
public static final ErrorCode NETWORK_SERVER
The backend server was unreachable.
public static final ErrorCode NETWORK_REQUEST_CONTENT
The query request content was invalid.
public static final ErrorCode NETWORK_EMPTY_INPUT
The query request input was missing.
public static final ErrorCode INVALID_CREDENTIALS
The HERE application ID and application code were missing or invalid.
public static final ErrorCode HTTP
The query request failed due to an HTTP error.
public static final ErrorCode NETWORK_UNKNOWN
There was an unknown network error.
Method Summary
Table 1111: Methods in ErrorCode
Methods
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible search request errors.
Enum Constant Details
public static final ErrorCode NONE
No error was encountered.
HERE Android SDK Developer's Guide
API Reference
1817
public static final ErrorCode GENERAL
There was a general error.
public static final ErrorCode NOT_FOUND
No appropriate response to the query request could be found.
public static final ErrorCode NOT_INITIALIZED
The search service was not properly initialized.
public static final ErrorCode INCOMPLETE
The results of the query request were incomplete.
public static final ErrorCode NETWORK_REQUIRED
The query request could not be completed while offline.
public static final ErrorCode OUT_OF_MEMORY
There was insufficient memory to complete the query request.
public static final ErrorCode UNKNOWN
There was an unknown error.
public static final ErrorCode INVALID_PARAMETERS
The request contains invalid parameters.
public static final ErrorCode CANCEL
The query request was cancelled.
public static final ErrorCode BUSY
The search service was busy with another request.
public static final ErrorCode INVALID_STATE
The search service was in an invalid state.
HERE Android SDK Developer's Guide
API Reference
1818
public static final ErrorCode SERVER_CONNECTION
There was a problem with the server connection.
public static final ErrorCode INVALID_OPERATION
The query request triggered an invalid operation.
public static final ErrorCode BAD_LOCATION
The query request contained bad location data.
public static final ErrorCode INDEX_FAILURE
There was an search service index failure.
public static final ErrorCode CANCELLED
The query request was cancelled.
public static final ErrorCode CREATED
The response to the query request was created.
public static final ErrorCode ACCEPTED
The query request was accepted, though not yet processed.
public static final ErrorCode NO_CONTENT
The response to the query request contained no content.
public static final ErrorCode SERVER_INTERNAL
There was an internal server error.
public static final ErrorCode SERVICE_UNAVAILABLE
The search service was unavailable.
public static final ErrorCode MOVED_PERMANENTLY
HERE Android SDK Developer's Guide
API Reference
1819
The requested resource has moved permanently.
public static final ErrorCode BAD_REQUEST
The query request was malformed and will not be processed.
public static final ErrorCode UNAUTHORIZED
The query request did not contain necessary authentication information.
public static final ErrorCode FORBIDDEN
Access to the requested resource was forbidden.
public static final ErrorCode OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final ErrorCode NOT_ACCEPTABLE
The response to the query request was not in a format that is acceptable to the client.
public static final ErrorCode RESOURCE_GONE
The resource no longer exists at the requested server location.
public static final ErrorCode QUERY_ADDRESS_MISSING
The query request was missing an address parameter.
public static final ErrorCode QUERY_LOCATION_CONTEXT_INVALID
The query location context was invalid.
public static final ErrorCode QUERY_LOCATION_CONTEXT_MISSING
The query request was missing a location context parameter.
public static final ErrorCode QUERY_NO_NEXT_PAGE
No further paginated results exist.
HERE Android SDK Developer's Guide
API Reference
1820
public static final ErrorCode QUERY_TEXT_MISSING
The query request was missing a search text parameter.
public static final ErrorCode QUERY_URI_MISSING
The query request was missing a link URI.
public static final ErrorCode SEARCH_RESULT_ITEM_MISSING
The place details query was missing a search result item parameter.
public static final ErrorCode INVALID_PARAMETER
A query request parameter was invalid.
public static final ErrorCode NETWORK_COMMUNICATION
There was a network communications error.
public static final ErrorCode NETWORK_BAD_URI
The HTTP request URI was invalid or malformed.
public static final ErrorCode NETWORK_SERVER
The backend server was unreachable.
public static final ErrorCode NETWORK_REQUEST_CONTENT
The query request content was invalid.
public static final ErrorCode NETWORK_EMPTY_INPUT
The query request input was missing.
public static final ErrorCode INVALID_CREDENTIALS
The HERE application ID and application code were missing or invalid.
public static final ErrorCode HTTP
The query request failed due to an HTTP error.
HERE Android SDK Developer's Guide
API Reference
1821
public static final ErrorCode NETWORK_UNKNOWN
There was an unknown network error.
Method Details
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ExploreRequest
The class ExploreRequest is a member of com.here.android.mpa.search .
Class Summary
public class ExploreRequest
extends com.here.android.mpa.search.DiscoveryRequest, com.here.android.mpa.search.Request,
java.lang.Object
Creates a ExploreRequest using a specified location context and category filter.
[For complete information, see the section Class Details]
Constructor Summary
Table 1112: Constructors in ExploreRequest
Constructors
ExploreRequest ()
Default constructor.
HERE Android SDK Developer's Guide
API Reference
1822
Method Summary
Table 1113: Methods in ExploreRequest
Methods
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
public ExploreRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
public ExploreRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius.
public ExploreRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the search area using a GeoBoundingBox .
public ExploreRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Class Details
Creates a ExploreRequest using a specified location context and category filter. An explore request is used
for retrieving a list of nearby relevant places for a given position. It answers the question "What interesting
places are near a location?" The results returned are confined to those located in the current search area
and are ordered by popularity. If a category filter is provided, the created request will limit results to include
only items with the specified categories.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate), a search area using setSearchArea(GeoCoordinate, int) or
setSearchArea(GeoBoundingBox) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Constructor Details
ExploreRequest ()
Default constructor.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate), a search area using setSearchArea(GeoCoordinate, int) or
setSearchArea(GeoBoundingBox) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Method Details
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
HERE Android SDK Developer's Guide
API Reference
1823
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public ExploreRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
Parameters:
filter
A CategoryFilter representing the category filter. When a CategoryFilter is specified, the result
items will be limited to the categories defined in the filter.
Returns:
The ExploreRequest.
public ExploreRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius.
Parameters:
center
The GeoCoordinate representing the search area center location.
radius
The search area circle radius in meters.
Returns:
The ExploreRequest.
public ExploreRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the search area using a GeoBoundingBox .
Parameters:
boundingArea
The GeoBoundingBox representing the search area.
Returns:
The ExploreRequest.
public ExploreRequest setSearchCenter (GeoCoordinate center)
HERE Android SDK Developer's Guide
API Reference
1824
Sets the search center.
Parameters:
center
The GeoCoordinate representing the location context used to search for nearby places.
Returns:
The ExploreRequest.
ExtendedAttribute
The class ExtendedAttribute is a member of com.here.android.mpa.search .
Class Summary
public class ExtendedAttribute
extends java.lang.Object
Represents additional detailed information about a Place.
[For complete information, see the section Class Details]
Field Summary
Table 1114: Fields in ExtendedAttribute
Fields
public static final String TRANSIT_DEPARTURES_EXTENDED_ATTRIBUTE_ID
Constant that defines the public transit departures extended identifier.
public static final String TRANSIT_LINES_EXTENDED_ATTRIBUTE_ID
Constant that defines the public transit lines extended identifier.
Method Summary
Table 1115: Methods in ExtendedAttribute
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getAttribution ()
Gets a ready-to-display (HTML formatted) string containing the source attribution text for this place.
public String getId ()
Gets the identifier for the ExtendedAttribute .
HERE Android SDK Developer's Guide
API Reference
1825
Methods
public String getLabel ()
Gets the localized display label for the ExtendedAttribute .
public String getText ()
Gets the String representation of ExtendedAttribute information, which can be displayed directly on the client device.
public Link getVia ()
Gets a Link object to the external website of the supplier of the information.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents additional detailed information about a Place.
This extensible collection of attributes that can include the following items with these identifier values:
payment - A list of available payment methods (such as cash, credit card, direct debit, etc.)
openingHours - A list of hours during which the place is open for business
annualClosings - A description of annual closing dates such as holidays or other special occasions
price - A price list
nearestLandmark - A description of the nearest landmark
languagesSpoken - A list of the languages that are spoken at the place
availableParking - A list of parking options available nearby
smoking - Whether smoking is allowed
disabledAccess - Whether disabled access is available
transitLines - A list of available public transport transit lines
departures - A list of next departures for available public transport transit lines
blindGuide - Whether a public transport stop has blind guides ('tactile paving').
elevator - Whether a public transport stop has elevator
escalator - Whether a public transport stop has escalator
Field Details
public static final String TRANSIT_DEPARTURES_EXTENDED_ATTRIBUTE_ID
Constant that defines the public transit departures extended identifier.
public static final String TRANSIT_LINES_EXTENDED_ATTRIBUTE_ID
Constant that defines the public transit lines extended identifier.
HERE Android SDK Developer's Guide
API Reference
1826
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getAttribution ()
Gets a ready-to-display (HTML formatted) string containing the source attribution text for this place.
The Places API gives access to content that is provided by a number of sources. Client applications must
display the source attribution next to the content. This requirement forms part of the terms and conditions
of the API.
The code snippet below demonstrates how to display the string in an Android TextView
TextView textView = (TextView) findViewById(R.id.attributionText);
textView.setText((Html.fromHtml(route.getTransitRouteSourceAttribution().getAttribution())));
textView.setMovementMethod(LinkMovementMethod.getInstance());
Returns:
The HTML formatted attribution string
public String getId ()
Gets the identifier for the ExtendedAttribute .
Returns:
The attribute identifier
public String getLabel ()
Gets the localized display label for the ExtendedAttribute .
Returns:
The display label
public String getText ()
Gets the String representation of ExtendedAttribute information, which can be displayed directly on
the client device.
Note: if the text represents a list of items, the items are separated by a line break entity ( <br/> if the text
format is HTML-encoded or newline if the text format is plain).
HERE Android SDK Developer's Guide
API Reference
1827
Returns:
The RichText display text
public Link getVia ()
Gets a Link object to the external website of the supplier of the information. This link must be used for
attribution when rich text attribution is not being used.
Returns:
The Link object to the external website of the supplier of the information
public int hashCode ()
For documentation, see java.lang.Object
GeocodeRequest
The class GeocodeRequest is a member of com.here.android.mpa.search .
Class Summary
public class GeocodeRequest
extends com.here.android.mpa.search.Request, java.lang.Object
The GeocodeRequest represents an extended Request used to retrieve Location data by way of Geocoder
search services.
Deprecated: As of release 3.6.
[For complete information, see the section Class Details]
Constructor Summary
Table 1116: Constructors in GeocodeRequest
Constructors
GeocodeRequest (String query)
Creates a geocoder request that resolves a free text query into a Location.
HERE Android SDK Developer's Guide
API Reference
1828
Method Summary
Table 1117: Methods in GeocodeRequest
Methods
public ErrorCode execute (ResultListener<Location> listener)
Executes an asynchronous request.
public int getCollectionSize ()
Gets the current collection size being used for request responses.
public GeocodeRequest setCollectionSize (int value)
Sets a collection size to be used for request responses.
public GeocodeRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public GeocodeRequest setSearchArea (GeoCoordinate center, int radius)
Sets the suggested search area using a center location and radius.
public GeocodeRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the suggested search area using a GeoBoundingBox .
Class Details
Deprecated: As of release 3.6.
Use GeocodeRequest2 instead.
The GeocodeRequest represents an extended Request used to retrieve Location data by way of Geocoder
search services.
Note: the response to a GeocodeRequest is a list of Location objects.
Constructor Details
GeocodeRequest (String query)
Creates a geocoder request that resolves a free text query into a Location.
Please note that if this free text query contains search area information, such as a state, then the search area
set through setSearchArea(GeoBoundingBox) or setSearchArea(GeoCoordinate, int) is ignored. For example,
a search for "Main St, Ohio" with a search area of New York City will return results outside of New York City.
However, a search for "Park Ave" with New York City as the search area will return results in that area.
Parameters:
query
Query text specifying the address to locate
Throws:
IllegalArgumentException
Upon a failure to handle a passed argument
HERE Android SDK Developer's Guide
API Reference
1829
Method Details
public ErrorCode execute (ResultListener<Location> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size
public GeocodeRequest setCollectionSize (int value)
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size per request.
Returns:
This Request object
Throws:
IllegalArgumentException
if size is out of range.
public GeocodeRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Please note that the Map Viewport is only used for online geocode requests.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1830
mapViewport
The bounding box of the map area currently visible.
public GeocodeRequest setSearchArea (GeoCoordinate center, int radius)
Sets the suggested search area using a center location and radius.
Please note that the Search Area is only used for online geocode requests.
Parameters:
center
The GeoCoordinate representing the search area center location.
radius
The search area circle radius in meters (greater-equal than 0).
Returns:
The GeocodeRequest.
public GeocodeRequest setSearchArea (GeoBoundingBox boundingArea)
Sets the suggested search area using a GeoBoundingBox .
Please note that the Search Area is only used for online geocode requests.
Parameters:
boundingArea
The GeoBoundingBox representing the search area.
Returns:
The GeocodeRequest.
GeocodeRequest2
The class GeocodeRequest2 is a member of com.here.android.mpa.search .
Class Summary
public class GeocodeRequest2
extends com.here.android.mpa.search.Request, java.lang.Object
The GeocodeRequest2 represents an extended Request used to retrieve GeocodeResult data by way of
Geocoder search services.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1831
Constructor Summary
Table 1118: Constructors in GeocodeRequest2
Constructors
GeocodeRequest2 (String query)
Creates a geocoder request that resolves a free text query into a GeocodeResult.
Method Summary
Table 1119: Methods in GeocodeRequest2
Methods
public ErrorCode execute (ResultListener<GeocodeResult> listener)
Executes an asynchronous request.
public int getCollectionSize ()
Gets the current collection size being used for request responses.
public GeocodeRequest2 setCollectionSize (int value)
Sets a collection size to be used for request responses.
public GeocodeRequest2 setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public GeocodeRequest2 setSearchArea (GeoCoordinate center, int radius)
Sets the suggested search area using a center location and radius.
public GeocodeRequest2 setSearchArea (GeoBoundingBox boundingArea)
Sets the suggested search area using a GeoBoundingBox .
Class Details
The GeocodeRequest2 represents an extended Request used to retrieve GeocodeResult data by way of
Geocoder search services.
Note: the response to a GeocodeRequest2 is a list of GeocodeResult objects.
Constructor Details
GeocodeRequest2 (String query)
Creates a geocoder request that resolves a free text query into a GeocodeResult.
Please note that if this free text query contains search area information, such as a state, then the search area
set through setSearchArea(GeoBoundingBox) or setSearchArea(GeoCoordinate, int) is ignored. For example,
a search for "Main St, Ohio" with a search area of New York City will return results outside of New York City.
However, a search for "Park Ave" with New York City as the search area will return results in that area.
Parameters:
query
HERE Android SDK Developer's Guide
API Reference
1832
Query text specifying the address to locate.
Throws:
IllegalArgumentException
Upon a failure to handle a passed argument.
Method Details
public ErrorCode execute (ResultListener<GeocodeResult> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress.
Returns:
The ErrorCode representing an appropriate result.
public int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size.
public GeocodeRequest2 setCollectionSize (int value)
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size per request.
Returns:
This Request object.
Throws:
IllegalArgumentException
if size is out of range.
public GeocodeRequest2 setMapViewport (GeoBoundingBox mapViewport)
HERE Android SDK Developer's Guide
API Reference
1833
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Please note that the Map Viewport is only used for online geocode requests.
Parameters:
mapViewport
The bounding box of the map area currently visible.
public GeocodeRequest2 setSearchArea (GeoCoordinate center, int radius)
Sets the suggested search area using a center location and radius.
Please note that the Search Area is only used for online geocode requests.
Parameters:
center
The GeoCoordinate representing the search area center location.
radius
The search area circle radius in meters (greater-equal than 0).
Returns:
The GeocodeRequest2.
public GeocodeRequest2 setSearchArea (GeoBoundingBox boundingArea)
Sets the suggested search area using a GeoBoundingBox .
Please note that the Search Area is only used for online geocode requests.
Parameters:
boundingArea
The GeoBoundingBox representing the search area.
Returns:
The GeocodeRequest2.
GeocodeResult
The class GeocodeResult is a member of com.here.android.mpa.search .
Class Summary
public class GeocodeResult
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1834
Represents the result of a geocode request.
[For complete information, see the section Class Details]
Method Summary
Table 1120: Methods in GeocodeResult
Methods
public boolean equals (Object obj)
public Location getLocation ()
The location data of the geocode result.
public String getMatchLevel ()
Shows the level of the most precise area information for the match, district, city or a higher administrative level.
public Map getMatchQuality ()
Details about the quality of the result.
public float getRelevance ()
The relevance of the result location to the original search parameters.
public int hashCode ()
Class Details
Represents the result of a geocode request. The data of a geocode result is represented by an instance of
Location, accessed through the location property. The quality of the result can be assessed in a broad sense
with the relevance property, or in more detail using the matchQuality dictionary.
Method Details
public boolean equals (Object obj)
Parameters:
obj
public Location getLocation ()
The location data of the geocode result.
Returns:
The Location of this geocode result.
public String getMatchLevel ()
HERE Android SDK Developer's Guide
API Reference
1835
Shows the level of the most precise area information for the match, district, city or a higher administrative
level. The possible values are: "country", "state", "county", "city", "district", "street", "intersection",
"houseNumber", "postalCode" and "landmark".
Returns:
The level of the most precise area information for the match, district, city or a higher administrative level.
public Map getMatchQuality ()
Details about the quality of the result. Additional information about the accuracy of the result is available
in the matchQuality dictionary. It contains one or more float values representing how well each individual
search parameter was matched. The values will be in the range [0, 1] with a value of 1 indicating a perfect
match. The possible keys are "State", "County", "City", "District", "Street", "SecondaryStreet", "HouseNumber",
and "PostalCode". The "SecondaryStreet" key will be present if an intersection was specified in the geocode
request. For example, if the request contained "1st St at 2nd Ave", the "Street" key would access the match
value for "1st St" and the "SecondaryStreet" key would access the match value for "2nd Ave".
Returns:
Details about the quality of the result.
public float getRelevance ()
The relevance of the result location to the original search parameters. The relevance of a result provides
a measure of how accurate or reliable it is. The valid range is [0, 1], with a value of 1 representing a perfect
match.
Returns:
The relevance of the result location to the original search parameters.
public int hashCode ()
HereRequest
The class HereRequest is a member of com.here.android.mpa.search .
Class Summary
public class HereRequest
extends com.here.android.mpa.search.DiscoveryRequest, com.here.android.mpa.search.Request,
java.lang.Object
The HereRequest answers the questions "Where am I?" and "What's right here where I am standing?" The
search results consist of a list of places with addresses that lie within the vicinity of the search location.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1836
Nested Class Summary
Table 1121: Nested Classes in HereRequest
Nested Classes
public static class HereRequest.UnsupportedFilterException
Thrown when a building filter is unsupported because the building identifier is missing or malformed.
Constructor Summary
Table 1122: Constructors in HereRequest
Constructors
HereRequest ()
Default constructor.
Method Summary
Table 1123: Methods in HereRequest
Methods
public HereRequest addBuildingFilter (Identifier buildingId)
Add a search filter based on building identifier.
public HereRequest addBuildingFilter (String buildingId)
Sets a search filter based on building identifier.
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
public HereRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
public HereRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Class Details
The HereRequest answers the questions "Where am I?" and "What's right here where I am standing?" The
search results consist of a list of places with addresses that lie within the vicinity of the search location. The
feature is typically used by applications that include "check-in" or "click on map to get more information"
options.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
HERE Android SDK Developer's Guide
API Reference
1837
Constructor Details
HereRequest ()
Default constructor.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Method Details
public HereRequest addBuildingFilter (Identifier buildingId)
Add a search filter based on building identifier. More than one building Identifier filter can be applied per
request.
Parameters:
buildingId
A building Identifier. When a filter is specified, the result items will be limited to the buildings with
identifiers defined in the filter. The Identifiers from ARBuildingInfo and MapBuildingObject are
supported.
Returns:
The HereRequest.
Throws:
HereRequest.UnsupportedFilterException
Filter not applied because Identifier does not contain a building ID.
See also:
getIdentifier()
getIdentifier()
public HereRequest addBuildingFilter (String buildingId)
Sets a search filter based on building identifier. More than one building identifier filter can be applied per
request.
The building identifier can also be retrieved using addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
Parameters:
buildingId
A building identifier. When a filter is specified, the result items will be limited to the buildings with
identifiers defined in the filter.
Returns:
HERE Android SDK Developer's Guide
API Reference
1838
The HereRequest.
See also:
BUILDING_ID_REFERENCE_NAME
addReference(String)
getReference(String)
addReference(String)
getReference(String)
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public HereRequest setCategoryFilter (CategoryFilter filter)
Sets a search filter based on categories.
Parameters:
filter
A CategoryFilter representing the category filter. When a CategoryFilter is specified, the result
items will be limited to the categories defined in the filter.
Returns:
The HereRequest.
public HereRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Parameters:
center
The GeoCoordinate representing the location context used to search for nearby places.
Returns:
The HereRequest.
HERE Android SDK Developer's Guide
API Reference
1839
UnsupportedFilterException
The class UnsupportedFilterException is a member of com.here.android.mpa.search.HereRequest.
Class Summary
public static class HereRequest.UnsupportedFilterException
extends java.lang.Exception, java.lang.Throwable, java.lang.Object
Thrown when a building filter is unsupported because the building identifier is missing or malformed.
[For complete information, see the section Class Details]
Constructor Summary
Table 1124: Constructors in UnsupportedFilterException
Constructors
UnsupportedFilterException (String detailMessage)
Class Details
Thrown when a building filter is unsupported because the building identifier is missing or malformed.
Constructor Details
UnsupportedFilterException (String detailMessage)
Parameters:
detailMessage
ImageMedia
The class ImageMedia is a member of com.here.android.mpa.search .
Class Summary
public final class ImageMedia
extends com.here.android.mpa.search.Media, java.lang.Object
Represents image content related to a Place.
[For complete information, see the section Class Details]
See also:
getImages()
HERE Android SDK Developer's Guide
API Reference
1840
Method Summary
Table 1125: Methods in ImageMedia
Methods
public boolean equals (Object obj)
public String getDimensionHref (int width, int height)
Get the HREF to retrieve an image with specific width-height dimensions.
public String getId ()
Gets the unique identifier for the Image .
public String getUrl ()
Gets the String representation of the URL for the source of the image file.
public UserLink getUser ()
Gets the details of the User who contributed the Image .
public int hashCode ()
Class Details
Represents image content related to a Place.
See also:
getImages()
Method Details
public boolean equals (Object obj)
Parameters:
obj
public String getDimensionHref (int width, int height)
Get the HREF to retrieve an image with specific width-height dimensions. A HTTP request using this HREF will
return the image data.
Parameters:
width
The image width.
height
The image height.
Returns:
The HREF to retrieve the image with the specified width-height dimensions. Can be null if an image with the
specified dimensions is unavailable.
HERE Android SDK Developer's Guide
API Reference
1841
See also:
addImageDimensions(int, int)
public String getId ()
Gets the unique identifier for the Image .
Note: an ID for an Image is optional, so a call to this method could return null .
Returns:
The ID (could be null)
public String getUrl ()
Gets the String representation of the URL for the source of the image file.
Returns:
The URL
public UserLink getUser ()
Gets the details of the User who contributed the Image .
Note: user contribution for an Image is optional, so a call to this method could return null .
Returns:
The User who contributed the Image (could be null)
public int hashCode ()
Link
The class Link is a member of com.here.android.mpa.search .
Class Summary
public class Link
extends java.lang.Object
Represents a Link indicating that the application must make another request to retrieve the desired
resource.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1842
Method Summary
Table 1126: Methods in Link
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
public String getTitle ()
Gets the localized title for the resource to which the Link refers.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a Link indicating that the application must make another request to retrieve the desired
resource.
Note: a Link contains metadata about the linked resource.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
Note: an icon URL for a linked object is optional, so a call to this method could return empty .
Returns:
The icon URL (could be empty)
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
Note: an ID for a linked object is optional, so a call to this method could return empty .
HERE Android SDK Developer's Guide
API Reference
1843
Returns:
The ID (could be empty)
public String getTitle ()
Gets the localized title for the resource to which the Link refers. Client devices can display this title within
an application.
Note: a title for a linked object is optional, so a call to this method could return empty .
Returns:
The title (could be empty)
public int hashCode ()
For documentation, see java.lang.Object
Location
The class Location is a member of com.here.android.mpa.search .
Class Summary
public class Location
extends java.lang.Object
Represents the physical location of a Place.
[For complete information, see the section Class Details]
Constructor Summary
Table 1127: Constructors in Location
Constructors
Location (GeoCoordinate coordinate)
Construct a Location with a initial GeoCoordinate .
Method Summary
Table 1128: Methods in Location
Methods
public boolean equals (Object obj)
HERE Android SDK Developer's Guide
API Reference
1844
Methods
public java.util.List <NavigationPosition> getAccessPoints ()
Get an array of NavigationPosition objects representing access points to the location.
public Address getAddress ()
Gets the Address for the Location .
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox representing the map view bounding box for the Location.
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate indicating where the map marker for the Location is rendered.
public String getId ()
Deprecated: As of SDK 3.3, this method is deprecated and always returns null.
Gets the java.lang.String representation of the unique ID for the Location.
public String getReference (String name)
Get the reference identifier for a specific domain.
public TimeZone getTimeZone ()
Get the time zone for the Location .
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
Class Details
Represents the physical location of a Place.
Constructor Details
Location (GeoCoordinate coordinate)
Construct a Location with a initial GeoCoordinate .
Parameters:
coordinate
Initial location coordinate.
Method Details
public boolean equals (Object obj)
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1845
public java.util.List <NavigationPosition> getAccessPoints ()
Get an array of NavigationPosition objects representing access points to the location. The NavigationPosition
object should be used as navigablePosition of a RouteWaypoint when calculating route to the location. For
example, An airport might have road access point for car routing and public transport access points for
public transport routing.
Returns:
The array of NavigationPosition.
public Address getAddress ()
Gets the Address for the Location .
Returns:
The Address, or null if unavailable
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox representing the map view bounding box for the Location.
Returns:
The GeoBoundingBox, or null if unavailable
public GeoCoordinate getCoordinate ()
Gets the GeoCoordinate indicating where the map marker for the Location is rendered. If you want to
create a route to this location please use this property for RouteWaypoint creation. This is referred to as
originalPosition in RouteWaypoint.
Returns:
The GeoCoordinate, or null if unavailable
public String getId ()
Deprecated: As of SDK 3.3, this method is deprecated and always returns null.
Gets the java.lang.String representation of the unique ID for the Location.
Returns:
The Location ID. As of 3.3, returns null.
public String getReference (String name)
HERE Android SDK Developer's Guide
API Reference
1846
Get the reference identifier for a specific domain. For example, a place can have a reference to an extruded
building object in the map. The reference identifier can be retrieved by calling this method with name
BUILDING_ID_REFERENCE_NAME .
NOTE: A reference will not be returned if it has not been added to the request using
PlaceRequest#addReference(String) .
Parameters:
name
The reference name.
Returns:
The reference identifier. If the reference identifier does not exist, an empty String is returned.
public TimeZone getTimeZone ()
Get the time zone for the Location .
Returns:
TimeZone or null if unavailable
public int hashCode ()
For documentation, see java.lang.Object
public String toString ()
Media
The class Media is a member of com.here.android.mpa.search .
Class Summary
public abstract class Media
extends java.lang.Object
Represents the base class for additional rich content about a Place.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1847
Nested Class Summary
Table 1129: Nested Classes in Media
Nested Classes
public static final enumeration Media.Type
Represents values describing supported Media types for a Place.
Method Summary
Table 1130: Methods in Media
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getAttributionText ()
Gets the String representation of the attribution text for the Media , according to the terms and conditions of the
originating source.
public SupplierLink getSupplier ()
Gets the Link to a resource representing the supplier of the Media (the object provides details about the origin of the
information).
public Type getType ()
Gets the specialized Type for the Media .
protected String getUrl ()
public ViaLink getVia ()
Gets the Link to the origin of the Media , typically a website of the supplier.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents the base class for additional rich content about a Place.
The following specialized content types might be available:
Editorial content
Image content
Review content
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
HERE Android SDK Developer's Guide
API Reference
1848
obj
public String getAttributionText ()
Gets the String representation of the attribution text for the Media , according to the terms and conditions
of the originating source.
Returns:
The attribution text
public SupplierLink getSupplier ()
Gets the Link to a resource representing the supplier of the Media (the object provides details about the
origin of the information).
Returns:
The supplier Link
public Type getType ()
Gets the specialized Type for the Media .
Returns:
The Type
protected String getUrl ()
public ViaLink getVia ()
Gets the Link to the origin of the Media , typically a website of the supplier.
Returns:
The via Link
public int hashCode ()
For documentation, see java.lang.Object
Type
The enumeration Type is a member of com.here.android.mpa.search.Media.
HERE Android SDK Developer's Guide
API Reference
1849
Enumeration Summary
public static final enumeration Media.Type
extends java.lang.Enum, java.lang.Object
Represents values describing supported Media types for a Place.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1131: Enum Constants in Type
Fields
public static final Type UNKNOWN
Unknown content.
public static final Type EDITORIAL
Editorial content.
public static final Type IMAGE
Image content.
public static final Type RATING
Rating content.
public static final Type REVIEW
Review content.
Method Summary
Table 1132: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Media.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing supported Media types for a Place.
Enum Constant Details
public static final Type UNKNOWN
Unknown content.
HERE Android SDK Developer's Guide
API Reference
1850
public static final Type EDITORIAL
Editorial content.
public static final Type IMAGE
Image content.
public static final Type RATING
Rating content.
public static final Type REVIEW
Review content.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Media.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MediaCollectionPage<T>
The class MediaCollectionPage<T> is a member of com.here.android.mpa.search .
Type Parameters:
T
Class Summary
public final class MediaCollectionPage
extends java.lang.Object
Represents a base class for a paginateable collection of Media objects of a specific type.
HERE Android SDK Developer's Guide
API Reference
1851
[For complete information, see the section Class Details]
Method Summary
Table 1133: Methods in MediaCollectionPage<T>
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public int getAvailable ()
Gets the total number of available Media items within the MediaCollectionPage .
public java.util.List <Media> getItems ()
Gets the list of Media items from the current page of the collection.
public MediaCollectionPageRequest<T> getNextPageRequest ()
Gets the MediaCollectionPageRequest for requesting the next page of the MediaCollectionPage .
public int getOffsetCount ()
Gets the collection offset count for the current page of the MediaCollectionPage .
public Type getType ()
Gets the specialized Media.Type for the Media objects contained within the MediaCollectionPage .
public int hashCode ()
For documentation, see java.lang.Object
public boolean removeItem (Media item)
Remove Media items from the current page of the collection.
Class Details
Represents a base class for a paginateable collection of Media objects of a specific type.
Note: each collection contains objects of one Media.Type.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public int getAvailable ()
Gets the total number of available Media items within the MediaCollectionPage .
Returns:
HERE Android SDK Developer's Guide
API Reference
1852
The number of available items
public java.util.List <Media> getItems ()
Gets the list of Media items from the current page of the collection. The type of each object in the list
depends on the MediaCollectionPage .
Note: if a collection is empty, the items attribute is not present and this method will return empty .
Returns:
The list of Media objects (could be empty)
public MediaCollectionPageRequest<T> getNextPageRequest ()
Gets the MediaCollectionPageRequest for requesting the next page of the MediaCollectionPage .
Returns:
The MediaCollectionPageRequest
public int getOffsetCount ()
Gets the collection offset count for the current page of the MediaCollectionPage .
For the first page of results, the offset count is 0. Following any call to getNextPageRequest(), the offset count
will be greater than 0.
Returns:
The collection offset count
public Type getType ()
Gets the specialized Media.Type for the Media objects contained within the MediaCollectionPage .
Returns:
The Media.Type
public int hashCode ()
For documentation, see java.lang.Object
public boolean removeItem (Media item)
Remove Media items from the current page of the collection.
Parameters:
item
HERE Android SDK Developer's Guide
API Reference
1853
The Media item to be removed from the current collection page.
Returns:
Returns true if the Media object is successfully removed from the page.
MediaCollectionPageRequest<T>
The class MediaCollectionPageRequest<T> is a member of com.here.android.mpa.search .
Type Parameters:
T
Class Summary
public class MediaCollectionPageRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve MediaCollectionPage information for a specific type
of Media associated with a Place, by way of Places search services.
[For complete information, see the section Class Details]
Constructor Summary
Table 1134: Constructors in MediaCollectionPageRequest<T>
Constructors
MediaCollectionPageRequest (<any> impl)
Method Summary
Table 1135: Methods in MediaCollectionPageRequest<T>
Methods
public ErrorCode execute (ResultListener<MediaCollectionPage<T> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
Class Details
Represents an extended Request used to retrieve MediaCollectionPage information for a specific type
of Media associated with a Place, by way of Places search services.
Note: the response to a MediaCollectionPageRequest is a MediaCollectionPage object.
HERE Android SDK Developer's Guide
API Reference
1854
Constructor Details
MediaCollectionPageRequest (<any> impl)
Parameters:
impl
Method Details
public ErrorCode execute (ResultListener<MediaCollectionPage<T> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
Parameters:
eventListener
NavigationPosition
The class NavigationPosition is a member of com.here.android.mpa.search .
Class Summary
public class NavigationPosition
extends java.lang.Object
Represents a position that should be used when calculating routes for navigation.
[For complete information, see the section Class Details]
Method Summary
Table 1136: Methods in NavigationPosition
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getAccessType ()
Returns the type of access as a String .
public GeoCoordinate getCoordinate ()
Returns the GeoCoordinate of the location This coordinate should be used as navigablePosition of a RouteWaypoint when
calculating route.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1855
Class Details
Represents a position that should be used when calculating routes for navigation.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getAccessType ()
Returns the type of access as a String . The access type 'road' is used for car routing. It is important
to match the accessType with the type of routing you are performing. For example, use objects with an
accessType of "road" for car routing.
Returns:
The type of access as a String.
See also:
public GeoCoordinate getCoordinate ()
Returns the GeoCoordinate of the location This coordinate should be used as navigablePosition of a
RouteWaypoint when calculating route.
Returns:
The GeoCoordinate of the location.
public int hashCode ()
For documentation, see java.lang.Object
Place
The class Place is a member of com.here.android.mpa.search .
Class Summary
public class Place
extends java.lang.Object
Represents a set of data about a physical place.
HERE Android SDK Developer's Guide
API Reference
1856
[For complete information, see the section Class Details]
See also:
Location
Field Summary
Table 1137: Fields in Place
Fields
public static final String PUBLIC_TRANSPORT_RELATED_LINK_NAME
Key name to get the public-transport DiscoveryLink (from the related attributes) for this Place .
public static final String RECOMMENDED_RELATED_LINK_NAME
Key name to get the recommended DiscoveryLink (from the related attributes) for this Place .
Method Summary
Table 1138: Methods in Place
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public Map getAlternativeNames ()
Gets the alternative names for the Place .
public List getAlternativeReferenceIds (String name)
Get a list of alternative identifiers of the same reference identifier for a specific domain.
public String getAttributionText ()
Gets the String representation of the attribution text for the Place .
public java.util.List <Category> getCategories ()
Gets the list of Category objects assigned to the Place .
public java.util.List <ContactDetail> getContacts ()
Gets the list of Contact objects for the Place .
public MediaCollectionPage<EditorialMedia> getEditorials ()
Gets the MediaCollectionPage containing EditorialMedia content for the Place .
HERE Android SDK Developer's Guide
API Reference
1857
Methods
public java.util.List <ExtendedAttribute> getExtendedAttributes ()
Gets additional information about a Place , a list of ExtendedAttribute objects that can include information such as:
payment - A list of available payment methods (such as cash, credit card, direct debit, etc.)
openingHours - A list of hours during which the place is open for business
annualClosings - A description of annual closing dates such as holidays or other special occasions
price - A price list
nearestLandmark - A description of the nearest landmark
languagesSpoken - A list of the languages that are spoken at the place
availableParking - A list of parking options available nearby
smoking - Whether smoking is allowed
disabledAccess - Whether disabled access is available
transitLines - A list of available public transport transit lines
departures - A list of next departures for available public transport transit lines
blindGuide - Whether a public transport stop has blind guides ('tactile paving').
elevator - Whether a public transport stop has elevator
escalator - Whether a public transport stop has escalator
public String getIconUrl ()
Gets the URL to retrieve the icon that best represents the Place .
public String getId ()
Gets the unique identifier for the Place .
public MediaCollectionPage<ImageMedia> getImages ()
Gets the MediaCollectionPage containing ImageMedia content for the Place .
public Location getLocation ()
Gets the physical Location of the Place .
public String getName ()
Gets the display name for the Place .
public MediaCollectionPage<RatingMedia> getRatings ()
Gets the MediaCollectionPage containing RatingMedia content for the Place .
public String getReference (String name)
Get the reference identifier for a specific domain.
public java.util.Map <java.lang.String, com.here.android.mpa.search.DiscoveryLink> getRelated
()
Gets the related places (where available) that might also interest an application user viewing information for the Place .
public ReportingLink getReportingLink ()
Gets the link for getting options for reporting an place because, for example, if it contains inappropriate content or the
place does not exists.
public PlaceLink getResidingVenue ()
Gets the venue (if available) where the Place resides.
HERE Android SDK Developer's Guide
API Reference
1858
Methods
public MediaCollectionPage<ReviewMedia> getReviews ()
Gets the MediaCollectionPage containing ReviewMedia content for the Place .
public SupplierLink getSupplier ()
Gets the Link for the Place supplier.
public Ratings getUserRatings ()
Gets the HERE.com user-supplied Ratings for the Place .
public String getViewUri ()
Gets the String representation of the URI for a user-viewable representation of the Place .
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a set of data about a physical place.
A Place acts as a container for various information about a place, which itself is a point of interest such as a
popular restaurant, a park, or someone's home.
Note: a Place can contain attributes, collections of media about the place, and key-value pairs of related
places.
See also:
Location
Field Details
public static final String PUBLIC_TRANSPORT_RELATED_LINK_NAME
Key name to get the public-transport DiscoveryLink (from the related attributes) for this Place .
public static final String RECOMMENDED_RELATED_LINK_NAME
Key name to get the recommended DiscoveryLink (from the related attributes) for this Place .
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1859
public Map getAlternativeNames ()
Gets the alternative names for the Place . The returned Map collection is keyed using a language code (eg.
"en").
Note: an alternative name is optional, so a call to this method could return empty .
Returns:
The alternative names (could be empty) collection keyed using a language code (eg. "en").
public List getAlternativeReferenceIds (String name)
Get a list of alternative identifiers of the same reference identifier for a specific domain. For example, a
venue content identifier reference can have alternative identifiers. The list of alternative identifiers can be
retrieved by calling this method with name "venues.content".
NOTE: A reference will not be returned if it has not been queried with the
PlaceRequest#addReference(String) function.
Parameters:
name
The reference name.
Returns:
The list of alternative identifiers. If alternative identifiers are not defined, an empty list is returned.
public String getAttributionText ()
Gets the String representation of the attribution text for the Place .
Note: attribution text for a Place is optional, so a call to this method could return empty .
Returns:
The attribution text (could be empty)
public java.util.List <Category> getCategories ()
Gets the list of Category objects assigned to the Place .
Note: categories maybe optional (especially when offline), so a call to this method could return empty .
Returns:
The list of Category objects
public java.util.List <ContactDetail> getContacts ()
Gets the list of Contact objects for the Place .
Note: contact information for a Place is optional, so a call to this method could return empty .
HERE Android SDK Developer's Guide
API Reference
1860
Returns:
The list of Contact objects (could be empty)
public MediaCollectionPage<EditorialMedia> getEditorials ()
Gets the MediaCollectionPage containing EditorialMedia content for the Place .
Note: editorial content for a Place is optional, so a call to this method could return null .
Returns:
The MediaCollectionPage (could be null)
public java.util.List <ExtendedAttribute> getExtendedAttributes ()
Gets additional information about a Place , a list of ExtendedAttribute objects that can include
information such as:
payment - A list of available payment methods (such as cash, credit card, direct debit, etc.)
openingHours - A list of hours during which the place is open for business
annualClosings - A description of annual closing dates such as holidays or other special occasions
price - A price list
nearestLandmark - A description of the nearest landmark
languagesSpoken - A list of the languages that are spoken at the place
availableParking - A list of parking options available nearby
smoking - Whether smoking is allowed
disabledAccess - Whether disabled access is available
transitLines - A list of available public transport transit lines
departures - A list of next departures for available public transport transit lines
blindGuide - Whether a public transport stop has blind guides ('tactile paving').
elevator - Whether a public transport stop has elevator
escalator - Whether a public transport stop has escalator
For transitLines TRANSIT_LINES_EXTENDED_ATTRIBUTE_ID and departures
TRANSIT_DEPARTURES_EXTENDED_ATTRIBUTE_ID attributes, the returned object can be cast to
TransitLinesAttribute and TransitDeparturesAttribute respectably. Which will allow further
related attributes to be retrieved.
Transit lines and departures information may not always be available in all transit station/stop locations.
However, this information is available using the PUBLIC_TRANSPORT_RELATED_LINK_NAME DiscoveryLink
from getRelated().
Returns:
The list of ExtendedAttribute objects
See also:
TransitLinesAttribute
TransitDeparturesAttribute
HERE Android SDK Developer's Guide
API Reference
1861
public String getIconUrl ()
Gets the URL to retrieve the icon that best represents the Place .
Returns:
The icon URL.
public String getId ()
Gets the unique identifier for the Place . Applications that want to keep a reference to a place should store
the ID for subsequent linking to additional resources.
Returns:
The ID
public MediaCollectionPage<ImageMedia> getImages ()
Gets the MediaCollectionPage containing ImageMedia content for the Place .
Note: image content for a Place is optional, so a call to this method could return null .
Returns:
The MediaCollectionPage (could be null)
public Location getLocation ()
Gets the physical Location of the Place .
Returns:
The Location
public String getName ()
Gets the display name for the Place .
Returns:
The Place name
public MediaCollectionPage<RatingMedia> getRatings ()
Gets the MediaCollectionPage containing RatingMedia content for the Place .
Note: rating content for a Place is optional, so a call to this method could return null .
Returns:
The MediaCollectionPage (could be null)
HERE Android SDK Developer's Guide
API Reference
1862
public String getReference (String name)
Get the reference identifier for a specific domain. For example, a place can have a reference to an extruded
building object in the map. The reference identifier can be retrieved by calling this method with name
'building'.
NOTE: A reference will not be returned if it has not been queried with the
PlaceRequest#addReference(String) function.
Parameters:
name
The reference name.
Returns:
The reference identifier. If the reference identifier does not exist, an empty String is returned.
public java.util.Map <java.lang.String,
com.here.android.mpa.search.DiscoveryLink> getRelated ()
Gets the related places (where available) that might also interest an application user viewing
information for the Place . The returned Map is keyed by a title for the related places (e.g.
PUBLIC_TRANSPORT_RELATED_LINK_NAME ), while the associated value is a link to a page of related
places.
Note: if there are no related places, the attribute is not present and this method will return an empty Map .
Returns:
The java.util.Map of key-value elements representing the collection of links to places related to the
Place (could be empty)
public ReportingLink getReportingLink ()
Gets the link for getting options for reporting an place because, for example, if it contains inappropriate
content or the place does not exists.
Returns:
The report link, can be null.
public PlaceLink getResidingVenue ()
Gets the venue (if available) where the Place resides. This might be of interest to an application user
viewing information for the Place .
Returns:
The PlaceLink (could be null)
HERE Android SDK Developer's Guide
API Reference
1863
public MediaCollectionPage<ReviewMedia> getReviews ()
Gets the MediaCollectionPage containing ReviewMedia content for the Place .
Note: review content for a Place is optional, so a call to this method could return null .
Returns:
The MediaCollectionPage (could be null)
public SupplierLink getSupplier ()
Gets the Link for the Place supplier. A supplier link extends the standard link object with an optional icon
link pointing to the supplier's brand icon.
Note: a Link for a Place supplier is optional, so a call to this method could return null .
Returns:
The supplier Link (could be null)
public Ratings getUserRatings ()
Gets the HERE.com user-supplied Ratings for the Place .
Returns:
The HERE.com user-supplied Ratings for the Place.
public String getViewUri ()
Gets the String representation of the URI for a user-viewable representation of the Place . Applications
must provide at least one such URI for every Place they fetch.
Returns:
The URI to a viewable site for the Place
public int hashCode ()
For documentation, see java.lang.Object
PlaceLink
The class PlaceLink is a member of com.here.android.mpa.search .
HERE Android SDK Developer's Guide
API Reference
1864
Class Summary
public class PlaceLink
extends com.here.android.mpa.search.DiscoveryResult, com.here.android.mpa.search.Link, java.lang.Object
Represents discovery information about a Place .
[For complete information, see the section Class Details]
Method Summary
Table 1139: Methods in PlaceLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public List getAlternativeReferenceIds (String name)
Get a list of alternative identifiers of the same reference identifier for a specific domain.
public double getAverageRating ()
Gets the average rating for a Place.
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place.
public Category getCategory ()
Gets the Category for the Place.
public PlaceRequest getDetailsRequest ()
Creates a request to retrieve the Place details.
public double getDistance ()
Gets the distance to the Place, in meters.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the Place.
public String getReference (String name)
Get the reference identifier for a specific domain.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isSponsored ()
Determines whether the search result is sponsored.
Class Details
Represents discovery information about a Place .
HERE Android SDK Developer's Guide
API Reference
1865
Note: detailed Place information is retrieved by way of the PlaceRequest returned from a call to the
getDetailsRequest() method.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public List getAlternativeReferenceIds (String name)
Get a list of alternative identifiers of the same reference identifier for a specific domain. For example, a
venue content identifier reference can have alternative identifiers. The list of alternative identifiers can be
retrieved by calling this method with name "venues.content".
NOTE: A reference will not be returned if it has not been queried with the
DiscoveryRequest#addReference(String) function.
Parameters:
name
The reference name.
Returns:
The list of alternative identifiers. If alternative identifiers are not
public double getAverageRating ()
Gets the average rating for a Place.
Note: the average rating is set to zero for places with no ratings.
Returns:
The average rating
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox describing a range of coordinates that correspond to the Place. Typically,
bounding boxes are associated with places such as cities and countries.
This bounding box does not necessarily have the location from getPosition() as its center. For example, if
the search was performed with a street name, this bounding box may be one that contains the entire street,
while getPosition() can be any point along the street.
Note: bounding box information for a Place is optional, so a call to this method could return null .
Returns:
HERE Android SDK Developer's Guide
API Reference
1866
The GeoBoundingBox containing the Place (could be null)
public Category getCategory ()
Gets the Category for the Place.
Note: a category is optional (especially when offline), so a call to this method could return null .
Returns:
The Category
public PlaceRequest getDetailsRequest ()
Creates a request to retrieve the Place details. Each call to this method creates a new request object.
Returns:
The PlaceRequest to retrieve the Place details
public double getDistance ()
Gets the distance to the Place, in meters.
Note: When the distance is set to zero, no distance value is available. The application is expected to perform
the calculation if a distance is required (use distanceTo(GeoCoordinate) along with the user current position
via getPosition()).
Returns:
The distance
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the geographical position of the Place.
Returns:
The GeoCoordinate
public String getReference (String name)
Get the reference identifier for a specific domain. For example, a place can have a reference to an extruded
building object in the map. The reference identifier can be retrieved by calling this method with name
BUILDING_ID_REFERENCE_NAME .
NOTE: A reference will not be returned if it has not been added to the request using
DiscoveryRequest#addReference(String) .
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
1867
The reference name.
Returns:
The reference identifier. If the reference identifier does not exist, an empty String is returned.
public int hashCode ()
For documentation, see java.lang.Object
public boolean isSponsored ()
Determines whether the search result is sponsored. Applications must provide some visual differentiation
between sponsored search results and regular search results.
Returns:
True if the search result is sponsored, false otherwise
PlaceRequest
The class PlaceRequest is a member of com.here.android.mpa.search .
Class Summary
public class PlaceRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve a Place object by way of Places search services.
[For complete information, see the section Class Details]
See also:
ExploreRequest
HereRequest
SearchRequest
Constructor Summary
Table 1140: Constructors in PlaceRequest
Constructors
PlaceRequest (PlaceLink placeLink)
Default constructor.
PlaceRequest (String source, String id)
Creates a PlaceRequest based on an external reference source and identifier.
HERE Android SDK Developer's Guide
API Reference
1868
Method Summary
Table 1141: Methods in PlaceRequest
Methods
public void addContent (String placeContent)
Requests specific EditorialMedia by providing one of the available place content sources.
public void addImageDimensions (int width, int height)
Request Image Media with specific dimensions.
public PlaceRequest addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results.
public ErrorCode execute (ResultListener<Place> listener)
Executes an asynchronous request.
public Set getContent ()
Returns the names of requested place content sources that was added using addContent(String).
public List getReferences ()
This function returns the names of requested reference identifiers to be returned in the results.
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses.
public PlaceRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses.
Class Details
Represents an extended Request used to retrieve a Place object by way of Places search services.
See also:
ExploreRequest
HereRequest
SearchRequest
Constructor Details
PlaceRequest (PlaceLink placeLink)
Default constructor.
Parameters:
placeLink
A selected PlaceLink found using a discovery request.
PlaceRequest (String source, String id)
HERE Android SDK Developer's Guide
API Reference
1869
Creates a PlaceRequest based on an external reference source and identifier.
Parameters:
source
Name of the external reference source.
id
The identifier of the requested place in external system.
See also:
addReference(String)
PVID_ID_REFERENCE_NAME
VENUES_ID_REFERENCE_NAME
VENUES_CONTENT_ID_REFERENCE_NAME
VENUES_DESTINATION_ID_REFERENCE_NAME
VENUES_VENUE_ID_REFERENCE_NAME
getReference(String)
getReference(String)
Method Details
public void addContent (String placeContent)
Requests specific EditorialMedia by providing one of the available place content sources. Currently only
PLACE_CONTENT_WIKIPEDIA is available.
Parameters:
placeContent
non-empty name for place content source.
See also:
PLACE_CONTENT_WIKIPEDIA
getEditorials()
EditorialMedia
public void addImageDimensions (int width, int height)
Request Image Media with specific dimensions. At least one of the sizes (width or height) needs to be valid
(greater than 0).
Parameters:
width
HERE Android SDK Developer's Guide
API Reference
1870
Image width (pass 0 for any width)
height
Image height (pass 0 for any height)
public PlaceRequest addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results.
For example, to retrieve an POI identifier (pvid), set this value to Request#PVID_ID_REFERENCE_NAME .
Parameters:
name
Name of reference identifier to retrieve.
Returns:
True if name added, false otherwise.
See also:
PVID_ID_REFERENCE_NAME
VENUES_ID_REFERENCE_NAME
VENUES_CONTENT_ID_REFERENCE_NAME
VENUES_DESTINATION_ID_REFERENCE_NAME
VENUES_VENUE_ID_REFERENCE_NAME
public ErrorCode execute (ResultListener<Place> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public Set getContent ()
Returns the names of requested place content sources that was added using addContent(String).
Returns:
non-null list of the content source names.
public List getReferences ()
HERE Android SDK Developer's Guide
API Reference
1871
This function returns the names of requested reference identifiers to be returned in the results.
Returns:
List of the names of reference identifiers to be returned in the result.
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses. The default formatting is
HTML.
Returns:
The current RichTextFormatting type
public PlaceRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses.
Parameters:
value
Desired RichTextFormatting
Returns:
This PlaceRequest object
RatingMedia
The class RatingMedia is a member of com.here.android.mpa.search .
Class Summary
public class RatingMedia
extends com.here.android.mpa.search.Media, java.lang.Object
Represents rating content about a Place.
[For complete information, see the section Class Details]
See also:
getRatings()
HERE Android SDK Developer's Guide
API Reference
1872
Method Summary
Table 1142: Methods in RatingMedia
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public double getAverage ()
Gets the average rating for the Place.
public int getCount ()
Gets the count of individual contributions that users provided for rating the Place.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents rating content about a Place. Each individual Rating contains information about the rating itself,
the user who contributed the rating, and a rating that the user offered for the place.
See also:
getRatings()
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public double getAverage ()
Gets the average rating for the Place.
Returns:
The average rating
public int getCount ()
Gets the count of individual contributions that users provided for rating the Place.
Returns:
The total ratings count
HERE Android SDK Developer's Guide
API Reference
1873
public int hashCode ()
For documentation, see java.lang.Object
Ratings
The class Ratings is a member of com.here.android.mpa.search .
Class Summary
public class Ratings
extends java.lang.Object
Represents a summary of user-supplied ratings for a Place.
[For complete information, see the section Class Details]
See also:
getUserRatings()
Method Summary
Table 1143: Methods in Ratings
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public double getAverage ()
Gets the average rating for the Place.
public int getCount ()
Gets the count of individual contributions that users provided for rating the Place.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a summary of user-supplied ratings for a Place.
Note: ratings are normalized to values from [0..5], to compensate for potential differences between supplier
ratings systems.
See also:
getUserRatings()
HERE Android SDK Developer's Guide
API Reference
1874
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public double getAverage ()
Gets the average rating for the Place.
Returns:
The average rating
public int getCount ()
Gets the count of individual contributions that users provided for rating the Place.
Returns:
The total ratings count
public int hashCode ()
For documentation, see java.lang.Object
ReportingLink
The class ReportingLink is a member of com.here.android.mpa.search .
Class Summary
public class ReportingLink
extends com.here.android.mpa.search.Link, java.lang.Object
Represents a ReportingLink for getting options for reporting on content if it contains inappropriate content.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1875
Method Summary
Table 1144: Methods in ReportingLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getTitle ()
Gets the localized title for the resource to which the Link refers.
public String getUrl ()
Gets the String representation of the reporting URL
public int hashCode ()
Class Details
Represents a ReportingLink for getting options for reporting on content if it contains inappropriate content.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getTitle ()
Gets the localized title for the resource to which the Link refers. Client devices can display this title within
an application.
Note: a title for a linked object is optional, so a call to this method could return empty .
Returns:
The title (could be empty)
public String getUrl ()
Gets the String representation of the reporting URL
Returns:
The URL
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1876
Request<T>
The class Request<T> is a member of com.here.android.mpa.search .
Type Parameters:
T
Data type for results
Class Summary
public abstract class Request
extends java.lang.Object
Represents a base class for a search request.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1145: Nested Classes in Request<T>
Nested Classes
public static final enumeration Request.Connectivity
Represents values describing possible types of connectivity that the request is performed.
Field Summary
Table 1146: Fields in Request<T>
Fields
public static final String BUILDING_ID_REFERENCE_NAME
Name used to get building identifier references.
public static final String PLACE_CONTENT_WIKIPEDIA
Name used to get editorial wikipedia content in place details response.
public static final String PVID_ID_REFERENCE_NAME
Name used to get core POI identifier references.
public static final String VENUES_CONTENT_ID_REFERENCE_NAME
Name used to get only venues.content identifier references.
public static final String VENUES_DESTINATION_ID_REFERENCE_NAME
Name used to get only venues.destination identifier references.
public static final String VENUES_ID_REFERENCE_NAME
Name used to get all venues identifier references.
HERE Android SDK Developer's Guide
API Reference
1877
Fields
public static final String VENUES_VENUE_ID_REFERENCE_NAME
Name used to get only venues.venue identifier references.
protected ConnectivityMode m_connectivityMode
Method Summary
Table 1147: Methods in Request<T>
Methods
protected Request<T> addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results.
public boolean cancel ()
Cancels any pending results from an invoked request.
public ErrorCode execute (ResultListener<T> eventListener)
Executes an asynchronous request.
protected int getCollectionSize ()
Gets the current collection size being used for request responses.
public Connectivity getConnectivity ()
This function returns the connectivity of request.
protected List getReferences ()
This function returns the names of requested reference identifiers to be returned in the results.
protected Request<T> setCollectionSize (int value)
Sets a collection size to be used for request responses.
public void setConnectivity (Connectivity connectivity)
Sets the connectivity of request.
protected Request<T> setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public Request<T> setUserAuthentication (String token)
Some requests, such as when posting images or reviews, applications must provide an OAuth 2.0 bearer token (obtained
from HERE Account) to authenticate the user performing the action.
Class Details
Represents a base class for a search request.
Field Details
public static final String BUILDING_ID_REFERENCE_NAME
Name used to get building identifier references.
HERE Android SDK Developer's Guide
API Reference
1878
Use addReference(String) to be able to retrieve the building identifier from the returned PlaceLink (using
getReference(String) ).
The building identifier can also be retrieved using addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
See also:
addReference(String)
getReference(String)
addReference(String)
getReference(String)
public static final String PLACE_CONTENT_WIKIPEDIA
Name used to get editorial wikipedia content in place details response.
Use addContent(String) to specify PLACE_CONTENT_WIKIPEDIA content source in PlaceRequest.
See also:
getContent()
getEditorials()
EditorialMedia
public static final String PVID_ID_REFERENCE_NAME
Name used to get core POI identifier references.
Use addReference(String) to be able to retrieve the POI identifier from the returned PlaceLink (using
getReference(String)).
The POI identifier can also be retrieved using addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
See also:
addReference(String)
getReference(String)
addReference(String)
getReference(String)
public static final String VENUES_CONTENT_ID_REFERENCE_NAME
Name used to get only venues.content identifier references.
HERE Android SDK Developer's Guide
API Reference
1879
Use addReference(String) to be able to retrieve the venues.content identifier from the returned PlaceLink
(using getReference(String) ).
The venues.content identifier can also be retrieved using addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
See also:
addReference(String)
getReference(String)
addReference(String)
getReference(String)
public static final String VENUES_DESTINATION_ID_REFERENCE_NAME
Name used to get only venues.destination identifier references.
Use addReference(String) to be able to retrieve the venues.destination identifier from the returned
PlaceLink (using getReference(String)).
The venues.destination identifier can also be retrieved using addReference(String) and getReference(String)
(or addReference(String) and getReference(String)).
See also:
addReference(String)
getReference(String)
addReference(String)
getReference(String)
public static final String VENUES_ID_REFERENCE_NAME
Name used to get all venues identifier references.
Use addReference(String) to be able to retrieve all venues identifier from the returned PlaceLink (using
getReference(String) ).
The venues identifier can also be retrieved addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
This reference name can be used retrieve all the different venues identifiers, namely:
VENUES_CONTENT_ID_REFERENCE_NAME, VENUES_DESTINATION_ID_REFERENCE_NAME and
VENUES_VENUE_ID_REFERENCE_NAME.
See also:
addReference(String)
getReference(String)
HERE Android SDK Developer's Guide
API Reference
1880
addReference(String)
getReference(String)
public static final String VENUES_VENUE_ID_REFERENCE_NAME
Name used to get only venues.venue identifier references.
Use addReference(String) to be able to retrieve the venues.venue identifier from the returned PlaceLink
(using getReference(String) ).
The venues.venue identifier can also be retrieved using addReference(String) and getReference(String) (or
addReference(String) and getReference(String)).
See also:
addReference(String)
getReference(String)
addReference(String)
getReference(String)
protected ConnectivityMode m_connectivityMode
Method Details
protected Request<T> addReference (String name)
This function adds the name of a requested reference identifiers to be returned in the results. For example,
to retrieve an extruded building identifier, set this value to BUILDING_ID_REFERENCE_NAME .
Parameters:
name
Name of reference identifier to retrieve.
Returns:
HERE Android SDK Developer's Guide
API Reference
1881
True if name added, false otherwise.
See also:
SearchRequest
ExploreRequest
HereRequest
PlaceRequest
public boolean cancel ()
Cancels any pending results from an invoked request.
Returns:
True if the request was canceled successfully, false otherwise
public ErrorCode execute (ResultListener<T> eventListener)
Executes an asynchronous request.
Parameters:
eventListener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
protected int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size
See also:
SearchRequest
ExploreRequest
HereRequest
TextSuggestionRequest
TextAutoSuggestionRequest
GeocodeRequest
HERE Android SDK Developer's Guide
API Reference
1882
public Connectivity getConnectivity ()
This function returns the connectivity of request.
Returns:
The request connectivity.
protected List getReferences ()
This function returns the names of requested reference identifiers to be returned in the results.
Returns:
List of the names of reference identifiers to be returned in the result.
See also:
SearchRequest
ExploreRequest
HereRequest
PlaceRequest
protected Request<T> setCollectionSize (int value)
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size size per request.
Returns:
This Request object
Throws:
IllegalArgumentException
if size is out of range.
See also:
SearchRequest
ExploreRequest
HereRequest
TextSuggestionRequest
TextAutoSuggestionRequest
HERE Android SDK Developer's Guide
API Reference
1883
GeocodeRequest
public void setConnectivity (Connectivity connectivity)
Sets the connectivity of request. By default, the connectivity of request is controlled by the SDK. If the SDK
is online then an online request will be made. If the SDK is offline then an offline request will be made. Be
aware, OFFLINE request can return limited result details. Results from ONLINE request will provide the best
information available.
Parameters:
connectivity
Desired request connectivity.
protected Request<T> setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Parameters:
mapViewport
The bounding box of the map area currently visible.
Returns:
The updated Request object itself.
See also:
SearchRequest
ExploreRequest
HereRequest
TextSuggestionRequest
TextAutoSuggestionRequest
GeocodeRequest
public Request<T> setUserAuthentication (String token)
Some requests, such as when posting images or reviews, applications must provide an OAuth 2.0 bearer
token (obtained from HERE Account) to authenticate the user performing the action. The procedure for
obtaining a token is outside of the scope of this documentation. Please refer to the HERE Account Single Sign
On (SSO) API documentation for more information.
Parameters:
token
HERE Android SDK Developer's Guide
API Reference
1884
The User authentication bearer token.
Returns:
The updated Request object itself.
Connectivity
The enumeration Connectivity is a member of com.here.android.mpa.search.Request.
Enumeration Summary
public static final enumeration Request.Connectivity
extends java.lang.Enum, java.lang.Object
Represents values describing possible types of connectivity that the request is performed.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1148: Enum Constants in Connectivity
Fields
public static final Connectivity DEFAULT
The request will be executed based on the current MapEngine online status, which depends on the current network access
and could be forced to offline using setOnline(boolean).
public static final Connectivity OFFLINE
The request will be executed in offline mode regardless whether there is enough map data on the device.
public static final Connectivity ONLINE
The request will be executed in online mode regardless whether device is online or not.
Method Summary
Table 1149: Methods in Connectivity
Methods
public static Connectivity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Request.Connectivity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible types of connectivity that the request is performed.
HERE Android SDK Developer's Guide
API Reference
1885
Enum Constant Details
public static final Connectivity DEFAULT
The request will be executed based on the current MapEngine online status, which depends on the current
network access and could be forced to offline using setOnline(boolean). If the MapEngine status is set to
online, then an online request will be made. If the MapEngine status is offline, then an offline request will be
made.
public static final Connectivity OFFLINE
The request will be executed in offline mode regardless whether there is enough map data on the device. If
there is not enough map data the request might fail or return zero results. If it fails, it will not try online.
public static final Connectivity ONLINE
The request will be executed in online mode regardless whether device is online or not. If the device is
offline the request will fail. If it fails, it will not try offline.
Method Details
public static Connectivity valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Request.Connectivity[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ResultListener<T>
The interface ResultListener<T> is a member of com.here.android.mpa.search .
Type Parameters:
T
Listener data type
Interface Summary
public abstract interface ResultListener
HERE Android SDK Developer's Guide
API Reference
1886
Represents an event listener that reports information about the completion of a request.
[For complete information, see the section Interface Details]
Method Summary
Table 1150: Methods in ResultListener<T>
Methods
public abstract void onCompleted (T data, ErrorCode error)
A callback indicating that a request operation has completed.
Interface Details
Represents an event listener that reports information about the completion of a request.
Method Details
public abstract void onCompleted (T data, ErrorCode error)
A callback indicating that a request operation has completed.
Parameters:
data
Search results (can be null if no results were found or an error was encountered). E.g. if there is no map
data due to working offline, null is returned.
error
An ErrorCode representing an appropriate result. ErrorCode.NOT_FOUND is returned if there are no
search results.
ReverseGeocodeMode
The enumeration ReverseGeocodeMode is a member of com.here.android.mpa.search .
Enumeration Summary
public final enumeration ReverseGeocodeMode
extends java.lang.Enum, java.lang.Object
Enumeration for ReverseGeocodeRequest2 customisation.
[For complete information, see the section Enumeration Details]
See also:
ReverseGeocodeRequest2(GeoCoordinate, Locale, ReverseGeocodeMode, float)
HERE Android SDK Developer's Guide
API Reference
1887
Enum Constant Summary
Table 1151: Enum Constants in ReverseGeocodeMode
Fields
public static final ReverseGeocodeMode RETRIEVE_ADDRESSES
Retrieve addresses near the specified position (default mode).
public static final ReverseGeocodeMode RETRIEVE_AREAS
Retrieve the administrative area information for the position provided in the request.
public static final ReverseGeocodeMode RETRIEVE_LANDMARKS
Retrieve landmarks like parks and lakes in the proximity provided in the request.
public static final ReverseGeocodeMode RETRIEVE_ALL
Retrieve streets, administrative areas and landmarks.
public static final ReverseGeocodeMode TRACK_POSITION
Retrieve street information based on a position and bearing.
Method Summary
Table 1152: Methods in ReverseGeocodeMode
Methods
public String toString ()
public static ReverseGeocodeMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ReverseGeocodeMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enumeration for ReverseGeocodeRequest2 customisation.
See also:
ReverseGeocodeRequest2(GeoCoordinate, Locale, ReverseGeocodeMode, float)
Enum Constant Details
public static final ReverseGeocodeMode RETRIEVE_ADDRESSES
Retrieve addresses near the specified position (default mode).
public static final ReverseGeocodeMode RETRIEVE_AREAS
Retrieve the administrative area information for the position provided in the request.
HERE Android SDK Developer's Guide
API Reference
1888
public static final ReverseGeocodeMode RETRIEVE_LANDMARKS
Retrieve landmarks like parks and lakes in the proximity provided in the request.
public static final ReverseGeocodeMode RETRIEVE_ALL
Retrieve streets, administrative areas and landmarks. This mode aggregates the results of three different
modes in one call.
public static final ReverseGeocodeMode TRACK_POSITION
Retrieve street information based on a position and bearing.
Method Details
public String toString ()
public static ReverseGeocodeMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ReverseGeocodeMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ReverseGeocodeRequest2
The class ReverseGeocodeRequest2 is a member of com.here.android.mpa.search .
Class Summary
public class ReverseGeocodeRequest2
extends com.here.android.mpa.search.Request, java.lang.Object
The ReverseGeocodeRequest2 represents an extended Request used to retrieve Location data by way of
Geocoder search services.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1889
Constructor Summary
Table 1153: Constructors in ReverseGeocodeRequest2
Constructors
ReverseGeocodeRequest2 (GeoCoordinate location)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
ReverseGeocodeRequest2 (GeoCoordinate location, Locale locale)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
ReverseGeocodeRequest2 (GeoCoordinate location, Locale locale, ReverseGeocodeMode mode, float
bearing)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
Method Summary
Table 1154: Methods in ReverseGeocodeRequest2
Methods
public ErrorCode execute (ResultListener<Location> listener)
Executes an asynchronous request.
Class Details
The ReverseGeocodeRequest2 represents an extended Request used to retrieve Location data by way of
Geocoder search services.
Note: the response to a ReverseGeocodeRequest2 is a single Location object.
Constructor Details
ReverseGeocodeRequest2 (GeoCoordinate location)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
Parameters:
location
A GeoCoordinate representing the query location context.
Throws:
IllegalArgumentException
Upon a failure to handle a passed argument.
ReverseGeocodeRequest2 (GeoCoordinate location, Locale locale)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1890
location
A GeoCoordinate representing the query location context.
locale
A Locale locale in which the response should be returned.
Throws:
IllegalArgumentException
Upon a failure to handle a passed argument.
ReverseGeocodeRequest2 (GeoCoordinate location, Locale locale,
ReverseGeocodeMode mode, float bearing)
Creates a reverse geocode request that resolves a GeoCoordinate into an Location.
Parameters:
location
A GeoCoordinate representing the query location context.
locale
A Locale locale in which the response should be returned.
mode
A ReverseGeocodeMode mode in which the response should be filtered.
bearing
A bearing expresses the direction in which the vehicle is heading in degrees starting at true North and
continuing clockwise around the compass. Ignored if mode is not equal to TRACK_POSITION.
Throws:
IllegalArgumentException
Upon a failure to handle a passed argument.
Method Details
public ErrorCode execute (ResultListener<Location> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
HERE Android SDK Developer's Guide
API Reference
1891
ReviewMedia
The class ReviewMedia is a member of com.here.android.mpa.search .
Class Summary
public class ReviewMedia
extends com.here.android.mpa.search.Media, java.lang.Object
Represents review content about a Place.
[For complete information, see the section Class Details]
See also:
getReviews()
Method Summary
Table 1155: Methods in ReviewMedia
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getDate ()
Gets the date when the user contributed the review.
public String getDescription ()
Gets the review content for the Place.
public String getId ()
Get the review identifier.
public String getIsoLanguageCode ()
Gets the ISO language code identifying the language in which the review is available.
public double getRating ()
Gets the rating that the contributor of the review gave to the Place.
public String getTitle ()
Gets the title of the review that the user contributed.
public UserLink getUser ()
Gets the Link to details about the user who contributed the review.
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1892
Class Details
Represents review content about a Place. Each individual Review contains information about the review
itself, the user who contributed the review, and a rating that the user offered for the place.
See also:
getReviews()
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getDate ()
Gets the date when the user contributed the review.
Returns:
The date
public String getDescription ()
Gets the review content for the Place. Depending on the supplier, the full description might not be displayed
and the full review might be available only within the resource to which the optional via attribute links.
Returns:
The content description
See also:
getVia()
public String getId ()
Get the review identifier.
Returns:
The review identifier.
public String getIsoLanguageCode ()
Gets the ISO language code identifying the language in which the review is available.
Note: a language code for a review is optional, so a call to this method could return null .
HERE Android SDK Developer's Guide
API Reference
1893
Returns:
The language code (could be null).
public double getRating ()
Gets the rating that the contributor of the review gave to the Place.
Returns:
The rating as estimated by the review contributor
See also:
Ratings
public String getTitle ()
Gets the title of the review that the user contributed.
Note: a title for a review is optional, so a call to this method could return null .
Returns:
The title (could be null).
public UserLink getUser ()
Gets the Link to details about the user who contributed the review.
Returns:
The user Link
public int hashCode ()
For documentation, see java.lang.Object
RichTextFormatting
The enumeration RichTextFormatting is a member of com.here.android.mpa.search .
Enumeration Summary
public final enumeration RichTextFormatting
extends java.lang.Enum, java.lang.Object
Represents values describing possible formats for rich text content.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1894
See also:
setRichTextFormatting(RichTextFormatting)
Enum Constant Summary
Table 1156: Enum Constants in RichTextFormatting
Fields
public static final RichTextFormatting HTML
HTML-encoded text.
public static final RichTextFormatting PLAIN
Plain text.
Method Summary
Table 1157: Methods in RichTextFormatting
Methods
public static RichTextFormatting valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static RichTextFormatting[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible formats for rich text content.
See also:
setRichTextFormatting(RichTextFormatting)
Enum Constant Details
public static final RichTextFormatting HTML
HTML-encoded text.
public static final RichTextFormatting PLAIN
Plain text.
Method Details
public static RichTextFormatting valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
1895
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RichTextFormatting[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SearchRequest
The class SearchRequest is a member of com.here.android.mpa.search .
Class Summary
public class SearchRequest
extends com.here.android.mpa.search.DiscoveryRequest, com.here.android.mpa.search.Request,
java.lang.Object
The SearchRequest processes text string queries based on the user's input to find specific places.
[For complete information, see the section Class Details]
Constructor Summary
Table 1158: Constructors in SearchRequest
Constructors
SearchRequest (String query)
SearchRequest constructor
Method Summary
Table 1159: Methods in SearchRequest
Methods
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
public SearchRequest setQueryText (String query)
Set the search query text.
public SearchRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius.
HERE Android SDK Developer's Guide
API Reference
1896
Methods
public SearchRequest setSearchCenter (GeoCoordinate center)
Sets a GeoCoordinate representing the location context used to search for results that are appropriate to the query
parameter.
Class Details
The SearchRequest processes text string queries based on the user's input to find specific places. It
answers questions of "what" and "where" for an online search of POI or address.
The results of the SearchRequest are sets of places that match a user's search term in a specific location
context (such as near a given location, around a user's current position or on the currently visible map).
A search location context must be provided by setting a search center location using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox) or
both. Failing to set a location context will result in an INVALID_PARAMETER when executing the request.
Constructor Details
SearchRequest (String query)
SearchRequest constructor
Parameters:
query
Query text specifying the kind of places to locate
Method Details
public ErrorCode execute (ResultListener<DiscoveryResultPage> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public SearchRequest setQueryText (String query)
Set the search query text.
Parameters:
query
Query text specifying the kind of places to locate
HERE Android SDK Developer's Guide
API Reference
1897
Returns:
The SearchRequest
public SearchRequest setSearchArea (GeoCoordinate center, int radius)
Sets the search area using a center location and radius. Use this method to localize search.
Parameters:
center
The GeoCoordinate representing the search area center location.
radius
The search area circle radius in meters. In online mode, valid value for radius is (0, 21000000). In offline
mode, it is (0, 100000).
Returns:
The SearchRequest.
Throws:
IllegalArgumentException
if radius is less or equal to 0.
public SearchRequest setSearchCenter (GeoCoordinate center)
Sets a GeoCoordinate representing the location context used to search for results that are appropriate to
the query parameter. Use this method to do worldwide search.
Parameters:
center
A GeoCoordinate representing the location context used to search for results that are appropriate to
the query parameter.
Returns:
The SearchRequest
SupplierLink
The class SupplierLink is a member of com.here.android.mpa.search .
Class Summary
public class SupplierLink
extends com.here.android.mpa.search.Link, java.lang.Object
Represents a SupplierLink which contains meta-information about a supplier.
HERE Android SDK Developer's Guide
API Reference
1898
[For complete information, see the section Class Details]
See also:
getSupplier()
getSupplier()
Method Summary
Table 1160: Methods in SupplierLink
Methods
public boolean equals (Object obj)
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
public String getName ()
Gets the name of the supplier that provided the Link .
public String getUrl ()
Gets the String representation of the URL to the supplier's profile
public int hashCode ()
Class Details
Represents a SupplierLink which contains meta-information about a supplier.
See also:
getSupplier()
getSupplier()
Method Details
public boolean equals (Object obj)
Parameters:
obj
public String getIconUrl ()
Gets the URL to retrieve the icon for the resource to which the Link refers.
Note: an icon URL for a linked object is optional, so a call to this method could return empty .
Returns:
HERE Android SDK Developer's Guide
API Reference
1899
The icon URL (could be empty)
public String getId ()
Gets the unique identifier for the resource to which the Link refers.
Note: an ID for a linked object is optional, so a call to this method could return empty .
Returns:
The ID (could be empty)
public String getName ()
Gets the name of the supplier that provided the Link .
Note: a supplier name for a linked object is optional, so a call to this method could return empty .
Returns:
The name of the supplier
public String getUrl ()
Gets the String representation of the URL to the supplier's profile
Returns:
The URL
public int hashCode ()
TextAutoSuggestionRequest
The class TextAutoSuggestionRequest is a member of com.here.android.mpa.search .
Class Summary
public class TextAutoSuggestionRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve a List of suggested search terms, instants results and
refined search links by way of Places search services.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1900
Nested Class Summary
Table 1161: Nested Classes in TextAutoSuggestionRequest
Nested Classes
public static final enumeration TextAutoSuggestionRequest.AutoSuggestFilterType
Represents values describing AutoSuggest response's result filter types that can be used to filter the AutoSuggest response.
Constructor Summary
Table 1162: Constructors in TextAutoSuggestionRequest
Constructors
TextAutoSuggestionRequest (String partialTerm)
Default constructor.
Method Summary
Table 1163: Methods in TextAutoSuggestionRequest
Methods
public ErrorCode execute (ResultListener<AutoSuggest> listener)
Executes an asynchronous request.
public int getCollectionSize ()
Gets the current collection size being used for request responses.
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses.
public TextAutoSuggestionRequest setCollectionSize (int value)
Sets a collection size to be used for request responses.
public TextAutoSuggestionRequest setFilters (java.util.EnumSet <AutoSuggestFilterType> filtersSet)
Set result type filter.
public TextAutoSuggestionRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public TextAutoSuggestionRequest setQueryText (String partialTerm)
Set the query partial search term.
public TextAutoSuggestionRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses.
public TextAutoSuggestionRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
HERE Android SDK Developer's Guide
API Reference
1901
Class Details
Represents an extended Request used to retrieve a List of suggested search terms, instants results and
refined search links by way of Places search services.
TextAutoSuggestionRequest supports online only. Please use TextSuggestionRequest for offline.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Constructor Details
TextAutoSuggestionRequest (String partialTerm)
Default constructor.
Creates a request to return a list of suggested search terms, instants results and refined search links that are
related to a specified location context and a partial search term.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Parameters:
partialTerm
A partial search term used to create a list of suggested search terms.
Method Details
public ErrorCode execute (ResultListener<AutoSuggest> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size
HERE Android SDK Developer's Guide
API Reference
1902
public RichTextFormatting getRichTextFormatting ()
Gets the current RichTextFormatting type being used in request responses.
Returns:
The current RichTextFormatting type
public TextAutoSuggestionRequest setCollectionSize (int value)
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size per request.
Returns:
This Request object
Throws:
IllegalArgumentException
if size is out of range.
public TextAutoSuggestionRequest setFilters (java.util.EnumSet
<AutoSuggestFilterType> filtersSet)
Set result type filter.
Parameters:
filtersSet
A java.util.EnumSet of TextAutoSuggestionRequest.AutoSuggestFilterType used to filter the
AutoSuggestion response.
Returns:
The TextAutoSuggestionRequest.
public TextAutoSuggestionRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Parameters:
mapViewport
The bounding box of the map area currently visible.
HERE Android SDK Developer's Guide
API Reference
1903
public TextAutoSuggestionRequest setQueryText (String partialTerm)
Set the query partial search term.
Parameters:
partialTerm
A partial search term used to create a list of suggested search terms.
Returns:
The TextAutoSuggestionRequest.
public TextAutoSuggestionRequest setRichTextFormatting (RichTextFormatting value)
Sets a RichTextFormatting to be used in request responses. The default formatting is HTML.
Parameters:
value
Desired RichTextFormatting
Returns:
This TextAutoSuggestionRequest object
public TextAutoSuggestionRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Parameters:
center
The GeoCoordinate representing the location context used to search for nearby places.
Returns:
The TextAutoSuggestionRequest.
AutoSuggestFilterType
The enumeration AutoSuggestFilterType is a member of
com.here.android.mpa.search.TextAutoSuggestionRequest.
Enumeration Summary
public static final enumeration TextAutoSuggestionRequest.AutoSuggestFilterType
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1904
Represents values describing AutoSuggest response's result filter types that can be used to filter the
AutoSuggest response.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1164: Enum Constants in AutoSuggestFilterType
Fields
public static final AutoSuggestFilterType ADDRESS
AutoSuggest response will contain Location and address suggestion result type.
public static final AutoSuggestFilterType PLACE
AutoSuggest response will contain POI suggestion result type.
public static final AutoSuggestFilterType CATEGORY
AutoSuggest response will contain Category search suggestion result type.
public static final AutoSuggestFilterType CHAIN
AutoSuggest response will contain Chain/Brand search suggestion result type.
public static final AutoSuggestFilterType QUERY
AutoSuggest response will contain Query completion suggestion result type.
Method Summary
Table 1165: Methods in AutoSuggestFilterType
Methods
public static AutoSuggestFilterType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TextAutoSuggestionRequest.AutoSuggestFilterType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing AutoSuggest response's result filter types that can be used to filter the
AutoSuggest response.
Enum Constant Details
public static final AutoSuggestFilterType ADDRESS
AutoSuggest response will contain Location and address suggestion result type.
public static final AutoSuggestFilterType PLACE
HERE Android SDK Developer's Guide
API Reference
1905
AutoSuggest response will contain POI suggestion result type.
public static final AutoSuggestFilterType CATEGORY
AutoSuggest response will contain Category search suggestion result type.
public static final AutoSuggestFilterType CHAIN
AutoSuggest response will contain Chain/Brand search suggestion result type.
public static final AutoSuggestFilterType QUERY
AutoSuggest response will contain Query completion suggestion result type.
Method Details
public static AutoSuggestFilterType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TextAutoSuggestionRequest.AutoSuggestFilterType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TextSuggestionRequest
The class TextSuggestionRequest is a member of com.here.android.mpa.search .
Class Summary
public class TextSuggestionRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve a List of search terms by way of Places search services.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1906
Constructor Summary
Table 1166: Constructors in TextSuggestionRequest
Constructors
TextSuggestionRequest (String partialTerm)
Default constructor.
Method Summary
Table 1167: Methods in TextSuggestionRequest
Methods
public ErrorCode execute (ResultListener<String> listener)
Executes an asynchronous request.
public int getCollectionSize ()
Gets the current collection size being used for request responses.
public RichTextFormatting getRichTextFormatting ()
Deprecated: As of SDK 3.6.
Gets the current RichTextFormatting type being used in request responses.
public TextSuggestionRequest setCollectionSize (int value)
Sets a collection size to be used for request responses.
public TextSuggestionRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user.
public TextSuggestionRequest setQueryText (String partialTerm)
Set the query partial search term.
public TextSuggestionRequest setRichTextFormatting (RichTextFormatting value)
Deprecated: As of SDK 3.6.
Sets a RichTextFormatting to be used in request responses.
public TextSuggestionRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Class Details
Represents an extended Request used to retrieve a List of search terms by way of Places search services.
A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Constructor Details
TextSuggestionRequest (String partialTerm)
HERE Android SDK Developer's Guide
API Reference
1907
Default constructor.
Creates a request to return a list of suggested search terms that are related to a specified location context
and a partial search term.
* A search location context must be provided by setting either a search center using
setSearchCenter(GeoCoordinate) or a bounding map viewport using setMapViewport(GeoBoundingBox).
Failing to set a map viewport will result in an INVALID_PARAMETER when executing the request.
Parameters:
partialTerm
The partial term to search.
Method Details
public ErrorCode execute (ResultListener<String> listener)
Executes an asynchronous request.
Parameters:
listener
A ResultListener passed along with the request to monitor progress
Returns:
The ErrorCode representing an appropriate result
public int getCollectionSize ()
Gets the current collection size being used for request responses.
Returns:
The current response collection size
public RichTextFormatting getRichTextFormatting ()
Deprecated: As of SDK 3.6.
Use TextAutoSuggestionRequest instead. TextSuggestionRequest does not support text formatting. The method
getRichTextFormatting is deprecated. If you want to receive HTML formatted response use TextAutoSuggestionRequest instead in
online mode.
Gets the current RichTextFormatting type being used in request responses.
Returns:
The current RichTextFormatting type
public TextSuggestionRequest setCollectionSize (int value)
HERE Android SDK Developer's Guide
API Reference
1908
Sets a collection size to be used for request responses. The maximum number of result items in each
collection will be limited to this value. The valid value range is [1..100]. The default collection size is 20.
Parameters:
value
Desired response collection size per request.
Returns:
This Request object
Throws:
IllegalArgumentException
if size is out of range.
public TextSuggestionRequest setMapViewport (GeoBoundingBox mapViewport)
The map viewport is a bounding box of the map area currently visible to the user. The viewport can act as
an implicit location context in the absence of an explicit location context. To ensure you get the best results
possible, you should always set a viewport if there is a map visible to the user.
Parameters:
mapViewport
The bounding box of the map area currently visible.
public TextSuggestionRequest setQueryText (String partialTerm)
Set the query partial search term.
Parameters:
partialTerm
A partial search term used to create a list of suggested search terms.
Returns:
The TextSuggestionRequest.
public TextSuggestionRequest setRichTextFormatting (RichTextFormatting value)
Deprecated: As of SDK 3.6.
Use TextAutoSuggestionRequest instead. TextSuggestionRequest does not support text formatting. The method
setRichTextFormatting is deprecated. If you want to receive HTML formatted response use TextAutoSuggestionRequest instead in
online mode.
Sets a RichTextFormatting to be used in request responses. The default formatting is PLAIN.
Parameters:
value
HERE Android SDK Developer's Guide
API Reference
1909
Desired RichTextFormatting
Returns:
This TextSuggestionRequest object
public TextSuggestionRequest setSearchCenter (GeoCoordinate center)
Sets the search center.
Parameters:
center
The GeoCoordinate representing the location context used to search for nearby places.
Returns:
The TextSuggestionRequest.
TransitDeparture
The class TransitDeparture is a member of com.here.android.mpa.search .
Class Summary
public class TransitDeparture
extends java.lang.Object
Represents information about a single departure.
[For complete information, see the section Class Details]
Field Summary
Table 1168: Fields in TransitDeparture
Fields
public static final String DEPARTURE_PLATFORM_KEY_NAME
Key name to retrieve the departure platform information.
public static final String DEPARTURE_TIME_KEY_NAME
Key name to retrieve departure time ( RFC 3339 date-time format with timezone offset).
public static final String EXCEPTION_EVENT_ADDITIONAL
Additional departure information provided.
public static final String EXCEPTION_EVENT_CANCELLED
Departure has been cancelled.
HERE Android SDK Developer's Guide
API Reference
1910
Fields
public static final String EXCEPTION_EVENT_REDIRECTED
Departure has been redirected.
public static final String EXCEPTION_EVENT_REPLACED
Departure has been replaced.
Method Summary
Table 1169: Methods in TransitDeparture
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getDirection ()
Gets direction of the departure on the line.
public String getException ()
An indicator for some exceptional event happened to this departure.
public java.util.List <ExtendedAttribute> getExtendedAttributes ()
Gets list of ExtendedAttribute features of departure.
public String getLine ()
Reference to the line in transit lines collection information.
public String getOperator ()
Gets a reference to the operator in the operators collection information.
public Map getRealTimeInformation ()
Gets the real (actual) departure time information.
public Map getScheduledTimeInformation ()
Gets the originally scheduled departure time information.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents information about a single departure. All times use RFC 3339 date-time format with timezone
offset.
Field Details
public static final String DEPARTURE_PLATFORM_KEY_NAME
Key name to retrieve the departure platform information.
HERE Android SDK Developer's Guide
API Reference
1911
public static final String DEPARTURE_TIME_KEY_NAME
Key name to retrieve departure time ( RFC 3339 date-time format with timezone offset).
public static final String EXCEPTION_EVENT_ADDITIONAL
Additional departure information provided.
public static final String EXCEPTION_EVENT_CANCELLED
Departure has been cancelled.
public static final String EXCEPTION_EVENT_REDIRECTED
Departure has been redirected.
public static final String EXCEPTION_EVENT_REPLACED
Departure has been replaced.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getDirection ()
Gets direction of the departure on the line.
Returns:
The departure direction on the line.
public String getException ()
An indicator for some exceptional event happened to this departure. Possible values are:
EXCEPTION_EVENT_REDIRECTED , EXCEPTION_EVENT_REPLACED , EXCEPTION_EVENT_CANCELLED and
EXCEPTION_EVENT_ADDITIONAL .
Returns:
HERE Android SDK Developer's Guide
API Reference
1912
Exception event (if any have occurred).
public java.util.List <ExtendedAttribute> getExtendedAttributes ()
Gets list of ExtendedAttribute features of departure. Supported keys are bikeAllowed and barrierFree .
Returns:
List of departure ExtendedAttribute.
public String getLine ()
Reference to the line in transit lines collection information.
Returns:
The line name.
public String getOperator ()
Gets a reference to the operator in the operators collection information.
Returns:
The operator name.
public Map getRealTimeInformation ()
Gets the real (actual) departure time information. The departure key represents the departure time.
Known key identifier values are:
DEPARTURE_TIME_KEY_NAME - real-time departure time (RFC 3339 date-time)
DEPARTURE_PLATFORM_KEY_NAME - real-time departure platform (optional)
Returns:
The map collection of real (actual) departure time information.
public Map getScheduledTimeInformation ()
Gets the originally scheduled departure time information.
Known key identifier values are:
DEPARTURE_TIME_KEY_NAME - scheduled departure time ( RFC 3339 date-time)
DEPARTURE_PLATFORM_KEY_NAME - scheduled departure platform (optional)
Returns:
The map collection of originally scheduled departure time information.
HERE Android SDK Developer's Guide
API Reference
1913
public int hashCode ()
For documentation, see java.lang.Object
TransitDeparturesAttribute
The class TransitDeparturesAttribute is a member of com.here.android.mpa.search .
Class Summary
public class TransitDeparturesAttribute
extends com.here.android.mpa.search.ExtendedAttribute, java.lang.Object
Represents a Transit Departures Extended Attribute that is associated with public transport stop/station and
contains information about scheduled departures from the place.
[For complete information, see the section Class Details]
Method Summary
Table 1170: Methods in TransitDeparturesAttribute
Methods
public TransitSchedulePage getSchedule ()
Gets a paged collection of scheduled departure information.
Class Details
Represents a Transit Departures Extended Attribute that is associated with public transport stop/station and
contains information about scheduled departures from the place.
Method Details
public TransitSchedulePage getSchedule ()
Gets a paged collection of scheduled departure information.
Returns:
TransitSchedulePage representing a paged collection of scheduled departure information.
TransitDestination
The class TransitDestination is a member of com.here.android.mpa.search .
HERE Android SDK Developer's Guide
API Reference
1914
Class Summary
public class TransitDestination
extends java.lang.Object
Represents a destination served from station/stop.
[For complete information, see the section Class Details]
Method Summary
Table 1171: Methods in TransitDestination
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getDestination ()
Gets the name of the destination.
public String getLine ()
Gets the name of the line serving the destination.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a destination served from station/stop.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getDestination ()
Gets the name of the destination.
Returns:
The destination name.
public String getLine ()
Gets the name of the line serving the destination.
HERE Android SDK Developer's Guide
API Reference
1915
Returns:
The line name.
public int hashCode ()
For documentation, see java.lang.Object
TransitLine
The class TransitLine is a member of com.here.android.mpa.search .
Class Summary
public class TransitLine
extends java.lang.Object
Represents a public transport line.
[For complete information, see the section Class Details]
Method Summary
Table 1172: Methods in TransitLine
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getDestination ()
Gets the line destination.
public TransitLineCategory getLineCategory ()
Gets the category information for the line.
public String getName ()
Gets the line name.
public String getOperator ()
Gets the operator serving the line.
public TransitLineStyle getStyle ()
Gets the style guideline information for the line.
public int hashCode ()
Class Details
Represents a public transport line.
HERE Android SDK Developer's Guide
API Reference
1916
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getDestination ()
Gets the line destination.
Returns:
The line destination.
public TransitLineCategory getLineCategory ()
Gets the category information for the line.
Returns:
The TransitLineCategory information.
public String getName ()
Gets the line name.
Returns:
The line name
public String getOperator ()
Gets the operator serving the line.
Returns:
The line operator.
public TransitLineStyle getStyle ()
Gets the style guideline information for the line.
Returns:
The TransitLineStyle information.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
1917
TransitLineCategory
The class TransitLineCategory is a member of com.here.android.mpa.search .
Class Summary
public class TransitLineCategory
extends java.lang.Object
Represents the category information for the public transport line.
[For complete information, see the section Class Details]
Method Summary
Table 1173: Methods in TransitLineCategory
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getIcon ()
Gets the icon for the category.
public String getId ()
Gets the category unique identifier.
public String getLocalName ()
Gets the locally used name for the category.
public String getTitle ()
Gets the localized name of the category.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents the category information for the public transport line.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1918
public String getIcon ()
Gets the icon for the category.
Returns:
The category icon.
public String getId ()
Gets the category unique identifier.
Returns:
The category identifier.
public String getLocalName ()
Gets the locally used name for the category.
Returns:
The locally used category name.
public String getTitle ()
Gets the localized name of the category.
Returns:
The localized category name.
public int hashCode ()
For documentation, see java.lang.Object
TransitLineStyle
The class TransitLineStyle is a member of com.here.android.mpa.search .
Class Summary
public class TransitLineStyle
extends java.lang.Object
Represents the styling guideline information for the public transport line.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1919
Method Summary
Table 1174: Methods in TransitLineStyle
Methods
public boolean equals (Object obj)
public String getColor ()
Gets the color value assigned to a line.
public String getIconShape ()
Gets the shape style identifying the icon for the line.
public String getOutlineColor ()
Gets the color of the border around the line name.
public String getTextColor ()
Gets the text color that should get used when the line color is used as background color.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents the styling guideline information for the public transport line. All colors are in hex format.
Method Details
public boolean equals (Object obj)
Parameters:
obj
public String getColor ()
Gets the color value assigned to a line.
Returns:
The line color value (hex format).
public String getIconShape ()
Gets the shape style identifying the icon for the line.
Returns:
The icon shape.
public String getOutlineColor ()
HERE Android SDK Developer's Guide
API Reference
1920
Gets the color of the border around the line name.
Returns:
The line border color value (hex format).
public String getTextColor ()
Gets the text color that should get used when the line color is used as background color.
Returns:
The text color value (hex format).
public int hashCode ()
For documentation, see java.lang.Object
TransitLinesAttribute
The class TransitLinesAttribute is a member of com.here.android.mpa.search .
Class Summary
public class TransitLinesAttribute
extends com.here.android.mpa.search.ExtendedAttribute, java.lang.Object
Represents a Transit Lines Extended Attribute that is associated with public transport stop/station and
contains information about the lines and destinations.
[For complete information, see the section Class Details]
Method Summary
Table 1175: Methods in TransitLinesAttribute
Methods
public java.util.List <TransitDestination> getDestinations ()
Gets list of destinations served from this stop/station.
public java.util.Map <java.lang.String, com.here.android.mpa.search.TransitLine> getLines ()
Gets collection of public transport lines using this stop/station.
Class Details
Represents a Transit Lines Extended Attribute that is associated with public transport stop/station and
contains information about the lines and destinations.
HERE Android SDK Developer's Guide
API Reference
1921
Method Details
public java.util.List <TransitDestination> getDestinations ()
Gets list of destinations served from this stop/station.
Returns:
List of TransitDesitnation information.
public java.util.Map <java.lang.String,
com.here.android.mpa.search.TransitLine> getLines ()
Gets collection of public transport lines using this stop/station.
Returns:
Map collection of transport line stop/station name to TransitLine information.
TransitOperator
The class TransitOperator is a member of com.here.android.mpa.search .
Class Summary
public class TransitOperator
extends java.lang.Object
Represents a public transport operator.
[For complete information, see the section Class Details]
Method Summary
Table 1176: Methods in TransitOperator
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getId ()
Gets the operator identifier.
public java.util.Map <java.lang.String, com.here.android.mpa.search.TransitOperatorLink>
getLinks ()
Gets the map collection of additional links to be displayed next to the departure information of the operator.
public TransitOperatorSupplier getSupplier ()
Gets the supplier of the operator's schedule information.
HERE Android SDK Developer's Guide
API Reference
1922
Methods
public String getTitle ()
Gets the name of the operator.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a public transport operator.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getId ()
Gets the operator identifier.
Returns:
The operator identifier.
public java.util.Map <java.lang.String,
com.here.android.mpa.search.TransitOperatorLink> getLinks ()
Gets the map collection of additional links to be displayed next to the departure information of the operator.
Returns:
Map collection of operator's names to TransitOperatorLink information.
public TransitOperatorSupplier getSupplier ()
Gets the supplier of the operator's schedule information.
Returns:
The TransitOperatorSupplier information.
public String getTitle ()
Gets the name of the operator.
Returns:
HERE Android SDK Developer's Guide
API Reference
1923
The operator name.
public int hashCode ()
For documentation, see java.lang.Object
TransitOperatorLink
The class TransitOperatorLink is a member of com.here.android.mpa.search .
Class Summary
public class TransitOperatorLink
extends java.lang.Object
Represents an additional link associated with transit operator.
[For complete information, see the section Class Details]
Field Summary
Table 1177: Fields in TransitOperatorLink
Fields
protected PlacesTransitOperatorLink m_pimpl
Method Summary
Table 1178: Methods in TransitOperatorLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getText ()
Gets the operator link text.
public Link getUrl ()
Gets the Link to the operator information.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents an additional link associated with transit operator.
HERE Android SDK Developer's Guide
API Reference
1924
Field Details
protected PlacesTransitOperatorLink m_pimpl
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getText ()
Gets the operator link text.
Returns:
The operator link text.
public Link getUrl ()
Gets the Link to the operator information.
Returns:
The Link to the operator information.
public int hashCode ()
For documentation, see java.lang.Object
TransitOperatorSupplier
The class TransitOperatorSupplier is a member of com.here.android.mpa.search .
Class Summary
public class TransitOperatorSupplier
extends java.lang.Object
Represents a supplier of the public transport operator's schedule.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1925
Method Summary
Table 1179: Methods in TransitOperatorSupplier
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getTitle ()
Gets the supplier title.
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a supplier of the public transport operator's schedule.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getTitle ()
Gets the supplier title.
Returns:
The supplier title.
public int hashCode ()
For documentation, see java.lang.Object
TransitSchedulePage
The class TransitSchedulePage is a member of com.here.android.mpa.search .
Class Summary
public class TransitSchedulePage
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1926
Represents departure information for a public transport stop/station.
[For complete information, see the section Class Details]
Method Summary
Table 1180: Methods in TransitSchedulePage
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public java.util.List <TransitDeparture> getItems ()
Gets the list of departures.
public java.util.Map <java.lang.String, com.here.android.mpa.search.TransitLine> getLines ()
Gets the map collection of transit line names to TransitLine information.
public TransitSchedulePageRequest getNextPageRequest ()
Gets the TransitSchedulePageRequest for requesting the next page of the TransitSchedulePage .
public int getOffsetCount ()
Gets the collection offset count for the current page of the TransitSchedulePage .
public java.util.Map <java.lang.String, com.here.android.mpa.search.TransitOperator>
getOperators ()
Gets the map collection of transit line operators to TransitOperator information.
public TransitSchedulePageRequest getPreviousPageRequest ()
Gets the TransitSchedulePageRequest for requesting the previous page of the TransitSchedulePage .
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents departure information for a public transport stop/station. Departure items are paginated based
on page size parameter.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public java.util.List <TransitDeparture> getItems ()
Gets the list of departures.
HERE Android SDK Developer's Guide
API Reference
1927
Returns:
The list of TransitDeparture
public java.util.Map <java.lang.String,
com.here.android.mpa.search.TransitLine> getLines ()
Gets the map collection of transit line names to TransitLine information.
Returns:
The map collection of lines serving departures shown in current departure item list using line name as a key
public TransitSchedulePageRequest getNextPageRequest ()
Gets the TransitSchedulePageRequest for requesting the next page of the TransitSchedulePage .
Returns:
The TransitSchedulePageRequest
public int getOffsetCount ()
Gets the collection offset count for the current page of the TransitSchedulePage .
For the first page of results, the offset count is 0. Following any call to getNextPageRequest(), the offset count
will be greater than 0.
Returns:
The collection offset count
public java.util.Map <java.lang.String,
com.here.android.mpa.search.TransitOperator> getOperators ()
Gets the map collection of transit line operators to TransitOperator information.
Returns:
The map collection of operators operating on this stop/station using operator ID as a key
public TransitSchedulePageRequest getPreviousPageRequest ()
Gets the TransitSchedulePageRequest for requesting the previous page of the TransitSchedulePage
.
Returns:
The TransitSchedulePageRequest
HERE Android SDK Developer's Guide
API Reference
1928
public int hashCode ()
For documentation, see java.lang.Object
TransitSchedulePageRequest
The class TransitSchedulePageRequest is a member of com.here.android.mpa.search .
Class Summary
public class TransitSchedulePageRequest
extends com.here.android.mpa.search.Request, java.lang.Object
Represents an extended Request used to retrieve TransitSchedulePage information associated with a
Place, by way of Places search services.
[For complete information, see the section Class Details]
Method Summary
Table 1181: Methods in TransitSchedulePageRequest
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public ErrorCode execute (ResultListener<TransitSchedulePage> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents an extended Request used to retrieve TransitSchedulePage information associated with a
Place, by way of Places search services.
Note: the response to a TransitSchedulePageRequest is a TransitSchedulePage object.
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
HERE Android SDK Developer's Guide
API Reference
1929
public ErrorCode execute (ResultListener<TransitSchedulePage> eventListener)
Executes an asynchronous request.
This method overrides search.Request.execute(ResultListener)
Parameters:
eventListener
public int hashCode ()
For documentation, see java.lang.Object
UserLink
The class UserLink is a member of com.here.android.mpa.search .
Class Summary
public class UserLink
extends com.here.android.mpa.search.Link, java.lang.Object
Represents a UserLink which contains additional attributes to describe a user.
[For complete information, see the section Class Details]
See also:
getUser()
getUser()
Method Summary
Table 1182: Methods in UserLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getName ()
Gets the name of the user that provided the the Link .
public String getUrl ()
Gets the String representation of the URL to the user's profile
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1930
Class Details
Represents a UserLink which contains additional attributes to describe a user.
See also:
getUser()
getUser()
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getName ()
Gets the name of the user that provided the the Link .
Note: a user name for a linked object is optional, so a call to this method could return empty .
Returns:
The icon URL (could be empty)
public String getUrl ()
Gets the String representation of the URL to the user's profile
Returns:
The URL
public int hashCode ()
For documentation, see java.lang.Object
ViaLink
The class ViaLink is a member of com.here.android.mpa.search .
Class Summary
public class ViaLink
extends com.here.android.mpa.search.Link, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1931
Represents a ViaLink to an external website of the supplier of content.
[For complete information, see the section Class Details]
See also:
getVia()
Method Summary
Table 1183: Methods in ViaLink
Methods
public boolean equals (Object obj)
For documentation, see java.lang.Object
public String getUrl ()
Gets the String representation of the URL to an external website
public int hashCode ()
For documentation, see java.lang.Object
Class Details
Represents a ViaLink to an external website of the supplier of content.
See also:
getVia()
Method Details
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public String getUrl ()
Gets the String representation of the URL to an external website
Returns:
The URL
public int hashCode ()
For documentation, see java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1932
service
The package service is a member of com.here.android.mpa.
Package Summary
service
The service package contains classes related to the mapping service.
Package Details
The service package contains classes related to the mapping service. The classes in this package should not
be imported.
streetlevel
The package streetlevel is a member of com.here.android.mpa.
Package Summary
streetlevel
The streetlevel package provides classes, interfaces, and enumerations that display an interactive
StreetLevelFragment.
Package Details
The streetlevel package provides classes, interfaces, and enumerations that display an interactive
StreetLevelFragment. It also provides related functionality that allows your application to create and add
street level content.
Some key classes and interfaces in this package are:
StreetLevelCoverage
StreetLevelFragment
StreetLevelModel
StreetLevel
StreetLevelGesture
StreetLevelObject
StreetLevelCoverage
This class allows the developer to search whether a given GeoCoordinate is in range of a street level bubble
within a given search radius. The search is asynchronous and is called back to the application via the
interface Listener.
HERE Android SDK Developer's Guide
API Reference
1933
StreetLevelFragment
The StreetLevelFragment class is a UI view that can be embedded into an activity or fragment to render street
level information.
For Example:
<fragment
class="com.here.android.mpa.streetlevel.StreetLevelFragment"
android:id="@+id/mapfragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
StreetLevelModel
Represents a model for street level data. For areas with appropriate street level coverage, applications can
get a StreetLevelModel from a getStreetLevelModel() to render 360-degree street level imagery.
StreetLevel
A StreetLevel object represents a unique street level bubble. This object is retrieved by requesting a bubble
with getStreetLevel(GeoCoordinate, int). For the best experience, the street level coverage should first be
checked with StreetLevelCoverage.
StreetLevelObject
The following is a list objects that can be created by an application to augment the street level experience.
User objects can be added via addStreetLevelObject(StreetLevelObject)
StreetLevelBillboard
StreetLevelIcon
StreetLevelRoute
The following is a list of proxy objects that can be fetched from interacting with a street level bubble. Proxy
objects are returned when the user interacts with a street level and is called back via onObjectsSelected(List)
StreetLevelLink
StreetLevelBuilding
StreetLevel
The class StreetLevel is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevel
extends java.lang.Object
Represents a street level object at a particular geographic location.
[For complete information, see the section Class Details]
See also:
getStreetLevel()
HERE Android SDK Developer's Guide
API Reference
1934
Method Summary
Table 1184: Methods in StreetLevel
Methods
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the center position of the StreetLevel.
public java.util.List <StreetLevelBuilding> getVisibleBuildings ()
Gets the list of StreetLevelBuilding objects shown in the StreetLevel.
public boolean isDownloaded ()
Determines whether street data for the StreetLevel has been downloaded.
Class Details
Represents a street level object at a particular geographic location.
See also:
getStreetLevel()
Method Details
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the center position of the StreetLevel.
Returns:
The GeoCoordinate
public java.util.List <StreetLevelBuilding> getVisibleBuildings ()
Gets the list of StreetLevelBuilding objects shown in the StreetLevel.
Returns:
The list of StreetLevelBuilding objects
public boolean isDownloaded ()
Determines whether street data for the StreetLevel has been downloaded.
Returns:
True if the data has been downloaded, false otherwise
HERE Android SDK Developer's Guide
API Reference
1935
StreetLevelBillboard
The class StreetLevelBillboard is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelBillboard
extends com.here.android.mpa.streetlevel.StreetLevelIconBase,
com.here.android.mpa.streetlevel.StreetLevelObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a street level billboard object.
[For complete information, see the section Class Details]
Constructor Summary
Table 1185: Constructors in StreetLevelBillboard
Constructors
StreetLevelBillboard (GeoCoordinate coordinate, Image image)
Public Constructor
Method Summary
Table 1186: Methods in StreetLevelBillboard
Methods
public float getHeight ()
Gets the current height of a StreetLevelBillboard, in meters.
public StreetLevelBillboardOrientation getOrientation ()
Gets the orientation of the StreetLevelBillboard.
public float getWidth ()
Gets the current width of a StreetLevelBillboard, in meters.
public StreetLevelBillboard setFacadePlacementSize (float width, float height, float minimumDistance,
float maximumDistance)
Sets icon size used in facade placement calculation.
public StreetLevelBillboard setHeight (float height)
Sets a height, in meters, for the StreetLevelBillboard.
public StreetLevelBillboard setOrientation (StreetLevelBillboardOrientation orientation)
Sets the orientation for the StreetLevelBillboard.
public StreetLevelBillboard setSize (float width, float height)
Sets a size for the billboard, in meters.
HERE Android SDK Developer's Guide
API Reference
1936
Methods
public StreetLevelBillboard setWidth (float width)
Sets a width, in meters, for the StreetLevelBillboard.
Class Details
Represents a street level billboard object. Users can add a StreetLevelBillboard object to an on-screen
StreetLevelModel instance by binding it with a StreetLevelFragment object.
Constructor Details
StreetLevelBillboard (GeoCoordinate coordinate, Image image)
Public Constructor
Parameters:
coordinate
The GeoCoordinate for this billboard
image
Image texture to be displayed on this billboard
Throws:
NullPointerException
Passed argument is null
IllegalArgumentException
Passed argument is invalid
Method Details
public float getHeight ()
Gets the current height of a StreetLevelBillboard, in meters.
Returns:
The current height
public StreetLevelBillboardOrientation getOrientation ()
Gets the orientation of the StreetLevelBillboard.
Returns:
The orientation of the StreetLevelBillboard.
public float getWidth ()
HERE Android SDK Developer's Guide
API Reference
1937
Gets the current width of a StreetLevelBillboard, in meters.
Returns:
The current width
public StreetLevelBillboard setFacadePlacementSize (float width, float height,
float minimumDistance, float maximumDistance)
Sets icon size used in facade placement calculation. By default the value specified in setSize(float,
float) is used and each call to setSize(float, float) causes placement recalculation. Once
setFacadePlacementSize(float, float, float, float) is called the value specified is used instead and setSize(float,
float) does not cause facade placement recalculation. It is assumed that facade placement size is an upper
limit of the actual size.
Parameters:
width
Width of the icon in meters.
height
Height of the icon in meters
minimumDistance
Minimum distance at which the size specified is applied.
maximumDistance
Maximum distance at which the size specified is applied.
Returns:
This StreetLevelBillboard object
public StreetLevelBillboard setHeight (float height)
Sets a height, in meters, for the StreetLevelBillboard.
Parameters:
height
Desired height
Returns:
This StreetLevelBillboard object
public StreetLevelBillboard setOrientation (StreetLevelBillboardOrientation
orientation)
Sets the orientation for the StreetLevelBillboard.
Parameters:
HERE Android SDK Developer's Guide
API Reference
1938
orientation
Orientation of the billboard
Returns:
This StreetLevelBillboard object
public StreetLevelBillboard setSize (float width, float height)
Sets a size for the billboard, in meters. If the size is not set, the billboard will not be displayed in the street
level image.
Parameters:
width
Desired width
height
Desired height
Returns:
This StreetLevelBillboard object
public StreetLevelBillboard setWidth (float width)
Sets a width, in meters, for the StreetLevelBillboard.
Parameters:
width
Desired width
Returns:
This StreetLevelBillboard object
StreetLevelBillboardOrientation
The class StreetLevelBillboardOrientation is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelBillboardOrientation
extends java.lang.Object
Encapsulates the orientation for StreetLevelBillboard) objects that users can add to a StreetLevelModel.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
1939
Nested Class Summary
Table 1187: Nested Classes in StreetLevelBillboardOrientation
Nested Classes
public static final enumeration StreetLevelBillboardOrientation.Orientation
This enumeration defines values for billboard orientation options
Constructor Summary
Table 1188: Constructors in StreetLevelBillboardOrientation
Constructors
StreetLevelBillboardOrientation (Orientation orientation, Vector3f normal, Vector3f up)
Public Constructor
Method Summary
Table 1189: Methods in StreetLevelBillboardOrientation
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public Vector3f getNormalVector ()
Gets the 3D normal vector of the billboard
public Orientation getOrientation ()
Gets the billboard orientation mode
public Vector3f getUpVector ()
Gets the 3D up vector of the billboard
public int hashCode ()
For documentation, see java.lang.Object
public void setNormalVector (Vector3f normal)
Sets the normal 3D vector of the billboard
public StreetLevelBillboardOrientation setOrientation (Orientation orientation)
Sets the billboard orientation mode
public void setUpVector (Vector3f up)
Sets the up 3D vector of the billboard
Class Details
Encapsulates the orientation for StreetLevelBillboard) objects that users can add to a StreetLevelModel.
Changes to properties of this interface are reflected in the display of the associated StreetLevelBillboard.
HERE Android SDK Developer's Guide
API Reference
1940
Constructor Details
StreetLevelBillboardOrientation (Orientation orientation, Vector3f normal,
Vector3f up)
Public Constructor
Parameters:
orientation
The StreetLevelBillboardOrientation.Orientation mode for this billboard
normal
The normal Vector3f for this billboard
up
The up Vector3f for this billboard
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
public Vector3f getNormalVector ()
Gets the 3D normal vector of the billboard
Returns:
The 3D normal vector
public Orientation getOrientation ()
Gets the billboard orientation mode
Returns:
Billboard orientation mode
public Vector3f getUpVector ()
Gets the 3D up vector of the billboard
Returns:
The 3D up vector
HERE Android SDK Developer's Guide
API Reference
1941
public int hashCode ()
For documentation, see java.lang.Object
public void setNormalVector (Vector3f normal)
Sets the normal 3D vector of the billboard
Parameters:
normal
Normal 3d vector
Throws:
NullPointerException
Passed argument is null
public StreetLevelBillboardOrientation setOrientation (Orientation orientation)
Sets the billboard orientation mode
Parameters:
orientation
Billboard orientation mode
Returns:
This StreetLevelBillboardOrientation object
public void setUpVector (Vector3f up)
Sets the up 3D vector of the billboard
Parameters:
up
Up 3d vector
Orientation
The enumeration Orientation is a member of
com.here.android.mpa.streetlevel.StreetLevelBillboardOrientation.
Enumeration Summary
public static final enumeration StreetLevelBillboardOrientation.Orientation
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1942
This enumeration defines values for billboard orientation options
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1190: Enum Constants in Orientation
Fields
public static final Orientation FIXED
The billboard is set explicitly using normal and up vectors
public static final Orientation VERTICAL_FIXED
The billboard is always upright, with the horizontal orientation set according to a normal vector
public static final Orientation BILLBOARD
The billboard is always upright and oriented towards the camera
Method Summary
Table 1191: Methods in Orientation
Methods
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelBillboardOrientation.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines values for billboard orientation options
Enum Constant Details
public static final Orientation FIXED
The billboard is set explicitly using normal and up vectors
public static final Orientation VERTICAL_FIXED
The billboard is always upright, with the horizontal orientation set according to a normal vector
public static final Orientation BILLBOARD
The billboard is always upright and oriented towards the camera
HERE Android SDK Developer's Guide
API Reference
1943
Method Details
public static Orientation valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelBillboardOrientation.Orientation[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StreetLevelBuilding
The class StreetLevelBuilding is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelBuilding
extends com.here.android.mpa.streetlevel.StreetLevelProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents all street level building objects that are a visible component of an on-screen
StreetLevelFragment.
[For complete information, see the section Class Details]
See also:
getVisibleBuildings()
Method Summary
Table 1192: Methods in StreetLevelBuilding
Methods
public float getHighlight ()
Gets the current StreetLevelBuilding highlight intensity, a float value within the range of [0..1] where 0 represents
minimum intensity and 1 represents maximum intensity.
public Identifier getIdentifier ()
Gets the unique StreetLevelBuilding identifier, used for binding StreetLevelIcon and StreetLevelBillboard objects.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the position of the StreetLevelBuilding .
HERE Android SDK Developer's Guide
API Reference
1944
Methods
public Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
This method overrides streetlevel.StreetLevelProxyObject.getType(void)
public boolean setHighlight (float intensity)
Sets a highlight intensity for the StreetLevelBuilding , a float value within the range of [0..1] where 0 represents
minimum intensity and 1 represents maximum intensity.
Class Details
Represents all street level building objects that are a visible component of an on-screen
StreetLevelFragment.
See also:
getVisibleBuildings()
Method Details
public float getHighlight ()
Gets the current StreetLevelBuilding highlight intensity, a float value within the range of [0..1] where 0
represents minimum intensity and 1 represents maximum intensity.
Returns:
The current highlight intensity
public Identifier getIdentifier ()
Gets the unique StreetLevelBuilding identifier, used for binding StreetLevelIcon and
StreetLevelBillboard objects.
Returns:
The Identifier for the building
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the position of the StreetLevelBuilding .
Returns:
The GeoCoordinate. A null value is returned if the StreetLevelBuilding is not visible on screen.
public Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
This method overrides streetlevel.StreetLevelProxyObject.getType(void)
HERE Android SDK Developer's Guide
API Reference
1945
public boolean setHighlight (float intensity)
Sets a highlight intensity for the StreetLevelBuilding , a float value within the range of [0..1] where 0
represents minimum intensity and 1 represents maximum intensity. The default value for highlight is 0, which
represents no highlight.
Parameters:
intensity
Desired highlight intensity
Returns:
true if the operation is successful. Returns false otherwise, for example, highlight intensity is not in the
valid range.
StreetLevelCoverage
The class StreetLevelCoverage is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelCoverage
extends java.lang.Object
Represents a class to determine whether specific areas of a map are covered for street level imagery.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1193: Nested Classes in StreetLevelCoverage
Nested Classes
public static abstract interface StreetLevelCoverage.Listener
Represents a listener to provide notification upon completion of a StreetLevelCoverage operation.
public static final enumeration StreetLevelCoverage.ResultCode
Represents values describing possible result types of the coverage check operation
Constructor Summary
Table 1194: Constructors in StreetLevelCoverage
Constructors
StreetLevelCoverage ()
Public constructor.
HERE Android SDK Developer's Guide
API Reference
1946
Method Summary
Table 1195: Methods in StreetLevelCoverage
Methods
public void cancel (GeoCoordinate geoCoordinate)
Cancel coverage check at GeoCoordinate GeoCoordinate, if still pending.
public boolean checkInCoverageZone (GeoCoordinate geoCoordinate, int radius, boolean
useAbsoluteCoverageCheck, Listener listener)
Determines whether the specified GeoCoordinate GeoCoordinate is within the street level coverage zone.
public long getTimeoutLimit ()
Gets a timeout value in milliseconds for coverage check when an outstanding request should be cancelled.
public void setTimeoutLimit (long value)
Sets a timeout value in milliseconds for coverage check when an outstanding request should be cancelled.
Class Details
Represents a class to determine whether specific areas of a map are covered for street level imagery.
Constructor Details
StreetLevelCoverage ()
Public constructor.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
Method Details
public void cancel (GeoCoordinate geoCoordinate)
Cancel coverage check at GeoCoordinate GeoCoordinate, if still pending.
Parameters:
geoCoordinate
The location where coverage-check should be cancelled
public boolean checkInCoverageZone (GeoCoordinate geoCoordinate, int radius,
boolean useAbsoluteCoverageCheck, Listener listener)
Determines whether the specified GeoCoordinate GeoCoordinate is within the street level coverage zone.
HERE Android SDK Developer's Guide
API Reference
1947
Note: use the onCoverageCheckCompleted(GeoCoordinate, int, StreetLevelCoverage.ResultCode) callback to
get the result.
Parameters:
geoCoordinate
A GeoCoordinate to check for containment within the coverage zone
radius
A int representing the radius in meters
useAbsoluteCoverageCheck
This argument (when true) performs a precise street level coverage check. When enabled, additional
map data maybe downloaded which may increase the time to perform the check. It is recommended the
absolute coverage check be performed at high zoom levels (close to streel level) or when an accurate
coverage check is required. At low zoom levels or when an approximate coverage check is needed, pass
false.
listener
Callback listener.
Returns:
True if coverage request successfully submitted. False, if pending request still in-progress.
public long getTimeoutLimit ()
Gets a timeout value in milliseconds for coverage check when an outstanding request should be cancelled.
Default value is -1, which means there will not be a timeout limit.
Returns:
Timeout value in millisecond
public void setTimeoutLimit (long value)
Sets a timeout value in milliseconds for coverage check when an outstanding request should be cancelled.
Caller of the request will received a callback with CANCELLED.
Parameters:
value
Timeout value in millisecond. Acceptable values can be either a positive number or -1 to indicate no
timeout.
Throws:
IllegalArgumentException
if the timeout value is invalid.
HERE Android SDK Developer's Guide
API Reference
1948
Listener
The interface Listener is a member of com.here.android.mpa.streetlevel.StreetLevelCoverage.
Interface Summary
public static abstract interface StreetLevelCoverage.Listener
Represents a listener to provide notification upon completion of a StreetLevelCoverage operation.
[For complete information, see the section Interface Details]
Method Summary
Table 1196: Methods in Listener
Methods
public abstract void onCoverageCheckCompleted (GeoCoordinate coordinate, int distanceToCoverage,
ResultCode result)
A callback indicating that the checkInCoverageZone(GeoCoordinate, int, boolean, StreetLevelCoverage.Listener) method has
completed its operation.
Interface Details
Represents a listener to provide notification upon completion of a StreetLevelCoverage operation.
Method Details
public abstract void onCoverageCheckCompleted (GeoCoordinate coordinate, int
distanceToCoverage, ResultCode result)
A callback indicating that the checkInCoverageZone(GeoCoordinate, int, boolean,
StreetLevelCoverage.Listener) method has completed its operation.
Note: this callback is sent from a callback thread, not from the UI thread.
Parameters:
coordinate
The GeoCoordinate GeoCoordinate used in the coverage check
distanceToCoverage
The distance (in meters) from the coordinate to the nearest coverage location.
result
A StreetLevelCoverage.ResultCode indicating the result of checking for street level coverage
HERE Android SDK Developer's Guide
API Reference
1949
ResultCode
The enumeration ResultCode is a member of com.here.android.mpa.streetlevel.StreetLevelCoverage.
Enumeration Summary
public static final enumeration StreetLevelCoverage.ResultCode
extends java.lang.Enum, java.lang.Object
Represents values describing possible result types of the coverage check operation
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1197: Enum Constants in ResultCode
Fields
public static final ResultCode UNKNOWN_COVERAGE
The coverage for the selected area is unknown.
public static final ResultCode HAS_COVERAGE
The selected area is within the street level coverage zone.
public static final ResultCode HAS_NO_COVERAGE
The selected area is not within the street level coverage zone.
public static final ResultCode NETWORK_ERROR
Request could not be completed because of a network error.
public static final ResultCode CANCELLED
Request was cancelled.
Method Summary
Table 1198: Methods in ResultCode
Methods
public static ResultCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelCoverage.ResultCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing possible result types of the coverage check operation
HERE Android SDK Developer's Guide
API Reference
1950
Enum Constant Details
public static final ResultCode UNKNOWN_COVERAGE
The coverage for the selected area is unknown.
public static final ResultCode HAS_COVERAGE
The selected area is within the street level coverage zone.
public static final ResultCode HAS_NO_COVERAGE
The selected area is not within the street level coverage zone.
public static final ResultCode NETWORK_ERROR
Request could not be completed because of a network error.
public static final ResultCode CANCELLED
Request was cancelled.
Method Details
public static ResultCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelCoverage.ResultCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StreetLevelFragment
The class StreetLevelFragment is a member of com.here.android.mpa.streetlevel .
Class Summary
public class StreetLevelFragment
HERE Android SDK Developer's Guide
API Reference
1951
extends java.lang.Object
Represents a street level fragment.
[For complete information, see the section Class Details]
See also:
android.app.Fragment
Constructor Summary
Table 1199: Constructors in StreetLevelFragment
Constructors
StreetLevelFragment ()
Constructor
Method Summary
Table 1200: Methods in StreetLevelFragment
Methods
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle.
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible street
level area to the edge of the logo.
public void getScreenCapture (OnScreenCaptureListener listener)
Gets the full screen bitmap for the android.view.View.
public StreetLevelGesture getStreetLevelGesture ()
Gets the StreetLevelGesture interface for the StreetLevelModel, used to enable or disable gestures.
public StreetLevelModel getStreetLevelModel ()
Retrieve the StreetLevelModel.
public void init (OnEngineInitListener listener)
User of StreetLevelFragment must call this function after the fragment is first attached to its activity.
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
User of StreetLevelFragment must call this function after the fragment is created.
HERE Android SDK Developer's Guide
API Reference
1952
Methods
public void init (Context context, MapVariant variant, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
User of StreetLevelFragment must call this function after the fragment is created.
public void init (ApplicationContext context, OnEngineInitListener listener)
User of StreetLevelFragment must call this function after the fragment is created.
public View onCreateView (LayoutInflater inflater, ViewGroup container, Bundle
savedInstanceState)
Called when a fragment is first attached to its activity.
public void onDestroy ()
Called when the fragment is destroyed.
public void onDestroyView ()
Called when the view previously created by onCreateView(LayoutInflater, ViewGroup, Bundle) has been detached from the
fragment.
public void onInflate (Activity activity, AttributeSet attrs, Bundle savedInstanceState)
Called when a fragment is being created as part of a view layout inflation, typically from setting the content view of an
activity.
public void onPause ()
Called when the Fragment is no longer resumed.
public void onResume ()
Called when the fragment is visible to the user and actively running.
public void onSaveInstanceState (Bundle outState)
Called when this fragment has been asked to save its current dynamic state.
public void setBlankStreetLevelImageVisible (boolean visible)
Request the view to draw "black" so a model can be reused without showing the previous street level image.This is useful in
case an application tries to display the street level image for a location where street level coverage is not available.This API
ensures that a "black" image is displayed if there is no street level coverage for the new location.
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the StreetLevelFragment's boundary, for the placement of the
HERE copyright logo.
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible street level area to
the edge of the logo (depending on the placement).If the copyright logo position is BOTTOM_LEFT the vertical offset is from
to the top of the copyright text.If copyright logo position is BOTTOM_RIGHT the vertical offset is from the top of the Report
Image link.
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the StreetLevelFragment.
HERE Android SDK Developer's Guide
API Reference
1953
Class Details
Represents a street level fragment. This is the fragment class designed to handle all UI-related use cases,
including rendering and screen touch events.
Note: each StreetLevelFragment must be bound to a StreetLevelModel instance, and StreetLevel objects
should be persisted during application runtime. StreetLevel objects live and expire according to the
associated activity's lifecycle. This fragment has android.app.Fragment#setRetainInstance(boolean) set, and
therefore the StreetLevelModel will retain any properties applied to it during an application's lifetime.
A StreetLevelFragment is defined in an Android layout XML file. For example:
<fragment
class="com.here.android.mpa.streetlevel.StreetLevelFragment"
android:id="@+id/streetlevelfragment"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_weight="1" />
Note: StreetLevelFragment automatically handles pause and resume of MapEngine during activity state
changes, thus it is not necessary for the activity that owns StreetLevelFragment(s) to manually call onPause()
/ onResume() during the activity's onPause() and onResume(). However, considerations should be made
regarding how much processing should be done in the onResume() method. Performing significant amounts
of processing may delay the view rendering in cases such as device orientation change. It is recommended to
use a specifically designated handler for organizing the amount of processing to be done in such cases.
See also:
android.app.Fragment
Constructor Details
StreetLevelFragment ()
Constructor
Method Details
public Rect getCopyrightBoundaryRect ()
Gets the current HERE copyright logo's boundary rectangle. Returns null if a boundary rect has not been set
previously.
Returns:
The copyright logo's boundary rect. null if a boundary rect has not been set previously.
See also:
setCopyrightBoundaryRect(Rect)
HERE Android SDK Developer's Guide
API Reference
1954
public int getCopyrightLogoHeight ()
Returns the height of the copyright logo.
This method only returns a valid value once fragment initialization has taken completed.
Returns:
The height of the copyright logo, in number of pixels
public int getCopyrightLogoWidth ()
Returns the width of the copyright logo.
This method only returns a valid value once fragment initialization has completed.
Returns:
The width of the copyright logo, in number of pixels
public int getCopyrightMargin ()
Returns the current margin for the HERE copyright logo, in number of pixels, as an offset from the edge of
the visible street level area to the edge of the logo. If the copyright logo position is BOTTOM_LEFT the vertical
offset is from to the top of the copyright text.If copyright logo position is BOTTOM_RIGHT the vertical offset
is from the top of the Report Image link.The default copyright margin values is set to one-third of the logo
width.
This method only returns a valid value once fragment initialization has taken place.
Returns:
The current offset from the edge of the StreetLevelFragment, in number of pixels
public void getScreenCapture (OnScreenCaptureListener listener)
Gets the full screen bitmap for the android.view.View. This API can be used to capture a screen shot
of the StreetLevelFragment The API is asynchronous and will callback once the operation is completed via
OnScreenCaptureListener. Note the StreetLevelFragment must be visible to create the screen capture.
Parameters:
listener
A OnScreenCaptureListener to callback on screencapture completion.
public StreetLevelGesture getStreetLevelGesture ()
Gets the StreetLevelGesture interface for the StreetLevelModel, used to enable or disable gestures.
Returns:
The StreetLevelGesture
HERE Android SDK Developer's Guide
API Reference
1955
public StreetLevelModel getStreetLevelModel ()
Retrieve the StreetLevelModel.
Returns:
the StreetLevelModel associated with this fragment
public void init (OnEngineInitListener listener)
User of StreetLevelFragment must call this function after the fragment is first attached to its activity. This
automatically initialises the Restricted Map Factory and create a StreetLevelModel for use. This method
is a method that should be used for fragments embedded in a layout XML. Do not use this method when
StreetLevelFragment is created programatically.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
listener
A OnEngineInitListener object will be called when StreetLevelFragment initialization is finished. A null
object can be supplied if caller do not expect any notification when initialization completes.
See also:
OnEngineInitListener
init(ApplicationContext, OnEngineInitListener)
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.4.
Use (com.here.android.mpa.common.MapEngine#init(com.here.android.mpa.common.ApplicationContext, instead.
User of StreetLevelFragment must call this function after the fragment is created. This automatically
initialises the Restricted Map Factory and create a StreetLevelModel for use. Do not use this method when
StreetLevelFragment is created programatically.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
context
Context of the application.
listener
A OnEngineInitListener object will be called when StreetLevelFragment initialization is finished. A null
object can be supplied if caller do not expect any notification when initialization completes.
See also:
HERE Android SDK Developer's Guide
API Reference
1956
OnEngineInitListener
init(OnEngineInitListener)
public void init (Context context, MapVariant variant, OnEngineInitListener
listener)
Deprecated: As of SDK 3.4.
Use MapEngine#init(ApplicationContext, OnEngineInitListener) instead.
User of StreetLevelFragment must call this function after the fragment is created. This automatically
initialises the Restricted Map Factory and create a StreetLevelModel for use. Do not use this method when
StreetLevelFragment is created programatically.
This method can configure map variant which will be used by MapEngine. If initialization fails -
OPERATION_NOT_ALLOWED will be reported. Currently following variants are supported: - GLOBAL - initialize
MapEngine to use international map variant; - KOREA - initialize MapEngine to use Korean map variant; -
null - initialize MapEngine to use stored map variant or international map variant for first run. This method
is used to configure MapEngine to use certain map variant. If MapEngine was already configured and
passed variant differs - error will be reported and initialization fails.
Parameters:
context
Context of the application.
variant
Map variant to use.
listener
A OnEngineInitListener object will be called when StreetLevelFragment initialization is finished. A null
object can be supplied if caller do not expect any notification when initialization completes.
See also:
OnEngineInitListener
init(OnEngineInitListener)
public void init (ApplicationContext context, OnEngineInitListener listener)
User of StreetLevelFragment must call this function after the fragment is created. This automatically
initialises the Restricted Map Factory and create a StreetLevelModel for use. Do not use this method when
StreetLevelFragment is created programatically.
This method will initialize MapEngine with ApplicationContext to be used during initialization.
Parameters:
context
ApplicationContext to be used during initialization.
listener
HERE Android SDK Developer's Guide
API Reference
1957
A OnEngineInitListener object will be called when StreetLevelFragment initialization is finished. A null
object can be supplied if caller do not expect any notification when initialization completes.
See also:
OnEngineInitListener
init(OnEngineInitListener)
public View onCreateView (LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState)
Called when a fragment is first attached to its activity. A Street Level View is automatically setup to cover the
full size of the StreetLevelFragment dimension.
Parameters:
inflater
container
savedInstanceState
See also:
android.app.Fragment#onAttach(android.app.Activity)
public void onDestroy ()
Called when the fragment is destroyed.
public void onDestroyView ()
Called when the view previously created by onCreateView(LayoutInflater, ViewGroup, Bundle)
has been detached from the fragment. The StreetLevelModel created by the fragment will be
detached from the fragment and destroyed automatically as part of the cleanup process. The
android.view.android.view.View.OnTouchListener will also be disconnected from the fragment.
public void onInflate (Activity activity, AttributeSet attrs, Bundle
savedInstanceState)
Called when a fragment is being created as part of a view layout inflation, typically from setting the content
view of an activity. This may be called immediately after the fragment is created from a tag in a layout file.
Parameters:
activity
attrs
savedInstanceState
See also:
android.app.Fragment#onInflate(android.app.Activity, android.util.AttributeSet, android.os.Bundle)
HERE Android SDK Developer's Guide
API Reference
1958
public void onPause ()
Called when the Fragment is no longer resumed. All Map Engine activities will be paused automatically.
See also:
android.app.Fragment#onPause()
public void onResume ()
Called when the fragment is visible to the user and actively running. All Map Engine activities will be resumed
automatically.
See also:
android.app.Fragment#onResume()
public void onSaveInstanceState (Bundle outState)
Called when this fragment has been asked to save its current dynamic state. Saving its current state allows
for it to be later reconstructed in a new instance.
Parameters:
outState
See also:
android.app.Fragment#onSaveInstanceState(android.os.Bundle)
public void setBlankStreetLevelImageVisible (boolean visible)
Request the view to draw "black" so a model can be reused without showing the previous street level
image.This is useful in case an application tries to display the street level image for a location where street
level coverage is not available.This API ensures that a "black" image is displayed if there is no street level
coverage for the new location.
Parameters:
visible
Boolean value to indicate if the blank image represented by the "black" model is visible.
public void setCopyrightBoundaryRect (Rect rect)
Sets a rectangle, in pixels, relative to the top left corner of the StreetLevelFragment's boundary, for the
placement of the HERE copyright logo.
If the specified rectangle is not contained completely within the current visible street level area, their area of
intersection will be used instead of the specified rectangle's area. The copyright logo and copyright margin
must fit into the rectangle, otherwise specified rectangle will be ignored.
HERE Android SDK Developer's Guide
API Reference
1959
The rectangle is reset upon screen rotation or upon screen re-creation, or it can be done by setting a null -
Rect .
Parameters:
rect
A Rect representing the desired rectangular container to be used for positioning the copyright logo. Use
null Rect to reset the boundary container.
Throws:
IllegalArgumentException
if Rect supplied is invalid
public void setCopyrightMargin (int margin)
Sets a margin for the HERE copyright logo, in number of pixels, as an offset from the edge of the visible
street level area to the edge of the logo (depending on the placement).If the copyright logo position
is BOTTOM_LEFT the vertical offset is from to the top of the copyright text.If copyright logo position is
BOTTOM_RIGHT the vertical offset is from the top of the Report Image link. The default copyright margin
values is set to one-third of the logo width.
Parameters:
margin
Desired offset from the edge of the StreetLevelFragment
public void setOnTouchListener (View.OnTouchListener listener)
Sets an android.view.OnTouchListener to be invoked whenever a touch event is sent to the
StreetLevelFragment.
Parameters:
listener
An android.view.OnTouchListener to set for the StreetLevelFragment
See also:
android.view.View.OnTouchListener
StreetLevelGesture
The class StreetLevelGesture is a member of com.here.android.mpa.streetlevel .
Class Summary
public class StreetLevelGesture
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
1960
Encapsulates all user interactions and gestures that are applicable to a StreetLevelFragment.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1201: Nested Classes in StreetLevelGesture
Nested Classes
public static abstract interface StreetLevelGesture.OnGestureListener
Event Listener interface for gesture events.
Method Summary
Table 1202: Methods in StreetLevelGesture
Methods
public void addOnGestureListener (OnGestureListener listener)
Adds a StreetLevelGesture.OnGestureListener to listen for map gesture events.
public boolean isDoubleTapEnabled ()
Gets the boolean indicating whether double tap is enabled for the StreetLevelGesture.
public boolean isPinchEnabled ()
Gets the boolean indicating whether pinch is enabled for the StreetLevelGesture.
public boolean isRotationEnabled ()
Gets the boolean indicating whether rotation is enabled for the StreetLevelGesture.
public boolean isTapEnabled ()
Gets the boolean indicating whether tap is enabled for the StreetLevelGesture .
public void removeOnGestureListener (OnGestureListener listener)
Removes an existing StreetLevelGesture.OnGestureListener.
public StreetLevelGesture setAllGesturesEnabled (boolean enabled)
Simultaneously sets every possible kind of gesture interaction to be either enabled or disabled for the StreetLevelGesture.
public StreetLevelGesture setDoubleTapEnabled (boolean enabled)
Sets double tap interaction to be either enabled or disabled for the StreetLevelGesture.
public StreetLevelGesture setPinchEnabled (boolean enabled)
Sets pinch interaction to be either enabled or disabled for the StreetLevelGesture.
public StreetLevelGesture setRotationEnabled (boolean enabled)
Sets rotation interaction to be either enabled or disabled for the StreetLevelGesture .
public StreetLevelGesture setTapEnabled (boolean enabled)
Sets tap interaction to be either enabled or disabled for the StreetLevelGesture.
HERE Android SDK Developer's Guide
API Reference
1961
Class Details
Encapsulates all user interactions and gestures that are applicable to a StreetLevelFragment. By default all
gestures are enabled.
Method Details
public void addOnGestureListener (OnGestureListener listener)
Adds a StreetLevelGesture.OnGestureListener to listen for map gesture events.
Note: after you add a StreetLevelGesture.OnGestureListener to an application, remember to call
removeOnGestureListener(OnGestureListener) if you no longer need to listen for street level gesture events
and want to free up application resources.
Parameters:
listener
A StreetLevelGesture.OnGestureListener to add to this StreetLevelGesture
See also:
removeOnGestureListener(OnGestureListener)
public boolean isDoubleTapEnabled ()
Gets the boolean indicating whether double tap is enabled for the StreetLevelGesture.
Returns:
True if double tap is enabled, false otherwise
public boolean isPinchEnabled ()
Gets the boolean indicating whether pinch is enabled for the StreetLevelGesture.
Returns:
True if pinch is enabled, false otherwise
public boolean isRotationEnabled ()
Gets the boolean indicating whether rotation is enabled for the StreetLevelGesture.
Returns:
True if rotation is enabled, false otherwise
public boolean isTapEnabled ()
Gets the boolean indicating whether tap is enabled for the StreetLevelGesture .
Returns:
HERE Android SDK Developer's Guide
API Reference
1962
True if tap is enabled, false otherwise
public void removeOnGestureListener (OnGestureListener listener)
Removes an existing StreetLevelGesture.OnGestureListener. Call this method to free up application resources
once you no longer need to listen for map gesture events.
Parameters:
listener
A StreetLevelGesture.OnGestureListener to remove from this StreetLevelGesture
public StreetLevelGesture setAllGesturesEnabled (boolean enabled)
Simultaneously sets every possible kind of gesture interaction to be either enabled or disabled for the
StreetLevelGesture.
Parameters:
enabled
A boolean specifying whether all gestures are enabled
Returns:
This StreetLevelGesture object
public StreetLevelGesture setDoubleTapEnabled (boolean enabled)
Sets double tap interaction to be either enabled or disabled for the StreetLevelGesture.
Parameters:
enabled
A boolean specifying whether double tap is enabled
Returns:
This StreetLevelGesture object
public StreetLevelGesture setPinchEnabled (boolean enabled)
Sets pinch interaction to be either enabled or disabled for the StreetLevelGesture.
Parameters:
enabled
A boolean specifying whether pinch is enabled
Returns:
This StreetLevelGesture object
HERE Android SDK Developer's Guide
API Reference
1963
public StreetLevelGesture setRotationEnabled (boolean enabled)
Sets rotation interaction to be either enabled or disabled for the StreetLevelGesture .
Parameters:
enabled
A boolean specifying whether rotation is enabled
Returns:
This StreetLevelGesture object
public StreetLevelGesture setTapEnabled (boolean enabled)
Sets tap interaction to be either enabled or disabled for the StreetLevelGesture.
Parameters:
enabled
A boolean specifying whether tap is enabled
Returns:
This StreetLevelGesture object
OnGestureListener
The interface OnGestureListener is a member of com.here.android.mpa.streetlevel.StreetLevelGesture.
Interface Summary
public static abstract interface StreetLevelGesture.OnGestureListener
Event Listener interface for gesture events.
[For complete information, see the section Interface Details]
Nested Class Summary
Table 1203: Nested Classes in OnGestureListener
Nested Classes
public static abstract class StreetLevelGesture.OnGestureListener.OnGestureListenerAdapter
Default implementation for the OnGestureListener interface.
HERE Android SDK Developer's Guide
API Reference
1964
Method Summary
Table 1204: Methods in OnGestureListener
Methods
public abstract boolean onCompassSelected ()
A callback indicating that the compass within the StreetLevelFragment has been selected.
public abstract boolean onDoubleTap (PointF p)
A callback indicating the detection of a double tap user gesture within the StreetLevelFragment.
public abstract boolean onObjectsSelected (java.util.List <StreetLevelSelectedObject>
selectedObjects)
A callback indicating that one or more objects within the StreetLevelFragment has been selected.
public abstract boolean onPinchZoom (float scaleFactor)
A callback indicating the detection of a pinch-to-zoom user gesture within the StreetLevelFragment.
public abstract boolean onRotate (PointF from, PointF to)
A callback indicating the detection of a rotation or tilt user gesture within the StreetLevelFragment.
public abstract boolean onTap (PointF p)
A callback indicating the detection of a tap user gesture within the StreetLevelFragment.
Interface Details
Event Listener interface for gesture events. Please use StreetLevelGesture.OnGestureListener if all events are
necessary and StreetLevelGesture.OnGestureListener.OnGestureListenerAdapter if some events are required.
This interface can be added via StreetLevelGesture.addOnGestureListener(OnGestureListener) and removed
via StreetLevelGesture.removeOnGestureListener(OnGestureListener). Please see StreetLevelGesture for a full
set of configurable APIs.
Method Details
public abstract boolean onCompassSelected ()
A callback indicating that the compass within the StreetLevelFragment has been selected.
Returns:
True if the selection has been consumed (which prevents the default StreetLevelFragment compass selection
behavior), false otherwise
public abstract boolean onDoubleTap (PointF p)
A callback indicating the detection of a double tap user gesture within the StreetLevelFragment.
Parameters:
p
A PointF representing the on-screen point of the double-tap gesture
HERE Android SDK Developer's Guide
API Reference
1965
Returns:
True if the tap has been consumed (which prevents the default StreetLevelFragment double tap behavior),
false otherwise
public abstract boolean onObjectsSelected (java.util.List
<StreetLevelSelectedObject> selectedObjects)
A callback indicating that one or more objects within the StreetLevelFragment has been selected.
Parameters:
selectedObjects
A list of StreetLevelSelectedObject objects that have been selected
Returns:
True if the selection has been consumed (which prevents the default StreetLevelFragment object selection
behavior), false otherwise
public abstract boolean onPinchZoom (float scaleFactor)
A callback indicating the detection of a pinch-to-zoom user gesture within the StreetLevelFragment.
Parameters:
scaleFactor
A scale factor relative to the points of the two simultaneous touches at separate screen coordinates
Returns:
True if consumed (which prevents the default StreetLevelFragment zoom-in or zoom-out behavior), false
otherwise
public abstract boolean onRotate (PointF from, PointF to)
A callback indicating the detection of a rotation or tilt user gesture within the StreetLevelFragment.
Parameters:
from
A android.graphics.PointF representing the on-screen point where the user first touched the
screen
to
A android.graphics.PointF representing the on-screen point where the user removed their finger
from the screen
Returns:
True if consumed (which prevents the default StreetLevelFragment rotate-to-here behavior), false otherwise
HERE Android SDK Developer's Guide
API Reference
1966
public abstract boolean onTap (PointF p)
A callback indicating the detection of a tap user gesture within the StreetLevelFragment.
Parameters:
p
The point coordinate of the tap
Returns:
True if the tap has been consumed (which prevents the default StreetLevelFragment tap behavior), false
otherwise
OnGestureListenerAdapter
The class OnGestureListenerAdapter is a member of
com.here.android.mpa.streetlevel.StreetLevelGesture.OnGestureListener.
Class Summary
public static abstract class StreetLevelGesture.OnGestureListener.OnGestureListenerAdapter
implements com.here.android.mpa.streetlevel.StreetLevelGesture.OnGestureListener
extends java.lang.Object
Default implementation for the OnGestureListener interface.
[For complete information, see the section Class Details]
See also:
StreetLevelGesture.OnGestureListener
Constructor Summary
Table 1205: Constructors in OnGestureListenerAdapter
Constructors
OnGestureListenerAdapter ()
Method Summary
Table 1206: Methods in OnGestureListenerAdapter
Methods
public boolean onCompassSelected ()
A callback indicating that the compass within the StreetLevelFragment has been selected.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onCompassSelected(void)
HERE Android SDK Developer's Guide
API Reference
1967
Methods
public boolean onDoubleTap (PointF p)
A callback indicating the detection of a double tap user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onDoubleTap(PointF)
public boolean onObjectsSelected (java.util.List <StreetLevelSelectedObject> selectedObjects)
A callback indicating that one or more objects within the StreetLevelFragment has been selected.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onObjectsSelected(List)
public boolean onPinchZoom (float scaleFactor)
A callback indicating the detection of a pinch-to-zoom user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onPinchZoom(float)
public boolean onRotate (PointF from, PointF to)
A callback indicating the detection of a rotation or tilt user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onRotate(PointF, PointF)
public boolean onTap (PointF p)
A callback indicating the detection of a tap user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onTap(PointF)
Class Details
Default implementation for the OnGestureListener interface. Users may use this abstract class and overload
specific methods to have a smaller code footprint.
See also:
StreetLevelGesture.OnGestureListener
Constructor Details
OnGestureListenerAdapter ()
Method Details
public boolean onCompassSelected ()
A callback indicating that the compass within the StreetLevelFragment has been selected.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onCompassSelected(void)
public boolean onDoubleTap (PointF p)
A callback indicating the detection of a double tap user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onDoubleTap(PointF)
Parameters:
HERE Android SDK Developer's Guide
API Reference
1968
p
public boolean onObjectsSelected (java.util.List <StreetLevelSelectedObject>
selectedObjects)
A callback indicating that one or more objects within the StreetLevelFragment has been selected.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onObjectsSelected(List)
Parameters:
selectedObjects
public boolean onPinchZoom (float scaleFactor)
A callback indicating the detection of a pinch-to-zoom user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onPinchZoom(float)
Parameters:
scaleFactor
public boolean onRotate (PointF from, PointF to)
A callback indicating the detection of a rotation or tilt user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onRotate(PointF, PointF)
Parameters:
from
to
public boolean onTap (PointF p)
A callback indicating the detection of a tap user gesture within the StreetLevelFragment.
This method overrides streetlevel.StreetLevelGesture.OnGestureListener.onTap(PointF)
Parameters:
p
StreetLevelIcon
The class StreetLevelIcon is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelIcon
HERE Android SDK Developer's Guide
API Reference
1969
extends com.here.android.mpa.streetlevel.StreetLevelIconBase,
com.here.android.mpa.streetlevel.StreetLevelObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a class for all street-level icon objects.
[For complete information, see the section Class Details]
Constructor Summary
Table 1207: Constructors in StreetLevelIcon
Constructors
StreetLevelIcon (GeoCoordinate coordinate, Image image)
Public Constructor
Method Summary
Table 1208: Methods in StreetLevelIcon
Methods
public Identifier getAttachmentIdentifier ()
Gets the Identifier for the building to which the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard) is
attached to.
public StreetLevelIconSize getSize ()
Gets the current StreetLevelIconSize of the StreetLevelIcon.
public StreetLevelIcon setAttachmentIdentifier (Identifier identifier)
Attaches street level icon object to a StreetLevelBuilding with specified Identifier .
public StreetLevelIcon setSize (StreetLevelIconSize size)
Sets a StreetLevelIconSize for the StreetLevelIcon.
Class Details
Represents a class for all street-level icon objects. Users can add a StreetLevelIcon object to an on-screen
StreetLevelModel instance by binding it with a StreetLevelFragment object.
Constructor Details
StreetLevelIcon (GeoCoordinate coordinate, Image image)
Public Constructor
Parameters:
coordinate
The location for this icon
image
HERE Android SDK Developer's Guide
API Reference
1970
The logo image for this icon
Method Details
public Identifier getAttachmentIdentifier ()
Gets the Identifier for the building to which the StreetLevelIconBase ( StreetLevelIcon or
StreetLevelBillboard) is attached to.
Returns:
The attached building identifier or null in case icon or billboard is not attached to a building
public StreetLevelIconSize getSize ()
Gets the current StreetLevelIconSize of the StreetLevelIcon.
Returns:
The StreetLevelIconSize
public StreetLevelIcon setAttachmentIdentifier (Identifier identifier)
Attaches street level icon object to a StreetLevelBuilding with specified Identifier .
Use null value to remove attachment.
Parameters:
identifier
Desired Identifier for the icon or billboard
Returns:
This StreetLevelIcon object
public StreetLevelIcon setSize (StreetLevelIconSize size)
Sets a StreetLevelIconSize for the StreetLevelIcon. If the size is not set, the icon will not be displayed in the
street-level image.
Parameters:
size
Desired StreetLevelIconSize for the StreetLevelIcon
Returns:
This StreetLevelIcon object
HERE Android SDK Developer's Guide
API Reference
1971
StreetLevelIconBase
The class StreetLevelIconBase is a member of com.here.android.mpa.streetlevel .
Class Summary
public abstract class StreetLevelIconBase
extends com.here.android.mpa.streetlevel.StreetLevelObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a base class for all image-based street level objects that users can add to a StreetLevelModel.
[For complete information, see the section Class Details]
Method Summary
Table 1209: Methods in StreetLevelIconBase
Methods
public PointF getAnchorPoint ()
Gets the array of float values representing the current X-coordinate (horizontal coordinate) and Y-coordinate (vertical
coordinate) for the anchor point for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard).
public Identifier getAttachmentIdentifier ()
Gets the Identifier for the building to which the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard) is attached to.
public PointF getBottomRightTextureCoordinate ()
Gets bottom right texture coordinate.
public StreetLevelIconPlacement getPlacementMode ()
Gets mode for calculating the final display position in of the street level image base object.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the current geographical location of the StreetLevelIconBase ( StreetLevelIcon or
StreetLevelBillboard).
public PointF getTopLeftTextureCoordinate ()
Gets top left texture coordinate.
public float getTransparency ()
Gets the current transparency for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard), a float value between
0 (fully transparent) and 1 (fully opaque).
public void setAnchorPoint (PointF anchor)
Sets an anchor point for the StreetLevelIconBase, for example a StreetLevelIcon or StreetLevelBillboard.
public StreetLevelIconBase setAttachmentIdentifier (Identifier identifier)
Attaches street level icon object to a StreetLevelBuilding with specified Identifier.
public void setImage (Image icon)
Sets an Image for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard).
HERE Android SDK Developer's Guide
API Reference
1972
Methods
public void setPlacementMode (StreetLevelIconPlacement placement)
Sets mode for calculating the final display position of the street level image base object.
public void setPosition (GeoCoordinate coordinate)
Sets a GeoCoordinate representing the position for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard).
public void setTextureCoordinates (PointF topLeft, PointF bottomRight)
Sets the extent of texture coordinates.
public void setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard).
Class Details
Represents a base class for all image-based street level objects that users can add to a StreetLevelModel.
This interface serves as a generalization (or abstract base) for several more specific street level object types,
bundling their common properties. Users can add the following types of image-based street level objects to
a StreetLevelModel:
StreetLevelIcon
StreetLevelBillboard
Method Details
public PointF getAnchorPoint ()
Gets the array of float values representing the current X-coordinate (horizontal coordinate) and Y-
coordinate (vertical coordinate) for the anchor point for the StreetLevelIconBase ( StreetLevelIcon or
StreetLevelBillboard).
Returns:
Anchor Point of the icon or null in case the retrieval fails
public Identifier getAttachmentIdentifier ()
Gets the Identifier for the building to which the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard)
is attached to.
Returns:
The attached building identifier or null in case icon or billboard is not attached to a building
public PointF getBottomRightTextureCoordinate ()
Gets bottom right texture coordinate.
Returns:
Bottom right texture coordinate or null in case the retrieval fails
HERE Android SDK Developer's Guide
API Reference
1973
public StreetLevelIconPlacement getPlacementMode ()
Gets mode for calculating the final display position in of the street level image base object.
Returns:
The current placement mode
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the current geographical location of the StreetLevelIconBase (
StreetLevelIcon or StreetLevelBillboard).
Returns:
The GeoCoordinate
public PointF getTopLeftTextureCoordinate ()
Gets top left texture coordinate.
Returns:
Top left texture coordinate or null in case the retrieval fails
public float getTransparency ()
Gets the current transparency for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard), a float
value between 0 (fully transparent) and 1 (fully opaque).
Returns:
The current transparency
public void setAnchorPoint (PointF anchor)
Sets an anchor point for the StreetLevelIconBase, for example a StreetLevelIcon or StreetLevelBillboard.
An anchor point specifies a point within an icon. When the icon is drawn inside a StreetLevelFragment, the
anchor point should coincide with the exact location of the icon.
Parameters:
anchor
The anchor point. Desired horizontal and vertical coordinate for the anchor must be within the range of
[0..1]
Throws:
NullPointerException
Passed argument is null
HERE Android SDK Developer's Guide
API Reference
1974
public StreetLevelIconBase setAttachmentIdentifier (Identifier identifier)
Attaches street level icon object to a StreetLevelBuilding with specified Identifier.
Use null value to remove current attachment.
Parameters:
identifier
Desired Identifier for the icon or billboard
Returns:
The updated StreetLevelIconBase object itself.
Throws:
NumberFormatException
Passed argument is of incorrect format
NullPointerException
Passed argument is null
public void setImage (Image icon)
Sets an Image for the StreetLevelIconBase ( StreetLevelIcon or StreetLevelBillboard).
Parameters:
icon
Desired Image for the icon or billboard
Throws:
IllegalArgumentException
Passed argument is invalid
NullPointerException
Passed argument is null
See also:
setAnchorPoint(PointF)
public void setPlacementMode (StreetLevelIconPlacement placement)
Sets mode for calculating the final display position of the street level image base object.
Parameters:
placement
A StreetLevelIconPlacement representing the horizontal and vertical placement properties of the street
level image base object StreetLevelIconPlacement
HERE Android SDK Developer's Guide
API Reference
1975
public void setPosition (GeoCoordinate coordinate)
Sets a GeoCoordinate representing the position for the StreetLevelIconBase ( StreetLevelIcon or
StreetLevelBillboard).
Parameters:
coordinate
Desired GeoCoordinate position for the icon or billboard
Throws:
IllegalArgumentException
Passed argument is invalid
NullPointerException
Passed argument is null
public void setTextureCoordinates (PointF topLeft, PointF bottomRight)
Sets the extent of texture coordinates.
Parameters:
topLeft
Top left texture coordinate, default (0, 0).
bottomRight
Bottom right texture coordinate, default (1, 1).
public void setTransparency (float alpha)
Sets a transparency level, within the range of [0..1], for the StreetLevelIconBase ( StreetLevelIcon or
StreetLevelBillboard). The final opacity is a combination of the value specified here and the value specified in
setOverlayTransparency(float).
Parameters:
alpha
Desired alpha value for the StreetLevelIconBase, 0 for fully transparent, 1 for fully opaque (the default
value is 1)
Throws:
IllegalArgumentException
Passed argument is not within the range of [0..1].
HERE Android SDK Developer's Guide
API Reference
1976
StreetLevelIconPlacement
The class StreetLevelIconPlacement is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelIconPlacement
extends java.lang.Object
Encapsulates the placement properties for all image-based street-level objects ( StreetLevelIcon or
StreetLevelBillboard) that users can add to a StreetLevelModel.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1210: Nested Classes in StreetLevelIconPlacement
Nested Classes
public static final enumeration StreetLevelIconPlacement.HorizontalPlacement
This enumeration defines values for automatic placement in lat/long coordinates.
public static final enumeration StreetLevelIconPlacement.VerticalPlacement
This enumeration defines values for automatic placement in altitude.
Constructor Summary
Table 1211: Constructors in StreetLevelIconPlacement
Constructors
StreetLevelIconPlacement (HorizontalPlacement horizontalPlacement, VerticalPlacement verticalPlacement,
float verticalHeight)
Public constructor
Method Summary
Table 1212: Methods in StreetLevelIconPlacement
Methods
public boolean equals (Object other)
For documentation, see java.lang.Object
public HorizontalPlacement getHorizontalPlacement ()
Gets the current horizontal placement mode for the street-level image base object
public VerticalPlacement getVerticalPlacement ()
Gets the current vertical placement mode for the street-level image base object
HERE Android SDK Developer's Guide
API Reference
1977
Methods
public float getVerticalPlacementHeight ()
Gets the vertical placement height
public int hashCode ()
For documentation, see java.lang.Object
public StreetLevelIconPlacement setHorizontalPlacement (HorizontalPlacement placement)
Sets the street-level image base object horizontal placement mode.
public StreetLevelIconPlacement setVerticalPlacement (VerticalPlacement placement)
Sets the street-level image base object vertical placement mode.
public StreetLevelIconPlacement setVerticalPlacementHeight (float height)
Sets the vertical placement height value.
Class Details
Encapsulates the placement properties for all image-based street-level objects ( StreetLevelIcon or
StreetLevelBillboard) that users can add to a StreetLevelModel. Changes to properties of this interface are
reflected in the display of the associated StreetLevelIcon or StreetLevelBillboard.
Constructor Details
StreetLevelIconPlacement (HorizontalPlacement horizontalPlacement,
VerticalPlacement verticalPlacement, float verticalHeight)
Public constructor
Parameters:
horizontalPlacement
Horizontal Placement mode.
verticalPlacement
Vertical Placement mode.
verticalHeight
Vertical height.
Method Details
public boolean equals (Object other)
For documentation, see java.lang.Object
Parameters:
other
HERE Android SDK Developer's Guide
API Reference
1978
public HorizontalPlacement getHorizontalPlacement ()
Gets the current horizontal placement mode for the street-level image base object
Returns:
The horizontal placement mode
public VerticalPlacement getVerticalPlacement ()
Gets the current vertical placement mode for the street-level image base object
Returns:
The vertical placement mode
public float getVerticalPlacementHeight ()
Gets the vertical placement height
Returns:
The Vertical placement height
public int hashCode ()
For documentation, see java.lang.Object
public StreetLevelIconPlacement setHorizontalPlacement (HorizontalPlacement
placement)
Sets the street-level image base object horizontal placement mode. The default value is DEFAULT.
Parameters:
placement
Horizontal Placement mode
Returns:
This StreetLevelIconPlacement object
public StreetLevelIconPlacement setVerticalPlacement (VerticalPlacement placement)
Sets the street-level image base object vertical placement mode. In case horizontal placement is set to
TRACK_CAMERA, vertical is ignored. The default value is DEFAULT.
Parameters:
placement
Vertical Placement mode
HERE Android SDK Developer's Guide
API Reference
1979
Returns:
This StreetLevelIconPlacement object
public StreetLevelIconPlacement setVerticalPlacementHeight (float height)
Sets the vertical placement height value. The height parameter has a different meaning depending on the
placement mode.
Parameters:
height
If the horizontal placement mode is TRACK_CAMERA, height is the vertical distance in meters from
the camera.
If the vertical placement mode is TERRAIN, height is the distance in meters above the terrain.
If the vertical placement mode is FACADE and horizontal placement is FACADE, height is the desired
height in meters above the terrain. However, if this value is lower than the facade's default street-
level object height, the default will be used instead. For all other horizontal placements modes, the
interpretation is the same as for TERRAIN.
If the vertical placement mode is ATTACHMENT, height is a scale factor relative to the attached
building height, where 0 is bottom of the building and 1 is top. Values can be outside of [0,1] range.
If the vertical placement mode is DEFAULT, height is the meters above sea level.
Returns:
This StreetLevelIconPlacement object
See also:
StreetLevelIconPlacement.VerticalPlacement
StreetLevelIconPlacement.HorizontalPlacement
HorizontalPlacement
The enumeration HorizontalPlacement is a member of
com.here.android.mpa.streetlevel.StreetLevelIconPlacement.
Enumeration Summary
public static final enumeration StreetLevelIconPlacement.HorizontalPlacement
extends java.lang.Enum, java.lang.Object
This enumeration defines values for automatic placement in lat/long coordinates.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1980
Enum Constant Summary
Table 1213: Enum Constants in HorizontalPlacement
Fields
public static final HorizontalPlacement DEFAULT
The object is placed at its geocoordinate position.
public static final HorizontalPlacement CENTROID
The icon is placed on the attached building's centroid, and it is visible through the building walls.
public static final HorizontalPlacement SURFACE
The object is placed on the closest surface of an attached building, and it is visible through the building walls.
public static final HorizontalPlacement FACADE
The object is placed on the most viewable side of an attached building.
public static final HorizontalPlacement TRACK_CAMERA
The object is placed at its geocoordinate position.
Method Summary
Table 1214: Methods in HorizontalPlacement
Methods
public static HorizontalPlacement valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelIconPlacement.HorizontalPlacement[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines values for automatic placement in lat/long coordinates.
Enum Constant Details
public static final HorizontalPlacement DEFAULT
The object is placed at its geocoordinate position.
public static final HorizontalPlacement CENTROID
The icon is placed on the attached building's centroid, and it is visible through the building walls. This
placement mode cannot be used with billboards.
public static final HorizontalPlacement SURFACE
HERE Android SDK Developer's Guide
API Reference
1981
The object is placed on the closest surface of an attached building, and it is visible through the building
walls.
public static final HorizontalPlacement FACADE
The object is placed on the most viewable side of an attached building. The object's placement is updated as
the camera moves.
public static final HorizontalPlacement TRACK_CAMERA
The object is placed at its geocoordinate position. All vertical placement modes are ignored; the vertical
placement height is evaluated as meters above or below the camera instead.
Method Details
public static HorizontalPlacement valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelIconPlacement.HorizontalPlacement[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VerticalPlacement
The enumeration VerticalPlacement is a member of
com.here.android.mpa.streetlevel.StreetLevelIconPlacement.
Enumeration Summary
public static final enumeration StreetLevelIconPlacement.VerticalPlacement
extends java.lang.Enum, java.lang.Object
This enumeration defines values for automatic placement in altitude.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
1982
Enum Constant Summary
Table 1215: Enum Constants in VerticalPlacement
Fields
public static final VerticalPlacement DEFAULT
Calculates height as meters above the sea level.
public static final VerticalPlacement TERRAIN
Calculates height as meters above the terrain.
public static final VerticalPlacement FACADE
Used with HorizontalPlacement.FACADE.
public static final VerticalPlacement ATTACHMENT
Calculates height as a percentage of the building height.
Method Summary
Table 1216: Methods in VerticalPlacement
Methods
public static VerticalPlacement valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelIconPlacement.VerticalPlacement[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines values for automatic placement in altitude.
Enum Constant Details
public static final VerticalPlacement DEFAULT
Calculates height as meters above the sea level.
public static final VerticalPlacement TERRAIN
Calculates height as meters above the terrain.
public static final VerticalPlacement FACADE
Used with HorizontalPlacement.FACADE. The object will use a default height or the height that you provide
(as calculated from the terrain), whichever is higher.
HERE Android SDK Developer's Guide
API Reference
1983
public static final VerticalPlacement ATTACHMENT
Calculates height as a percentage of the building height.
Method Details
public static VerticalPlacement valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelIconPlacement.VerticalPlacement[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StreetLevelIconSize
The class StreetLevelIconSize is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelIconSize
extends java.lang.Object
Encapsulates the size properties for a StreetLevelIcon.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1217: Nested Classes in StreetLevelIconSize
Nested Classes
public static final enumeration StreetLevelIconSize.ScalePolicy
Represents values describing the policy for scaling a StreetLevelIconSize.
HERE Android SDK Developer's Guide
API Reference
1984
Constructor Summary
Table 1218: Constructors in StreetLevelIconSize
Constructors
StreetLevelIconSize (int width, int height)
Public Constructor
Method Summary
Table 1219: Methods in StreetLevelIconSize
Methods
public float getFarDistance ()
Gets the current far distance of a StreetLevelIcon.
public float getFarScale ()
Gets the current far scale of a StreetLevelIcon.
public int getHeight ()
Gets the current height of a StreetLevelIcon, in pixels.
public float getNearDistance ()
Gets the current near distance of a StreetLevelIcon.
public float getNearScale ()
Gets the current near scale of a StreetLevelIcon.
public ScalePolicy getScalePolicy ()
Gets the current StreetLevelIconSize.ScalePolicy of a StreetLevelIcon.
public int getWidth ()
Gets the current width of a StreetLevelIcon, in pixels.
public StreetLevelIconSize setFarDistance (float farDistance)
Sets a far distance for the StreetLevelIconSize.Default value is 1.0f.
public StreetLevelIconSize setFarScale (float farScale)
Sets a far scale for the StreetLevelIconSize.Default value is 1.0f.
public StreetLevelIconSize setHeight (int height)
Sets a height, in pixels, for the StreetLevelIconSize.
public StreetLevelIconSize setNearDistance (float nearDistance)
Sets a near distance for the StreetLevelIconSize.
public StreetLevelIconSize setNearScale (float nearScale)
Sets a near scale for the StreetLevelIconSize.
public StreetLevelIconSize setScalePolicy (ScalePolicy policy)
Sets a StreetLevelIconSize.ScalePolicy for the StreetLevelIconSize.
HERE Android SDK Developer's Guide
API Reference
1985
Methods
public StreetLevelIconSize setWidth (int width)
Sets a width, in pixels, for the StreetLevelIconSize.
Class Details
Encapsulates the size properties for a StreetLevelIcon. Changes to properties of this interface are reflected in
the displayed size of the associated StreetLevelIcon.
Constructor Details
StreetLevelIconSize (int width, int height)
Public Constructor
Parameters:
width
Width of the icon, in pixels
height
Height of the icon, in pixels
Method Details
public float getFarDistance ()
Gets the current far distance of a StreetLevelIcon.
Returns:
The current far distance
public float getFarScale ()
Gets the current far scale of a StreetLevelIcon.
Returns:
The current far scale
public int getHeight ()
Gets the current height of a StreetLevelIcon, in pixels.
Returns:
The current height
HERE Android SDK Developer's Guide
API Reference
1986
public float getNearDistance ()
Gets the current near distance of a StreetLevelIcon.
Returns:
The current near distance
public float getNearScale ()
Gets the current near scale of a StreetLevelIcon. Default value is 1.0f.
Returns:
The current near scale
public ScalePolicy getScalePolicy ()
Gets the current StreetLevelIconSize.ScalePolicy of a StreetLevelIcon.
Returns:
The current StreetLevelIconSize.ScalePolicy
public int getWidth ()
Gets the current width of a StreetLevelIcon, in pixels.
Returns:
The current width
public StreetLevelIconSize setFarDistance (float farDistance)
Sets a far distance for the StreetLevelIconSize.Default value is 1.0f.
Parameters:
farDistance
Desired far distance
Returns:
This StreetLevelIconSize object
public StreetLevelIconSize setFarScale (float farScale)
Sets a far scale for the StreetLevelIconSize.Default value is 1.0f.
Parameters:
farScale
Desired far scale
HERE Android SDK Developer's Guide
API Reference
1987
Returns:
This StreetLevelIconSize object
public StreetLevelIconSize setHeight (int height)
Sets a height, in pixels, for the StreetLevelIconSize.
Parameters:
height
Desired height
Returns:
This StreetLevelIconSize object
public StreetLevelIconSize setNearDistance (float nearDistance)
Sets a near distance for the StreetLevelIconSize. Default value is 1.0f.
Parameters:
nearDistance
Desired near distance
Returns:
This StreetLevelIconSize object
public StreetLevelIconSize setNearScale (float nearScale)
Sets a near scale for the StreetLevelIconSize. Default value is 1.0f.
Parameters:
nearScale
Desired near scale
Returns:
This StreetLevelIconSize object
public StreetLevelIconSize setScalePolicy (ScalePolicy policy)
Sets a StreetLevelIconSize.ScalePolicy for the StreetLevelIconSize. Default value is ScalePolicy.FIXED .
Parameters:
policy
Desired StreetLevelIconSize.ScalePolicy
Returns:
HERE Android SDK Developer's Guide
API Reference
1988
This StreetLevelIconSize object
public StreetLevelIconSize setWidth (int width)
Sets a width, in pixels, for the StreetLevelIconSize.
Parameters:
width
Desired width
Returns:
This StreetLevelIconSize object
ScalePolicy
The enumeration ScalePolicy is a member of com.here.android.mpa.streetlevel.StreetLevelIconSize.
Enumeration Summary
public static final enumeration StreetLevelIconSize.ScalePolicy
extends java.lang.Enum, java.lang.Object
Represents values describing the policy for scaling a StreetLevelIconSize.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1220: Enum Constants in ScalePolicy
Fields
public static final ScalePolicy FIXED
Use a specified near-scale value.
public static final ScalePolicy LINEAR
Use a linear interpolation between near-scale and far-scale.
public static final ScalePolicy PERSPECTIVE
Use a value based on near-scale, distance from the camera and near distance.
Method Summary
Table 1221: Methods in ScalePolicy
Methods
public int value ()
HERE Android SDK Developer's Guide
API Reference
1989
Methods
public static ScalePolicy valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelIconSize.ScalePolicy[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the policy for scaling a StreetLevelIconSize. The scale policy value is determined
based on the on distance from the camera as well as the near and far distance values.
Enum Constant Details
public static final ScalePolicy FIXED
Use a specified near-scale value.
public static final ScalePolicy LINEAR
Use a linear interpolation between near-scale and far-scale.
public static final ScalePolicy PERSPECTIVE
Use a value based on near-scale, distance from the camera and near distance.
Method Details
public int value ()
public static ScalePolicy valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelIconSize.ScalePolicy[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
1990
StreetLevelLink
The class StreetLevelLink is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelLink
extends com.here.android.mpa.streetlevel.StreetLevelProxyObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a class for all street level link objects used to follow from StreetLevel to StreetLevel within an on-
screen StreetLevelFragment.
[For complete information, see the section Class Details]
See also:
getSelectedObjects(PointF)
Method Summary
Table 1222: Methods in StreetLevelLink
Methods
public StreetLevel getStreetLevel ()
Gets the StreetLevel of the user object that the StreetLevelLink represents.
public Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
This method overrides streetlevel.StreetLevelProxyObject.getType(void)
Class Details
Represents a class for all street level link objects used to follow from StreetLevel to StreetLevel within an on-
screen StreetLevelFragment. The street level link is visualised as a navigation arrow.
See also:
getSelectedObjects(PointF)
Method Details
public StreetLevel getStreetLevel ()
Gets the StreetLevel of the user object that the StreetLevelLink represents.
Returns:
The StreetLevel
HERE Android SDK Developer's Guide
API Reference
1991
public Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
This method overrides streetlevel.StreetLevelProxyObject.getType(void)
StreetLevelModel
The class StreetLevelModel is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelModel
extends java.lang.Object
Represents a model for street level data.
[For complete information, see the section Class Details]
See also:
StreetLevelCoverage
Nested Class Summary
Table 1223: Nested Classes in StreetLevelModel
Nested Classes
public static abstract interface StreetLevelModel.OnEventListener
Represents a listener to provide notification upon completion of a StreetLevelModel event.
public static abstract interface StreetLevelModel.OnRetrievalListener
Listener class to be used with getStreetLevel(GeoCoordinate, StreetLevelModel.OnRetrievalListener) to retrieve a StreetLevel.
Constructor Summary
Table 1224: Constructors in StreetLevelModel
Constructors
StreetLevelModel ()
Public Constructor
HERE Android SDK Developer's Guide
API Reference
1992
Field Summary
Table 1225: Fields in StreetLevelModel
Fields
public static final float MOVE_PRESERVE_HEADING
Pass this parameter value if the heading level is to be preserved when a StreetLevel object is redrawn.
public static final float MOVE_PRESERVE_PITCH
Pass this parameter value if the pitch level is to be preserved when a StreetLevel object is redrawn.
public static final float MOVE_PRESERVE_ZOOM
Pass this parameter value if the zoom level is to be preserved when a StreetLevel object is redrawn.
Method Summary
Table 1226: Methods in StreetLevelModel
Methods
public void addStreetLevelModelListener (OnEventListener eventListener)
Adds a StreetLevelModel.OnEventListener to listen for street level model events.
public boolean addStreetLevelObject (StreetLevelObject streetLevelObject)
Adds a StreetLevelObject to the StreetLevel.
public void cancelMoveTo (boolean animate)
Cancels a StreetLevel transition initiated previously by a call to moveTo(StreetLevel, boolean, float, float, float) or
moveTo(StreetLevel, boolean, GeoCoordinate, float).
public void executeSynchronized (Runnable task)
Execute a batched set of commands to the StreetLevelModel.
public PointF geoToPixel (GeoCoordinate geoCoordinates)
Converts a specified GeoCoordinate into a corresponding PointF that represents screen pixel coordinates.
public float getHeading ()
Gets the current heading of the StreetLevel.
public int getHeight ()
Gets the current height of the StreetLevelModel, in pixels.
public float getMaxHeading ()
Gets the maximum heading value that is valid for the StreetLevel.
public float getMaxPitch ()
Gets the maximum pitch value that is valid for the StreetLevel.
public float getMaxZoom ()
Gets the maximum zoom value that is valid for the StreetLevel.
HERE Android SDK Developer's Guide
API Reference
1993
Methods
public float getMinHeading ()
Gets the minimum heading value that is valid for the StreetLevel.
public float getMinPitch ()
Gets the minimum pitch value that is valid for the StreetLevel.
public float getMinZoom ()
Gets the minimum zoom value that is valid for the StreetLevel.
public float getOverlayTransparency ()
Gets the current overlay transparency value of the StreetLevel, a float within the range of [0..1].
public float getPitch ()
Gets the current pitch of the StreetLevel.
public GeoCoordinate getPosition ()
Gets the current camera position for the StreetLevelModel.
public java.util.List <StreetLevelSelectedObject> getSelectedObjects (PointF p)
Gets the List of StreetLevelSelectedObject objects which have been selected at the specified screen pixel coordinates.
public StreetLevelModelState getState ()
Gets the current state of the StreetLevelModel.
public boolean getStreetLevel (GeoCoordinate center, OnRetrievalListener listener)
Asynchronously gets the StreetLevel closest to a specified GeoCoordinate.
public StreetLevel getStreetLevel (GeoCoordinate center, int searchRadius)
Synchronously gets the StreetLevel closest to a specified GeoCoordinate.
public StreetLevel getStreetLevel (PointF point)
Gets the StreetLevel closest to a specified on-screen PointF .
public StreetLevel getStreetLevel ()
Gets the current active StreetLevel.
public int getWidth ()
Gets the current width of the StreetLevelModel, in pixels.
public float getZoom ()
Gets the current zoom level of the StreetLevel.
public boolean isCompassMapVisible ()
Gets the boolean indicating whether the street level compass map is shown for the StreetLevelModel.
public boolean isMoving ()
Determines whether the StreetLevelModel is moving from one StreetLevel to another.
public boolean isNavigationArrowVisible ()
Gets the current visibility state of the street navigation arrow.
HERE Android SDK Developer's Guide
API Reference
1994
Methods
public boolean isStreetGeometryVisible ()
Gets the current visibility state of street geometry.
public boolean isStreetLevelDataNeeded ()
Determines whether more StreetLevel data is needed.
public void moveCamera (GeoCoordinate position, float heading, float pitch, float zoom)
Moves the camera position to the specified position.
public void moveTo (StreetLevel streetLevel, boolean animation, float heading, float pitch,
float zoom)
Moves the view to a specified StreetLevel (animating or not), while simultaneously setting the street level's heading (a
fraction within the range of minimum and maximum levels), pitch (a fraction within the range of minimum and maximum
levels), and zoom level (a fraction within the range of minimum and maximum levels).
public void moveTo (StreetLevel streetLevel, boolean animation, GeoCoordinate cameraHeading,
float zoom)
Moves the view to a specified StreetLevel (animating or not), while simultaneously setting the street level's heading
(a fraction within the range of minimum and maximum levels) and zoom (a fraction within the range of minimum and
maximum levels).
public void pan (PointF from, PointF to)
Pans the StreetLevel from one specified on-screen PointF to another.
public GeoCoordinate pixelToGeo (PointF p)
Converts a pair of screen pixel coordinates into a corresponding GeoCoordinate.
public void removeStreetLevelModelListener (OnEventListener eventListener)
Removes an existing StreetLevelModel.OnEventListener.
public boolean removeStreetLevelObject (StreetLevelObject streetLevelObject)
Removes a StreetLevelObject from the StreetLevel.
public void rotate (PointF from, PointF to)
Rotates the StreetLevel from one specified on-screen PointF to another.
public void setCompassMapVisible (boolean visible)
Sets a StreetLevelModel to either show or hide the street level compass map.
public void setHeading (float heading)
Sets a heading for the StreetLevel.
public void setNavigationArrow (Image icon)
Sets an Image for the icon to be used as a street navigation arrow.
public void setNavigationArrowVisible (boolean visible)
Sets the visibility state for the street navigation arrow.
public void setOverlayTransparency (float alpha)
Sets an overlay transparency value for the StreetLevel, a float within the range of [0..1].
HERE Android SDK Developer's Guide
API Reference
1995
Methods
public void setPitch (float pitch)
Sets a pitch for the StreetLevel.
public void setStreetGeometryVisible (boolean visible)
Sets the visibility state for street geometry.
public void setZoom (float zoom)
Sets a zoom level for the StreetLevel.
public List toCameraOrientation (PointF point)
Determines the camera orientation required to display a specified PointF in the center of the screen.
Class Details
Represents a model for street level data. For areas with appropriate street level coverage, applications can
bind a StreetLevelModel with a StreetLevelFragment to render 360-degree street level imagery.
See also:
StreetLevelCoverage
Constructor Details
StreetLevelModel ()
Public Constructor
Field Details
public static final float MOVE_PRESERVE_HEADING
Pass this parameter value if the heading level is to be preserved when a StreetLevel object is redrawn. This is
the one valid value that lies outside the range of typical moveTo(StreetLevel, boolean, GeoCoordinate, float)
parameters.
public static final float MOVE_PRESERVE_PITCH
Pass this parameter value if the pitch level is to be preserved when a StreetLevel object is redrawn. This is
the one valid value that lies outside the range of typical moveTo(StreetLevel, boolean, GeoCoordinate, float)
parameters.
public static final float MOVE_PRESERVE_ZOOM
Pass this parameter value if the zoom level is to be preserved when a StreetLevel object is redrawn. This is
the one valid value that lies outside the range of typical moveTo(StreetLevel, boolean, GeoCoordinate, float)
parameters.
HERE Android SDK Developer's Guide
API Reference
1996
Method Details
public void addStreetLevelModelListener (OnEventListener eventListener)
Adds a StreetLevelModel.OnEventListener to listen for street level model events.
Note: it is recommended to remove street level model event listeners after they are destroyed.
Parameters:
eventListener
A StreetLevelModel.OnEventListener to add to the StreetLevelModel
See also:
removeStreetLevelModelListener(OnEventListener)
public boolean addStreetLevelObject (StreetLevelObject streetLevelObject)
Adds a StreetLevelObject to the StreetLevel.
Parameters:
streetLevelObject
A StreetLevelObject to add
Returns:
True if the StreetLevelObject was added successfully, false otherwise
See also:
removeStreetLevelObject(StreetLevelObject)
public void cancelMoveTo (boolean animate)
Cancels a StreetLevel transition initiated previously by a call to moveTo(StreetLevel, boolean, float, float,
float) or moveTo(StreetLevel, boolean, GeoCoordinate, float). The original view will be re-established.
Parameters:
animate
A boolean specifying whether the move back to the original view is animated
public void executeSynchronized (Runnable task)
Execute a batched set of commands to the StreetLevelModel. This is useful to improve performance when
multiple operations require re-rendering of the display.
Parameters:
task
HERE Android SDK Developer's Guide
API Reference
1997
Task block to execute synchronously.
public PointF geoToPixel (GeoCoordinate geoCoordinates)
Converts a specified GeoCoordinate into a corresponding PointF that represents screen pixel coordinates.
Note: this method could return null if the conversion fails.
Parameters:
geoCoordinates
A GeoCoordinate to convert
Returns:
The PointF representing screen pixel coordinates (could be null)
public float getHeading ()
Gets the current heading of the StreetLevel.
Returns:
The current heading
public int getHeight ()
Gets the current height of the StreetLevelModel, in pixels.
Returns:
The current height
public float getMaxHeading ()
Gets the maximum heading value that is valid for the StreetLevel.
Returns:
The maximum heading value
public float getMaxPitch ()
Gets the maximum pitch value that is valid for the StreetLevel.
Returns:
The maximum pitch value
public float getMaxZoom ()
HERE Android SDK Developer's Guide
API Reference
1998
Gets the maximum zoom value that is valid for the StreetLevel.
Returns:
The maximum zoom value
public float getMinHeading ()
Gets the minimum heading value that is valid for the StreetLevel.
Returns:
The minimum heading value
public float getMinPitch ()
Gets the minimum pitch value that is valid for the StreetLevel.
Returns:
The minimum pitch value
public float getMinZoom ()
Gets the minimum zoom value that is valid for the StreetLevel.
Returns:
The minimum zoom value
public float getOverlayTransparency ()
Gets the current overlay transparency value of the StreetLevel, a float within the range of [0..1]. The overlay
transparency is the transparency for the objects overlaid on top of the street level image like link arrows,
street names, icons etc.
Returns:
The current overlay transparency value
public float getPitch ()
Gets the current pitch of the StreetLevel.
Returns:
The current pitch
public GeoCoordinate getPosition ()
Gets the current camera position for the StreetLevelModel.
HERE Android SDK Developer's Guide
API Reference
1999
Returns:
The GeoCoordinate representing the current camera position
public java.util.List <StreetLevelSelectedObject> getSelectedObjects (PointF p)
Gets the List of StreetLevelSelectedObject objects which have been selected at the specified screen pixel
coordinates.
Note: use getObject() instanceof to determine the exact types of StreetLevelSelectedObject objects that
have been selected ( StreetLevelBuilding, StreetLevelLink, etc.).
Parameters:
p
Screen Pixel coordinate
Returns:
The List of selected StreetLevelSelectedObject objects
public StreetLevelModelState getState ()
Gets the current state of the StreetLevelModel. This is a compound call to get the zoom level, heading, pitch
from one API.
Returns:
The StreetLevelModelState
public boolean getStreetLevel (GeoCoordinate center, OnRetrievalListener
listener)
Asynchronously gets the StreetLevel closest to a specified GeoCoordinate. This is an optimized version of
getStreetLevel(GeoCoordinate, int) as it retrieves the StreetLevel with optimal radius base on the current
zoom level.
Parameters:
center
A GeoCoordinate representing the geographical position used to determine the closest StreetLevel.
listener
Callback listener to be notified when retrieval request completes.
Returns:
True if retrieval request can be processed. False, otherwise.
Throws:
NullPointerException
if center or listener is null.
HERE Android SDK Developer's Guide
API Reference
2000
See also:
getStreetLevel(GeoCoordinate, int)
getStreetLevel(PointF)
getStreetLevel()
public StreetLevel getStreetLevel (GeoCoordinate center, int searchRadius)
Synchronously gets the StreetLevel closest to a specified GeoCoordinate.
The search is constrained by a specified radius, in meters, from the specified GeoCoordinate .
Parameters:
center
A GeoCoordinate representing the geographical position used to determine the closest StreetLevel
searchRadius
Desired search radius, in meters, from center.
Returns:
The StreetLevel
See also:
getStreetLevel(GeoCoordinate, OnRetrievalListener)
getStreetLevel(PointF)
getStreetLevel()
public StreetLevel getStreetLevel (PointF point)
Gets the StreetLevel closest to a specified on-screen PointF .
Parameters:
point
A PointF representing the on-screen point used to determine the closest StreetLevel
Returns:
The StreetLevel
See also:
getStreetLevel(GeoCoordinate, OnRetrievalListener)
getStreetLevel(GeoCoordinate, int)
getStreetLevel()
public StreetLevel getStreetLevel ()
HERE Android SDK Developer's Guide
API Reference
2001
Gets the current active StreetLevel.
Returns:
The current StreetLevel
See also:
getStreetLevel(GeoCoordinate, OnRetrievalListener)
getStreetLevel(GeoCoordinate, int)
getStreetLevel(PointF)
public int getWidth ()
Gets the current width of the StreetLevelModel, in pixels.
Returns:
The current width
public float getZoom ()
Gets the current zoom level of the StreetLevel.
Returns:
The current zoom level
public boolean isCompassMapVisible ()
Gets the boolean indicating whether the street level compass map is shown for the StreetLevelModel.
Returns:
True if the compass map is visible, false otherwise
public boolean isMoving ()
Determines whether the StreetLevelModel is moving from one StreetLevel to another.
Returns:
True if a StreetLevel move is in progress, false otherwise
public boolean isNavigationArrowVisible ()
Gets the current visibility state of the street navigation arrow.
Returns:
True if the street navigation arrow is currently visible, false otherwise
HERE Android SDK Developer's Guide
API Reference
2002
public boolean isStreetGeometryVisible ()
Gets the current visibility state of street geometry.
Returns:
True if street geometry is currently visible, false otherwise
public boolean isStreetLevelDataNeeded ()
Determines whether more StreetLevel data is needed.
Returns:
True if more data is needed, false otherwise
public void moveCamera (GeoCoordinate position, float heading, float pitch,
float zoom)
Moves the camera position to the specified position.
Parameters:
position
Position of the Camera, Can have altitude to move the camera from the default height above the street.
heading
Desired heading of the Camera
pitch
Desired pitch of the Camera
zoom
Desired zoom of the Camera
Note: if you wish to keep the current heading, pitch or zoom level, pass one or more of the following
values as the relevant parameter:
MOVE_PRESERVE_HEADING to keep the current heading
MOVE_PRESERVE_PITCH to keep the current pitch
MOVE_PRESERVE_ZOOM to keep the current zoom level
public void moveTo (StreetLevel streetLevel, boolean animation, float
heading, float pitch, float zoom)
Moves the view to a specified StreetLevel (animating or not), while simultaneously setting the street level's
heading (a fraction within the range of minimum and maximum levels), pitch (a fraction within the range
of minimum and maximum levels), and zoom level (a fraction within the range of minimum and maximum
levels).
HERE Android SDK Developer's Guide
API Reference
2003
Note: if you wish to keep the current heading, pitch or zoom level, pass one or more of the following values
as the relevant parameter:
MOVE_PRESERVE_HEADING to keep the current heading
MOVE_PRESERVE_PITCH to keep the current pitch
MOVE_PRESERVE_ZOOM to keep the current zoom level
Parameters:
streetLevel
Desired StreetLevel
animation
A boolean specifying whether the move is animated
heading
Desired heading of the new StreetLevel
pitch
Desired pitch of the new StreetLevel
zoom
Desired zoom level of the new StreetLevel
See also:
moveTo(StreetLevel, boolean, GeoCoordinate, float)
getMinHeading()
getMaxHeading()
getMinPitch()
getMaxPitch()
getMinZoom()
getMaxZoom()
cancelMoveTo(boolean)
public void moveTo (StreetLevel streetLevel, boolean animation, GeoCoordinate
cameraHeading, float zoom)
Moves the view to a specified StreetLevel (animating or not), while simultaneously setting the street level's
heading (a fraction within the range of minimum and maximum levels) and zoom (a fraction within the range
of minimum and maximum levels).
Note: if you wish to keep the current heading or zoom level, pass one or more of the following values as the
relevant parameter:
MOVE_PRESERVE_HEADING to keep the current heading
MOVE_PRESERVE_ZOOM to keep the current zoom level
Parameters:
streetLevel
HERE Android SDK Developer's Guide
API Reference
2004
Desired StreetLevel
animation
A boolean specifying whether the move is animated
cameraHeading
A GeoCoordinate representing the desired heading of the new StreetLevel
zoom
Desired zoom level of the new StreetLevel
See also:
moveTo(StreetLevel, boolean, float, float, float)
getMinHeading()
getMaxHeading()
getMinZoom()
getMaxZoom()
cancelMoveTo(boolean)
public void pan (PointF from, PointF to)
Pans the StreetLevel from one specified on-screen PointF to another.
Parameters:
from
An originating on-screen PointF (pre-pan)
to
An on-screen PointF representing the end of the pan
public GeoCoordinate pixelToGeo (PointF p)
Converts a pair of screen pixel coordinates into a corresponding GeoCoordinate.
Note: this method could return null if the conversion fails.
Parameters:
p
Position of screen pixel to convert
Returns:
The GeoCoordinate (could be null)
public void removeStreetLevelModelListener (OnEventListener eventListener)
Removes an existing StreetLevelModel.OnEventListener.
HERE Android SDK Developer's Guide
API Reference
2005
Note: it is recommended to remove street level model event listeners after they are destroyed.
Parameters:
eventListener
A StreetLevelModel.OnEventListener to remove from the StreetLevelModel
public boolean removeStreetLevelObject (StreetLevelObject streetLevelObject)
Removes a StreetLevelObject from the StreetLevel.
Parameters:
streetLevelObject
A StreetLevelObject to remove
Returns:
True if the StreetLevelObject was removed successfully, false otherwise
public void rotate (PointF from, PointF to)
Rotates the StreetLevel from one specified on-screen PointF to another.
Parameters:
from
An originating on-screen PointF (pre-rotation)
to
An on-screen PointF representing the end of the rotation
public void setCompassMapVisible (boolean visible)
Sets a StreetLevelModel to either show or hide the street level compass map. By default, the compass map is
visible.
The compass map is a circular map view that can be viewed by panning downward towards the ground. Its
primary purpose is to provide users their direction and location context while they're viewing the street level.
Users cannot directly manipulate a compass map, but changes from panning or navigating the street level
image are immediately reflected in it.
Parameters:
visible
A boolean specifying whether compass map is going to be visible
public void setHeading (float heading)
Sets a heading for the StreetLevel.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2006
heading
Desired heading
See also:
getMinHeading()
getMaxHeading()
public void setNavigationArrow (Image icon)
Sets an Image for the icon to be used as a street navigation arrow. There is no default navigation arrow
image. If user does not provide one, no arrow will be displayed, but there is a hollow area at the bottom of
the street level image where the arrow is supposed to be. Navigating the street level is still possible in this
case by tapping on the corners of the hollow area.
Parameters:
icon
A Image representing image of the arrow
Throws:
NullPointerException
if icon is null.
IllegalArgumentException
if icon is not valid
public void setNavigationArrowVisible (boolean visible)
Sets the visibility state for the street navigation arrow. By default the navigation arrow is not visible.
Parameters:
visible
A boolean specifying whether the street navigation arrow is visible
public void setOverlayTransparency (float alpha)
Sets an overlay transparency value for the StreetLevel, a float within the range of [0..1]. This method sets
the transparency for the objects overlaid on top of the street level image like link arrows, street names, icons
etc.
Parameters:
alpha
Desired overlay transparency
public void setPitch (float pitch)
HERE Android SDK Developer's Guide
API Reference
2007
Sets a pitch for the StreetLevel.
Parameters:
pitch
Desired pitch
See also:
getMinPitch()
getMaxPitch()
public void setStreetGeometryVisible (boolean visible)
Sets the visibility state for street geometry.
Parameters:
visible
A boolean specifying whether street geometry is visible or not
public void setZoom (float zoom)
Sets a zoom level for the StreetLevel.
Parameters:
zoom
Desired zoom level
See also:
getMinZoom()
getMaxZoom()
public List toCameraOrientation (PointF point)
Determines the camera orientation required to display a specified PointF in the center of the screen.
Parameters:
point
Desired center PointF which would require a change in camera orientation
Returns:
The list of Float values representing the required camera orientation, where the first element contains the
heading (in degrees) and second element contains the pitch (in degrees)
HERE Android SDK Developer's Guide
API Reference
2008
OnEventListener
The interface OnEventListener is a member of com.here.android.mpa.streetlevel.StreetLevelModel.
Interface Summary
public static abstract interface StreetLevelModel.OnEventListener
Represents a listener to provide notification upon completion of a StreetLevelModel event.
[For complete information, see the section Interface Details]
See also:
addStreetLevelModelListener(OnEventListener)
Nested Class Summary
Table 1227: Nested Classes in OnEventListener
Nested Classes
public static abstract class StreetLevelModel.OnEventListener.OnEventListenerAdapter
Default implementation for the OnEventListener interface.
Method Summary
Table 1228: Methods in OnEventListener
Methods
public abstract void onBuildingHide (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been unloaded.
public abstract void onBuildingShow (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been loaded.
public abstract void onIconPlaced (StreetLevelSelectedObject pickedObject)
A callback indicating that an icon is successfully placed on a StreetLevelSelectedObject
public abstract void onMoveContinue ()
A callback indicating that a StreetLevelModel move has continued after waiting for StreetLevel data availability.
public abstract void onMoveEnd (boolean completed)
A callback indicating that a StreetLevelModel move has ended.
public abstract void onMoveEnd (GeoCoordinate coordinate)
A callback indicating that a StreetLevelModel move has ended.
public abstract void onMoveStart ()
A callback indicating that a StreetLevelModel move has started.
HERE Android SDK Developer's Guide
API Reference
2009
Methods
public abstract void onMoveWait ()
A callback indicating that a StreetLevelModel move is waiting for StreetLevel data to be available before continuing.
public abstract void onOrientationEnd (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has ended.
public abstract void onOrientationStart (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has started.
public abstract void onPositionChanged (GeoCoordinate coordinate)
A callback indicating that the StreetLevel position has changed.
public abstract void onStreetLevelChanged ()
A callback indicating that StreetLevel data has changed.
public abstract void onStreetLevelFullyLoaded ()
A callback indicating that StreetLevel data is fully loaded.
public abstract void onStreetLevelInvalidated ()
A callback indicating that StreetLevel data has become invalid.
public abstract void onStreetLevelPreviewAvailable ()
A callback indicating that StreetLevel preview image is available.
public abstract void onZoomEnd (float zoom)
A callback indicating that a StreetLevel zoom operation has ended.
public abstract void onZoomStart (float zoom)
A callback indicating that StreetLevel a zoom operation has started.
Interface Details
Represents a listener to provide notification upon completion of a StreetLevelModel event.
See also:
addStreetLevelModelListener(OnEventListener)
Method Details
public abstract void onBuildingHide (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been unloaded.
Parameters:
building
StreetLevelBuilding
public abstract void onBuildingShow (StreetLevelBuilding building)
HERE Android SDK Developer's Guide
API Reference
2010
A callback indicating a StreetLevelBuilding has been loaded.
Parameters:
building
StreetLevelBuilding
public abstract void onIconPlaced (StreetLevelSelectedObject pickedObject)
A callback indicating that an icon is successfully placed on a StreetLevelSelectedObject
Parameters:
pickedObject
StreetLevelSelectedObject
public abstract void onMoveContinue ()
A callback indicating that a StreetLevelModel move has continued after waiting for StreetLevel data
availability.
public abstract void onMoveEnd (boolean completed)
A callback indicating that a StreetLevelModel move has ended.
Parameters:
completed
A boolean specifying whether the move operation was successful
public abstract void onMoveEnd (GeoCoordinate coordinate)
A callback indicating that a StreetLevelModel move has ended.
Parameters:
coordinate
Current position
public abstract void onMoveStart ()
A callback indicating that a StreetLevelModel move has started.
public abstract void onMoveWait ()
A callback indicating that a StreetLevelModel move is waiting for StreetLevel data to be available before
continuing.
HERE Android SDK Developer's Guide
API Reference
2011
public abstract void onOrientationEnd (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has ended.
Parameters:
heading
A camera heading
pitch
A camera pitch
public abstract void onOrientationStart (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has started.
Parameters:
heading
A camera heading
pitch
A camera pitch
public abstract void onPositionChanged (GeoCoordinate coordinate)
A callback indicating that the StreetLevel position has changed.
Parameters:
coordinate
An updated position
public abstract void onStreetLevelChanged ()
A callback indicating that StreetLevel data has changed.
public abstract void onStreetLevelFullyLoaded ()
A callback indicating that StreetLevel data is fully loaded.
public abstract void onStreetLevelInvalidated ()
A callback indicating that StreetLevel data has become invalid.
public abstract void onStreetLevelPreviewAvailable ()
HERE Android SDK Developer's Guide
API Reference
2012
A callback indicating that StreetLevel preview image is available.
public abstract void onZoomEnd (float zoom)
A callback indicating that a StreetLevel zoom operation has ended.
Parameters:
zoom
A zoom level
public abstract void onZoomStart (float zoom)
A callback indicating that StreetLevel a zoom operation has started.
Parameters:
zoom
A zoom level
OnEventListenerAdapter
The class OnEventListenerAdapter is a member of
com.here.android.mpa.streetlevel.StreetLevelModel.OnEventListener.
Class Summary
public static abstract class StreetLevelModel.OnEventListener.OnEventListenerAdapter
implements com.here.android.mpa.streetlevel.StreetLevelModel.OnEventListener
extends java.lang.Object
Default implementation for the OnEventListener interface.
[For complete information, see the section Class Details]
See also:
StreetLevelModel.OnEventListener
Constructor Summary
Table 1229: Constructors in OnEventListenerAdapter
Constructors
OnEventListenerAdapter ()
HERE Android SDK Developer's Guide
API Reference
2013
Method Summary
Table 1230: Methods in OnEventListenerAdapter
Methods
public void onBuildingHide (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been unloaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onBuildingHide(StreetLevelBuilding)
public void onBuildingShow (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been loaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onBuildingShow(StreetLevelBuilding)
public void onIconPlaced (StreetLevelSelectedObject pickedObject)
A callback indicating that an icon is successfully placed on a StreetLevelSelectedObject
This method overrides streetlevel.StreetLevelModel.OnEventListener.onIconPlaced(StreetLevelSelectedObject)
public void onMoveContinue ()
A callback indicating that a StreetLevelModel move has continued after waiting for StreetLevel data availability.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveContinue(void)
public void onMoveEnd (boolean completed)
A callback indicating that a StreetLevelModel move has ended.A callback indicating that a StreetLevelModel move has
ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveEnd(boolean)
public void onMoveEnd (GeoCoordinate coordinate)
A callback indicating that a StreetLevelModel move has ended.A callback indicating that a StreetLevelModel move has
ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveEnd(GeoCoordinate)
public void onMoveStart ()
A callback indicating that a StreetLevelModel move has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveStart(void)
public void onMoveWait ()
A callback indicating that a StreetLevelModel move is waiting for StreetLevel data to be available before continuing.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveWait(void)
public void onOrientationEnd (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onOrientationEnd(float, float)
public void onOrientationStart (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onOrientationStart(float, float)
HERE Android SDK Developer's Guide
API Reference
2014
Methods
public void onPositionChanged (GeoCoordinate coordinate)
A callback indicating that the StreetLevel position has changed.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onPositionChanged(GeoCoordinate)
public void onStreetLevelChanged ()
A callback indicating that StreetLevel data has changed.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelChanged(void)
public void onStreetLevelFullyLoaded ()
A callback indicating that StreetLevel data is fully loaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelFullyLoaded(void)
public void onStreetLevelInvalidated ()
A callback indicating that StreetLevel data has become invalid.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelInvalidated(void)
public void onStreetLevelPreviewAvailable ()
A callback indicating that StreetLevel preview image is available.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelPreviewAvailable(void)
public void onZoomEnd (float zoom)
A callback indicating that a StreetLevel zoom operation has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onZoomEnd(float)
public void onZoomStart (float zoom)
A callback indicating that StreetLevel a zoom operation has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onZoomStart(float)
Class Details
Default implementation for the OnEventListener interface. Users may use this abstract class and overload
specific methods to have a smaller code footprint.
See also:
StreetLevelModel.OnEventListener
Constructor Details
OnEventListenerAdapter ()
Method Details
public void onBuildingHide (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been unloaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onBuildingHide(StreetLevelBuilding)
HERE Android SDK Developer's Guide
API Reference
2015
Parameters:
building
public void onBuildingShow (StreetLevelBuilding building)
A callback indicating a StreetLevelBuilding has been loaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onBuildingShow(StreetLevelBuilding)
Parameters:
building
public void onIconPlaced (StreetLevelSelectedObject pickedObject)
A callback indicating that an icon is successfully placed on a StreetLevelSelectedObject
This method overrides streetlevel.StreetLevelModel.OnEventListener.onIconPlaced(StreetLevelSelectedObject)
Parameters:
pickedObject
public void onMoveContinue ()
A callback indicating that a StreetLevelModel move has continued after waiting for StreetLevel data
availability.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveContinue(void)
public void onMoveEnd (boolean completed)
A callback indicating that a StreetLevelModel move has ended.A callback indicating that a StreetLevelModel
move has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveEnd(boolean)
Parameters:
completed
public void onMoveEnd (GeoCoordinate coordinate)
A callback indicating that a StreetLevelModel move has ended.A callback indicating that a StreetLevelModel
move has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveEnd(GeoCoordinate)
Parameters:
coordinate
HERE Android SDK Developer's Guide
API Reference
2016
public void onMoveStart ()
A callback indicating that a StreetLevelModel move has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveStart(void)
public void onMoveWait ()
A callback indicating that a StreetLevelModel move is waiting for StreetLevel data to be available before
continuing.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onMoveWait(void)
public void onOrientationEnd (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onOrientationEnd(float, float)
Parameters:
heading
pitch
public void onOrientationStart (float heading, float pitch)
A callback indicating that a StreetLevel orientation change has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onOrientationStart(float, float)
Parameters:
heading
pitch
public void onPositionChanged (GeoCoordinate coordinate)
A callback indicating that the StreetLevel position has changed.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onPositionChanged(GeoCoordinate)
Parameters:
coordinate
public void onStreetLevelChanged ()
A callback indicating that StreetLevel data has changed.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelChanged(void)
HERE Android SDK Developer's Guide
API Reference
2017
public void onStreetLevelFullyLoaded ()
A callback indicating that StreetLevel data is fully loaded.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelFullyLoaded(void)
public void onStreetLevelInvalidated ()
A callback indicating that StreetLevel data has become invalid.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelInvalidated(void)
public void onStreetLevelPreviewAvailable ()
A callback indicating that StreetLevel preview image is available.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onStreetLevelPreviewAvailable(void)
public void onZoomEnd (float zoom)
A callback indicating that a StreetLevel zoom operation has ended.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onZoomEnd(float)
Parameters:
zoom
public void onZoomStart (float zoom)
A callback indicating that StreetLevel a zoom operation has started.
This method overrides streetlevel.StreetLevelModel.OnEventListener.onZoomStart(float)
Parameters:
zoom
OnRetrievalListener
The interface OnRetrievalListener is a member of com.here.android.mpa.streetlevel.StreetLevelModel.
Interface Summary
public static abstract interface StreetLevelModel.OnRetrievalListener
Listener class to be used with getStreetLevel(GeoCoordinate, StreetLevelModel.OnRetrievalListener) to retrieve
a StreetLevel.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
2018
Method Summary
Table 1231: Methods in OnRetrievalListener
Methods
public abstract void onGetStreetLevelCompleted (StreetLevel object)
Callback method to notify caller when the StreetLevel retrieval request is completed.
Interface Details
Listener class to be used with getStreetLevel(GeoCoordinate, StreetLevelModel.OnRetrievalListener) to retrieve
a StreetLevel.
Method Details
public abstract void onGetStreetLevelCompleted (StreetLevel object)
Callback method to notify caller when the StreetLevel retrieval request is completed.
Parameters:
object
StreetLevel retrieved. Can be null if no StreetLevel is present.
StreetLevelModelState
The class StreetLevelModelState is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelModelState
implements android.os.Parcelable
extends java.lang.Object
Represents a composite class comprising the zoom level, heading, pitch and roll for a StreetLevelModel.
[For complete information, see the section Class Details]
Constructor Summary
Table 1232: Constructors in StreetLevelModelState
Constructors
StreetLevelModelState (Parcel in)
HERE Android SDK Developer's Guide
API Reference
2019
Field Summary
Table 1233: Fields in StreetLevelModelState
Fields
public static final android.os.Parcelable.Creator <StreetLevelModelState> CREATOR
Method Summary
Table 1234: Methods in StreetLevelModelState
Methods
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public boolean equals (Object obj)
For documentation, see java.lang.Object
public float getHeading ()
Gets the current heading of the StreetLevelModel.
public float getPitch ()
Gets the current pitch of the StreetLevelModel.
public float getZoom ()
Gets the current zoom level of the StreetLevelModel.
public int hashCode ()
For documentation, see java.lang.Object
public void writeToParcel (Parcel dest, int flags)
For documentation, see android.os.Parcelable.writeToParcel(Parcel, int)
Class Details
Represents a composite class comprising the zoom level, heading, pitch and roll for a StreetLevelModel.
Note: this object can be retrieved by calling getState().
Constructor Details
StreetLevelModelState (Parcel in)
Parameters:
in
HERE Android SDK Developer's Guide
API Reference
2020
Field Details
public static final android.os.Parcelable.Creator <StreetLevelModelState>
CREATOR
Method Details
public int describeContents ()
For documentation, see android.os.Parcelable.describeContents()
public boolean equals (Object obj)
For documentation, see java.lang.Object
Parameters:
obj
public float getHeading ()
Gets the current heading of the StreetLevelModel.
Returns:
The current heading
public float getPitch ()
Gets the current pitch of the StreetLevelModel.
Returns:
The current pitch
public float getZoom ()
Gets the current zoom level of the StreetLevelModel.
Returns:
The current zoom level
public int hashCode ()
For documentation, see java.lang.Object
public void writeToParcel (Parcel dest, int flags)
HERE Android SDK Developer's Guide
API Reference
2021
For documentation, see android.os.Parcelable.writeToParcel(Parcel, int)
Parameters:
dest
flags
StreetLevelObject
The class StreetLevelObject is a member of com.here.android.mpa.streetlevel .
Class Summary
public abstract class StreetLevelObject
extends com.here.android.mpa.common.ViewObject, java.lang.Object
Represents a base class for all street level related objects that users can add to an on-screen
StreetLevelModel instance.
[For complete information, see the section Class Details]
See also:
StreetLevelIconBase
Nested Class Summary
Table 1235: Nested Classes in StreetLevelObject
Nested Classes
public static final enumeration StreetLevelObject.Type
Represents values describing the types of objects that a user can add to a StreetLevelModel instance by calling
addStreetLevelObject(StreetLevelObject).
Method Summary
Table 1236: Methods in StreetLevelObject
Methods
public Type getBaseType ()
Gets the base ViewObject.Type that the StreetLevelObject represents.
public Type getType ()
Gets the specific StreetLevelObject.Type that the StreetLevelObject represents.
Class Details
Represents a base class for all street level related objects that users can add to an on-screen
StreetLevelModel instance.
HERE Android SDK Developer's Guide
API Reference
2022
This class serves as a generalization (or abstract base) for several more specified street level object
types, bundling their common properties. Users can add the following types of street level objects to a
StreetLevelModel:
StreetLevelIcon
StreetLevelBillboard
See also:
StreetLevelIconBase
Method Details
public Type getBaseType ()
Gets the base ViewObject.Type that the StreetLevelObject represents.
Returns:
The ViewObject.Type
public Type getType ()
Gets the specific StreetLevelObject.Type that the StreetLevelObject represents.
Returns:
The StreetLevelObject.Type
Type
The enumeration Type is a member of com.here.android.mpa.streetlevel.StreetLevelObject.
Enumeration Summary
public static final enumeration StreetLevelObject.Type
extends java.lang.Enum, java.lang.Object
Represents values describing the types of objects that a user can add to a StreetLevelModel instance by
calling addStreetLevelObject(StreetLevelObject).
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1237: Enum Constants in Type
Fields
public static final Type BILLBOARD_OBJECT
A StreetLevelBillboard.
HERE Android SDK Developer's Guide
API Reference
2023
Fields
public static final Type ICON_OBJECT
A StreetLevelIcon.
public static final Type ROUTE_OBJECT
A StreetLevelRoute
public static final Type UNKNOWN
An unknown StreetLevelObject.Type.
Method Summary
Table 1238: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StreetLevelObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the types of objects that a user can add to a StreetLevelModel instance by
calling addStreetLevelObject(StreetLevelObject).
Enum Constant Details
public static final Type BILLBOARD_OBJECT
A StreetLevelBillboard.
public static final Type ICON_OBJECT
A StreetLevelIcon.
public static final Type ROUTE_OBJECT
A StreetLevelRoute
public static final Type UNKNOWN
An unknown StreetLevelObject.Type.
HERE Android SDK Developer's Guide
API Reference
2024
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StreetLevelOffScreenCapture
The class StreetLevelOffScreenCapture is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelOffScreenCapture
implements com.here.android.mpa.common.OffScreenRenderer
extends java.lang.Object
StreetLevel derivation of the com.here.android.mpa.common.OffScreenRenderer renderer.
[For complete information, see the section Class Details]
Constructor Summary
Table 1239: Constructors in StreetLevelOffScreenCapture
Constructors
StreetLevelOffScreenCapture (Context context)
Public constructor.
Method Summary
Table 1240: Methods in StreetLevelOffScreenCapture
Methods
public void getScreenCapture (OnScreenCaptureListener listener)
Returns a bitmap of the Street Level Imagery.
public void pause ()
Pause the offscreen renderer
HERE Android SDK Developer's Guide
API Reference
2025
Methods
public StreetLevelOffScreenCapture setModel (StreetLevelModel model)
Set the StreetLevelModel for off-screen rendering
public StreetLevelOffScreenCapture setSize (int width, int height)
Set the size of the requested screen capture.
public void start ()
Start the offscreen renderer.
public void start (SurfaceHolder renderTarget, SurfaceUpdatedListener listener)
Start the offscreen renderer.
public void stop ()
Stop the offscreen renderer.
Class Details
StreetLevel derivation of the com.here.android.mpa.common.OffScreenRenderer renderer. This
class as allows the user to capture screenshots of a StreetLevel without using an Android View .
Constructor Details
StreetLevelOffScreenCapture (Context context)
Public constructor.
Parameters:
context
Application context.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
Method Details
public void getScreenCapture (OnScreenCaptureListener listener)
Returns a bitmap of the Street Level Imagery. Bitmap is of size set by setSize(int, int). Call this method only
after the rendering thread is started via start(). This method is asynchronous and will invoke a callback once
the operation is completed through the ScreenCaptureListener. Note that the rendering thread must be
started before this operation.
Parameters:
listener
A ScreenCaptureListener to listen for the callback when screen capture is complete.
HERE Android SDK Developer's Guide
API Reference
2026
See also:
setSize(int, int)
start()
public void pause ()
Pause the offscreen renderer
public StreetLevelOffScreenCapture setModel (StreetLevelModel model)
Set the StreetLevelModel for off-screen rendering
Parameters:
model
StreetLevelModel
Returns:
This StreetLevelOffScreenCapture object
public StreetLevelOffScreenCapture setSize (int width, int height)
Set the size of the requested screen capture. This method must be called before start().
Parameters:
width
Desired width of the returned bitmap
height
Desired height of the returned bitmap
Returns:
This StreetLevelOffScreenCapture object
public void start ()
Start the offscreen renderer. A new PBuffer based surface will be allocated.
public void start (SurfaceHolder renderTarget, SurfaceUpdatedListener
listener)
Start the offscreen renderer. The renderer will be attached to the supplied Surface argument.
Parameters:
renderTarget
HERE Android SDK Developer's Guide
API Reference
2027
Surface to attach to.
listener
Callback when the surface has been updated
public void stop ()
Stop the offscreen renderer. All resource allocated will be released.
StreetLevelProxyObject
The class StreetLevelProxyObject is a member of com.here.android.mpa.streetlevel .
Class Summary
public abstract class StreetLevelProxyObject
extends com.here.android.mpa.common.ViewObject, java.lang.Object
Represents a base class for all street level objects rendered as part of the map.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1241: Nested Classes in StreetLevelProxyObject
Nested Classes
public static final enumeration StreetLevelProxyObject.Type
Represents values describing the types of objects that can be retrieved from a StreetLevelModel instance by calling
getSelectedObjects(PointF).
Method Summary
Table 1242: Methods in StreetLevelProxyObject
Methods
public abstract Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
Class Details
Represents a base class for all street level objects rendered as part of the map. This interface serves as
a generalization (or abstract base) for several more specified proxy object types, bundling their common
properties.
HERE Android SDK Developer's Guide
API Reference
2028
Method Details
public abstract Type getType ()
Gets the type of object that the {link StreetLevelProxyObject} represents.
Returns:
The StreetLevelProxyObject.Type
Type
The enumeration Type is a member of com.here.android.mpa.streetlevel.StreetLevelProxyObject.
Enumeration Summary
public static final enumeration StreetLevelProxyObject.Type
extends java.lang.Enum, java.lang.Object
Represents values describing the types of objects that can be retrieved from a StreetLevelModel instance by
calling getSelectedObjects(PointF).
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1243: Enum Constants in Type
Fields
public static final Type LINK_OBJECT
A StreetLevelLink.
public static final Type BUILDING_OBJECT
A StreetLevelBuilding.
public static final Type TERRAIN_OBJECT
Not supported yet
public static final Type UNKNOWN
Unknown object type.
Method Summary
Table 1244: Methods in Type
Methods
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
2029
Methods
public static StreetLevelProxyObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values describing the types of objects that can be retrieved from a StreetLevelModel instance by
calling getSelectedObjects(PointF).
Enum Constant Details
public static final Type LINK_OBJECT
A StreetLevelLink.
public static final Type BUILDING_OBJECT
A StreetLevelBuilding.
public static final Type TERRAIN_OBJECT
Not supported yet
public static final Type UNKNOWN
Unknown object type.
Method Details
public static Type valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StreetLevelProxyObject.Type[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
2030
StreetLevelRoute
The class StreetLevelRoute is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelRoute
extends com.here.android.mpa.streetlevel.StreetLevelObject, com.here.android.mpa.common.ViewObject,
java.lang.Object
Represents a route displayed within a StreetLevelFragment
[For complete information, see the section Class Details]
See also:
StreetLevelFragment
Constructor Summary
Table 1245: Constructors in StreetLevelRoute
Constructors
StreetLevelRoute ()
StreetLevelRoute (Route route)
Method Summary
Table 1246: Methods in StreetLevelRoute
Methods
public int getColor ()
Gets the current ARGB (Alpha/Red/Green/Blue) integer color value used to display the route.
public Route getRoute ()
Gets the Route that has been displayed on the StreetLevel.
public StreetLevelRoute setColor (int argbColor)
Sets a color for displaying the route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
public StreetLevelRoute setRoute (Route route)
Sets a Route that will be displayed on the StreetLevel.
Class Details
Represents a route displayed within a StreetLevelFragment
See also:
StreetLevelFragment
HERE Android SDK Developer's Guide
API Reference
2031
Constructor Details
StreetLevelRoute ()
StreetLevelRoute (Route route)
Parameters:
route
Method Details
public int getColor ()
Gets the current ARGB (Alpha/Red/Green/Blue) integer color value used to display the route.
Returns:
The current ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and 255
meaning 100% contribution
See also:
android.graphics.Color
public Route getRoute ()
Gets the Route that has been displayed on the StreetLevel.
Returns:
The Route
public StreetLevelRoute setColor (int argbColor)
Sets a color for displaying the route, using an ARGB (Alpha/Red/Green/Blue) integer color value.
Parameters:
argbColor
The ARGB integer color value. The packed integer is made up of 4 bytes: alpha, red, green, blue. Each
color component has a value range from [0..255] with 0 meaning no contribution for that component, and
255 meaning 100% contribution
Returns:
The updated StreetLevelRoute object itself.
See also:
android.graphics.Color
HERE Android SDK Developer's Guide
API Reference
2032
public StreetLevelRoute setRoute (Route route)
Sets a Route that will be displayed on the StreetLevel. NOTE: Truck routes and public transport timetable
routes are unsupported. A java.lang.IllegalArgumentException will be thrown.
Parameters:
route
A Route representing the route to be displayed on the StreetLevel
Returns:
The updated StreetLevelRoute object itself.
Throws:
IllegalArgumentException
if route is a truck or public transport timetable route.
StreetLevelSelectedObject
The class StreetLevelSelectedObject is a member of com.here.android.mpa.streetlevel .
Class Summary
public final class StreetLevelSelectedObject
extends java.lang.Object
Represents a base class for all objects that are selectable on a StreetLevelFragment.
[For complete information, see the section Class Details]
See also:
getSelectedObjects(PointF)
Method Summary
Table 1247: Methods in StreetLevelSelectedObject
Methods
public Vector3f getNormal ()
Gets the Vector3f representing the normal vector of the selected object.
public ViewObject getObject ()
Gets the ViewObject representation of the StreetLevelSelectedObject.
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the current position of the StreetLevelSelectedObject.
HERE Android SDK Developer's Guide
API Reference
2033
Class Details
Represents a base class for all objects that are selectable on a StreetLevelFragment.
See also:
getSelectedObjects(PointF)
Method Details
public Vector3f getNormal ()
Gets the Vector3f representing the normal vector of the selected object. This can be used with
StreetLevelBillboardOrientation in setOrientation(StreetLevelBillboardOrientation.Orientation)
Returns:
The normal Vector3d
public ViewObject getObject ()
Gets the ViewObject representation of the StreetLevelSelectedObject.
Note: use instanceof to determine the exact type ( StreetLevelBuilding, StreetLevelLink, etc.).
Returns:
The ViewObject
public GeoCoordinate getPosition ()
Gets the GeoCoordinate representing the current position of the StreetLevelSelectedObject.
Returns:
The GeoCoordinate
tce
The package tce is a member of com.here.android.mpa.
Package Summary
tce
The package tce (Toll Cost Extension) provides classes, interfaces, and enumerations that allow your
application to easily access Toll Cost Extension REST API.
Package Details
HERE Android SDK Developer's Guide
API Reference
2034
The package tce (Toll Cost Extension) provides classes, interfaces, and enumerations that allow your
application to easily access Toll Cost Extension REST API.
TollCostError
The class TollCostError is a member of com.here.android.mpa.tce .
Class Summary
public final class TollCostError
extends java.lang.Object
Represents error reported by TollCostRequest.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1248: Nested Classes in TollCostError
Nested Classes
public static final enumeration TollCostError.ErrorCode
Different Error codes reported by TollCostRequest.
Method Summary
Table 1249: Methods in TollCostError
Methods
public ErrorCode getErrorCode ()
public String getErrorMessage ()
Class Details
Represents error reported by TollCostRequest.
Method Details
public ErrorCode getErrorCode ()
Returns:
error code.
public String getErrorMessage ()
Returns:
HERE Android SDK Developer's Guide
API Reference
2035
human readable description of this error.
ErrorCode
The enumeration ErrorCode is a member of com.here.android.mpa.tce.TollCostError.
Enumeration Summary
public static final enumeration TollCostError.ErrorCode
extends java.lang.Enum, java.lang.Object
Different Error codes reported by TollCostRequest.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1250: Enum Constants in ErrorCode
Fields
public static final ErrorCode SUCCESS
Operation successful.
public static final ErrorCode NO_PERMISSION
No permission to use Toll cost feature.
public static final ErrorCode ALREADY_RUNNING
Request is already in progress.
public static final ErrorCode CANCELLED
Operation cancelled.
public static final ErrorCode INVALID_PARAMETER
Invalid parameters.
public static final ErrorCode NO_CONNECTION
No network connection.
public static final ErrorCode SERVER_ERROR
Server error.
public static final ErrorCode UNKNOWN
Unknown.
HERE Android SDK Developer's Guide
API Reference
2036
Method Summary
Table 1251: Methods in ErrorCode
Methods
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostError.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Different Error codes reported by TollCostRequest.
Enum Constant Details
public static final ErrorCode SUCCESS
Operation successful.
public static final ErrorCode NO_PERMISSION
No permission to use Toll cost feature.
public static final ErrorCode ALREADY_RUNNING
Request is already in progress.
public static final ErrorCode CANCELLED
Operation cancelled.
public static final ErrorCode INVALID_PARAMETER
Invalid parameters.
public static final ErrorCode NO_CONNECTION
No network connection.
public static final ErrorCode SERVER_ERROR
Server error.
HERE Android SDK Developer's Guide
API Reference
2037
public static final ErrorCode UNKNOWN
Unknown.
Method Details
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostError.ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TollCostOptions
The class TollCostOptions is a member of com.here.android.mpa.tce .
Class Summary
public final class TollCostOptions
extends java.lang.Object
Represent different input parameters for TollCostRequest.
[For complete information, see the section Class Details]
Constructor Summary
Table 1252: Constructors in TollCostOptions
Constructors
TollCostOptions ()
Create TollCostOptions .
Method Summary
Table 1253: Methods in TollCostOptions
Methods
public boolean equals (Object obj)
HERE Android SDK Developer's Guide
API Reference
2038
Methods
public String getCurrency ()
Gets currency parameter in currency's ISO-4217 code.
public Date getDeparture ()
Gets the departure time for the given Route.
public TollCostVehicleProfile getVehicleProfile ()
Gets the copy of TollCostVehicleProfile.
public int hashCode ()
public void setCurrency (String currencyCode)
Sets the currency parameter in currency's ISO-4217 code.
public void setDeparture (Date date)
Sets the departure time for the Route.
public void setVehicleProfile (TollCostVehicleProfile vehicleProfile)
Sets the TollCostVehicleProfile parameters.
Class Details
Represent different input parameters for TollCostRequest.
Constructor Details
TollCostOptions ()
Create TollCostOptions .
Method Details
public boolean equals (Object obj)
Parameters:
obj
public String getCurrency ()
Gets currency parameter in currency's ISO-4217 code. Default value is EUR .
Returns:
currency parameter;
public Date getDeparture ()
Gets the departure time for the given Route.
HERE Android SDK Developer's Guide
API Reference
2039
Returns:
departure time of route if set previously, otherwise null.
public TollCostVehicleProfile getVehicleProfile ()
Gets the copy of TollCostVehicleProfile.
Returns:
the parameter TollCostVehicleProfile.
public int hashCode ()
public void setCurrency (String currencyCode)
Sets the currency parameter in currency's ISO-4217 code. All of the costs are returned in the specified
currency. Default value is EUR .
When the currency is found to be invalid, the related request raises an TollCostError .
Parameters:
currencyCode
- currency's ISO-4217 code in string format.
Throws:
IllegalArgumentException
if format is null or not 3 character long.
public void setDeparture (Date date)
Sets the departure time for the Route.
Parameters:
date
departure time.
Throws:
NullPointerException
if date is null.
public void setVehicleProfile (TollCostVehicleProfile vehicleProfile)
Sets the TollCostVehicleProfile parameters.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2040
vehicleProfile
TollCostVehicleProfile parameter.
TollCostRequest
The class TollCostRequest is a member of com.here.android.mpa.tce .
Class Summary
public final class TollCostRequest
extends java.lang.Object
Allows you to determine the toll costs for a specified route for a defined vehicle profile.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1254: Nested Classes in TollCostRequest
Nested Classes
public static abstract interface TollCostRequest.Listener
Represents a listener that reports information about the completion of a TollCostRequest TollCostRequest.
Constructor Summary
Table 1255: Constructors in TollCostRequest
Constructors
TollCostRequest (Route route, TollCostOptions options)
Create a Toll Cost Extension request with the given route and parameters.
Method Summary
Table 1256: Methods in TollCostRequest
Methods
public void cancel ()
Attempts to cancel the ongoing TollCostRequest.
public void execute (Listener<TollCostResult> listener)
Execute the TollCostRequest asynchronously with the specified listener.
Class Details
Allows you to determine the toll costs for a specified route for a defined vehicle profile.
HERE Android SDK Developer's Guide
API Reference
2041
Please note that it only support route calculated with transport mode CAR and TRUCK in ONLINE mode. Also
note that, this request works only in Online Mode.
Constructor Details
TollCostRequest (Route route, TollCostOptions options)
Create a Toll Cost Extension request with the given route and parameters. The route parameter only provides
the route and no routing option is considered for the toll cost calculation. It is the caller's responsibility
to have the route and toll cost options compatible. When they are not compatible, e.g. for the toll cost
the vehicle type is set as car, whereas the route is created for a truck, the quality of the outcome may
deteriorate.
Please also note that route should only be calculated with transport mode CAR and TRUCK in ONLINE mode.
Parameters:
route
Route to calculate toll cost.
options
TollCostOptions to create TCE Request.
Throws:
IllegalArgumentException
if route or options is not valid OR route is calculated offline OR route is not calculated with
transportMode CAR or TRUCK.
Method Details
public void cancel ()
Attempts to cancel the ongoing TollCostRequest. Calling this method does not guarantees cancellation of the
request. Subsequent calls of this method will be ignored, once the request is cancelled.
public void execute (Listener<TollCostResult> listener)
Execute the TollCostRequest asynchronously with the specified listener.
Parameters:
listener
A TollCostRequest.Listener to be notified with result when the request is completed.
Listener<T>
The interface Listener<T> is a member of com.here.android.mpa.tce.TollCostRequest.
HERE Android SDK Developer's Guide
API Reference
2042
Type Parameters:
T
Listener data type.
Interface Summary
public static abstract interface TollCostRequest.Listener
Represents a listener that reports information about the completion of a TollCostRequest TollCostRequest.
[For complete information, see the section Interface Details]
Method Summary
Table 1257: Methods in Listener<T>
Methods
public abstract void onComplete (T data, TollCostError error)
A callback indicating that a request operation has completed.
Interface Details
Represents a listener that reports information about the completion of a TollCostRequest TollCostRequest.
Method Details
public abstract void onComplete (T data, TollCostError error)
A callback indicating that a request operation has completed.
Parameters:
data
Search results (can be null if an error was encountered).
error
An TollCostError representing an appropriate error/success conditions.
TollCostResult
The class TollCostResult is a member of com.here.android.mpa.tce .
Class Summary
public final class TollCostResult
extends java.lang.Object
Represent result of TollCostRequest.
HERE Android SDK Developer's Guide
API Reference
2043
[For complete information, see the section Class Details]
Method Summary
Table 1258: Methods in TollCostResult
Methods
public Map getTollCostByCountry ()
Gets the toll cost for each country the route traverses.
public Map getTollCostByTollSystemName ()
Gets the toll cost for each toll system the route traverses.
public BigDecimal getTotalTollCost ()
Gets the total toll cost of given Route.
Class Details
Represent result of TollCostRequest. This class wrap different toll costs.
Method Details
public Map getTollCostByCountry ()
Gets the toll cost for each country the route traverses.
Returns:
A map of ISO ALPHA-3 country code and toll cost in the specified setCurrency(String) currency. Default
currency is EUR.
public Map getTollCostByTollSystemName ()
Gets the toll cost for each toll system the route traverses.
Please note that the toll system names will not be localized.
Returns:
A map of toll system name and toll cost in the specified setCurrency(String) currency. Default currency is EUR.
public BigDecimal getTotalTollCost ()
Gets the total toll cost of given Route.
Returns:
total toll cost in the specified setCurrency(String) currency. Default currency is EUR.
HERE Android SDK Developer's Guide
API Reference
2044
TollCostVehicleProfile
The class TollCostVehicleProfile is a member of com.here.android.mpa.tce .
Class Summary
public final class TollCostVehicleProfile
extends java.lang.Object
Specify vehicle parameters to calculate toll cost.
[For complete information, see the section Class Details]
See also:
setVehicleProfile(TollCostVehicleProfile)
Nested Class Summary
Table 1259: Nested Classes in TollCostVehicleProfile
Nested Classes
public static final enumeration TollCostVehicleProfile.EmissionType
Vehicle emission type.
public static final enumeration TollCostVehicleProfile.Hybrid
Vehicle running mode.
public static final enumeration TollCostVehicleProfile.ShippedHazardousGoods
Shipped Hazardous Goods
public static final enumeration TollCostVehicleProfile.TrailerType
Trailer Type.
public static final enumeration TollCostVehicleProfile.TrailersCount
Trailers count.
public static final enumeration TollCostVehicleProfile.VehicleType
Represent different Vehicle types.
Constructor Summary
Table 1260: Constructors in TollCostVehicleProfile
Constructors
TollCostVehicleProfile ()
public constructor
HERE Android SDK Developer's Guide
API Reference
2045
Method Summary
Table 1261: Methods in TollCostVehicleProfile
Methods
public boolean equals (Object obj)
public EmissionType getEmissionType ()
Gets vehicle emission type.
public double getHeight ()
Gets vehicle height in meters.
public int getHeightAbove1stAxle ()
Gets height above 1st axle in meters.
public Hybrid getHybridMode ()
Gets vehicle running mode.
public double getLimitedWeight ()
Gets total weight of the vehicle including trailer(s) or caravan in tonne.
public int getPassengersCount ()
Gets number of passengers can fit in vehicle.
public ShippedHazardousGoods getShippedHazardousGoods ()
Gets hazardous goods transported in the vehicle.
public int getTiresCount ()
Gets vehicle's tires count.
public TrailersCount getTrailerCount ()
Gets trailer count.
public double getTrailerHeight ()
Gets trailer height in meters.
public int getTrailerNumberAxles ()
Gets number of trailer's axles.
public TrailerType getTrailerType ()
Gets trailer type.
public int getVehicleAxles ()
Gets number of vehicle's axles (not including trailer axles).
public VehicleType getVehicleType ()
Gets vehicle type.
public double getWeight ()
Gets vehicle weight in tonne.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2046
Methods
public boolean isCommercial ()
Gets if the vehicle is designed for commercial use.
public boolean isDisabledEquipped ()
Gets if the vehicle is specially equipped for transporting disabled people.
public TollCostVehicleProfile setCommercial (boolean commercial)
Sets if the vehicle is designed for commercial use.
public void setDisabledEquipped (boolean enable)
Sets if the vehicle is specially equipped for transporting disabled people.
public TollCostVehicleProfile setEmissionType (EmissionType emissionType)
Sets vehicle emission type.
public TollCostVehicleProfile setHeight (double height)
Sets vehicle height in meters.
public TollCostVehicleProfile setHeightAbove1stAxle (int heightAbove1stAxle)
Sets height above 1st axle in meters.
public TollCostVehicleProfile setHybridMode (Hybrid hybridMode)
Sets vehicle running mode.
public TollCostVehicleProfile setLimitedWeight (double limitedWeight)
Sets total weight of the vehicle including trailer(s) or caravan in tonne.
public TollCostVehicleProfile setPassengersCount (int passengersCount)
Set number of passengers can fit in vehicle.
public TollCostVehicleProfile setShippedHazardousGoods (ShippedHazardousGoods shippedHazardousGoods)
Sets hazardous goods transported in the vehicle.
public TollCostVehicleProfile setTiresCount (int tiresCount)
Sets vehicle's tires count.
public TollCostVehicleProfile setTrailerCount (TrailersCount trailerCount)
Sets trailer count.
public TollCostVehicleProfile setTrailerHeight (double trailerHeight)
Sets trailer height in meters.
public TollCostVehicleProfile setTrailerNumberAxles (int trailerNumberAxles)
Sets number of trailer's axles.
public TollCostVehicleProfile setTrailerType (TrailerType trailerType)
Sets trailer type.
public TollCostVehicleProfile setVehicleAxles (int axles)
Sets number of vehicle's axles (not including trailer axles).
HERE Android SDK Developer's Guide
API Reference
2047
Methods
public TollCostVehicleProfile setVehicleType (VehicleType vehicleType)
Sets vehicle type.
public TollCostVehicleProfile setWeight (double weight)
Sets vehicle weight in tonne.
Class Details
Specify vehicle parameters to calculate toll cost. This class can be used to create TollCostOptions that can be
further used in TollCostRequest to make request for toll cost .
See also:
setVehicleProfile(TollCostVehicleProfile)
Constructor Details
TollCostVehicleProfile ()
public constructor
Method Details
public boolean equals (Object obj)
Parameters:
obj
public EmissionType getEmissionType ()
Gets vehicle emission type. Default is NONE.
Returns:
vehicle emission type.
public double getHeight ()
Gets vehicle height in meters.
Returns:
vehicle's height.
public int getHeightAbove1stAxle ()
Gets height above 1st axle in meters.
HERE Android SDK Developer's Guide
API Reference
2048
Returns:
height above 1st axle.
public Hybrid getHybridMode ()
Gets vehicle running mode. Default is NONE.
Returns:
vehicle running mode.
public double getLimitedWeight ()
Gets total weight of the vehicle including trailer(s) or caravan in tonne.
Returns:
total weight of the vehicle including trailer(s) or caravan in tonne.
public int getPassengersCount ()
Gets number of passengers can fit in vehicle. Default is 1 .
Returns:
number of passengers can fit in vehicle.
public ShippedHazardousGoods getShippedHazardousGoods ()
Gets hazardous goods transported in the vehicle. Default is NONE.
Returns:
hazardous goods transported in the vehicle.
public int getTiresCount ()
Gets vehicle's tires count. Default is 4 .
Returns:
vehicle's tires count.
public TrailersCount getTrailerCount ()
Gets trailer count. Default is VEHICLE_WITHOUT_TRAILER.
Returns:
Trailer count.
HERE Android SDK Developer's Guide
API Reference
2049
public double getTrailerHeight ()
Gets trailer height in meters.
Returns:
Trailer height in meters.
public int getTrailerNumberAxles ()
Gets number of trailer's axles. Default is 0 .
Returns:
Number of trailer's axles.
public TrailerType getTrailerType ()
Gets trailer type. Default is NONE.
Returns:
Trailer type.
public int getVehicleAxles ()
Gets number of vehicle's axles (not including trailer axles). Default is 2 .
Returns:
number of vehicle's axles.
public VehicleType getVehicleType ()
Gets vehicle type. Default is AUTO.
Returns:
vehicle type.
public double getWeight ()
Gets vehicle weight in tonne.
Returns:
vehicle weight in tonne.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2050
public boolean isCommercial ()
Gets if the vehicle is designed for commercial use. Default is false .
Returns:
if the vehicle is designed for commercial use
public boolean isDisabledEquipped ()
Gets if the vehicle is specially equipped for transporting disabled people.
Returns:
if the vehicle is specially equipped for transporting disabled people.
public TollCostVehicleProfile setCommercial (boolean commercial)
Sets if the vehicle is designed for commercial use. Default is false .
Parameters:
commercial
if the vehicle is designed for commercial use
Returns:
updated instance for chaining.
public void setDisabledEquipped (boolean enable)
Sets if the vehicle is specially equipped for transporting disabled people. Default is false .
Parameters:
enable
if the vehicle is specially equipped for transporting disabled people.
public TollCostVehicleProfile setEmissionType (EmissionType emissionType)
Sets vehicle emission type. Default is NONE.
Parameters:
emissionType
vehicle emission type.
Returns:
updated instance for chaining.
HERE Android SDK Developer's Guide
API Reference
2051
public TollCostVehicleProfile setHeight (double height)
Sets vehicle height in meters.
Parameters:
height
vehicle height in meters.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if height is not greater than 0.
public TollCostVehicleProfile setHeightAbove1stAxle (int heightAbove1stAxle)
Sets height above 1st axle in meters.
Parameters:
heightAbove1stAxle
height above 1st axle.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if heightAbove1stAxle is not greater than 0.
public TollCostVehicleProfile setHybridMode (Hybrid hybridMode)
Sets vehicle running mode. Default is NONE.
Parameters:
hybridMode
vehicle running mode.
Returns:
updated instance for chaining.
public TollCostVehicleProfile setLimitedWeight (double limitedWeight)
Sets total weight of the vehicle including trailer(s) or caravan in tonne.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2052
limitedWeight
total weight of the vehicle including trailer(s) or caravan in tonne.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if limitedWeight is not greater than 0.
public TollCostVehicleProfile setPassengersCount (int passengersCount)
Set number of passengers can fit in vehicle. Default is 1 .
Parameters:
passengersCount
number of passengers.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if passengersCount is not greater than 0.
public TollCostVehicleProfile setShippedHazardousGoods (ShippedHazardousGoods
shippedHazardousGoods)
Sets hazardous goods transported in the vehicle. Default is NONE.
Parameters:
shippedHazardousGoods
hazardous goods transported in the vehicle.
Returns:
updated instance for chaining.
public TollCostVehicleProfile setTiresCount (int tiresCount)
Sets vehicle's tires count. Default is 4 .
Parameters:
tiresCount
tires count.
Returns:
HERE Android SDK Developer's Guide
API Reference
2053
updated instance for chaining.
Throws:
IllegalArgumentException
if tiresCount is not greater than 0.
public TollCostVehicleProfile setTrailerCount (TrailersCount trailerCount)
Sets trailer count. Default is VEHICLE_WITHOUT_TRAILER.
Note - setTrailerType(TollCostVehicleProfile.TrailerType), setTrailerHeight(double) and
setTrailerNumberAxles(int) should also be set otherwise TollCostError will be reported while making request.
Parameters:
trailerCount
number of trailer.
Returns:
updated instance for chaining.
public TollCostVehicleProfile setTrailerHeight (double trailerHeight)
Sets trailer height in meters.
Note - setTrailerType(TollCostVehicleProfile.TrailerType), setTrailerCount(TollCostVehicleProfile.TrailersCount)
and setTrailerNumberAxles(int) should also be set otherwise TollCostError will be reported while making
request.
Parameters:
trailerHeight
trailer height.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if trailerHeight is not greater than 0.
See also:
setTrailerType(TrailerType)
public TollCostVehicleProfile setTrailerNumberAxles (int trailerNumberAxles)
Sets number of trailer's axles.
HERE Android SDK Developer's Guide
API Reference
2054
Note - setTrailerType(TollCostVehicleProfile.TrailerType), setTrailerHeight(double) and
setTrailerCount(TollCostVehicleProfile.TrailersCount) should also be set otherwise TollCostError will be
reported while making request.
Parameters:
trailerNumberAxles
number of trailer's axles.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if trailerNumberAxles is not greater than 0.
See also:
setTrailerType(TrailerType)
public TollCostVehicleProfile setTrailerType (TrailerType trailerType)
Sets trailer type. Default is NONE.
Note - setTrailerCount(TollCostVehicleProfile.TrailersCount), setTrailerHeight(double) and
setTrailerNumberAxles(int) should also be set, if Trailer type is not NONE otherwise TollCostError will be
reported while making request.
Parameters:
trailerType
trailer Type
Returns:
updated instance for chaining.
public TollCostVehicleProfile setVehicleAxles (int axles)
Sets number of vehicle's axles (not including trailer axles). Default is 2 .
Parameters:
axles
vehicle's axles
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if axles is not greater than 0.
HERE Android SDK Developer's Guide
API Reference
2055
public TollCostVehicleProfile setVehicleType (VehicleType vehicleType)
Sets vehicle type. Default is AUTO.
Parameters:
vehicleType
vehicle type.
Returns:
updated instance for chaining.
public TollCostVehicleProfile setWeight (double weight)
Sets vehicle weight in tonne.
Parameters:
weight
vehicle weight.
Returns:
updated instance for chaining.
Throws:
IllegalArgumentException
if weight is not greater than 0.
EmissionType
The enumeration EmissionType is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.EmissionType
extends java.lang.Enum, java.lang.Object
Vehicle emission type.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
2056
Enum Constant Summary
Table 1262: Enum Constants in EmissionType
Fields
public static final EmissionType NONE
No emission type set.
public static final EmissionType EURO_I
EURO_I emission type.
public static final EmissionType EURO_II
EURO_II emission type.
public static final EmissionType EURO_III
EURO_III emission type.
public static final EmissionType EURO_IV
EURO_IV emission type.
public static final EmissionType EURO_V
EURO_V emission type.
public static final EmissionType EURO_VI
EURO_VI emission type.
public static final EmissionType EURO_EEV
EURO_EEV emission type.
public static final EmissionType ELECTRIC_VEHICLES
Electric vehicles.
Method Summary
Table 1263: Methods in EmissionType
Methods
public static EmissionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.EmissionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Vehicle emission type.
Enum Constant Details
public static final EmissionType NONE
HERE Android SDK Developer's Guide
API Reference
2057
No emission type set.
public static final EmissionType EURO_I
EURO_I emission type.
public static final EmissionType EURO_II
EURO_II emission type.
public static final EmissionType EURO_III
EURO_III emission type.
public static final EmissionType EURO_IV
EURO_IV emission type.
public static final EmissionType EURO_V
EURO_V emission type.
public static final EmissionType EURO_VI
EURO_VI emission type.
public static final EmissionType EURO_EEV
EURO_EEV emission type.
public static final EmissionType ELECTRIC_VEHICLES
Electric vehicles.
Method Details
public static EmissionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
HERE Android SDK Developer's Guide
API Reference
2058
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostVehicleProfile.EmissionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Hybrid
The enumeration Hybrid is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.Hybrid
extends java.lang.Enum, java.lang.Object
Vehicle running mode.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1264: Enum Constants in Hybrid
Fields
public static final Hybrid PARTIALLY_ON_ELECTRICITY
the vehicle is partly running on electricity.
public static final Hybrid NONE
Otherwise
Method Summary
Table 1265: Methods in Hybrid
Methods
public static Hybrid valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.Hybrid[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Vehicle running mode.
HERE Android SDK Developer's Guide
API Reference
2059
Enum Constant Details
public static final Hybrid PARTIALLY_ON_ELECTRICITY
the vehicle is partly running on electricity.
public static final Hybrid NONE
Otherwise
Method Details
public static Hybrid valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostVehicleProfile.Hybrid[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ShippedHazardousGoods
The enumeration ShippedHazardousGoods is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.ShippedHazardousGoods
extends java.lang.Enum, java.lang.Object
Shipped Hazardous Goods
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1266: Enum Constants in ShippedHazardousGoods
Fields
public static final ShippedHazardousGoods NONE
No Hazardous Goods
HERE Android SDK Developer's Guide
API Reference
2060
Fields
public static final ShippedHazardousGoods EXPLOSIVES
Explosives
public static final ShippedHazardousGoods ANY_HAZARDOUS_MATERIAL
Any hazardous material
Method Summary
Table 1267: Methods in ShippedHazardousGoods
Methods
public static ShippedHazardousGoods valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.ShippedHazardousGoods[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Shipped Hazardous Goods
Enum Constant Details
public static final ShippedHazardousGoods NONE
No Hazardous Goods
public static final ShippedHazardousGoods EXPLOSIVES
Explosives
public static final ShippedHazardousGoods ANY_HAZARDOUS_MATERIAL
Any hazardous material
Method Details
public static ShippedHazardousGoods valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
2061
public static TollCostVehicleProfile.ShippedHazardousGoods[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrailerType
The enumeration TrailerType is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.TrailerType
extends java.lang.Enum, java.lang.Object
Trailer Type.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1268: Enum Constants in TrailerType
Fields
public static final TrailerType NONE
No trailer type.
public static final TrailerType CARAVAN
Caravan
public static final TrailerType TRAILER
Trailer
Method Summary
Table 1269: Methods in TrailerType
Methods
public static TrailerType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.TrailerType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Trailer Type.
HERE Android SDK Developer's Guide
API Reference
2062
Enum Constant Details
public static final TrailerType NONE
No trailer type.
public static final TrailerType CARAVAN
Caravan
public static final TrailerType TRAILER
Trailer
Method Details
public static TrailerType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostVehicleProfile.TrailerType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrailersCount
The enumeration TrailersCount is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.TrailersCount
extends java.lang.Enum, java.lang.Object
Trailers count.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
2063
Enum Constant Summary
Table 1270: Enum Constants in TrailersCount
Fields
public static final TrailersCount VEHICLE_WITHOUT_TRAILER
Vehicle without trailer
public static final TrailersCount VEHICLE_WITH_ONE_TRAILER
Vehicle with one trailer,
public static final TrailersCount VEHICLE_WITH_TWO_TRAILERS
Vehicle with two trailers.
public static final TrailersCount VEHICLE_WITH_THREE_OR_MORE_TRAILERS
Vehicle with three or more trailers.
Method Summary
Table 1271: Methods in TrailersCount
Methods
public static TrailersCount valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.TrailersCount[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Trailers count.
Enum Constant Details
public static final TrailersCount VEHICLE_WITHOUT_TRAILER
Vehicle without trailer
public static final TrailersCount VEHICLE_WITH_ONE_TRAILER
Vehicle with one trailer,
public static final TrailersCount VEHICLE_WITH_TWO_TRAILERS
Vehicle with two trailers.
public static final TrailersCount VEHICLE_WITH_THREE_OR_MORE_TRAILERS
HERE Android SDK Developer's Guide
API Reference
2064
Vehicle with three or more trailers.
Method Details
public static TrailersCount valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostVehicleProfile.TrailersCount[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VehicleType
The enumeration VehicleType is a member of com.here.android.mpa.tce.TollCostVehicleProfile.
Enumeration Summary
public static final enumeration TollCostVehicleProfile.VehicleType
extends java.lang.Enum, java.lang.Object
Represent different Vehicle types.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1272: Enum Constants in VehicleType
Fields
public static final VehicleType MOTORCYCLE
MotorCycle
public static final VehicleType AUTO
Auto
public static final VehicleType TRUCK
Truck
public static final VehicleType MOTOR_HOME
Motor Home
HERE Android SDK Developer's Guide
API Reference
2065
Fields
public static final VehicleType MINIBUS
Mini bus
public static final VehicleType BUS
Bus
public static final VehicleType MOTORCYCLE_SIDECAR
Motorcycle sidecar
public static final VehicleType TRICYLE
Tricycle
public static final VehicleType DELIVERY_TRUCK
Delivery Truck
public static final VehicleType SNOWMOBILE
Snow Mobile
public static final VehicleType PICK_UP
Pickup
public static final VehicleType TRACTOR
Tractor
public static final VehicleType TAXI
Taxi
public static final VehicleType HCM_EME
HCM/EME
Method Summary
Table 1273: Methods in VehicleType
Methods
public static VehicleType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static TollCostVehicleProfile.VehicleType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represent different Vehicle types.
Enum Constant Details
public static final VehicleType MOTORCYCLE
MotorCycle
HERE Android SDK Developer's Guide
API Reference
2066
public static final VehicleType AUTO
Auto
public static final VehicleType TRUCK
Truck
public static final VehicleType MOTOR_HOME
Motor Home
public static final VehicleType MINIBUS
Mini bus
public static final VehicleType BUS
Bus
public static final VehicleType MOTORCYCLE_SIDECAR
Motorcycle sidecar
public static final VehicleType TRICYLE
Tricycle
public static final VehicleType DELIVERY_TRUCK
Delivery Truck
public static final VehicleType SNOWMOBILE
Snow Mobile
public static final VehicleType PICK_UP
Pickup
public static final VehicleType TRACTOR
HERE Android SDK Developer's Guide
API Reference
2067
Tractor
public static final VehicleType TAXI
Taxi
public static final VehicleType HCM_EME
HCM/EME
Method Details
public static VehicleType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static TollCostVehicleProfile.VehicleType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
urbanmobility
The package urbanmobility is a member of com.here.android.mpa.
Package Summary
urbanmobility
The package urbanmobility provides classes, callbacks, and enumerations that can be used to enable
functionality related to public transit such as search for nearby transit stations and requests for departure
boards.
Package Details
The package urbanmobility provides classes, callbacks, and enumerations that can be used to enable
functionality related to public transit such as search for nearby transit stations and requests for departure
boards.
HERE Android SDK Developer's Guide
API Reference
2068
AbstractListRequest<T>
The class AbstractListRequest<T> is a member of com.here.android.mpa.urbanmobility .
Type Parameters:
T
specifies the type of the object returned when executing this request.
Class Summary
public abstract class AbstractListRequest
extends com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents an abstract request that expects List as a result, and provides access to common request
parameters.
[For complete information, see the section Class Details]
Constructor Summary
Table 1274: Constructors in AbstractListRequest<T>
Constructors
AbstractListRequest ()
Method Summary
Table 1275: Methods in AbstractListRequest<T>
Methods
public AbstractRequest<T> setMaximumResults (int maxResults)
Sets the maximum number of results to be returned in the response.
Class Details
Represents an abstract request that expects List as a result, and provides access to common request
parameters. All setter methods return the current instance, so these calls can be chained.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Constructor Details
AbstractListRequest ()
HERE Android SDK Developer's Guide
API Reference
2069
Method Details
public AbstractRequest<T> setMaximumResults (int maxResults)
Sets the maximum number of results to be returned in the response. It is not set by default.
Parameters:
maxResults
number of results in response, must be greater than 0
Returns:
this request instance
Throws:
IllegalArgumentException
if maxResults is invalid.
AbstractRequest<T>
The class AbstractRequest<T> is a member of com.here.android.mpa.urbanmobility .
Type Parameters:
T
specifies the type of the object returned when executing this request.
Class Summary
public abstract class AbstractRequest
extends java.lang.Object
Represents an abstract request and provides access to common request parameters.
[For complete information, see the section Class Details]
Constructor Summary
Table 1276: Constructors in AbstractRequest<T>
Constructors
AbstractRequest ()
Method Summary
Table 1277: Methods in AbstractRequest<T>
Methods
public boolean equals (Object o)
HERE Android SDK Developer's Guide
API Reference
2070
Methods
public void execute ()
Asynchronously retrieves a response for this request.
public int hashCode ()
public AbstractRequest<T> setClient (String client)
Sets the name of the client.
Class Details
Represents an abstract request and provides access to common request parameters. All setter methods
return the current instance, so these calls can be chained.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Constructor Details
AbstractRequest ()
Method Details
public boolean equals (Object o)
Parameters:
o
public void execute ()
Asynchronously retrieves a response for this request. Clients should provide a ResponseListener which
will be called upon completion of the request.
public int hashCode ()
public AbstractRequest<T> setClient (String client)
Sets the name of the client. "unset" will be used if not set.
Parameters:
client
name of the client
Returns:
this request instance
HERE Android SDK Developer's Guide
API Reference
2071
AccessPoint
The class AccessPoint is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class AccessPoint
extends java.lang.Object
Represents information about an access point to a Departure or Arrival.
[For complete information, see the section Class Details]
Method Summary
Table 1278: Methods in AccessPoint
Methods
public boolean equals (Object o)
public GeoCoordinate getCoordinate ()
Get coordinates of this access point.
public String getId ()
Get ID of this access point.
public String getName ()
Get the name of the access point.
public int hashCode ()
Class Details
Represents information about an access point to a Departure or Arrival. Locations like railway station may
have multiple entrance or exits which coordinates may differ a lot. AccessPoint represents such single
entrance or exit.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public GeoCoordinate getCoordinate ()
Get coordinates of this access point.
HERE Android SDK Developer's Guide
API Reference
2072
Returns:
access point coordinates
public String getId ()
Get ID of this access point.
Returns:
access point id
public String getName ()
Get the name of the access point.
Returns:
access point name
public int hashCode ()
Address
The class Address is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Address
extends java.lang.Object
Represents information about an address: coordinates, street name, postal code etc.
[For complete information, see the section Class Details]
Method Summary
Table 1279: Methods in Address
Methods
public boolean equals (Object o)
public String getCity ()
Get the name of the city.
public GeoCoordinate getCoordinate ()
Get coordinates corresponding to this address.
HERE Android SDK Developer's Guide
API Reference
2073
Methods
public String getCountry ()
Get the name of the country.
public String getCountryCode ()
Get 3 letter ISO 3166-1 country code.
public String getDistrict ()
Get the city district name.
public String getHouseNumber ()
Get the house number.
public String getName ()
Get the name of the place at this address if available, empty string otherwise.
public String getOpeningHours ()
Gets opening hours of a parking lot
public String getParkingId ()
Gets unique identifier for a parking lot
public Boolean getPnR ()
Gets whether parking lot is designated specifically for Park and Ride
public String getPostalCode ()
Get the postal code.
public Integer getSpaces ()
Gets number of parking spaces available in a parking lot
public String getState ()
Get the country state name, if applicable.
public String getStreet ()
Get the street name.
public int hashCode ()
Class Details
Represents information about an address: coordinates, street name, postal code etc.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
2074
public String getCity ()
Get the name of the city.
Returns:
city name
public GeoCoordinate getCoordinate ()
Get coordinates corresponding to this address. NOTE: Same Addresses (same postal code, street name, house
number etc.) may potentially have different coordinates, please be aware of that.
Returns:
coordinates associated with this address
public String getCountry ()
Get the name of the country.
Returns:
name of the country
public String getCountryCode ()
Get 3 letter ISO 3166-1 country code.
Returns:
ISO country code
public String getDistrict ()
Get the city district name.
Returns:
district name
public String getHouseNumber ()
Get the house number.
Returns:
house number
public String getName ()
HERE Android SDK Developer's Guide
API Reference
2075
Get the name of the place at this address if available, empty string otherwise.
Returns:
name of the place or empty string if not available
public String getOpeningHours ()
Gets opening hours of a parking lot
Returns:
opening hours of a parking lot
public String getParkingId ()
Gets unique identifier for a parking lot
Returns:
unique identifier for a parking lot
public Boolean getPnR ()
Gets whether parking lot is designated specifically for Park and Ride
Returns:
whether parking lot is designated specifically for Park and Ride
public String getPostalCode ()
Get the postal code.
Returns:
postal code
public Integer getSpaces ()
Gets number of parking spaces available in a parking lot
Returns:
number of parking spaces available in a parking lot
public String getState ()
Get the country state name, if applicable.
Returns:
HERE Android SDK Developer's Guide
API Reference
2076
state name
public String getStreet ()
Get the street name.
Returns:
street name
public int hashCode ()
Alert
The class Alert is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Alert
extends java.lang.Object
Represents an alert/disruption information about particular Transport and Operator.
[For complete information, see the section Class Details]
Method Summary
Table 1280: Methods in Alert
Methods
public boolean equals (Object o)
public Branding getBranding ()
Gets alert source branding info.
public String getId ()
Get unique Id for this alert.
public String getInfo ()
Get alert information text to display to the user.
public Provider getProvider ()
Get Provider of the alert data.
public Link getSource ()
Get a Link to the original source of this alert (Twitter feed, Agency API, RSS etc.).
HERE Android SDK Developer's Guide
API Reference
2077
Methods
public java.util.Collection <Transport> getTransports ()
Get Collection of Transport objects affected by this alert.
public Date getValidFrom ()
Get the Date from which this alert is valid.
public Date getValidTill ()
Get the Date till which this alert is valid.
public int hashCode ()
Class Details
Represents an alert/disruption information about particular Transport and Operator.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public Branding getBranding ()
Gets alert source branding info. Some alert sources (like Twitter) have branding requirement and clients
must comply to these and show to the user.
Returns:
source Branding info, or null if not available.
public String getId ()
Get unique Id for this alert. Might help to identify if this alert was already processed on the client.
Returns:
alert id
public String getInfo ()
Get alert information text to display to the user. Information text is localized according to Locale.getDefault().
If given language is not supported English version is returned.
Returns:
alert information text
HERE Android SDK Developer's Guide
API Reference
2078
public Provider getProvider ()
Get Provider of the alert data.
Returns:
alert data provider
public Link getSource ()
Get a Link to the original source of this alert (Twitter feed, Agency API, RSS etc.).
Returns:
Link to the alert's source, or null if not available
public java.util.Collection <Transport> getTransports ()
Get Collection of Transport objects affected by this alert.
Returns:
collection of transports
public Date getValidFrom ()
Get the Date from which this alert is valid.
Returns:
valid from date, or null if not available
public Date getValidTill ()
Get the Date till which this alert is valid.
Returns:
valid till date, or null if not available
public int hashCode ()
AlternativeDeparture
The class AlternativeDeparture is a member of com.here.android.mpa.urbanmobility .
HERE Android SDK Developer's Guide
API Reference
2079
Class Summary
public final class AlternativeDeparture
extends java.lang.Object
Represents information about an alternative departure.
[For complete information, see the section Class Details]
Method Summary
Table 1281: Methods in AlternativeDeparture
Methods
public boolean equals (Object o)
public RealTimeInfo getRealTimeInfo ()
Gets the real-time departure time if available.
public Date getTime ()
Gets the originally scheduled departure time.
public Transport getTransport ()
Gets the transport information.
public int hashCode ()
Class Details
Represents information about an alternative departure.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public RealTimeInfo getRealTimeInfo ()
Gets the real-time departure time if available.
Returns:
real-time departure time, or null when not available.
public Date getTime ()
HERE Android SDK Developer's Guide
API Reference
2080
Gets the originally scheduled departure time.
Returns:
Originally scheduled departure time, or null if not available.
public Transport getTransport ()
Gets the transport information.
Returns:
transport information, or null if not available
public int hashCode ()
Arrival
The class Arrival is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Arrival
extends java.lang.Object
Represents information about an arrival.
[For complete information, see the section Class Details]
Method Summary
Table 1282: Methods in Arrival
Methods
public boolean equals (Object o)
public AccessPoint getAccessPoint ()
Gets AccessPoint which should be used to access this location.
public Place getPlace ()
Gets the arrival Place information.
public String getPlatform ()
Gets the originally scheduled arrival platform.
public RealTimeInfo getRealTimeInfo ()
Gets the arrival real-time info if available.
HERE Android SDK Developer's Guide
API Reference
2081
Methods
public Station getStation ()
Gets the arrival Station information.
public Date getTime ()
Gets the originally scheduled arrival time.
public int hashCode ()
Class Details
Represents information about an arrival.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public AccessPoint getAccessPoint ()
Gets AccessPoint which should be used to access this location.
Returns:
AccessPoint, or null if not available
public Place getPlace ()
Gets the arrival Place information.
Returns:
arrival Place information, or null if not available
public String getPlatform ()
Gets the originally scheduled arrival platform.
Returns:
originally scheduled arrival platform, or empty string if not available.
public RealTimeInfo getRealTimeInfo ()
HERE Android SDK Developer's Guide
API Reference
2082
Gets the arrival real-time info if available.
Returns:
arrival real-time info, or null if not available
public Station getStation ()
Gets the arrival Station information. NOTE: This property is available only if arrival Place is also a Station.
Returns:
Station information ,or null if not available
public Date getTime ()
Gets the originally scheduled arrival time.
Returns:
originally scheduled arrival time, or null if not available
public int hashCode ()
Branding
The class Branding is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Branding
extends java.lang.Object
Represents alert source branding info.
[For complete information, see the section Class Details]
Method Summary
Table 1283: Methods in Branding
Methods
public boolean equals (Object o)
public String getTweetAvatarUrl ()
Gets url of the tweet author avatar.
HERE Android SDK Developer's Guide
API Reference
2083
Methods
public String getTweetFullName ()
Gets full name of the tweet author.
public String getTweetId ()
Gets id of the source tweet.
public Date getTweetTime ()
Gets timestamp of the source tweet.
public String getTweetUser ()
Gets username of the tweet author.
public int hashCode ()
Class Details
Represents alert source branding info. Some alert sources (like Twitter) have branding requirement and
clients must comply to these and show to the user.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getTweetAvatarUrl ()
Gets url of the tweet author avatar.
Returns:
url of the tweet author avatar, or empty string if not available
public String getTweetFullName ()
Gets full name of the tweet author.
Returns:
full name of the tweet author, or empty string if not available
public String getTweetId ()
Gets id of the source tweet.
Returns:
HERE Android SDK Developer's Guide
API Reference
2084
id of the tweet, or empty string if not available
public Date getTweetTime ()
Gets timestamp of the source tweet.
Returns:
tweet timestamp, or null if not available
public String getTweetUser ()
Gets username of the tweet author.
Returns:
username of the tweet author, or empty string if not available
public int hashCode ()
BrandingLogosRequest
The class BrandingLogosRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class BrandingLogosRequest
extends com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to retrieve information about branding logos of transit agencies.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1284: Nested Classes in BrandingLogosRequest
Nested Classes
public static final enumeration BrandingLogosRequest.LogoSize
Represents possible logo sizes.
HERE Android SDK Developer's Guide
API Reference
2085
Method Summary
Table 1285: Methods in BrandingLogosRequest
Methods
public BrandingLogosRequest setSize (LogoSize size)
Set desired logo size.
Class Details
Represents a request to retrieve information about branding logos of transit agencies.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public BrandingLogosRequest setSize (LogoSize size)
Set desired logo size. It is SMALL by default.
Parameters:
size
desired BrandingLogosRequest.LogoSize
Returns:
this request instance
LogoSize
The enumeration LogoSize is a member of com.here.android.mpa.urbanmobility.BrandingLogosRequest.
Enumeration Summary
public static final enumeration BrandingLogosRequest.LogoSize
extends java.lang.Enum, java.lang.Object
Represents possible logo sizes.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1286: Enum Constants in LogoSize
Fields
public static final LogoSize SMALL
Default small logo image.
HERE Android SDK Developer's Guide
API Reference
2086
Fields
public static final LogoSize LARGE
High resolution logo image (if available).
Method Summary
Table 1287: Methods in LogoSize
Methods
public static LogoSize valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static BrandingLogosRequest.LogoSize[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents possible logo sizes.
Enum Constant Details
public static final LogoSize SMALL
Default small logo image.
public static final LogoSize LARGE
High resolution logo image (if available).
Method Details
public static LogoSize valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static BrandingLogosRequest.LogoSize[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
2087
BrandingLogosResult
The class BrandingLogosResult is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class BrandingLogosResult
extends java.lang.Object
Represents information about branding logos of transit agencies.
[For complete information, see the section Class Details]
Method Summary
Table 1288: Methods in BrandingLogosResult
Methods
public boolean equals (Object o)
public java.util.List <Link> getLogos ()
Gets ordered list of hyperlinks to branded logos of agencies.
public int hashCode ()
Class Details
Represents information about branding logos of transit agencies.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.List <Link> getLogos ()
Gets ordered list of hyperlinks to branded logos of agencies. Typically these are just urls to PNG file.
Returns:
List of logo Links.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2088
City
The class City is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class City
extends java.lang.Object
Represents a city with the associated city coverage information.
[For complete information, see the section Class Details]
Method Summary
Table 1289: Methods in City
Methods
public boolean equals (Object o)
public String getCountry ()
Gets the name of the country that the city belongs to.
public Date getCreated ()
Gets the date that the city information was created.
public String getDisplayName ()
Gets hint of how name, state and country could be displayed in screen.
public int getDistance ()
Gets distance to be used when user coordinates are known.
public GeoCoordinate getLocation ()
Gets geo coordinates of the city.
public MissingCoverage getMissingCoverage ()
Gets information about missing operators, lines or timetables.
public String getName ()
Gets name of the city.
public java.util.Collection <Operator> getOperators ()
Gets operators serving city.
public int getPopulation ()
Gets the city population.
public java.util.Collection <Provider> getProviders ()
Gets coverage data providers.
HERE Android SDK Developer's Guide
API Reference
2089
Methods
public float getQuality ()
Gets the percentage of the city coverage in between 0.0 (nothing covered) and 1.0 (completely covered).
public double getRelevancy ()
Gets city relevancy as a weight value [0..1], that reflects how relevant this city should be for user when user is in some
specific location.
public String getState ()
Gets name of the state that the city belongs to.
public int getStopsCount ()
Gets the number of stops found in this city.
public int getTransportsCount ()
Gets the number of transports found.
public Date getUpdated ()
Gets the date the city information was updated.
public int hashCode ()
Class Details
Represents a city with the associated city coverage information.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getCountry ()
Gets the name of the country that the city belongs to. Country name is localized according to
Locale.getDefault(). If given language is not supported English version is returned.
Returns:
Name of the country.
public Date getCreated ()
Gets the date that the city information was created.
Returns:
HERE Android SDK Developer's Guide
API Reference
2090
The date the city information was created.
public String getDisplayName ()
Gets hint of how name, state and country could be displayed in screen. There is no guarantee that this
hint must be correct. Display name is localized according to Locale.getDefault(). If given language is not
supported English version is returned.
Returns:
Display name string or empty string.
public int getDistance ()
Gets distance to be used when user coordinates are known.
Returns:
Distance in meters, or -1 if not available.
public GeoCoordinate getLocation ()
Gets geo coordinates of the city.
Returns:
Geo coordinates of the city.
public MissingCoverage getMissingCoverage ()
Gets information about missing operators, lines or timetables.
Returns:
Information about missing operators, lines or timetables, or null if not available.
public String getName ()
Gets name of the city. Name is localized according to Locale.getDefault(). If given language is not supported
English version is returned.
Returns:
Name of the city.
public java.util.Collection <Operator> getOperators ()
Gets operators serving city.
Returns:
HERE Android SDK Developer's Guide
API Reference
2091
Collection of operators serving city.
public int getPopulation ()
Gets the city population.
Returns:
City population, or -1 if not available.
public java.util.Collection <Provider> getProviders ()
Gets coverage data providers.
Returns:
Collection of data providers.
public float getQuality ()
Gets the percentage of the city coverage in between 0.0 (nothing covered) and 1.0 (completely covered).
Returns:
City coverage quality from 0.0 to 1.0, or -1.0 if not available.
public double getRelevancy ()
Gets city relevancy as a weight value [0..1], that reflects how relevant this city should be for user when user is
in some specific location. This will mostly give correct results but it cannot be guaranteed.
Returns:
City relevancy 0..1, or -1.0 if not available.
public String getState ()
Gets name of the state that the city belongs to.
Returns:
Name of the state that the city belongs to, or empty string if not available.
public int getStopsCount ()
Gets the number of stops found in this city.
Returns:
Number of stops found, or -1 if not available.
HERE Android SDK Developer's Guide
API Reference
2092
public int getTransportsCount ()
Gets the number of transports found.
Returns:
Number of transports found, or -1 if not available.
public Date getUpdated ()
Gets the date the city information was updated.
Returns:
The date the city information was updated.
public int hashCode ()
CityCoverageRequest
The class CityCoverageRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class CityCoverageRequest
extends com.here.android.mpa.urbanmobility.AbstractListRequest,
com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to retrieve public transit data coverage by city.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1290: Nested Classes in CityCoverageRequest
Nested Classes
public static final enumeration CityCoverageRequest.UpdateType
Indicates if the result should contain only NEW or UPDATED cities (since given time).
Method Summary
Table 1291: Methods in CityCoverageRequest
Methods
public CityCoverageRequest setLocation (GeoCoordinate value)
Sets the location of the center point for search.
HERE Android SDK Developer's Guide
API Reference
2093
Methods
public CityCoverageRequest setNearbyMax (int value)
Set maximum number of cities returned in a separate "nearby" list.
public CityCoverageRequest setRadius (int value)
Sets the radius.
public CityCoverageRequest setRequestCityDetailsEnabled (boolean value)
Set if city details (such as population, available operators) should be returned.
public CityCoverageRequest setTime (Date value)
Sets a time filter for result cities.
public CityCoverageRequest setUpdateType (UpdateType value)
Sets type of time filter, which determines if the result will contain new, updated, or both new and updated, cities (since the
given time).
Class Details
Represents a request to retrieve public transit data coverage by city. All setter methods return the current
instance, so these calls can be chained.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public CityCoverageRequest setLocation (GeoCoordinate value)
Sets the location of the center point for search. It is not set by default - returns all cities.
Parameters:
value
coordinates of center point for search
Returns:
this request instance
public CityCoverageRequest setNearbyMax (int value)
Set maximum number of cities returned in a separate "nearby" list. Cities with zero relevancy are included
in this list. All cities with relevancy value of more than 0 are returned in the "main" cities list. By default, this
value is not set, so no nearby cities list is returned.
Note: Cities in the "nearby" list are returned without any details.
Parameters:
value
number of nearby cities in response, must be greater than 0
HERE Android SDK Developer's Guide
API Reference
2094
Returns:
this request instance
Throws:
IllegalArgumentException
if nearbyMax is invalid.
public CityCoverageRequest setRadius (int value)
Sets the radius. in meters, that define the area of the search. It is 150,000 by default.
Parameters:
value
area of the search, in meters, must be greater than or equal 0
Returns:
this request instance
Throws:
IllegalArgumentException
if radius is invalid.
public CityCoverageRequest setRequestCityDetailsEnabled (boolean value)
Set if city details (such as population, available operators) should be returned. It is true by default.
Parameters:
value
true if city details should be returned, false otherwise
Returns:
this request instance
public CityCoverageRequest setTime (Date value)
Sets a time filter for result cities. Use CityCoverageRequest.UpdateType parameter to specify how filtering
behaves. If it will return cities created or updated since given time, or both (created or updated). It is not set
by default - no time filtering.
Parameters:
value
date and time filter
Returns:
this request instance
HERE Android SDK Developer's Guide
API Reference
2095
public CityCoverageRequest setUpdateType (UpdateType value)
Sets type of time filter, which determines if the result will contain new, updated, or both new and updated,
cities (since the given time). By default ALL is used.
Parameters:
value
type of time filter
Returns:
this request instance
UpdateType
The enumeration UpdateType is a member of com.here.android.mpa.urbanmobility.CityCoverageRequest.
Enumeration Summary
public static final enumeration CityCoverageRequest.UpdateType
extends java.lang.Enum, java.lang.Object
Indicates if the result should contain only NEW or UPDATED cities (since given time).
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1292: Enum Constants in UpdateType
Fields
public static final UpdateType ALL
Both new and cities updated since the given time are returned.
public static final UpdateType NEW
Only new cities since the given time are returned.
public static final UpdateType UPDATED
Only cities updated since the given time are returned.
HERE Android SDK Developer's Guide
API Reference
2096
Method Summary
Table 1293: Methods in UpdateType
Methods
public static UpdateType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CityCoverageRequest.UpdateType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Indicates if the result should contain only NEW or UPDATED cities (since given time). Default is ALL cities
(both updated and new since given time) are returned.
Enum Constant Details
public static final UpdateType ALL
Both new and cities updated since the given time are returned.
public static final UpdateType NEW
Only new cities since the given time are returned.
public static final UpdateType UPDATED
Only cities updated since the given time are returned.
Method Details
public static UpdateType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CityCoverageRequest.UpdateType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
2097
CityCoverageResult
The class CityCoverageResult is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class CityCoverageResult
extends com.here.android.mpa.urbanmobility.CitySearchResult, java.lang.Object
Represents detailed information about cities coverage.
[For complete information, see the section Class Details]
Method Summary
Table 1294: Methods in CityCoverageResult
Methods
public boolean equals (Object o)
public java.util.List <City> getNearbyCities ()
Gets nearby cities with minimum coverage data.
public int hashCode ()
Class Details
Represents detailed information about cities coverage.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.List <City> getNearbyCities ()
Gets nearby cities with minimum coverage data.
Returns:
List of cities.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2098
CitySearchRequest
The class CitySearchRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class CitySearchRequest
extends com.here.android.mpa.urbanmobility.AbstractListRequest,
com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to search city by name and get public transit data coverage for it.
[For complete information, see the section Class Details]
Method Summary
Table 1295: Methods in CitySearchRequest
Methods
public CitySearchRequest setRequestCityDetailsEnabled (boolean details)
Set if city details (such as population and available operators) should be returned.
Class Details
Represents a request to search city by name and get public transit data coverage for it. All setter methods
return the current instance, so these calls can be chained.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public CitySearchRequest setRequestCityDetailsEnabled (boolean details)
Set if city details (such as population and available operators) should be returned. It is true by default.
Parameters:
details
true if city details should be returned, false otherwise
Returns:
this request instance
HERE Android SDK Developer's Guide
API Reference
2099
CitySearchResult
The class CitySearchResult is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class CitySearchResult
extends java.lang.Object
Represents detailed information about found cities and related coverage.
[For complete information, see the section Class Details]
Method Summary
Table 1296: Methods in CitySearchResult
Methods
public boolean equals (Object o)
public java.util.List <City> getCities ()
Gets cities with detailed coverage data.
public int getRealTimeCount ()
Gets total count of CoverageType.REAL_TIME supported cities.
public Date getRefTime ()
Get time of most updated available coverage data.
public int getSimpleRoutingCount ()
Gets total count of CoverageType.SIMPLE_ROUTING supported cities.
public int getTimeTableCount ()
Gets total count of CoverageType.TIME_TABLE supported cities.
public int hashCode ()
Class Details
Represents detailed information about found cities and related coverage.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
2100
public java.util.List <City> getCities ()
Gets cities with detailed coverage data.
Returns:
List of cities.
public int getRealTimeCount ()
Gets total count of CoverageType.REAL_TIME supported cities.
Returns:
Number of CoverageType.REAL_TIME supported cities.
public Date getRefTime ()
Get time of most updated available coverage data. Client can save this and when checking for new updates,
set the time parameter as this value.
Returns:
Time of most updated available coverage data.
public int getSimpleRoutingCount ()
Gets total count of CoverageType.SIMPLE_ROUTING supported cities.
Returns:
Number of CoverageType.SIMPLE_ROUTING supported cities.
public int getTimeTableCount ()
Gets total count of CoverageType.TIME_TABLE supported cities.
Returns:
Number of CoverageType.TIME_TABLE supported cities.
public int hashCode ()
CoverageType
The enumeration CoverageType is a member of com.here.android.mpa.urbanmobility .
HERE Android SDK Developer's Guide
API Reference
2101
Enumeration Summary
public final enumeration CoverageType
extends java.lang.Enum, java.lang.Object
Type of coverage.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1297: Enum Constants in CoverageType
Fields
public static final CoverageType REAL_TIME
Covered with real time data (e.g.
public static final CoverageType SIMPLE_ROUTING
Covered with simple routing data.
public static final CoverageType TIME_TABLE
Covered with time table data.
public static final CoverageType UNKNOWN
Information about coverage type is unavailable.
Method Summary
Table 1298: Methods in CoverageType
Methods
public static CoverageType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CoverageType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Type of coverage.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Enum Constant Details
public static final CoverageType REAL_TIME
Covered with real time data (e.g. got directly from 3rd-party api).
HERE Android SDK Developer's Guide
API Reference
2102
public static final CoverageType SIMPLE_ROUTING
Covered with simple routing data.
public static final CoverageType TIME_TABLE
Covered with time table data.
public static final CoverageType UNKNOWN
Information about coverage type is unavailable.
Method Details
public static CoverageType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CoverageType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Departure
The class Departure is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Departure
extends java.lang.Object
Represents information about a departure.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2103
Method Summary
Table 1299: Methods in Departure
Methods
public boolean equals (Object o)
public AccessPoint getAccessPoint ()
Gets AccessPoint which should be used to access this location.
public java.util.List <AlternativeDeparture> getAlternativeDepartures ()
Gets a list of departures which are alternative to this departure.
public DepartureFrequency getDepartureFrequency ()
Gets a DepartureFrequency object describing frequency of similar departures.
public Place getPlace ()
Gets the Place information from which this departure occurs.
public String getPlatform ()
Gets the originally scheduled departure platform.
public RealTimeInfo getRealTimeInfo ()
Gets the real-time departure time if available.
public Station getStation ()
Gets the Station information from which this departure occurs.
public Date getTime ()
Gets the originally scheduled departure time.
public Transport getTransport ()
Gets the transport information.
public int hashCode ()
Class Details
Represents information about a departure.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public AccessPoint getAccessPoint ()
HERE Android SDK Developer's Guide
API Reference
2104
Gets AccessPoint which should be used to access this location.
Returns:
AccessPoint, or null if not available
public java.util.List <AlternativeDeparture> getAlternativeDepartures ()
Gets a list of departures which are alternative to this departure.
Returns:
list of alternative departures if any
public DepartureFrequency getDepartureFrequency ()
Gets a DepartureFrequency object describing frequency of similar departures.
Returns:
information about departure frequency, or null if not available
public Place getPlace ()
Gets the Place information from which this departure occurs.
Returns:
Place from which this departure occurs, or null if not available
public String getPlatform ()
Gets the originally scheduled departure platform.
Returns:
originally scheduled departure platform, or empty string if not available.
public RealTimeInfo getRealTimeInfo ()
Gets the real-time departure time if available.
Returns:
real-time departure time or null when not available
public Station getStation ()
Gets the Station information from which this departure occurs. NOTE: This property is available only if Place
of the departure is also a Station.
HERE Android SDK Developer's Guide
API Reference
2105
Returns:
Station information ,or null if not available
public Date getTime ()
Gets the originally scheduled departure time.
Returns:
Originally scheduled departure time, or null if not available.
public Transport getTransport ()
Gets the transport information.
Returns:
transport information, or null if not available
public int hashCode ()
DepartureBoard
The class DepartureBoard is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class DepartureBoard
extends java.lang.Object
Represents departure information for a public transport at a given stop/station.
[For complete information, see the section Class Details]
Method Summary
Table 1300: Methods in DepartureBoard
Methods
public boolean equals (Object o)
public java.util.List <Departure> getDepartures ()
Gets the list of departures.
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
HERE Android SDK Developer's Guide
API Reference
2106
Methods
public java.util.Collection <Operator> getOperators ()
Gets the collection of Operator objects.
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
public int hashCode ()
Class Details
Represents departure information for a public transport at a given stop/station.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.List <Departure> getDepartures ()
Gets the list of departures.
Returns:
The list of Departures
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
Returns:
collection of Links
public java.util.Collection <Operator> getOperators ()
Gets the collection of Operator objects.
Returns:
The collection of operators operating on this stop/station
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
HERE Android SDK Developer's Guide
API Reference
2107
Returns:
the collection of transports serving departures shown in current departure list
public int hashCode ()
DepartureBoardRequest
The class DepartureBoardRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class DepartureBoardRequest
extends com.here.android.mpa.urbanmobility.AbstractListRequest,
com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to retrieve a station next departures board.
[For complete information, see the section Class Details]
Method Summary
Table 1301: Methods in DepartureBoardRequest
Methods
public DepartureBoardRequest setRequestRealTimeInfoEnabled (boolean returnRealTimeInfo)
Set if RealTimeInfo for found departures should be included in the response.
public DepartureBoardRequest setStrictResultEnabled (boolean strict)
Indicates that departure board should include results only for given stop, not also for related stops.
public DepartureBoardRequest setTime (Date time)
Sets the time point after which departures should be returned.
public DepartureBoardRequest setTransportTypes (EnumSet transportTypes)
Sets which transport types are allowed to be included in the response.
Class Details
Represents a request to retrieve a station next departures board. Note that all setter methods return current
instance so these calls can be nicely chained.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
HERE Android SDK Developer's Guide
API Reference
2108
Method Details
public DepartureBoardRequest setRequestRealTimeInfoEnabled (boolean
returnRealTimeInfo)
Set if RealTimeInfo for found departures should be included in the response. It is false by default.
Parameters:
returnRealTimeInfo
indicates if real-time info should be returned
Returns:
this request instance
public DepartureBoardRequest setStrictResultEnabled (boolean strict)
Indicates that departure board should include results only for given stop, not also for related stops. Default
is false, i.e. departure board might contain departures for related stops.
Parameters:
strict
true to request departures only for given stop, false otherwise
Returns:
this request instance
public DepartureBoardRequest setTime (Date time)
Sets the time point after which departures should be returned. It is current time by default.
Parameters:
time
time of departures
Returns:
this request instance
public DepartureBoardRequest setTransportTypes (EnumSet transportTypes)
Sets which transport types are allowed to be included in the response. All transport types are included by
default.
Parameters:
transportTypes
allowed transport types
Returns:
HERE Android SDK Developer's Guide
API Reference
2109
this request instance
Throws:
IllegalArgumentException
if transportTypes is empty.
DepartureFrequency
The class DepartureFrequency is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class DepartureFrequency
extends java.lang.Object
Represents information about departure frequencies.
[For complete information, see the section Class Details]
Method Summary
Table 1302: Methods in DepartureFrequency
Methods
public boolean equals (Object o)
public int getMaxRealTimeInterval ()
Gets maximal number of minutes between expected transport realtime departures.
public int getMaxScheduledInterval ()
Gets maximal number of minutes between transport scheduled departures.
public int getMinRealTimeInterval ()
Gets minimal number of minutes between expected transport realtime departures.
public int getMinScheduledInterval ()
Gets minimal number of minutes between transport scheduled departures.
public int hashCode ()
Class Details
Represents information about departure frequencies.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
HERE Android SDK Developer's Guide
API Reference
2110
Method Details
public boolean equals (Object o)
Parameters:
o
public int getMaxRealTimeInterval ()
Gets maximal number of minutes between expected transport realtime departures.
Returns:
maximal number of minutes between expected transport realtime departures, or -1 if not known
public int getMaxScheduledInterval ()
Gets maximal number of minutes between transport scheduled departures.
Returns:
maximal number of minutes between transport scheduled departures, or -1 if not known
public int getMinRealTimeInterval ()
Gets minimal number of minutes between expected transport realtime departures.
Returns:
minimal number of minutes between expected transport realtime departures, or -1 if not known
public int getMinScheduledInterval ()
Gets minimal number of minutes between transport scheduled departures.
Returns:
minimal number of minutes between transport scheduled departures, or -1 if not known
public int hashCode ()
ErrorCode
The enumeration ErrorCode is a member of com.here.android.mpa.urbanmobility .
Enumeration Summary
public final enumeration ErrorCode
HERE Android SDK Developer's Guide
API Reference
2111
extends java.lang.Enum, java.lang.Object
This enum represents Urban Mobility request errors.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1303: Enum Constants in ErrorCode
Fields
public static final ErrorCode NONE
No error.
public static final ErrorCode VIOLATES_OPTIONS
A route was found but is invalid because it makes use of roads that were disabled by RouteOptions.
public static final ErrorCode INVALID_OPERATION
The operation is not allowed at this time because another request is in progress.
public static final ErrorCode INVALID_CREDENTIALS
The HERE application ID and application code were missing or invalid.
public static final ErrorCode INVALID_PARAMETERS
Invalid request parameters were provided.
public static final ErrorCode INVALID_PERIOD
Given time period is invalid.
public static final ErrorCode START_DESTINATION_TOO_CLOSE
The start and destination locations are too close to each other.
public static final ErrorCode CANCELLED
The request was cancelled.
public static final ErrorCode OPERATION_NOT_ALLOWED
Access to this operation is denied.
public static final ErrorCode NETWORK_COMMUNICATION
There was a network communications error.
public static final ErrorCode NOT_FOUND
No search matches were found.
public static final ErrorCode ROUTING_NOT_POSSIBLE
Routing was not possible.
public static final ErrorCode NO_COVERAGE
No coverage in this region/area.
public static final ErrorCode NO_STATION_NEARBY
No stations were found near the given address.
HERE Android SDK Developer's Guide
API Reference
2112
Fields
public static final ErrorCode UNAVAILABLE_API
API is not available in this region or area.
public static final ErrorCode INVALID_RESPONSE
Backend service returned invalid response.
public static final ErrorCode SERVICE_UNAVAILABLE
The backend service was unavailable.
public static final ErrorCode INSUFFICIENT_MAP_DATA
The route cannot be calculated because there is not enough local map data to perform route calculation.
public static final ErrorCode OUT_OF_MEMORY
There was insufficient memory to complete the request.
public static final ErrorCode UNKNOWN
There was an unknown error.
Method Summary
Table 1304: Methods in ErrorCode
Methods
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enum represents Urban Mobility request errors.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Enum Constant Details
public static final ErrorCode NONE
No error.
public static final ErrorCode VIOLATES_OPTIONS
A route was found but is invalid because it makes use of roads that were disabled by RouteOptions.
public static final ErrorCode INVALID_OPERATION
The operation is not allowed at this time because another request is in progress.
HERE Android SDK Developer's Guide
API Reference
2113
public static final ErrorCode INVALID_CREDENTIALS
The HERE application ID and application code were missing or invalid.
public static final ErrorCode INVALID_PARAMETERS
Invalid request parameters were provided.
public static final ErrorCode INVALID_PERIOD
Given time period is invalid.
public static final ErrorCode START_DESTINATION_TOO_CLOSE
The start and destination locations are too close to each other.
public static final ErrorCode CANCELLED
The request was cancelled.
public static final ErrorCode OPERATION_NOT_ALLOWED
Access to this operation is denied. Contact your HERE representative for more information.
public static final ErrorCode NETWORK_COMMUNICATION
There was a network communications error.
public static final ErrorCode NOT_FOUND
No search matches were found.
public static final ErrorCode ROUTING_NOT_POSSIBLE
Routing was not possible.
public static final ErrorCode NO_COVERAGE
No coverage in this region/area.
public static final ErrorCode NO_STATION_NEARBY
HERE Android SDK Developer's Guide
API Reference
2114
No stations were found near the given address.
public static final ErrorCode UNAVAILABLE_API
API is not available in this region or area.
public static final ErrorCode INVALID_RESPONSE
Backend service returned invalid response.
public static final ErrorCode SERVICE_UNAVAILABLE
The backend service was unavailable. Try again later.
public static final ErrorCode INSUFFICIENT_MAP_DATA
The route cannot be calculated because there is not enough local map data to perform route calculation.
Client can re-download map data and calculate route again.
public static final ErrorCode OUT_OF_MEMORY
There was insufficient memory to complete the request.
public static final ErrorCode UNKNOWN
There was an unknown error.
Method Details
public static ErrorCode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static ErrorCode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
2115
ExploredCoverage
The class ExploredCoverage is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class ExploredCoverage
extends java.lang.Object
Represents coverage information about a location that is further away.
[For complete information, see the section Class Details]
Method Summary
Table 1305: Methods in ExploredCoverage
Methods
public boolean equals (Object o)
public int getRadius ()
Gets radius for which the coverage information is provided.
public java.util.Collection <Station> getStations ()
Gets information about maximum five (5) closest stations.
public int getStopsCount ()
Gets number of stops found within the specified radius.
public java.util.Collection <Transport> getTransports ()
Gets transports taken from the closest five (5) stops within the specified radius, sorted by feature type.
public int getTransportsCount ()
Gets number of transports found within the specified radius.
public int hashCode ()
Class Details
Represents coverage information about a location that is further away. In other words, a user needs to first
change the location to get routing. This coverage information also includes information to the closest station
(if there is one inside of radius) and information of lines going through five closest stations (if these stations
are inside of the radius).
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
HERE Android SDK Developer's Guide
API Reference
2116
Parameters:
o
public int getRadius ()
Gets radius for which the coverage information is provided. The default value is 150000 metres.
Returns:
Radius for which the coverage information is provided, in metres.
public java.util.Collection <Station> getStations ()
Gets information about maximum five (5) closest stations.
Returns:
Collection of stations.
public int getStopsCount ()
Gets number of stops found within the specified radius.
Returns:
Number of stops found within the specified radius.
public java.util.Collection <Transport> getTransports ()
Gets transports taken from the closest five (5) stops within the specified radius, sorted by feature type.
Returns:
Collection of transports.
public int getTransportsCount ()
Gets number of transports found within the specified radius.
Returns:
Number of transports found within the specified radius.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2117
Fare
The class Fare is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Fare
extends java.lang.Object
Represents information about a single fare (e.g.
[For complete information, see the section Class Details]
Method Summary
Table 1306: Methods in Fare
Methods
public boolean equals (Object o)
public String getCurrency ()
Gets ISO 4217 code of currency in which the price is given, e.g.
public Boolean getEstimated ()
Gets whether the fare price is estimated or if it's an exact value.
public FareType getFareType ()
Gets type of fare represented by this object.
public java.util.Collection <Link> getLinks ()
Gets the collection of Links associated with this fare e.g.
public double getMaximumPrice ()
Gets maximum price of the fare (or parking costs if reason is "parking")
public String getName ()
Gets name of the fare.
public double getPrice ()
Gets price of the fare (or parking costs if reason is "parking")
public String getPriceAsString ()
Gets the fare price as a formatted, ready-to-display string, entailing the currency.
public String getReason ()
Gets the reason for the cost described in this element, e.g.
public int hashCode ()
public String toString ()
HERE Android SDK Developer's Guide
API Reference
2118
Class Details
Represents information about a single fare (e.g. ticket).
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getCurrency ()
Gets ISO 4217 code of currency in which the price is given, e.g. "EUR".
Returns:
ISO 4217 code of currency of the price
See also:
ISO 4217
public Boolean getEstimated ()
Gets whether the fare price is estimated or if it's an exact value. For example most taxi fares can only be
estimated since the final price depends on the trip duration which is affected by the traffic.
Returns:
true if the price is estimated, false if exact
public FareType getFareType ()
Gets type of fare represented by this object. The client application is responsible to correctly visualize the
fare model to the user. Since the supported fare types can be extended in the future, it's recommended
hiding the fare information when encountering an unrecognized fare type.
Returns:
type of fare
public java.util.Collection <Link> getLinks ()
Gets the collection of Links associated with this fare e.g. to booking page.
Returns:
Collection of Links associated with this fare, or empty collection.
HERE Android SDK Developer's Guide
API Reference
2119
public double getMaximumPrice ()
Gets maximum price of the fare (or parking costs if reason is "parking")
If the price is a range, indicated by fare type being set to RANGE, this value will be representing the upper
bound of the range, and getPrice() returns possibly the lower bound of a price range. If the price is not a
range, this method will return the same value as getPrice().
Returns:
price of the fare (possibly upper bound of a price range)
See also:
getFareType()
getPrice()
public String getName ()
Gets name of the fare.
Returns:
name of the fare
public double getPrice ()
Gets price of the fare (or parking costs if reason is "parking")
For parking costs this is the maximum hourly rate or daily rate.
When fare type is set to RANGE, this method returns the lower bound of a price range, and
getMaximumPrice() contains the upper bound of a price range, or the same value as this method if the price
is exact.
Returns:
price of the fare (possibly lower bound of a price range)
See also:
getFareType()
getMaximumPrice()
public String getPriceAsString ()
Gets the fare price as a formatted, ready-to-display string, entailing the currency. Insensitive to locale, uses a
fixed convention for simplicity sake.
Returns:
fare price as a ready-to-display string (incl. currency)
HERE Android SDK Developer's Guide
API Reference
2120
public String getReason ()
Gets the reason for the cost described in this element, e.g. parking.
Returns:
the reason for the cost (eg. parking)
public int hashCode ()
public String toString ()
FareType
The enumeration FareType is a member of com.here.android.mpa.urbanmobility .
Enumeration Summary
public final enumeration FareType
extends java.lang.Enum, java.lang.Object
Specifies the type of a fare
[For complete information, see the section Enumeration Details]
See also:
Fare
Enum Constant Summary
Table 1307: Enum Constants in FareType
Fields
public static final FareType HOURLY
The indicated price is the cost per hour.
public static final FareType DAILY
The indicated price is the cost per day.
public static final FareType RANGE
The price represents a range with minimum and maximum value.
public static final FareType UNRECOGNIZED
The fare type is specific, but not recognized by the SDK
HERE Android SDK Developer's Guide
API Reference
2121
Method Summary
Table 1308: Methods in FareType
Methods
public static FareType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static FareType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies the type of a fare
See also:
Fare
Enum Constant Details
public static final FareType HOURLY
The indicated price is the cost per hour. Example: 11$/hour.
public static final FareType DAILY
The indicated price is the cost per day. Example: 62$/day.
public static final FareType RANGE
The price represents a range with minimum and maximum value.
public static final FareType UNRECOGNIZED
The fare type is specific, but not recognized by the SDK
Method Details
public static FareType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
2122
public static FareType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
FeatureAvailability
The enumeration FeatureAvailability is a member of com.here.android.mpa.urbanmobility .
Enumeration Summary
public final enumeration FeatureAvailability
extends java.lang.Enum, java.lang.Object
Three state flag indicating if given feature is available, unavailable, or there is no information about
availability.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1309: Enum Constants in FeatureAvailability
Fields
public static final FeatureAvailability YES
Feature is available.
public static final FeatureAvailability NO
Feature is unavailable.
public static final FeatureAvailability UNKNOWN
Feature availability is unknown.
Method Summary
Table 1310: Methods in FeatureAvailability
Methods
public static FeatureAvailability valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static FeatureAvailability[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Three state flag indicating if given feature is available, unavailable, or there is no information about
availability.
HERE Android SDK Developer's Guide
API Reference
2123
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Enum Constant Details
public static final FeatureAvailability YES
Feature is available.
public static final FeatureAvailability NO
Feature is unavailable.
public static final FeatureAvailability UNKNOWN
Feature availability is unknown.
Method Details
public static FeatureAvailability valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static FeatureAvailability[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
IntermediateStop
The class IntermediateStop is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class IntermediateStop
extends java.lang.Object
Represents information intermediate stop along a RouteSection.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2124
Method Summary
Table 1311: Methods in IntermediateStop
Methods
public boolean equals (Object o)
public Date getArrivalTime ()
Get the arrival time at this stop if available, returns null otherwise.
public Date getDepartureTime ()
Get the departure time at this stop if available, returns null otherwise.
public RealTimeInfo getRealTimeInfo ()
Get RealTimeInfo about departure and/or arrival at this stop if available, returns null otherwise.
public Station getStation ()
Get full Station info about this intermediate stop.
public int hashCode ()
Class Details
Represents information intermediate stop along a RouteSection.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public Date getArrivalTime ()
Get the arrival time at this stop if available, returns null otherwise.
Returns:
arrival time or null if not available
public Date getDepartureTime ()
Get the departure time at this stop if available, returns null otherwise.
Returns:
departure time or null if not available
HERE Android SDK Developer's Guide
API Reference
2125
public RealTimeInfo getRealTimeInfo ()
Get RealTimeInfo about departure and/or arrival at this stop if available, returns null otherwise.
Returns:
real-time info or null if not available
public Station getStation ()
Get full Station info about this intermediate stop.
Returns:
full station information
public int hashCode ()
Link
The class Link is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Link
extends java.lang.Object
Represents a link which can be associated with operator, transit alert or a ticket.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1312: Nested Classes in Link
Nested Classes
public static final enumeration Link.LinkType
Type of the link as enum for convenient use.
Method Summary
Table 1313: Methods in Link
Methods
public boolean equals (Object o)
public String getText ()
Gets the link text.
HERE Android SDK Developer's Guide
API Reference
2126
Methods
public LinkType getType ()
Gets the link type, i.e.
public String getUrl ()
Gets the URL of the link.
public String getUrlText ()
Gets clickable part of text.
public int hashCode ()
Class Details
Represents a link which can be associated with operator, transit alert or a ticket. For example, a link to the
transit operator's website. This information must be exposed in the client application.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getText ()
Gets the link text.
Returns:
link text.
public LinkType getType ()
Gets the link type, i.e. is it link to agency web-site or logo or a ticket booking link.
Returns:
the link type
public String getUrl ()
Gets the URL of the link.
Returns:
URL of the link
HERE Android SDK Developer's Guide
API Reference
2127
public String getUrlText ()
Gets clickable part of text. If not available (empty string) the full text need to be clickable. For example if
getText() returns "Lorem ipsum dolor sit amet, consectetur adipiscing elit." and getUrlText() returns "Lorem
ipsum" then only "Lorem ipsum" part should be clickable.
Returns:
clickable part of text, or empty string if not available
public int hashCode ()
LinkType
The enumeration LinkType is a member of com.here.android.mpa.urbanmobility.Link.
Enumeration Summary
public static final enumeration Link.LinkType
extends java.lang.Enum, java.lang.Object
Type of the link as enum for convenient use.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1314: Enum Constants in LinkType
Fields
public static final LinkType AGENCY
Link type agency: Operator information URL.
public static final LinkType AGENCY_LOGO
Link type logo: Operator logo URL.
public static final LinkType TARIFF
Link type tariff: Tariff information URL.
public static final LinkType ALERT
Link type alert: Link to original source of transit alert (eg.
public static final LinkType WEBSITE
Link type website: Website URL.
public static final LinkType BOOKING
Link type booking: Booking url.
HERE Android SDK Developer's Guide
API Reference
2128
Fields
public static final LinkType UNKNOWN
Link type unknown.
Method Summary
Table 1315: Methods in LinkType
Methods
public static LinkType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Link.LinkType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Type of the link as enum for convenient use. The allowed values are:
Enum Constant Details
public static final LinkType AGENCY
Link type agency: Operator information URL.
public static final LinkType AGENCY_LOGO
Link type logo: Operator logo URL.
public static final LinkType TARIFF
Link type tariff: Tariff information URL.
public static final LinkType ALERT
Link type alert: Link to original source of transit alert (eg. Twitter page). There is not text in Link node when
alert.
public static final LinkType WEBSITE
Link type website: Website URL.
public static final LinkType BOOKING
Link type booking: Booking url.
HERE Android SDK Developer's Guide
API Reference
2129
public static final LinkType UNKNOWN
Link type unknown.
Method Details
public static LinkType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Link.LinkType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Maneuver
The class Maneuver is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class Maneuver
extends java.lang.Object
Represents maneuver needed to take during the journey.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1316: Nested Classes in Maneuver
Nested Classes
public static final enumeration Maneuver.Action
public static final enumeration Maneuver.Direction
HERE Android SDK Developer's Guide
API Reference
2130
Constructor Summary
Table 1317: Constructors in Maneuver
Constructors
Maneuver (ManeuverImpl impl)
Method Summary
Table 1318: Methods in Maneuver
Methods
public boolean equals (Object o)
public Action getAction ()
Gets the action for this maneuver.
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the maneuver - the smallest rectangle that contains maneuver geometry.
public Direction getDirection ()
Gets maneuver direction hint.
public int getDistance ()
Gets distance from start to end of the maneuver, in meters.
public long getDuration ()
Gets duration - the amount of time in seconds for a single maneuver.
public java.util.List <GeoCoordinate> getGeometry ()
Gets maneuver geometry - list of points that for maneuver polyline.
public String getInstruction ()
Gets verbal description of maneuver.
public String getNextRoadName ()
Gets name of the next road in the route that the maneuver is heading toward.
public String getNextRoadNumber ()
Gets number of the road (such as A5, B49, etc.) towards which the maneuver is heading.
public int hashCode ()
Class Details
Represents maneuver needed to take during the journey.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
HERE Android SDK Developer's Guide
API Reference
2131
Constructor Details
Maneuver (ManeuverImpl impl)
Parameters:
impl
Method Details
public boolean equals (Object o)
Parameters:
o
public Action getAction ()
Gets the action for this maneuver. Does not always indicate a direction.
Returns:
Maneuver.Action to be taken
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the maneuver - the smallest rectangle that contains maneuver geometry.
Returns:
GeoBoundingBox that contains maneuver geometry
public Direction getDirection ()
Gets maneuver direction hint. Can be used to display the appropriate arrow icon for the maneuver.
Returns:
Maneuver.Direction hint
public int getDistance ()
Gets distance from start to end of the maneuver, in meters.
Returns:
distance in meters, or -1 if not available
public long getDuration ()
Gets duration - the amount of time in seconds for a single maneuver.
HERE Android SDK Developer's Guide
API Reference
2132
Returns:
duration in seconds
public java.util.List <GeoCoordinate> getGeometry ()
Gets maneuver geometry - list of points that for maneuver polyline.
Returns:
list of coordinates
public String getInstruction ()
Gets verbal description of maneuver. Instruction is localized according to Locale.getDefault(). If given
language is not supported English version is returned.
Returns:
instruction, or empty string if not available
public String getNextRoadName ()
Gets name of the next road in the route that the maneuver is heading toward.
Returns:
name of the road, or empty string if not available
public String getNextRoadNumber ()
Gets number of the road (such as A5, B49, etc.) towards which the maneuver is heading.
Returns:
number of the road, or empty string if not available
public int hashCode ()
Action
The enumeration Action is a member of com.here.android.mpa.urbanmobility.Maneuver.
Enumeration Summary
public static final enumeration Maneuver.Action
extends java.lang.Enum, java.lang.Object
HERE Android SDK Developer's Guide
API Reference
2133
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1319: Enum Constants in Action
Fields
public static final Action UNDEFINED
public static final Action DEPART
public static final Action DEPART_AIRPORT
public static final Action ARRIVE
public static final Action ARRIVE_AIRPORT
public static final Action ARRIVE_LEFT
public static final Action ARRIVE_RIGHT
public static final Action LEFT_LOOP
public static final Action LEFT_UTURN
public static final Action SHARP_LEFT_TURN
public static final Action LEFT_TURN
public static final Action SLIGHT_LEFT_TURN
public static final Action CONTINUE
public static final Action SLIGHT_RIGHT_TURN
public static final Action RIGHT_TURN
public static final Action SHARP_RIGHT_TURN
public static final Action RIGHT_UTURN
public static final Action RIGHT_LOOP
public static final Action LEFT_EXIT
public static final Action RIGHT_EXIT
public static final Action LEFT_RAMP
public static final Action RIGHT_RAMP
public static final Action LEFT_FORK
public static final Action MIDDLE_FORK
public static final Action RIGHT_FORK
public static final Action LEFT_MERGE
public static final Action RIGHT_MERGE
HERE Android SDK Developer's Guide
API Reference
2134
Fields
public static final Action NAME_CHANGE
public static final Action TRAFFIC_CIRCLE
public static final Action FERRY
public static final Action LEFT_ROUNDABOUT_EXIT_1
public static final Action LEFT_ROUNDABOUT_EXIT_2
public static final Action LEFT_ROUNDABOUT_EXIT_3
public static final Action LEFT_ROUNDABOUT_EXIT_4
public static final Action LEFT_ROUNDABOUT_EXIT_5
public static final Action LEFT_ROUNDABOUT_EXIT_6
public static final Action LEFT_ROUNDABOUT_EXIT_7
public static final Action LEFT_ROUNDABOUT_EXIT_8
public static final Action LEFT_ROUNDABOUT_EXIT_9
public static final Action LEFT_ROUNDABOUT_EXIT_10
public static final Action LEFT_ROUNDABOUT_EXIT_11
public static final Action LEFT_ROUNDABOUT_EXIT_12
public static final Action RIGHT_ROUNDABOUT_EXIT_1
public static final Action RIGHT_ROUNDABOUT_EXIT_2
public static final Action RIGHT_ROUNDABOUT_EXIT_3
public static final Action RIGHT_ROUNDABOUT_EXIT_4
public static final Action RIGHT_ROUNDABOUT_EXIT_5
public static final Action RIGHT_ROUNDABOUT_EXIT_6
public static final Action RIGHT_ROUNDABOUT_EXIT_7
public static final Action RIGHT_ROUNDABOUT_EXIT_8
public static final Action RIGHT_ROUNDABOUT_EXIT_9
public static final Action RIGHT_ROUNDABOUT_EXIT_10
public static final Action RIGHT_ROUNDABOUT_EXIT_11
public static final Action RIGHT_ROUNDABOUT_EXIT_12
public static final Action ENTER
public static final Action CHANGE
public static final Action LEAVE
HERE Android SDK Developer's Guide
API Reference
2135
Method Summary
Table 1320: Methods in Action
Methods
public static Action valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.Action[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final Action UNDEFINED
public static final Action DEPART
public static final Action DEPART_AIRPORT
public static final Action ARRIVE
public static final Action ARRIVE_AIRPORT
public static final Action ARRIVE_LEFT
public static final Action ARRIVE_RIGHT
public static final Action LEFT_LOOP
public static final Action LEFT_UTURN
public static final Action SHARP_LEFT_TURN
public static final Action LEFT_TURN
HERE Android SDK Developer's Guide
API Reference
2136
public static final Action SLIGHT_LEFT_TURN
public static final Action CONTINUE
public static final Action SLIGHT_RIGHT_TURN
public static final Action RIGHT_TURN
public static final Action SHARP_RIGHT_TURN
public static final Action RIGHT_UTURN
public static final Action RIGHT_LOOP
public static final Action LEFT_EXIT
public static final Action RIGHT_EXIT
public static final Action LEFT_RAMP
public static final Action RIGHT_RAMP
public static final Action LEFT_FORK
public static final Action MIDDLE_FORK
public static final Action RIGHT_FORK
public static final Action LEFT_MERGE
HERE Android SDK Developer's Guide
API Reference
2137
public static final Action RIGHT_MERGE
public static final Action NAME_CHANGE
public static final Action TRAFFIC_CIRCLE
public static final Action FERRY
public static final Action LEFT_ROUNDABOUT_EXIT_1
public static final Action LEFT_ROUNDABOUT_EXIT_2
public static final Action LEFT_ROUNDABOUT_EXIT_3
public static final Action LEFT_ROUNDABOUT_EXIT_4
public static final Action LEFT_ROUNDABOUT_EXIT_5
public static final Action LEFT_ROUNDABOUT_EXIT_6
public static final Action LEFT_ROUNDABOUT_EXIT_7
public static final Action LEFT_ROUNDABOUT_EXIT_8
public static final Action LEFT_ROUNDABOUT_EXIT_9
public static final Action LEFT_ROUNDABOUT_EXIT_10
public static final Action LEFT_ROUNDABOUT_EXIT_11
public static final Action LEFT_ROUNDABOUT_EXIT_12
HERE Android SDK Developer's Guide
API Reference
2138
public static final Action RIGHT_ROUNDABOUT_EXIT_1
public static final Action RIGHT_ROUNDABOUT_EXIT_2
public static final Action RIGHT_ROUNDABOUT_EXIT_3
public static final Action RIGHT_ROUNDABOUT_EXIT_4
public static final Action RIGHT_ROUNDABOUT_EXIT_5
public static final Action RIGHT_ROUNDABOUT_EXIT_6
public static final Action RIGHT_ROUNDABOUT_EXIT_7
public static final Action RIGHT_ROUNDABOUT_EXIT_8
public static final Action RIGHT_ROUNDABOUT_EXIT_9
public static final Action RIGHT_ROUNDABOUT_EXIT_10
public static final Action RIGHT_ROUNDABOUT_EXIT_11
public static final Action RIGHT_ROUNDABOUT_EXIT_12
public static final Action ENTER
public static final Action CHANGE
public static final Action LEAVE
HERE Android SDK Developer's Guide
API Reference
2139
Method Details
public static Action valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Maneuver.Action[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Direction
The enumeration Direction is a member of com.here.android.mpa.urbanmobility.Maneuver.
Enumeration Summary
public static final enumeration Maneuver.Direction
extends java.lang.Enum, java.lang.Object
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1321: Enum Constants in Direction
Fields
public static final Direction UNDEFINED
public static final Direction FORWARD
public static final Direction RIGHT
public static final Direction LEFT
public static final Direction BEAR_RIGHT
public static final Direction LIGHT_RIGHT
public static final Direction HARD_RIGHT
public static final Direction UTURN_RIGHT
public static final Direction UTURN_LEFT
public static final Direction HARD_LEFT
public static final Direction LIGHT_LEFT
HERE Android SDK Developer's Guide
API Reference
2140
Fields
public static final Direction BEAR_LEFT
Method Summary
Table 1322: Methods in Direction
Methods
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Maneuver.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final Direction UNDEFINED
public static final Direction FORWARD
public static final Direction RIGHT
public static final Direction LEFT
public static final Direction BEAR_RIGHT
public static final Direction LIGHT_RIGHT
public static final Direction HARD_RIGHT
public static final Direction UTURN_RIGHT
public static final Direction UTURN_LEFT
public static final Direction HARD_LEFT
HERE Android SDK Developer's Guide
API Reference
2141
public static final Direction LIGHT_LEFT
public static final Direction BEAR_LEFT
Method Details
public static Direction valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static Maneuver.Direction[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
MissingCoverage
The class MissingCoverage is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class MissingCoverage
extends java.lang.Object
Represents missing coverage information.
[For complete information, see the section Class Details]
Method Summary
Table 1323: Methods in MissingCoverage
Methods
public boolean equals (Object o)
public java.util.Collection <Operator> getOperators ()
Gets collection of public transit operators with missing coverage.
public java.util.Collection <Transport> getTransports ()
Gets collection of transports with missing coverage.
HERE Android SDK Developer's Guide
API Reference
2142
Methods
public CoverageType getType ()
Gets type of missing coverage.
public int hashCode ()
Class Details
Represents missing coverage information.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.Collection <Operator> getOperators ()
Gets collection of public transit operators with missing coverage.
Returns:
Collection of operators with missing coverage.
public java.util.Collection <Transport> getTransports ()
Gets collection of transports with missing coverage.
Returns:
Collection of transports with missing coverage.
public CoverageType getType ()
Gets type of missing coverage.
Returns:
Type of missing coverage.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2143
MultiBoardRequest
The class MultiBoardRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class MultiBoardRequest
extends com.here.android.mpa.urbanmobility.AbstractListRequest,
com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to retrieve a multi station departures board.
[For complete information, see the section Class Details]
Method Summary
Table 1324: Methods in MultiBoardRequest
Methods
public MultiBoardRequest setDepartureTime (Date time)
Sets the time point after which departures should be returned.
public MultiBoardRequest setMaxDeparturesPerStation (int maxDepartures)
Sets the maximum number of departures to be returned per station.
public MultiBoardRequest setRadius (int radius)
Sets radius in meters that defines the area of the search.
public MultiBoardRequest setRequestRealTimeInfoEnabled (boolean realTimeInfo)
Set if RealTimeInfo for found departures should be included in the response.
public MultiBoardRequest setTransportTypes (EnumSet transportTypes)
Sets which transport types are allowed to be included in the response.
Class Details
Represents a request to retrieve a multi station departures board. Note that all setter methods return
current instance so these calls can be nicely chained.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public MultiBoardRequest setDepartureTime (Date time)
Sets the time point after which departures should be returned. It is current time by default.
Parameters:
time
HERE Android SDK Developer's Guide
API Reference
2144
time of departures
Returns:
this request instance
public MultiBoardRequest setMaxDeparturesPerStation (int maxDepartures)
Sets the maximum number of departures to be returned per station. It is not set by default.
Parameters:
maxDepartures
number of departures to be returned per station, must be greater than 0
Returns:
this request instance
Throws:
IllegalArgumentException
if maxDepartures is invalid.
public MultiBoardRequest setRadius (int radius)
Sets radius in meters that defines the area of the search. It is 500 by default.
Parameters:
radius
area of the search in meters, must be greater than or equal 0
Returns:
this request instance
Throws:
IllegalArgumentException
if radius is invalid.
public MultiBoardRequest setRequestRealTimeInfoEnabled (boolean realTimeInfo)
Set if RealTimeInfo for found departures should be included in the response. It is false by default.
Parameters:
realTimeInfo
true if real-time info should be returned, false otherwise
Returns:
this request instance
HERE Android SDK Developer's Guide
API Reference
2145
public MultiBoardRequest setTransportTypes (EnumSet transportTypes)
Sets which transport types are allowed to be included in the response. All transport types are included by
default.
Parameters:
transportTypes
allowed transport types
Returns:
this request instance
Throws:
IllegalArgumentException
if transportTypes is empty.
MultiBoardResult
The class MultiBoardResult is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class MultiBoardResult
extends java.lang.Object
Represents multi departure information for a public transport around a given location.
[For complete information, see the section Class Details]
Method Summary
Table 1325: Methods in MultiBoardResult
Methods
public boolean equals (Object o)
public java.util.Collection <StationWithDepartureBoard> getStations ()
Gets the collection of stations with departure boards.
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
public int hashCode ()
Class Details
Represents multi departure information for a public transport around a given location.
HERE Android SDK Developer's Guide
API Reference
2146
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.Collection <StationWithDepartureBoard> getStations ()
Gets the collection of stations with departure boards.
Returns:
The collection of StationWithDepartureBoards
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
Returns:
the collection of transports serving departures shown in current departure boards
public int hashCode ()
NearbyCoverageRequest
The class NearbyCoverageRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class NearbyCoverageRequest
extends com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to retrieve nearby public transit data coverage.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2147
Method Summary
Table 1326: Methods in NearbyCoverageRequest
Methods
public NearbyCoverageRequest setRequestCityDetailsEnabled (boolean details)
Sets whether if city details (such as population and available operators) should be returned.
Class Details
Represents a request to retrieve nearby public transit data coverage. All setter methods return the current
instance, so these calls can be chained.
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public NearbyCoverageRequest setRequestCityDetailsEnabled (boolean details)
Sets whether if city details (such as population and available operators) should be returned. It is true by
default.
Parameters:
details
true if city details should be returned, false otherwise
Returns:
this request instance
NearbyCoverageResult
The class NearbyCoverageResult is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class NearbyCoverageResult
extends java.lang.Object
Represents information about nearby stops, lines, and city (in case if the user is assumed to be in one).
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2148
Method Summary
Table 1327: Methods in NearbyCoverageResult
Methods
public boolean equals (Object o)
public City getCity ()
Gets coverage information about a city.
public ExploredCoverage getExploredCoverage ()
Gets information about what is available in the more remote vicinity.
public String getGeoRef ()
Gets reference to the user's location as Geohash (e.g.
public int getRadius ()
Gets the radius, in meters, for which the coverage information is provided.
public int getStopsCount ()
Gets number of stops found.
public int getTransportsCount ()
Gets the number of transports found.
public CoverageType getType ()
Gets type of coverage in this area
public int hashCode ()
public boolean isCovered ()
Gets whether or not the user is considered to be covered.
Class Details
Represents information about nearby stops, lines, and city (in case if the user is assumed to be in one).
IMPORTANT: Urban Mobility Coverage Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public City getCity ()
Gets coverage information about a city.
Returns:
HERE Android SDK Developer's Guide
API Reference
2149
Coverage information about a city, or null if not available.
public ExploredCoverage getExploredCoverage ()
Gets information about what is available in the more remote vicinity. Routing is based on this information as
soon as the user location has changed.
Returns:
Explored coverage information, or null if not available.
public String getGeoRef ()
Gets reference to the user's location as Geohash (e.g. "u33d") that can be used to collect feedback without
disclosing the user's exact location.
Returns:
User location reference as Geohash string.
public int getRadius ()
Gets the radius, in meters, for which the coverage information is provided. The default value of radius is
150000m.
Returns:
Radius for which the coverage information is provided.
public int getStopsCount ()
Gets number of stops found.
Returns:
Number of stops found.
public int getTransportsCount ()
Gets the number of transports found.
Returns:
Number of transports found.
public CoverageType getType ()
Gets type of coverage in this area
Returns:
HERE Android SDK Developer's Guide
API Reference
2150
Type of coverage in this area.
public int hashCode ()
public boolean isCovered ()
Gets whether or not the user is considered to be covered.
Returns:
True if user is considered to be covered otherwise false.
Operator
The class Operator is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Operator
extends java.lang.Object
Represents a public transport operator.
[For complete information, see the section Class Details]
Method Summary
Table 1328: Methods in Operator
Methods
public boolean equals (Object o)
public String getEmail ()
Gets the operator email address.
public String getId ()
Gets the operator identifier/code.
public java.util.Collection <Link> getLinks ()
Gets Link s to operator related resources e.g.
public String getName ()
Gets the name of the operator.
public String getPhone ()
Gets the operator contact phone number.
HERE Android SDK Developer's Guide
API Reference
2151
Methods
public CoverageType getType ()
Gets the coverage type of the operator.
public int hashCode ()
Class Details
Represents a public transport operator.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getEmail ()
Gets the operator email address.
Returns:
The operator email address, or empty string if not available.
public String getId ()
Gets the operator identifier/code.
Returns:
operator identifier/code.
public java.util.Collection <Link> getLinks ()
Gets Link s to operator related resources e.g. agency logo link.
Returns:
Collection of operator related resources Links.
public String getName ()
Gets the name of the operator.
Returns:
The operator name.
HERE Android SDK Developer's Guide
API Reference
2152
public String getPhone ()
Gets the operator contact phone number.
Returns:
The operator contact phone number, or empty string if not available.
public CoverageType getType ()
Gets the coverage type of the operator.
Returns:
The operator CoverageType.
public int hashCode ()
Place
The class Place is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class Place
extends java.lang.Object
Represents information about a place like transit station, airport etc..
[For complete information, see the section Class Details]
Constructor Summary
Table 1329: Constructors in Place
Constructors
Place (PlaceImpl impl)
Method Summary
Table 1330: Methods in Place
Methods
public boolean equals (Object o)
HERE Android SDK Developer's Guide
API Reference
2153
Methods
public Address getAddress ()
Get the Address associated with this place.
public FeatureAvailability getBlindGuideAvailability ()
Indicates if blind guide is available at given place.
public int getDistanceFromCurrentLocation ()
Get distance from your current location to the place in meters.
public long getDurationFromCurrentLocation ()
Get duration from your current location to the place in seconds.
public FeatureAvailability getElevatorAvailability ()
Indicates if elevator is available at given place.
public FeatureAvailability getEscalatorAvailability ()
Indicates if escalator is available at given place.
public String getInfo ()
Gets optional informational text related to this place.
public java.util.Collection <Transport> getTransports ()
Gets the transports operating at this place.
public int hashCode ()
Class Details
Represents information about a place like transit station, airport etc..
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Constructor Details
Place (PlaceImpl impl)
Parameters:
impl
Method Details
public boolean equals (Object o)
Parameters:
o
public Address getAddress ()
HERE Android SDK Developer's Guide
API Reference
2154
Get the Address associated with this place.
Returns:
place address
public FeatureAvailability getBlindGuideAvailability ()
Indicates if blind guide is available at given place.
Returns:
FeatureAvailability flag indicating blind guide availability
public int getDistanceFromCurrentLocation ()
Get distance from your current location to the place in meters. NOTE: It is available only if current location
was specified in request.
Returns:
distance to the place in meters, or -1 if not available
public long getDurationFromCurrentLocation ()
Get duration from your current location to the place in seconds. NOTE: It is available only if current location
was specified in request.
Returns:
duration to the place in seconds, or -1 if not available
public FeatureAvailability getElevatorAvailability ()
Indicates if elevator is available at given place.
Returns:
FeatureAvailability flag indicating elevator availability
public FeatureAvailability getEscalatorAvailability ()
Indicates if escalator is available at given place.
Returns:
FeatureAvailability flag indicating escalator availability
public String getInfo ()
Gets optional informational text related to this place.
HERE Android SDK Developer's Guide
API Reference
2155
Returns:
information text, or empty string if not available
public java.util.Collection <Transport> getTransports ()
Gets the transports operating at this place.
Returns:
collection of transports
public int hashCode ()
Provider
The class Provider is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class Provider
extends java.lang.Object
Represents a public transport data provider.
[For complete information, see the section Class Details]
Method Summary
Table 1331: Methods in Provider
Methods
public boolean equals (Object o)
public String getName ()
Gets name of provider.
public int hashCode ()
Class Details
Represents a public transport data provider. One data provider (such as an aggregation website or API) can
provide data for multiple Operator which provide transit in a specific location.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
HERE Android SDK Developer's Guide
API Reference
2156
Method Details
public boolean equals (Object o)
Parameters:
o
public String getName ()
Gets name of provider. Name is localized according to Locale.getDefault(). If given language is not supported
English version is returned.
Returns:
Name of provider.
public int hashCode ()
RealTimeInfo
The class RealTimeInfo is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class RealTimeInfo
extends java.lang.Object
Represents real-time information of a departure or arrival.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1332: Nested Classes in RealTimeInfo
Nested Classes
public static final enumeration RealTimeInfo.RealTimeStatus
Method Summary
Table 1333: Methods in RealTimeInfo
Methods
public boolean equals (Object o)
public Date getArrivalTime ()
Gets the real-time arrival time if available, returns null otherwise.
HERE Android SDK Developer's Guide
API Reference
2157
Methods
public Date getDepartureTime ()
Gets the real-time departure time if available, returns null otherwise.
public String getPlatform ()
Gets the real-time departure/arrival platform if available, returns empty string otherwise.
public RealTimeStatus getStatus ()
An indicator for some exceptional event happened to this departure/arrival.
public int hashCode ()
Class Details
Represents real-time information of a departure or arrival.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public Date getArrivalTime ()
Gets the real-time arrival time if available, returns null otherwise.
Returns:
real-time arrival time or null if not available
public Date getDepartureTime ()
Gets the real-time departure time if available, returns null otherwise.
Returns:
real-time departure time or null if not available
public String getPlatform ()
Gets the real-time departure/arrival platform if available, returns empty string otherwise.
Returns:
real-time departure/arrival platform or empty string if not available.
public RealTimeStatus getStatus ()
HERE Android SDK Developer's Guide
API Reference
2158
An indicator for some exceptional event happened to this departure/arrival. Possible values are members of
RealTimeInfo.RealTimeStatus
Returns:
Exception event, default is OK.
public int hashCode ()
RealTimeStatus
The enumeration RealTimeStatus is a member of com.here.android.mpa.urbanmobility.RealTimeInfo.
Enumeration Summary
public static final enumeration RealTimeInfo.RealTimeStatus
extends java.lang.Enum, java.lang.Object
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1334: Enum Constants in RealTimeStatus
Fields
public static final RealTimeStatus OK
Is scheduled at the original arrival/departure time and at the given platform.
public static final RealTimeStatus REDIRECTED
The line is not following the normal stops sequence.
public static final RealTimeStatus REPLACED
User should take a replacement transport for this departure/arrival.
public static final RealTimeStatus CANCELLED
The service has a permanent failure and will not arrive and depart.
public static final RealTimeStatus ADDITIONAL
This is an additional not planned service.
Method Summary
Table 1335: Methods in RealTimeStatus
Methods
public static RealTimeStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
2159
Methods
public static RealTimeInfo.RealTimeStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Enum Constant Details
public static final RealTimeStatus OK
Is scheduled at the original arrival/departure time and at the given platform.
public static final RealTimeStatus REDIRECTED
The line is not following the normal stops sequence.
public static final RealTimeStatus REPLACED
User should take a replacement transport for this departure/arrival.
public static final RealTimeStatus CANCELLED
The service has a permanent failure and will not arrive and depart.
public static final RealTimeStatus ADDITIONAL
This is an additional not planned service.
Method Details
public static RealTimeStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static RealTimeInfo.RealTimeStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
HERE Android SDK Developer's Guide
API Reference
2160
RequestManager
The class RequestManager is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class RequestManager
extends java.lang.Object
Represents a manager responsible for creating Urban Mobility specific requests, with a
RequestManager.ResponseListener to trigger appropriate callback methods upon completion.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1336: Nested Classes in RequestManager
Nested Classes
public static abstract interface RequestManager.ResponseListener
Represents a listener to provide information about request result.
Constructor Summary
Table 1337: Constructors in RequestManager
Constructors
RequestManager ()
Method Summary
Table 1338: Methods in RequestManager
Methods
public BrandingLogosRequest createBrandingLogosRequest (ResponseListener<BrandingLogosResult> listener)
Creates an instance of BrandingLogosRequest to get information about branding logos of transit agencies.
public CityCoverageRequest createCityCoverageRequest (ResponseListener<CityCoverageResult> listener)
Creates an instance of CityCoverageRequest to get coverage data.
public CitySearchRequest createCitySearchRequest (String cityName, ResponseListener<CitySearchResult>
listener)
Creates an instance of CitySearchRequest to search by city name.
public DepartureBoardRequest createDepartureBoardRequest (GeoCoordinate stationCoordinate, String
stationId, ResponseListener<DepartureBoard> listener)
Creates an instance of DepartureBoardRequest.
HERE Android SDK Developer's Guide
API Reference
2161
Methods
public MultiBoardRequest createMultiBoardRequest (GeoCoordinate stationCoordinate,
ResponseListener<MultiBoardResult> listener)
Creates an instance of MultiBoardRequest to search by coordinates.
public MultiBoardRequest createMultiBoardRequest (Set stationIds, ResponseListener<MultiBoardResult>
listener)
Creates an instance of MultiBoardRequest to search only by Station IDs.
public NearbyCoverageRequest createNearbyCoverageRequest (GeoCoordinate location,
ResponseListener<NearbyCoverageResult> listener)
Creates an instance of NearbyCoverageRequest to get nearby coverage data.
public StationSearchRequest createStationSearchRequest (GeoCoordinate stationCoordinate, String
stationName, ResponseListener<StationSearchResult> listener)
Creates an instance of StationSearchRequest with optional name filter.
public StationSearchRequest createStationSearchRequest (Set stationIds,
ResponseListener<StationSearchResult> listener)
Creates an instance of StationSearchRequest to search only by Station IDs.
Class Details
Represents a manager responsible for creating Urban Mobility specific requests, with a
RequestManager.ResponseListener to trigger appropriate callback methods upon completion.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Constructor Details
RequestManager ()
Method Details
public BrandingLogosRequest createBrandingLogosRequest
(ResponseListener<BrandingLogosResult> listener)
Creates an instance of BrandingLogosRequest to get information about branding logos of transit agencies.
Parameters:
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of BrandingLogosRequest
HERE Android SDK Developer's Guide
API Reference
2162
public CityCoverageRequest createCityCoverageRequest
(ResponseListener<CityCoverageResult> listener)
Creates an instance of CityCoverageRequest to get coverage data.
Parameters:
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of CityCoverageRequest
public CitySearchRequest createCitySearchRequest (String cityName,
ResponseListener<CitySearchResult> listener)
Creates an instance of CitySearchRequest to search by city name.
Parameters:
cityName
Name of the city or its beginning. By default, the city name is in the local language. Exceptions for
non-local users are transcribed city names in countries with non-Latin scripts and English names of
important stops in some cities, such as Central Station in Berlin, Germany. Must not be empty or null.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of CitySearchRequest
Throws:
IllegalArgumentException
if cityName is invalid.
public DepartureBoardRequest createDepartureBoardRequest (GeoCoordinate
stationCoordinate, String stationId, ResponseListener<DepartureBoard> listener)
Creates an instance of DepartureBoardRequest.
Parameters:
stationCoordinate
The station coordinates. Must not be null.
stationId
Station ID for which departures will be returned. Must not be null or empty.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
HERE Android SDK Developer's Guide
API Reference
2163
Returns:
new instance of DepartureBoardRequest
Throws:
IllegalArgumentException
if stationCoordinate or stationId is invalid.
public MultiBoardRequest createMultiBoardRequest (GeoCoordinate
stationCoordinate, ResponseListener<MultiBoardResult> listener)
Creates an instance of MultiBoardRequest to search by coordinates.
Parameters:
stationCoordinate
The station coordinates. Must not be null.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of MultiBoardRequest
Throws:
IllegalArgumentException
if stationCoordinate is invalid.
public MultiBoardRequest createMultiBoardRequest (Set stationIds,
ResponseListener<MultiBoardResult> listener)
Creates an instance of MultiBoardRequest to search only by Station IDs.
Parameters:
stationIds
Set of stations IDs. Must not be null or empty.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of MultiBoardRequest
Throws:
IllegalArgumentException
if stationCoordinate is invalid.
HERE Android SDK Developer's Guide
API Reference
2164
public NearbyCoverageRequest createNearbyCoverageRequest (GeoCoordinate
location, ResponseListener<NearbyCoverageResult> listener)
Creates an instance of NearbyCoverageRequest to get nearby coverage data.
Parameters:
location
The location of center point for search.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of NearbyCoverageRequest
Throws:
IllegalArgumentException
if location is invalid.
public StationSearchRequest createStationSearchRequest (GeoCoordinate
stationCoordinate, String stationName, ResponseListener<StationSearchResult>
listener)
Creates an instance of StationSearchRequest with optional name filter. When stationName is given (non-null
and non-empty), it will be used to filter out the search result.
Parameters:
stationCoordinate
The station coordinates. Must not be null.
stationName
Station name or empty string if not specified.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of StationSearchRequest
Throws:
IllegalArgumentException
if stationCoordinate is invalid.
public StationSearchRequest createStationSearchRequest (Set stationIds,
ResponseListener<StationSearchResult> listener)
Creates an instance of StationSearchRequest to search only by Station IDs.
HERE Android SDK Developer's Guide
API Reference
2165
Parameters:
stationIds
IDs to search for or empty Set if none were specified. Must not be empty or null.
listener
Instance of RequestManager.ResponseListener that will be called on request completion.
Returns:
new instance of StationSearchRequest
Throws:
IllegalArgumentException
if stationIds is invalid - null or empty.
ResponseListener<T>
The interface ResponseListener<T> is a member of com.here.android.mpa.urbanmobility.RequestManager.
Type Parameters:
T
Interface Summary
public static abstract interface RequestManager.ResponseListener
Represents a listener to provide information about request result.
[For complete information, see the section Interface Details]
Method Summary
Table 1339: Methods in ResponseListener<T>
Methods
public abstract void onError (ErrorCode errorCode, String errorMessage)
A callback indicating that a request has finished with error.
public abstract void onSuccess (T requestResult)
A callback indicating that a request has finished with success.
Interface Details
Represents a listener to provide information about request result.
HERE Android SDK Developer's Guide
API Reference
2166
Method Details
public abstract void onError (ErrorCode errorCode, String errorMessage)
A callback indicating that a request has finished with error.
Parameters:
errorCode
Error code.
errorMessage
Error description string, or null if not available.
public abstract void onSuccess (T requestResult)
A callback indicating that a request has finished with success.
Parameters:
requestResult
The object representing request result.
RouteSection
The class RouteSection is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class RouteSection
extends java.lang.Object
Represents information about a single section/segment of a UMRoute which is covered by a single
TransportType or is a pedestrian walk.
[For complete information, see the section Class Details]
Method Summary
Table 1340: Methods in RouteSection
Methods
public boolean equals (Object o)
public java.util.Collection <Alert> getAlerts ()
Gets collection of associated Alerts.
public Arrival getArrival ()
Get information about this route section arrival.
HERE Android SDK Developer's Guide
API Reference
2167
Methods
public Departure getDeparture ()
Get information about this route section departure.
public int getDistance ()
Get distance in meters covered by this route section.
public long getDuration ()
Get expected duration in seconds to cover this route section.
public java.util.Collection <Fare> getFares ()
Get the Fares which cover this particular route section.
public java.util.List <GeoCoordinate> getGeometry ()
Get the geometry of this route section.
public String getId ()
Gets unique id for this section.
public java.util.List <IntermediateStop> getIntermediateStops ()
Get all IntermediateStops of this route section.
public java.util.List <Maneuver> getManeuvers ()
Get list of Maneuvers for this route section, or empty list if not available.
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
public TransportType getTransportType ()
Get TransportType which is used on this route section.
public int hashCode ()
public boolean isTimeUncertain ()
Indicate if departure/arrival times are uncertain.
Class Details
Represents information about a single section/segment of a UMRoute which is covered by a single
TransportType or is a pedestrian walk.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean equals (Object o)
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
2168
public java.util.Collection <Alert> getAlerts ()
Gets collection of associated Alerts.
Returns:
collection of Alerts
public Arrival getArrival ()
Get information about this route section arrival. See Arrival for details.
Returns:
information about arrival
public Departure getDeparture ()
Get information about this route section departure. See Departure for details.
Returns:
information about departure
public int getDistance ()
Get distance in meters covered by this route section.
Returns:
distances in meters
public long getDuration ()
Get expected duration in seconds to cover this route section.
Returns:
duration in seconds
public java.util.Collection <Fare> getFares ()
Get the Fares which cover this particular route section.
Returns:
collection of fares
public java.util.List <GeoCoordinate> getGeometry ()
Get the geometry of this route section.
HERE Android SDK Developer's Guide
API Reference
2169
Returns:
geometry as list of GeoCoordinate objects
public String getId ()
Gets unique id for this section.
Returns:
unique section id
public java.util.List <IntermediateStop> getIntermediateStops ()
Get all IntermediateStops of this route section. Will return empty list in case of walking section or when
intermediate stops are not available for given route.
Returns:
list of intermediate stops
public java.util.List <Maneuver> getManeuvers ()
Get list of Maneuvers for this route section, or empty list if not available.
Returns:
list of maneuvers
public java.util.Collection <Link> getOperatorDisclaimers ()
Gets collection of associated operator disclaimer Links.
Returns:
collection of Links
public TransportType getTransportType ()
Get TransportType which is used on this route section. Returns null if this it is a walking section.
Returns:
transport type of this section or null if it is a walking section
public int hashCode ()
public boolean isTimeUncertain ()
HERE Android SDK Developer's Guide
API Reference
2170
Indicate if departure/arrival times are uncertain. It is true for estimated values and false if it comes from real
time or time table data.
Returns:
true if departure/arrival time is uncertain (i.e. value is estimated), false otherwise (i.e. value is from time
table or real time)
Station
The class Station is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class Station
extends com.here.android.mpa.urbanmobility.Place, java.lang.Object
Represents information about a Station.
[For complete information, see the section Class Details]
Method Summary
Table 1341: Methods in Station
Methods
public boolean equals (Object o)
public String getId ()
Gets the identifier of the station, which is specific to transit backend.
public int hashCode ()
public boolean isDepartureBoardAvailable ()
Indicates if this station has a departure board available, meaning that a DepartureBoardRequest can be executed with this
station ID to get a DepartureBoard.
Class Details
Represents information about a Station.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
2171
public String getId ()
Gets the identifier of the station, which is specific to transit backend.
Returns:
id of the station
public int hashCode ()
public boolean isDepartureBoardAvailable ()
Indicates if this station has a departure board available, meaning that a DepartureBoardRequest can be
executed with this station ID to get a DepartureBoard.
Returns:
true if departure board is available, false otherwise
StationSearchRequest
The class StationSearchRequest is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class StationSearchRequest
extends com.here.android.mpa.urbanmobility.AbstractListRequest,
com.here.android.mpa.urbanmobility.AbstractRequest, java.lang.Object
Represents a request to search stations within certain radius by name, geo-coordinates or IDs.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1342: Nested Classes in StationSearchRequest
Nested Classes
public static final enumeration StationSearchRequest.NameMatchingMethod
Possible matching methods for a station name.
Method Summary
Table 1343: Methods in StationSearchRequest
Methods
public StationSearchRequest setMaximumResults (int maxResults)
HERE Android SDK Developer's Guide
API Reference
2172
Methods
public StationSearchRequest setRadius (int radius)
Set the station search radius in meters.
public StationSearchRequest setRequestStationDetailsEnabled (boolean details)
Set if station details (e.g.
public StationSearchRequest setStationNameMatchingMethod (NameMatchingMethod method)
Set the matching method for station names when searching with name filter.
Class Details
Represents a request to search stations within certain radius by name, geo-coordinates or IDs. Note that all
setter methods return current instance so these calls can be nicely chained.
IMPORTANT: Urban Mobility Transit Station Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public StationSearchRequest setMaximumResults (int maxResults)
Parameters:
maxResults
public StationSearchRequest setRadius (int radius)
Set the station search radius in meters. It is 500 by default.
Parameters:
radius
search radius in meters, must be greater than or equal 0
Returns:
this request instance
Throws:
IllegalArgumentException
if radius is invalid.
public StationSearchRequest setRequestStationDetailsEnabled (boolean details)
Set if station details (e.g. lines running through the station) should be returned. It is true by default.
Parameters:
details
true if station details should be returned, false otherwise
HERE Android SDK Developer's Guide
API Reference
2173
Returns:
this request instance
public StationSearchRequest setStationNameMatchingMethod (NameMatchingMethod
method)
Set the matching method for station names when searching with name filter. It is FUZZY by default.
Parameters:
method
matching method
Returns:
this request instance
NameMatchingMethod
The enumeration NameMatchingMethod is a member of
com.here.android.mpa.urbanmobility.StationSearchRequest.
Enumeration Summary
public static final enumeration StationSearchRequest.NameMatchingMethod
extends java.lang.Enum, java.lang.Object
Possible matching methods for a station name.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1344: Enum Constants in NameMatchingMethod
Fields
public static final NameMatchingMethod STRICT
Search for a station with the name exactly match one of the names requested or contains its part.
public static final NameMatchingMethod FUZZY
Search for a station with the name similar to one of the names requested i.e.
HERE Android SDK Developer's Guide
API Reference
2174
Method Summary
Table 1345: Methods in NameMatchingMethod
Methods
public static NameMatchingMethod valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static StationSearchRequest.NameMatchingMethod[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Possible matching methods for a station name. Default is FUZZY meaning that non-exact matches will be
allowed.
Enum Constant Details
public static final NameMatchingMethod STRICT
Search for a station with the name exactly match one of the names requested or contains its part.
public static final NameMatchingMethod FUZZY
Search for a station with the name similar to one of the names requested i.e. non-exact matches are allowed.
Method Details
public static NameMatchingMethod valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static StationSearchRequest.NameMatchingMethod[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
StationSearchResult
The class StationSearchResult is a member of com.here.android.mpa.urbanmobility .
HERE Android SDK Developer's Guide
API Reference
2175
Class Summary
public final class StationSearchResult
extends java.lang.Object
Station Search result which contains a java.util.java.util.List of found Stations and, when
requested, a java.util.java.util.Collection of all unique Transports that run through those
stations.
[For complete information, see the section Class Details]
Method Summary
Table 1346: Methods in StationSearchResult
Methods
public boolean equals (Object o)
public java.util.List <Station> getStations ()
Get the list of found Stations
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
public int hashCode ()
Class Details
Station Search result which contains a java.util.java.util.List of found Stations and, when
requested, a java.util.java.util.Collection of all unique Transports that run through those
stations.
IMPORTANT: Urban Mobility Transit Station Search is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public java.util.List <Station> getStations ()
Get the list of found Stations
Returns:
list of found stations, might be empty
HERE Android SDK Developer's Guide
API Reference
2176
public java.util.Collection <Transport> getTransports ()
Gets the collection of Transport objects.
Returns:
the collection of transports serving departures shown in current departure list
public int hashCode ()
StationWithDepartureBoard
The class StationWithDepartureBoard is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class StationWithDepartureBoard
extends com.here.android.mpa.urbanmobility.Station, com.here.android.mpa.urbanmobility.Place,
java.lang.Object
Represents stop/station with departure information for a public transport.
[For complete information, see the section Class Details]
Method Summary
Table 1347: Methods in StationWithDepartureBoard
Methods
public boolean equals (Object o)
public DepartureBoard getDepartureBoard ()
Gets stop/station information for which departure board belongs.
public int hashCode ()
Class Details
Represents stop/station with departure information for a public transport.
IMPORTANT: Urban Mobility Departure Board is a Beta feature. The related classes are subject to change
without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
HERE Android SDK Developer's Guide
API Reference
2177
public DepartureBoard getDepartureBoard ()
Gets stop/station information for which departure board belongs.
Returns:
The station information for which departure board belongs.
public int hashCode ()
Tariff
The class Tariff is a member of com.here.android.mpa.urbanmobility .
Class Summary
public final class Tariff
extends java.lang.Object
Represents a collection of Fares which together covers the cost of a certain UMRoute.
[For complete information, see the section Class Details]
Method Summary
Table 1348: Methods in Tariff
Methods
public boolean equals (Object o)
public java.util.Collection <Fare> getFares ()
Gets Collection of Fare objects which describe fare for individual section in the route.
public int hashCode ()
Class Details
Represents a collection of Fares which together covers the cost of a certain UMRoute.
IMPORTANT: Urban Mobility routing is a Beta feature. The related classes are subject to change without
notice.
Method Details
public boolean equals (Object o)
Parameters:
HERE Android SDK Developer's Guide
API Reference
2178
o
public java.util.Collection <Fare> getFares ()
Gets Collection of Fare objects which describe fare for individual section in the route.
Returns:
collection of fare for individual section in the route
public int hashCode ()
Transport
The class Transport is a member of com.here.android.mpa.urbanmobility .
Class Summary
public class Transport
extends java.lang.Object
Represents a kind of transport (e.g.
[For complete information, see the section Class Details]
Method Summary
Table 1349: Methods in Transport
Methods
public boolean equals (Object o)
public FeatureAvailability getBarrierFree ()
Indicates if transport is barrier free.
public FeatureAvailability getBikeAllowed ()
Indicates if bikes are allowed for this transport.
public int getColor ()
Gets the transport color.
public String getDirection ()
Gets the transport direction if applicable (e.g.
public String getName ()
Gets the transport name.
HERE Android SDK Developer's Guide
API Reference
2179
Methods
public Operator getOperator ()
Gets the operator serving the transport.
public int getOutlineColor ()
Gets the color of the border around the transport name.
public int getTextColor ()
Gets the text color that should get used when the transport color is used as background color.
public TransportType getTransportType ()
Gets the type of transport.
public String getTransportTypeName ()
Gets the locally used name for this transport type.
public int hashCode ()
Class Details
Represents a kind of transport (e.g. transit line or bike) with its properties like name, color that can be used
to display on the map, or operator that serves given transport.
IMPORTANT: Urban Mobility is a Beta feature. The related classes are subject to change without notice.
Method Details
public boolean equals (Object o)
Parameters:
o
public FeatureAvailability getBarrierFree ()
Indicates if transport is barrier free.
Returns:
FeatureAvailability flag indicating if transport is barrier free
public FeatureAvailability getBikeAllowed ()
Indicates if bikes are allowed for this transport.
Returns:
FeatureAvailability flag indicating if bikes are allowed for this transport
HERE Android SDK Developer's Guide
API Reference
2180
public int getColor ()
Gets the transport color. See android.graphics.android.graphics.Color for more details on color
format.
Returns:
transport color, or Color.BLACK if none
public String getDirection ()
Gets the transport direction if applicable (e.g. bus which goes to "Flughafen Tegel Airport").
Returns:
the transport direction, or empty string if not available
public String getName ()
Gets the transport name. Name is localized according to Locale.getDefault(). If given language is not
supported English version is returned.
Returns:
the transport name, or empty string if not available
public Operator getOperator ()
Gets the operator serving the transport.
Returns:
the transport operator, or null if not available
public int getOutlineColor ()
Gets the color of the border around the transport name. See
android.graphics.android.graphics.Color for more details on color format.
Returns:
transport border color, or Color.TRANSPARENT if none
HERE Android SDK Developer's Guide
API Reference
2181
public int getTextColor ()
Gets the text color that should get used when the transport color is used as background color. See
android.graphics.android.graphics.Color for more details on color format.
Returns:
text color, or Color.BLACK if none
public TransportType getTransportType ()
Gets the type of transport.
Returns:
TransportType representing kind of transport
public String getTransportTypeName ()
Gets the locally used name for this transport type. Name is localized according to Locale.getDefault(). If given
language is not supported English version is returned.
Returns:
locally used transport type name or empty string if not available
public int hashCode ()
venues3d
The package venues3d is a member of com.here.android.mpa.
Package Summary
venues3d
This package provides facilities to search and display objects representing three-dimensional views of
venues.
Package Details
This package provides facilities to search and display objects representing three-dimensional views of
venues. It replaces the venue maps feature contained in the com.here.android.mpa.venuemaps package.
HERE Android SDK Developer's Guide
API Reference
2182
The entry point to this Venue 3D feature is either the VenueMapFragment class with UI support, or
VenueService, which offers headless venue functionality.
For more information on using 3D venues, please consult the "3D Venues" section in the HERE SDK for
Android Developer's Guide.
Area
The class Area is a member of com.here.android.mpa.venues3d .
Class Summary
public class Area
extends com.here.android.mpa.venues3d.SpatialObject, java.lang.Object
This class is a base class that represents a physical area within a Venue .
[For complete information, see the section Class Details]
See also:
Venue
Level
OuterArea
Space
Constructor Summary
Table 1350: Constructors in Area
Constructors
Area (AreaImpl impl)
Package Private Constructor
Method Summary
Table 1351: Methods in Area
Methods
public GeoBoundingBox getBoundingBox ()
This method retrieves the bounding box for this Area .
public GeoCoordinate getCenter ()
This method retrieves the center of the bounding box of the Area .
public String getName ()
This method retrieves the human-readable name related to the holder of the spatial area.
HERE Android SDK Developer's Guide
API Reference
2183
Methods
public GeoPolygon getPolygon ()
This method retrieves the GeoPolygon for this Area , if it exists.
Class Details
This class is a base class that represents a physical area within a Venue . It is extended by the classes
OuterArea and Space , both of which have a bounding box and center coordinates, and possibly a
GeoPolygon .
This class can not be instantiated directly. Subclasses OuterArea and Space can be obtained by methods on
Level .
See also:
Venue
Level
OuterArea
Space
Constructor Details
Area (AreaImpl impl)
Package Private Constructor
Parameters:
impl
The impl object to be constructed of.
Method Details
public GeoBoundingBox getBoundingBox ()
This method retrieves the bounding box for this Area .
Returns:
An object representing the bounding box for the given area.
public GeoCoordinate getCenter ()
This method retrieves the center of the bounding box of the Area .
Returns:
An object containing the geographic coordinates of the center of the given area.
HERE Android SDK Developer's Guide
API Reference
2184
public String getName ()
This method retrieves the human-readable name related to the holder of the spatial area. This can be, for
example, the name of a shop.
Returns:
The string containing the name.
public GeoPolygon getPolygon ()
This method retrieves the GeoPolygon for this Area , if it exists.
Returns:
A GeoPolygon or null.
BaseLocation
The class BaseLocation is a member of com.here.android.mpa.venues3d .
Class Summary
public class BaseLocation
extends java.lang.Object
This class represents a location used in indoor routing.
[For complete information, see the section Class Details]
See also:
RoutingController
Nested Class Summary
Table 1352: Nested Classes in BaseLocation
Nested Classes
public static final enumeration BaseLocation.LocationType
This enumeration defines identifiers for location types.
Constructor Summary
Table 1353: Constructors in BaseLocation
Constructors
BaseLocation ()
HERE Android SDK Developer's Guide
API Reference
2185
Constructors
BaseLocation (BaseLocationImpl impl)
Package Private Constructor
Field Summary
Table 1354: Fields in BaseLocation
Fields
protected LocationType m_locationType
protected BaseLocation m_parkingLocation
protected BaseLocationImpl m_pimpl
Method Summary
Table 1355: Methods in BaseLocation
Methods
public Area getArea ()
This method returns Area associated with a location.
public GeoCoordinate getGeoCoordinate ()
This method returns a GeoCoordinate associated with a location.
public LocationType getType ()
This method return BaseLocation.LocationType of this instance.
public boolean isValid ()
This method returns information if a given location is valid.
public void setParkingLocation (BaseLocation location)
This method sets parking location.
Class Details
This class represents a location used in indoor routing.
See also:
RoutingController
Constructor Details
BaseLocation ()
BaseLocation (BaseLocationImpl impl)
HERE Android SDK Developer's Guide
API Reference
2186
Package Private Constructor
Parameters:
impl
The impl object to be constructed of.
Field Details
protected LocationType m_locationType
protected BaseLocation m_parkingLocation
protected BaseLocationImpl m_pimpl
Method Details
public Area getArea ()
This method returns Area associated with a location. If a location relates to a Space, it returns a Space
object. If a location relates to a OuterArea, it returns a OuterArea object. Otherwise this method returns
null.
Returns:
An Area associated with a location
public GeoCoordinate getGeoCoordinate ()
This method returns a GeoCoordinate associated with a location.
Returns:
A GeoCoordinate associated with a location
public LocationType getType ()
This method return BaseLocation.LocationType of this instance.
Returns:
A location type.
public boolean isValid ()
This method returns information if a given location is valid.
HERE Android SDK Developer's Guide
API Reference
2187
Returns:
A boolean indicates if a location is valid
public void setParkingLocation (BaseLocation location)
This method sets parking location.
Parameters:
location
BaseLocation object.
LocationType
The enumeration LocationType is a member of com.here.android.mpa.venues3d.BaseLocation.
Enumeration Summary
public static final enumeration BaseLocation.LocationType
extends java.lang.Enum, java.lang.Object
This enumeration defines identifiers for location types.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1356: Enum Constants in LocationType
Fields
public static final LocationType SPACE
Location in inside a space.
public static final LocationType OUTDOOR
Location is outdoor.
public static final LocationType LEVEL
Free point on given level.
public static final LocationType OTHER
Location is outdoor.
HERE Android SDK Developer's Guide
API Reference
2188
Method Summary
Table 1357: Methods in LocationType
Methods
public static LocationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static BaseLocation.LocationType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines identifiers for location types.
Enum Constant Details
public static final LocationType SPACE
Location in inside a space.
public static final LocationType OUTDOOR
Location is outdoor.
public static final LocationType LEVEL
Free point on given level.
public static final LocationType OTHER
Location is outdoor.
Method Details
public static LocationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static BaseLocation.LocationType[] values ()
HERE Android SDK Developer's Guide
API Reference
2189
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CombinedNavigationManager
The class CombinedNavigationManager is a member of com.here.android.mpa.venues3d .
Class Summary
public class CombinedNavigationManager
extends java.lang.Object
A navigation manager class that provides guidance advice and information along a combined route.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1358: Nested Classes in CombinedNavigationManager
Nested Classes
public static abstract interface CombinedNavigationManager.CombinedNavigationManagerListener
An interface for responding to navigation events sent by the CombinedNavigationManager .
public static final enumeration CombinedNavigationManager.CombinedNavigationState
The possible states of CombinedNavigationManager .
public static final enumeration CombinedNavigationManager.CombinedNavigationType
Specifies the possible types of navigation.
Field Summary
Table 1359: Fields in CombinedNavigationManager
Fields
public static final double INVALID_DISTANCE_VALUE
Represents an invalid distance value.
Method Summary
Table 1360: Methods in CombinedNavigationManager
Methods
public void addListener (CombinedNavigationManagerListener listener)
Adds a listener to the navigation manager.
public CombinedNavigationType getCurrentNavigationType ()
Returns the type of currently active navigation.
HERE Android SDK Developer's Guide
API Reference
2190
Methods
public double getDistanceFromStart ()
Returns the current distance from the start point of navigation.
public double getDistanceToDestination ()
Returns the current distance to destination.
public CombinedNavigationState getNavigationState ()
Gets the current state of the navigation related to the tracked route.
public boolean isPaused ()
Returns true , if current navigation is paused, false otherwise.
public void pause (boolean value)
When set to true , the current navigation will be paused (if any).
public void removeListener (CombinedNavigationManagerListener listener)
Removes a listener from the navigation manager.
public boolean simulate (CombinedRoute route, double speed, boolean distortionEnabled, double
updateInterval)
Starts a turn-by-turn navigation simulation session using the specified combined route.
public boolean start (CombinedRoute route)
Starts a turn-by-turn navigation session using the specified combined route.
public void stop ()
Stops a turn-by-turn navigation session started via start(CombinedRoute) or simulate(CombinedRoute, double, boolean,
double)
Class Details
A navigation manager class that provides guidance advice and information along a combined route.
Field Details
public static final double INVALID_DISTANCE_VALUE
Represents an invalid distance value.
See also:
getDistanceFromStart()
getDistanceToDestination()
Method Details
public void addListener (CombinedNavigationManagerListener listener)
HERE Android SDK Developer's Guide
API Reference
2191
Adds a listener to the navigation manager. The listener must implement the
CombinedNavigationManager.CombinedNavigationManagerListener interface. The listener receives event
callbacks containing information about the current navigation session.
Parameters:
listener
The CombinedNavigationManager.CombinedNavigationManagerListener object to be added.
public CombinedNavigationType getCurrentNavigationType ()
Returns the type of currently active navigation.
public double getDistanceFromStart ()
Returns the current distance from the start point of navigation.
Returns:
the distance from the start point in meters. Returns INVALID_DISTANCE_VALUE if an error occurred or
navigation hasn't been started.
public double getDistanceToDestination ()
Returns the current distance to destination.
Returns:
the distance to destination in meters. Returns INVALID_DISTANCE_VALUE if an error occurred or navigation
hasn't been started.
public CombinedNavigationState getNavigationState ()
Gets the current state of the navigation related to the tracked route.
public boolean isPaused ()
Returns true , if current navigation is paused, false otherwise.
Returns:
true, if current navigation is paused, false otherwise.
public void pause (boolean value)
When set to true , the current navigation will be paused (if any). When set to false , the current navigation
will resume if previously paused. This has no effect if there is no navigation currently in progress.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2192
value
When set to true, the current navigation will be paused (if any).
public void removeListener (CombinedNavigationManagerListener listener)
Removes a listener from the navigation manager. The listener must implement the
CombinedNavigationManager.CombinedNavigationManagerListener interface. The listener receives event
callbacks containing information about the current navigation session.
Parameters:
listener
The CombinedNavigationManager.CombinedNavigationManagerListener object to be removed.
public boolean simulate (CombinedRoute route, double speed, boolean
distortionEnabled, double updateInterval)
Starts a turn-by-turn navigation simulation session using the specified combined route.
Parameters:
route
The combined route section to navigate.
speed
The speed at which the simulated location changes in meters per second.
distortionEnabled
If enabled, each generated position will be distorted with some random factor
updateInterval
Specifies how often the new position will be updated. I.e. it controls smoothness of the navigation
simulation.
Returns:
True if started successfully and false otherwise, indicatiing that one of the route sections is invalid or the
navigation is already running.
public boolean start (CombinedRoute route)
Starts a turn-by-turn navigation session using the specified combined route.
Parameters:
route
The combined route section to navigate.
Returns:
True if started successfully and false otherwise, indicatiing that one of the route sections is invalid or the
navigation is already running.
HERE Android SDK Developer's Guide
API Reference
2193
public void stop ()
Stops a turn-by-turn navigation session started via start(CombinedRoute) or simulate(CombinedRoute,
double, boolean, double)
CombinedNavigationManagerListener
The interface CombinedNavigationManagerListener is a member of
com.here.android.mpa.venues3d.CombinedNavigationManager.
Interface Summary
public static abstract interface CombinedNavigationManager.CombinedNavigationManagerListener
An interface for responding to navigation events sent by the CombinedNavigationManager .
[For complete information, see the section Interface Details]
Method Summary
Table 1361: Methods in CombinedNavigationManagerListener
Methods
public abstract void onDestinationReached ()
Called when the destination of turn-by-turn navigation is reached.
public abstract void onIndoorSectionWillStart (VenueRoute indoorSection, CombinedRoute
combinedRoute)
Called when an indoor section of the combined route will be started.
public abstract void onLinkingSectionWillStart (LinkingRoute linkingSection, CombinedRoute
combinedRoute)
Called when an link section of the combined route will be started.
public abstract void onOutdoorSectionWillStart (OutdoorRoute outdoorSection, CombinedRoute
combinedRoute)
Called when an outdoor section of the combined route will be started.
public abstract void onRouteUpdated (CombinedRoute combinedRoute)
Called when a change is made to the route being navigated.
Interface Details
An interface for responding to navigation events sent by the CombinedNavigationManager .
Method Details
public abstract void onDestinationReached ()
HERE Android SDK Developer's Guide
API Reference
2194
Called when the destination of turn-by-turn navigation is reached.
public abstract void onIndoorSectionWillStart (VenueRoute indoorSection,
CombinedRoute combinedRoute)
Called when an indoor section of the combined route will be started.
Parameters:
indoorSection
VenueRoute representing the next indoor section.
combinedRoute
CombinedRoute representing the current route.
public abstract void onLinkingSectionWillStart (LinkingRoute linkingSection,
CombinedRoute combinedRoute)
Called when an link section of the combined route will be started.
Parameters:
linkingSection
LinkRoute representing the next link section.
combinedRoute
CombinedRoute representing the current route.
public abstract void onOutdoorSectionWillStart (OutdoorRoute outdoorSection,
CombinedRoute combinedRoute)
Called when an outdoor section of the combined route will be started.
Parameters:
outdoorSection
OutdoorRoute representing the next outdoor section.
combinedRoute
CombinedRoute representing the current route.
public abstract void onRouteUpdated (CombinedRoute combinedRoute)
Called when a change is made to the route being navigated. This can occur after successful rerouting due to
the user leaving the current route.
Parameters:
combinedRoute
CombinedRoute representing the current route.
HERE Android SDK Developer's Guide
API Reference
2195
CombinedNavigationState
The enumeration CombinedNavigationState is a member of
com.here.android.mpa.venues3d.CombinedNavigationManager.
Enumeration Summary
public static final enumeration CombinedNavigationManager.CombinedNavigationState
extends java.lang.Enum, java.lang.Object
The possible states of CombinedNavigationManager .
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1362: Enum Constants in CombinedNavigationState
Fields
public static final CombinedNavigationState IDLE
No navigation is in progress.
public static final CombinedNavigationState PAUSED
Navigation is in progress but not currently active.
public static final CombinedNavigationState RUNNING
Navigation is in progress and active.
public static final CombinedNavigationState SIMULATING
Navigation simulating is in progress and active.
Method Summary
Table 1363: Methods in CombinedNavigationState
Methods
public static CombinedNavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CombinedNavigationManager.CombinedNavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The possible states of CombinedNavigationManager .
HERE Android SDK Developer's Guide
API Reference
2196
Enum Constant Details
public static final CombinedNavigationState IDLE
No navigation is in progress.
public static final CombinedNavigationState PAUSED
Navigation is in progress but not currently active.
public static final CombinedNavigationState RUNNING
Navigation is in progress and active.
public static final CombinedNavigationState SIMULATING
Navigation simulating is in progress and active.
Method Details
public static CombinedNavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CombinedNavigationManager.CombinedNavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CombinedNavigationType
The enumeration CombinedNavigationType is a member of
com.here.android.mpa.venues3d.CombinedNavigationManager.
Enumeration Summary
public static final enumeration CombinedNavigationManager.CombinedNavigationType
extends java.lang.Enum, java.lang.Object
Specifies the possible types of navigation.
HERE Android SDK Developer's Guide
API Reference
2197
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1364: Enum Constants in CombinedNavigationType
Fields
public static final CombinedNavigationType NONE
None navigation is currently active
public static final CombinedNavigationType INDOOR
Currently indoor navigation is active
public static final CombinedNavigationType LINK
Currently link section navigation is active
public static final CombinedNavigationType OUTDOOR
Currently outdoor navigation is active
Method Summary
Table 1365: Methods in CombinedNavigationType
Methods
public static CombinedNavigationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CombinedNavigationManager.CombinedNavigationType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Specifies the possible types of navigation.
Enum Constant Details
public static final CombinedNavigationType NONE
None navigation is currently active
public static final CombinedNavigationType INDOOR
Currently indoor navigation is active
public static final CombinedNavigationType LINK
Currently link section navigation is active
HERE Android SDK Developer's Guide
API Reference
2198
public static final CombinedNavigationType OUTDOOR
Currently outdoor navigation is active
Method Details
public static CombinedNavigationType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CombinedNavigationManager.CombinedNavigationType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
CombinedRoute
The class CombinedRoute is a member of com.here.android.mpa.venues3d .
Class Summary
public class CombinedRoute
extends java.lang.Object
Represents route from start to end point.
[For complete information, see the section Class Details]
See also:
IRouteSection
Nested Class Summary
Table 1366: Nested Classes in CombinedRoute
Nested Classes
public static final enumeration CombinedRoute.VenueRoutingError
Represents identifiers for routing errors.
HERE Android SDK Developer's Guide
API Reference
2199
Method Summary
Table 1367: Methods in CombinedRoute
Methods
public boolean conformsConnectorOptions ()
Returns true if the returned route does no use any accessors set to be avoided in VenueRouteOptions.
public boolean conformsModeOptions ()
Returns true if the result route for every outdoor segment, except to/from parking, is the mode the user has requested in
VenueRouteOptions.
public RoutingError getCoreMapError ()
Returns RoutingError, indicating inner core map error.
public BaseLocation getEnd ()
Returns a BaseLocation objects associated with end point of the route.
public VenueRoutingError getError ()
Returns CombinedRoute.VenueRoutingError indicating route computation result.
public int getLength ()
Returns the length of the route in meters.
public java.util.List <IRouteSection> getRouteSections ()
Returns a list of IRouteSection objects associated with this route instance.
public BaseLocation getStart ()
Returns a BaseLocation objects associated with start point of the route.
public java.util.List <BaseLocation> getWaypoints ()
Returns a list of BaseLocation objects associated with waypoints on the route including start and end points.
Class Details
Represents route from start to end point. The route is split to one or more route sections.
See also:
IRouteSection
Method Details
public boolean conformsConnectorOptions ()
Returns true if the returned route does no use any accessors set to be avoided in VenueRouteOptions.
Sometimes, no route can be created that satisfies all route options set by the user (like: use of elevators,
escalators, stairs and ramps). If any of these are set to be avoided, this method can be used to check if the
calculated route still uses any of these accessors.
Returns:
true if the returned route does no use any accessors set to be avoided in VenueRouteOptions.
HERE Android SDK Developer's Guide
API Reference
2200
public boolean conformsModeOptions ()
Returns true if the result route for every outdoor segment, except to/from parking, is the mode the user has
requested in VenueRouteOptions.
Returns:
true if the result route for every outdoor segment, except to/from parking, is the mode the user has
requested in VenueRouteOptions.
public RoutingError getCoreMapError ()
Returns RoutingError, indicating inner core map error. This function should be used only when the method
getError returns the error code CORE_MAP .
Returns:
RoutingError, indicating inner core map error.
public BaseLocation getEnd ()
Returns a BaseLocation objects associated with end point of the route.
Returns:
Last point of route (flag anchor).
public VenueRoutingError getError ()
Returns CombinedRoute.VenueRoutingError indicating route computation result.
Returns:
CombinedRoute.VenueRoutingError indicating route computation result.
public int getLength ()
Returns the length of the route in meters.
Returns:
The length of the route in meters.
public java.util.List <IRouteSection> getRouteSections ()
Returns a list of IRouteSection objects associated with this route instance. This information can be used to
check type of turn-by-turn information available for each route sections of this combined route instance.
Returns:
HERE Android SDK Developer's Guide
API Reference
2201
A list of route sections.
public BaseLocation getStart ()
Returns a BaseLocation objects associated with start point of the route.
Returns:
First point of route (flag anchor).
public java.util.List <BaseLocation> getWaypoints ()
Returns a list of BaseLocation objects associated with waypoints on the route including start and end points.
Returns:
List of waypoint point on route (flag anchors).
VenueRoutingError
The enumeration VenueRoutingError is a member of com.here.android.mpa.venues3d.CombinedRoute.
Enumeration Summary
public static final enumeration CombinedRoute.VenueRoutingError
extends java.lang.Enum, java.lang.Object
Represents identifiers for routing errors.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1368: Enum Constants in VenueRoutingError
Fields
public static final VenueRoutingError NO_ERROR
No error
public static final VenueRoutingError ARGUMENTS
Problem with arguments
public static final VenueRoutingError INTERNAL
Internal problem in HereSDK or data problem
public static final VenueRoutingError CORE_MAP
Problem with core map routing
HERE Android SDK Developer's Guide
API Reference
2202
Fields
public static final VenueRoutingError UNKNOWN
Unknown problem
Method Summary
Table 1369: Methods in VenueRoutingError
Methods
public static VenueRoutingError valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static CombinedRoute.VenueRoutingError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents identifiers for routing errors.
Enum Constant Details
public static final VenueRoutingError NO_ERROR
No error
public static final VenueRoutingError ARGUMENTS
Problem with arguments
public static final VenueRoutingError INTERNAL
Internal problem in HereSDK or data problem
public static final VenueRoutingError CORE_MAP
Problem with core map routing
public static final VenueRoutingError UNKNOWN
Unknown problem
Method Details
public static VenueRoutingError valueOf (String name)
HERE Android SDK Developer's Guide
API Reference
2203
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static CombinedRoute.VenueRoutingError[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Content
The class Content is a member of com.here.android.mpa.venues3d .
Class Summary
public final class Content
extends java.lang.Object
This class encapsulates POI (Point Of Interest) information of the spatial area in a venue.
[For complete information, see the section Class Details]
Method Summary
Table 1370: Methods in Content
Methods
public Address getAddress ()
This method retrieves the postal address of the spatial area.
public String getContentId ()
This method retrieves the unique content identifier of the spatial area.
public Map getCustomAttributes ()
Gets the Map<String, Object> of custom attributes.
public String getEmail ()
This method retrieves the email address related to holder of the spatial area.
public String getName ()
This method retrieves the human-readable name related to the holder of the spatial area.
public String getParentCategoryId ()
This method retrieves the parent Category identifier of the spatial area.
public String getPhoneNumber ()
This method returns the phone number related to holder of the spatial area.
HERE Android SDK Developer's Guide
API Reference
2204
Methods
public String getPlaceCategoryId ()
This method retrieves the Category identifier of the spatial area.
public List getSearchTags ()
This method retrieves the tags which describes the content holder.
public String getUniqueVenueId ()
This method retrieves the unique venue identifier of the spatial area.
public String getWebsite ()
This method retrieves the URL of the web site related to holder of the spatial area.
Class Details
This class encapsulates POI (Point Of Interest) information of the spatial area in a venue. Examples of POI
information are the street address, access information, search tags, space type, category.
Method Details
public Address getAddress ()
This method retrieves the postal address of the spatial area.
Returns:
An object containing the address of the spatial area.
public String getContentId ()
This method retrieves the unique content identifier of the spatial area. Content ID can be used in
PlaceRequest(String, String) together with reference name VENUES_CONTENT_ID_REFERENCE_NAME to get
reach information about the content. Request can fail if there is no information about the content in Places
API.
Returns:
A String containing the content identifier.
public Map getCustomAttributes ()
Gets the Map<String, Object> of custom attributes. Attribute values may be of type java.lang.Boolean ,
java.lang.Double , java.lang.String , java.lang.List , and java.lang.Map .
Returns:
a java.util.Map<String, Object> from strings to values encoding the custom attributes or null if there are no
custom properties.
HERE Android SDK Developer's Guide
API Reference
2205
public String getEmail ()
This method retrieves the email address related to holder of the spatial area.
Returns:
The string containing the email address.
public String getName ()
This method retrieves the human-readable name related to the holder of the spatial area. This can be, for
example, the name of a shop.
Returns:
The string containing the name.
public String getParentCategoryId ()
This method retrieves the parent Category identifier of the spatial area. This information can be used, for
example, to check the type of the space: shopping, transportation-facility, etc.
Returns:
The string containing the parent category identifier.
public String getPhoneNumber ()
This method returns the phone number related to holder of the spatial area.
Returns:
The string containing the phone number.
public String getPlaceCategoryId ()
This method retrieves the Category identifier of the spatial area. For example, this information can be used
to check the type of store, such as food and clothing.
Returns:
The string containing the category identifier.
See also:
getSortedSpacesByCategory(String)
public List getSearchTags ()
This method retrieves the tags which describes the content holder. For example, the tags for an electronics
retailer may contain: television, phone, mobile, computer, and so on. The tags can help you search inside a
venue ( Venue ) for specific key words.
HERE Android SDK Developer's Guide
API Reference
2206
Returns:
A list of text strings representing the tags.
public String getUniqueVenueId ()
This method retrieves the unique venue identifier of the spatial area. This identifier is constant for each
spatial area and can't be changed in later data updates.
Returns:
The string containing the unique venue identifier.
public String getWebsite ()
This method retrieves the URL of the web site related to holder of the spatial area.
Returns:
The string containing the URL.
DeselectionSource
The enumeration DeselectionSource is a member of com.here.android.mpa.venues3d .
Enumeration Summary
public final enumeration DeselectionSource
extends java.lang.Enum, java.lang.Object
This enumeration defines identifiers for values indicating how a venue was deselected.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1371: Enum Constants in DeselectionSource
Fields
public static final DeselectionSource MOVE_OUT
Indicates that the map was moved away from the venue.
public static final DeselectionSource ZOOM_OUT
Indicates that the map was zoomed out to a zoom level at which the venue is not visible or not fully visible in the view port.
public static final DeselectionSource MAP_TAPPED
Indicates that the map was tapped outside the venue.
HERE Android SDK Developer's Guide
API Reference
2207
Fields
public static final DeselectionSource LAYER_SWITCHED_OFF
Indicates that the VenueMapLayer was switched off.
public static final DeselectionSource SELECT_OTHER_VENUE
Indicates that another venue was selected.
public static final DeselectionSource MANUALLY
Indicates that a Venue was deselected manually through the API.
Method Summary
Table 1372: Methods in DeselectionSource
Methods
public static DeselectionSource valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static DeselectionSource[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines identifiers for values indicating how a venue was deselected.
Enum Constant Details
public static final DeselectionSource MOVE_OUT
Indicates that the map was moved away from the venue.
public static final DeselectionSource ZOOM_OUT
Indicates that the map was zoomed out to a zoom level at which the venue is not visible or not fully visible in
the view port.
public static final DeselectionSource MAP_TAPPED
Indicates that the map was tapped outside the venue.
public static final DeselectionSource LAYER_SWITCHED_OFF
Indicates that the VenueMapLayer was switched off.
public static final DeselectionSource SELECT_OTHER_VENUE
HERE Android SDK Developer's Guide
API Reference
2208
Indicates that another venue was selected.
public static final DeselectionSource MANUALLY
Indicates that a Venue was deselected manually through the API.
Method Details
public static DeselectionSource valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static DeselectionSource[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
IRouteSection
The interface IRouteSection is a member of com.here.android.mpa.venues3d .
Interface Summary
public abstract interface IRouteSection
An interface for checking a route section type.
[For complete information, see the section Interface Details]
See also:
LinkingRoute
OutdoorRoute
VenueRoute
Nested Class Summary
Table 1373: Nested Classes in IRouteSection
Nested Classes
public static final enumeration IRouteSection.RouteSectionType
This enumeration defines identifiers for route sections types.
HERE Android SDK Developer's Guide
API Reference
2209
Method Summary
Table 1374: Methods in IRouteSection
Methods
public abstract int getLength ()
Returns the length of this route section in meters.
public abstract RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
Interface Details
An interface for checking a route section type.
See also:
LinkingRoute
OutdoorRoute
VenueRoute
Method Details
public abstract int getLength ()
Returns the length of this route section in meters.
Returns:
The route's length in meters
public abstract RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
Returns:
A route type.
RouteSectionType
The enumeration RouteSectionType is a member of com.here.android.mpa.venues3d.IRouteSection.
Enumeration Summary
public static final enumeration IRouteSection.RouteSectionType
extends java.lang.Enum, java.lang.Object
This enumeration defines identifiers for route sections types.
HERE Android SDK Developer's Guide
API Reference
2210
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1375: Enum Constants in RouteSectionType
Fields
public static final RouteSectionType VENUE
Route section is inside a venue.
public static final RouteSectionType OUTDOOR
Route section is outside a venue.
public static final RouteSectionType LINK
Route section describes a direct line from the start to the end point of the section, where there is no turn-by-turn routing
data is available.
Method Summary
Table 1376: Methods in RouteSectionType
Methods
public static RouteSectionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static IRouteSection.RouteSectionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines identifiers for route sections types.
Enum Constant Details
public static final RouteSectionType VENUE
Route section is inside a venue.
public static final RouteSectionType OUTDOOR
Route section is outside a venue.
public static final RouteSectionType LINK
Route section describes a direct line from the start to the end point of the section, where there is no turn-by-
turn routing data is available. This typically may occur in sections where one end is inside a venue and other
end outside a venue.
HERE Android SDK Developer's Guide
API Reference
2211
Method Details
public static RouteSectionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static IRouteSection.RouteSectionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Level
The class Level is a member of com.here.android.mpa.venues3d .
Class Summary
public final class Level
extends java.lang.Object
This class represents a storey in a Venue (building).
[For complete information, see the section Class Details]
See also:
Venue
OuterArea
VenueController
Method Summary
Table 1377: Methods in Level
Methods
public boolean equals (Object o)
public Area getAreaAtPosition (GeoCoordinate position)
This method retrieves the Area of the level at a given position.
public GeoCoordinate getCenter ()
This method retrieves the coordinates of the center of the given Level .
HERE Android SDK Developer's Guide
API Reference
2212
Methods
public int getFloorNumber ()
This method retrieves the floor number assigned to the given Level .
public String getFloorSynonym ()
This method retrieves the floor synonym, for example: 1, B, P1, MEZZ etc.
public java.util.List <Space> getNearbySpaces (GeoCoordinate position, float radius)
This method retrievs spaces that intersect a circle around a given coordinate.
public java.util.List <OuterArea> getOuterAreas ()
This method retrieves a list of OuterArea objects associated with the given Level instance.
public java.util.List <Space> getSortedSpaces ()
This method retrieves an alphabetically-ordered list of Space objects for the given instance of Level , excluding facilities.
public java.util.List <Space> getSortedSpacesByCategory (String categoryName)
This method retrieves an alphabetically-ordered list of Space objects that belong to the category specified by the caller for
all the OuterArea instances that belong to the given Level .
public java.util.List <Space> getSortedSpacesWithFacilities ()
This method retrieves an alphabetically-ordered list of all the Space objects associated with all the OuterArea objects of the
given instance of Level .
public int hashCode ()
Class Details
This class represents a storey in a Venue (building). A Venue consists of one or more Level objects. Each
Level in turn includes one or more OuterArea objects.
Level cannot be instantiated directly. Instead, it can be obtained by calling the getLevels() method.
See also:
Venue
OuterArea
VenueController
Method Details
public boolean equals (Object o)
Parameters:
o
public Area getAreaAtPosition (GeoCoordinate position)
This method retrieves the Area of the level at a given position.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2213
position
The position for which to return the area.
Returns:
An area or null. The area may be a Space or an OuterArea.
public GeoCoordinate getCenter ()
This method retrieves the coordinates of the center of the given Level .
Returns:
An object containing the geographic coordinates of the center of the given level.
public int getFloorNumber ()
This method retrieves the floor number assigned to the given Level . Note that 0 (zero) indicates the ground
floor, negative values indicate underground floors and positive values indicate floors above ground level.
Returns:
A value indicating the floor number.
public String getFloorSynonym ()
This method retrieves the floor synonym, for example: 1, B, P1, MEZZ etc.
Returns:
A String object containing the floor synonym.
public java.util.List <Space> getNearbySpaces (GeoCoordinate position, float
radius)
This method retrievs spaces that intersect a circle around a given coordinate.
Parameters:
position
The position of the center of the circle.
radius
The radius of the circle in meters.
Returns:
A (possibly empty) list of nearby spaces.
public java.util.List <OuterArea> getOuterAreas ()
HERE Android SDK Developer's Guide
API Reference
2214
This method retrieves a list of OuterArea objects associated with the given Level instance. Depending on
the physical appearance of the building, a Level can include one or more OuterArea objects. An OuterArea
object can be used to get the Space objects associated with it.
Returns:
A list of instances of OuterArea.
public java.util.List <Space> getSortedSpaces ()
This method retrieves an alphabetically-ordered list of Space objects for the given instance of Level ,
excluding facilities. This method returns the Space objects for all OuterArea objects associated with the
given instance of Level
Returns:
A list of Space objects, excluding facilities.
public java.util.List <Space> getSortedSpacesByCategory (String
categoryName)
This method retrieves an alphabetically-ordered list of Space objects that belong to the category specified
by the caller for all the OuterArea instances that belong to the given Level .
Parameters:
categoryName
The category of OuterArea instances to retrieve.
Returns:
A list of Space objects.
public java.util.List <Space> getSortedSpacesWithFacilities ()
This method retrieves an alphabetically-ordered list of all the Space objects associated with all the
OuterArea objects of the given instance of Level . Facilities are included in the returned list.
Returns:
A list of Space objects, including facilities.
public int hashCode ()
LevelLocation
The class LevelLocation is a member of com.here.android.mpa.venues3d .
HERE Android SDK Developer's Guide
API Reference
2215
Class Summary
public class LevelLocation
extends com.here.android.mpa.venues3d.BaseLocation, java.lang.Object
Represents a level free point location used as either start- or endpoint in indoor routing.
[For complete information, see the section Class Details]
See also:
OutdoorLocation
SpaceLocation
RoutingController
Constructor Summary
Table 1378: Constructors in LevelLocation
Constructors
LevelLocation (Level level, GeoCoordinate coordinate, VenueController controller)
Constructs a level location object.
Class Details
Represents a level free point location used as either start- or endpoint in indoor routing.
See also:
OutdoorLocation
SpaceLocation
RoutingController
Constructor Details
LevelLocation (Level level, GeoCoordinate coordinate, VenueController
controller)
Constructs a level location object.
Parameters:
level
Level object.
coordinate
geolocation as a GeoCoordinate.
controller
VenueController object representing a venue where the space is located.
HERE Android SDK Developer's Guide
API Reference
2216
LinkingRoute
The class LinkingRoute is a member of com.here.android.mpa.venues3d .
Class Summary
public class LinkingRoute
implements com.here.android.mpa.venues3d.IRouteSection
extends java.lang.Object
Represents a link section of the route.
[For complete information, see the section Class Details]
See also:
OutdoorRoute
VenueRoute
Method Summary
Table 1379: Methods in LinkingRoute
Methods
public boolean equals (Object o)
public GeoCoordinate getFrom ()
Returns a geolocation of the start point of this route route section.
public int getLength ()
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
public GeoCoordinate getTo ()
Returns a geolocation of the end point of this route route section.
public int hashCode ()
Class Details
Represents a link section of the route. The route can contain sections that are inside venue, outside venue,
and link sections that typically connects indoor and outdoor locations together.
See also:
OutdoorRoute
VenueRoute
HERE Android SDK Developer's Guide
API Reference
2217
Method Details
public boolean equals (Object o)
Parameters:
o
public GeoCoordinate getFrom ()
Returns a geolocation of the start point of this route route section.
Returns:
A GeoCoordinate object representing the start point of this route section.
public int getLength ()
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
Returns:
A route type.
public GeoCoordinate getTo ()
Returns a geolocation of the end point of this route route section.
Returns:
A GeoCoordinate object representing the end point of this route section.
public int hashCode ()
Margin
The class Margin is a member of com.here.android.mpa.venues3d .
Class Summary
public class Margin
extends java.lang.Object
This class represents margins in screen pixels.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2218
Constructor Summary
Table 1380: Constructors in Margin
Constructors
Margin (int left, int top, int right, int bottom)
This method is a constructor.
Method Summary
Table 1381: Methods in Margin
Methods
public int getBottom ()
This method retrieves the bottom margin.
public int getLeft ()
This method retrieves the left margin.
public int getRight ()
This method retrieves the right margin.
public int getTop ()
This method retrieves the top margin.
Class Details
This class represents margins in screen pixels.
Constructor Details
Margin (int left, int top, int right, int bottom)
This method is a constructor.
Parameters:
left
A value indicating the left margin.
top
A value indicating the top margin.
right
A value indicating the right margin.
bottom
A value indicating the bottom margin.
HERE Android SDK Developer's Guide
API Reference
2219
Method Details
public int getBottom ()
This method retrieves the bottom margin.
Returns:
A value indicating the bottom margin in screen pixels.
public int getLeft ()
This method retrieves the left margin.
Returns:
A value indicating the left margin in screen pixels.
public int getRight ()
This method retrieves the right margin.
Returns:
A value indicating the right margin in screen pixels.
public int getTop ()
This method retrieves the top margin.
Returns:
A value indicating the top margin in screen pixels.
OutdoorLocation
The class OutdoorLocation is a member of com.here.android.mpa.venues3d .
Class Summary
public class OutdoorLocation
extends com.here.android.mpa.venues3d.BaseLocation, java.lang.Object
Represents an outdoor location used as either start- or endpoint in indoor routing.
[For complete information, see the section Class Details]
See also:
SpaceLocation
RoutingController
HERE Android SDK Developer's Guide
API Reference
2220
Class Details
Represents an outdoor location used as either start- or endpoint in indoor routing.
See also:
SpaceLocation
RoutingController
OutdoorRoute
The class OutdoorRoute is a member of com.here.android.mpa.venues3d .
Class Summary
public class OutdoorRoute
implements com.here.android.mpa.venues3d.IRouteSection
extends java.lang.Object
Represents an outdoor section of the route.
[For complete information, see the section Class Details]
See also:
LinkingRoute
VenueRoute
Method Summary
Table 1382: Methods in OutdoorRoute
Methods
public boolean equals (Object o)
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the outdoor route.
public int getLength ()
public Route getRoute ()
Returns Route object encapsulated by this route section.
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2221
Class Details
Represents an outdoor section of the route. The route can contain sections that are inside venue, outside
venue, and link sections that typically connects indoor and outdoor locations together.
See also:
LinkingRoute
VenueRoute
Method Details
public boolean equals (Object o)
Parameters:
o
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the outdoor route.
Returns:
A GeoBoundingBox object.
public int getLength ()
public Route getRoute ()
Returns Route object encapsulated by this route section.
Returns:
A route object.
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
public int hashCode ()
OuterArea
The class OuterArea is a member of com.here.android.mpa.venues3d .
HERE Android SDK Developer's Guide
API Reference
2222
Class Summary
public final class OuterArea
extends com.here.android.mpa.venues3d.Area, com.here.android.mpa.venues3d.SpatialObject,
java.lang.Object
This class represents the physical outer area of a Level associated with a Venue (building).
[For complete information, see the section Class Details]
See also:
Venue
Level
getSortedSpaces()
getSortedSpacesByCategory(String)
getSortedSpacesWithFacilities()
Space
VenueController
Method Summary
Table 1383: Methods in OuterArea
Methods
public java.util.List <Space> getNearbySpaces (GeoCoordinate position, float radius)
This method retrievs spaces that intersect a circle around a given coordinate.
public Space getSpaceAtPosition (GeoCoordinate position)
This method retrieves the Space of the outer area at a given position.
public java.util.List <Space> getSpaces ()
This method retrieves an array of Space objects for the given instance of OuterArea .
Class Details
This class represents the physical outer area of a Level associated with a Venue (building).
A level may have several outer areas for, depending on the physical appearance of the building. This class
can be used to get Space objects associated with it.
OuterArea cannot be instantiated directly. Instead, it can be obtained by calling getOuterAreas().
See also:
Venue
Level
getSortedSpaces()
HERE Android SDK Developer's Guide
API Reference
2223
getSortedSpacesByCategory(String)
getSortedSpacesWithFacilities()
Space
VenueController
Method Details
public java.util.List <Space> getNearbySpaces (GeoCoordinate position, float
radius)
This method retrievs spaces that intersect a circle around a given coordinate.
Parameters:
position
The position of the center of the circle.
radius
The radius of the circle in meters.
Returns:
A (possibly empty) list of nearby spaces.
public Space getSpaceAtPosition (GeoCoordinate position)
This method retrieves the Space of the outer area at a given position.
Parameters:
position
The position for which to return the space.
Returns:
A space or null.
public java.util.List <Space> getSpaces ()
This method retrieves an array of Space objects for the given instance of OuterArea .
Returns:
A list of Space objects.
RoutingController
The class RoutingController is a member of com.here.android.mpa.venues3d .
HERE Android SDK Developer's Guide
API Reference
2224
Class Summary
public class RoutingController
extends java.lang.Object
[For complete information, see the section Class Details]
Nested Class Summary
Table 1384: Nested Classes in RoutingController
Nested Classes
public static abstract interface RoutingController.RoutingControllerListener
Represents a listener to provide notification when a route calculation is completed.
Method Summary
Table 1385: Methods in RoutingController
Methods
public void addListener (RoutingControllerListener listener)
Adds RoutingController.RoutingControllerListener object to RoutingController object.
public void calculateCombinedRoute (BaseLocation from, BaseLocation to, VenueRouteOptions options)
Starts route calculation with given start and end locations.
public void calculateCombinedRoute (BaseLocation[] points, VenueRouteOptions options)
Starts route calculation with given waypoints.
public void hideRoute ()
Hides the currently visible route.
public void removeListener (RoutingControllerListener listener)
Removes given RoutingController.RoutingControllerListener object from the list of listeners, which receive the
CombinedRoute related events.
public void showRoute (CombinedRoute route)
Shows combined route from start location to destination in the map.
Class Details
Method Details
public void addListener (RoutingControllerListener listener)
Adds RoutingController.RoutingControllerListener object to RoutingController object.
Parameters:
listener
HERE Android SDK Developer's Guide
API Reference
2225
The RoutingControllerListener object to be added
public void calculateCombinedRoute (BaseLocation from, BaseLocation to,
VenueRouteOptions options)
Starts route calculation with given start and end locations. Calculation is done in an asynchronous manner,
and the calculated route will be available for listeners of the RoutingController.RoutingControllerListener
interface upon completion. Parking locations are only taken into account if the transport mode is set to car
in RouteOptions. If the transport mode is car and the starting point has an associated parking location, the
route segment from the starting point to the associated parking location will be in pedestrian mode. If the
transport mode is car and the end point has an associated parking location, the route segment from the
parking location to the end point will be in pedestrian mode.
Parameters:
from
The start point of the route as BaseLocation object.
to
The end point of the route as BaseLocation object.
options
The route options to set.
public void calculateCombinedRoute (BaseLocation[] points, VenueRouteOptions
options)
Starts route calculation with given waypoints. Calculation is done in an asynchronous manner, and the
calculated route will be available for listeners of the RoutingController.RoutingControllerListener interface
upon completion. Parking locations are only taken into account for the start and end points of the route,
and only if the transport mode is set to car in RouteOptions. Parking locations on intermediate waypoints
are ignored. If the transport mode is car and the starting point has an associated parking location, the
route segment from the starting point to the associated parking location will be in pedestrian mode. If the
transport mode is car and the end point has an associated parking location, the route segment from the
parking location to the end point will be in pedestrian mode.
Parameters:
points
The points on of the route as BaseLocation object (start, waypoints, end). Maximum number of
elements is 11 (9 waypoints).
options
The route options to set.
public void hideRoute ()
Hides the currently visible route. Does nothing if there is no route visible.
HERE Android SDK Developer's Guide
API Reference
2226
public void removeListener (RoutingControllerListener listener)
Removes given RoutingController.RoutingControllerListener object from the list of listeners, which receive the
CombinedRoute related events.
Parameters:
listener
The RoutingControllerListener object to be removed.
public void showRoute (CombinedRoute route)
Shows combined route from start location to destination in the map. This route can be used as a guide about
how to get from starting point to the destination. Only one route at a time can be shown. When calling this
method while there is already a route visible in the map, it will be replaced with the given route.
Parameters:
route
The route to show.
RoutingControllerListener
The interface RoutingControllerListener is a member of com.here.android.mpa.venues3d.RoutingController.
Interface Summary
public static abstract interface RoutingController.RoutingControllerListener
Represents a listener to provide notification when a route calculation is completed.
[For complete information, see the section Interface Details]
Method Summary
Table 1386: Methods in RoutingControllerListener
Methods
public abstract void onCombinedRouteCompleted (CombinedRoute route)
Route calculation is completed.
Interface Details
Represents a listener to provide notification when a route calculation is completed.
This class can not be instantiated directly. Use getRoutingController() to obtain an instances of this class.
HERE Android SDK Developer's Guide
API Reference
2227
Method Details
public abstract void onCombinedRouteCompleted (CombinedRoute route)
Route calculation is completed.
Parameters:
route
The CombinedRoute object representing different route sections including indoor part(s),
possible outdoor part and possible link section(s). The route can be shown on the map using
showRoute(CombinedRoute) method. A CombinedRoute route object contains 0 route sections in case if
route calculation fails.
Space
The class Space is a member of com.here.android.mpa.venues3d .
Class Summary
public final class Space
extends com.here.android.mpa.venues3d.Area, com.here.android.mpa.venues3d.SpatialObject,
java.lang.Object
This class represents a physical space in a Venue (building), for example a shop in a shopping mall.
[For complete information, see the section Class Details]
See also:
Content
Venue
Nested Class Summary
Table 1387: Nested Classes in Space
Nested Classes
public static final enumeration Space.SpaceType
This enumeration defines identifiers for space types.
Method Summary
Table 1388: Methods in Space
Methods
public Content getContent ()
This method obtains the Content object associated with the given Space instance.
HERE Android SDK Developer's Guide
API Reference
2228
Methods
public int getFloorNumber ()
This method retrieves the floor number assigned to the given Level .
public String getFloorSynonym ()
This method retrieves the floor synonym, for example: 1, B, P1, MEZZ etc.
public Bitmap getIcon (Context context)
This method obtains the icon used to indicate the given space on the map.
public SpaceType getType ()
This method obtains the space type assigned to the given object.
public String getVenueName ()
This method obtains the name of the Venue in which the given space is located.
Class Details
This class represents a physical space in a Venue (building), for example a shop in a shopping mall. When
the VenueMapFragment is used, the Space is interactive and the application user can tap on it.
See also:
Content
Venue
Method Details
public Content getContent ()
This method obtains the Content object associated with the given Space instance.
Returns:
An object representing the content of the given Space instance.
public int getFloorNumber ()
This method retrieves the floor number assigned to the given Level . Note that 0 (zero) indicates the ground
floor, negative values indicate underground floors and positive values indicate floors above ground level.
Returns:
A value indicating the floor number.
public String getFloorSynonym ()
This method retrieves the floor synonym, for example: 1, B, P1, MEZZ etc.
Returns:
A string object containing the floor synonym.
HERE Android SDK Developer's Guide
API Reference
2229
public Bitmap getIcon (Context context)
This method obtains the icon used to indicate the given space on the map.
Parameters:
context
An object representing the context of the application.
Returns:
A Bitmap object representing the icon or null if the Space does not use an icon.
public SpaceType getType ()
This method obtains the space type assigned to the given object. Use this method to determine if the space
is a facility.
Returns:
An object indicating the Space.SpaceType.
public String getVenueName ()
This method obtains the name of the Venue in which the given space is located.
Returns:
A string containing the name of the venue.
SpaceType
The enumeration SpaceType is a member of com.here.android.mpa.venues3d.Space.
Enumeration Summary
public static final enumeration Space.SpaceType
extends java.lang.Enum, java.lang.Object
This enumeration defines identifiers for space types.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
2230
Enum Constant Summary
Table 1389: Enum Constants in SpaceType
Fields
public static final SpaceType SPACE
Indicates a standard Space object.
public static final SpaceType FACILITY
Indicates a Space object which is a facility.
Method Summary
Table 1390: Methods in SpaceType
Methods
public static SpaceType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static Space.SpaceType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines identifiers for space types.
Enum Constant Details
public static final SpaceType SPACE
Indicates a standard Space object.
public static final SpaceType FACILITY
Indicates a Space object which is a facility. Examples of facilities are elevators, stairs, toilets, ATM's etc.
Method Details
public static SpaceType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
HERE Android SDK Developer's Guide
API Reference
2231
public static Space.SpaceType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
SpaceLocation
The class SpaceLocation is a member of com.here.android.mpa.venues3d .
Class Summary
public class SpaceLocation
extends com.here.android.mpa.venues3d.BaseLocation, java.lang.Object
Represents a indoor space location used as either start- or endpoint in indoor routing.
[For complete information, see the section Class Details]
See also:
OutdoorLocation
RoutingController
Constructor Summary
Table 1391: Constructors in SpaceLocation
Constructors
SpaceLocation (Space space, VenueController controller)
Constructs a space location object with a given space and venue controller objects.
Class Details
Represents a indoor space location used as either start- or endpoint in indoor routing.
See also:
OutdoorLocation
RoutingController
Constructor Details
SpaceLocation (Space space, VenueController controller)
Constructs a space location object with a given space and venue controller objects.
Parameters:
space
Space object.
controller
HERE Android SDK Developer's Guide
API Reference
2232
VenueController object representing a venue where the space is located.
SpatialObject
The class SpatialObject is a member of com.here.android.mpa.venues3d .
Class Summary
public class SpatialObject
extends java.lang.Object
This class represents a physical space on a map.
[For complete information, see the section Class Details]
Constructor Summary
Table 1392: Constructors in SpatialObject
Constructors
SpatialObject (SpatialObjectImpl impl)
Package Private Constructor
Method Summary
Table 1393: Methods in SpatialObject
Methods
public boolean equals (Object o)
public String getId ()
This method retrieves a string which uniquely identifies the given instance of SpatialObject .
public int hashCode ()
Class Details
This class represents a physical space on a map. This space is defined by a unique identifier.
Constructor Details
SpatialObject (SpatialObjectImpl impl)
Package Private Constructor
Parameters:
impl
HERE Android SDK Developer's Guide
API Reference
2233
The impl object to be constructed of.
Method Details
public boolean equals (Object o)
Parameters:
o
public String getId ()
This method retrieves a string which uniquely identifies the given instance of SpatialObject . The string
can be used to specify the space for example, when calling the method selectAsync(String, String). .
Returns:
A string containing the unique identifier of the object.
public int hashCode ()
StyleSettings
The class StyleSettings is a member of com.here.android.mpa.venues3d .
Class Summary
public class StyleSettings
extends java.lang.Object
Defines style settings for venue and space objects.
[For complete information, see the section Class Details]
See also:
RoutingController
Constructor Summary
Table 1394: Constructors in StyleSettings
Constructors
StyleSettings ()
Constructs a StyleSettings object.
HERE Android SDK Developer's Guide
API Reference
2234
Method Summary
Table 1395: Methods in StyleSettings
Methods
public Integer getFillColor ()
Returns the fill color of the object if it's specified or null otherwise.
public Integer getLabelFillColor ()
Returns the fill color of the label text of the object if it's specified or null otherwise.
public Image getLabelImage ()
Returns the image which is shown with the label of the object.
public String getLabelName ()
Returns the name which is shown in the label of the object.
public Integer getLabelOutlineColor ()
Returns the outline color of the label text of the object if it's specified or null otherwise.
public Integer getOutlineColor ()
Returns the outline color of the object if it's specified or null otherwise.
public Integer getSelectedFillColor ()
Returns the fill color of the object in the selected state if it's specified or null otherwise.
public Integer getSelectedOutlineColor ()
Returns the outline color of the object in the selected state if it's specified or null otherwise.
public void setFillColor (Integer color)
Sets the fill color of the object.
public void setLabelFillColor (Integer color)
Sets the fill color of the label text of the object.
public void setLabelImage (Image image)
Sets the image which is shown with the label of the object.
public void setLabelName (String name)
Sets the name which is shown in the label of the object.
public void setLabelOutlineColor (Integer color)
Sets the outline color of the label text of the object.
public void setOutlineColor (Integer color)
Sets the outline color of the object.
public void setSelectedFillColor (Integer color)
Sets the fill color of the object in the selected state.
public void setSelectedOutlineColor (Integer color)
Sets the outline color of the object in the selected state.
HERE Android SDK Developer's Guide
API Reference
2235
Class Details
Defines style settings for venue and space objects.
See also:
RoutingController
Constructor Details
StyleSettings ()
Constructs a StyleSettings object.
Method Details
public Integer getFillColor ()
Returns the fill color of the object if it's specified or null otherwise.
Returns:
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
setFillColor(Integer)
public Integer getLabelFillColor ()
Returns the fill color of the label text of the object if it's specified or null otherwise.
Returns:
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
setLabelFillColor(Integer)
public Image getLabelImage ()
Returns the image which is shown with the label of the object.
Returns:
An Image which is shown with the label of the object.
See also:
setLabelImage(Image)
public String getLabelName ()
HERE Android SDK Developer's Guide
API Reference
2236
Returns the name which is shown in the label of the object.
Returns:
A String which is shown in the label of the object.
See also:
setLabelName(String)
public Integer getLabelOutlineColor ()
Returns the outline color of the label text of the object if it's specified or null otherwise.
Returns:
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
setLabelOutlineColor(Integer)
public Integer getOutlineColor ()
Returns the outline color of the object if it's specified or null otherwise.
Returns:
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
setOutlineColor(Integer)
public Integer getSelectedFillColor ()
Returns the fill color of the object in the selected state if it's specified or null otherwise.
Returns:
A color as 32-bit integer. Format is (in hex): 0xAARRGGBB.
See also:
setSelectedFillColor(Integer)
public Integer getSelectedOutlineColor ()
Returns the outline color of the object in the selected state if it's specified or null otherwise.
Returns:
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
setSelectedOutlineColor(Integer)
HERE Android SDK Developer's Guide
API Reference
2237
public void setFillColor (Integer color)
Sets the fill color of the object. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getFillColor()
public void setLabelFillColor (Integer color)
Sets the fill color of the label text of the object. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getLabelFillColor()
public void setLabelImage (Image image)
Sets the image which is shown with the label of the object.
Parameters:
image
A Image which is shown with the label of the object.
See also:
getLabelImage()
public void setLabelName (String name)
Sets the name which is shown in the label of the object.
Parameters:
name
A String which is shown in the label of the object.
See also:
getLabelName()
HERE Android SDK Developer's Guide
API Reference
2238
public void setLabelOutlineColor (Integer color)
Sets the outline color of the label text of the object. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getLabelOutlineColor()
public void setOutlineColor (Integer color)
Sets the outline color of the object. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getOutlineColor()
public void setSelectedFillColor (Integer color)
Sets the fill color of the object in the selected state. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getSelectedFillColor()
public void setSelectedOutlineColor (Integer color)
Sets the outline color of the object in the selected state. A color is 32-bit Integer or null if it's not specified.
Parameters:
color
A color as 32-bit Integer. Format is (in hex): 0xAARRGGBB.
See also:
getSelectedOutlineColor()
HERE Android SDK Developer's Guide
API Reference
2239
Venue
The class Venue is a member of com.here.android.mpa.venues3d .
Class Summary
public final class Venue
extends java.lang.Object
This class represents a public building or a group of public buildings on a map.
[For complete information, see the section Class Details]
See also:
Level
OuterArea
Space
VenueController
Method Summary
Table 1396: Methods in Venue
Methods
public boolean equals (Object o)
public GeoBoundingBox getBoundingBox ()
This method retrieves the bounding box of the given Venue instance.
public GeoCoordinate getCenter ()
This method retrieves the center of the bounding box of the given venue.
public Content getContent ()
This method retrieves the Content object the given Venue instance.
public String getId ()
This method retrieves a string which uniquely identifies the given venue.
public java.util.List <Level> getLevels ()
This method retrieves a list of Level objects for the given Venue .
public java.util.List <Space> getNearbySpaces (Space space, float radius)
This method retrieves spaces that intersect a circle around the center of a space.
public java.util.List <Space> getSortedSpaces ()
This method retrieves the alphabetically ordered array of Space objects for the given Venue .
public Space getSpace (String id)
This method retrieves the space or the facility as the Space object based on the given identifier inside this Venue .
HERE Android SDK Developer's Guide
API Reference
2240
Methods
public int hashCode ()
Class Details
This class represents a public building or a group of public buildings on a map. Examples of public buildings
are shopping malls and airports. Venue objects are based on models stored by the back-end service and
constructed as necessary, for example when the map pans to an area where a venue exists. Similarly, when
the map is panned away from that area, the venue object is removed from the map view to free up the
memory reserved for the venues.
A Venue instance includes one or more Level objects. A Level in turn consists of one or more OuterArea
objects. An OuterArea represents a physical form of an outer area of a level in the building. An OuterArea
typically contains Space objects that represent, for example, single shops inside the venue.
A Venue cannot be instantiated directly. Instead, an instance can be obtained by calling getVenue().
See also:
Level
OuterArea
Space
VenueController
Method Details
public boolean equals (Object o)
Parameters:
o
public GeoBoundingBox getBoundingBox ()
This method retrieves the bounding box of the given Venue instance.
Returns:
An object representing the bounding box that encloses the given venue.
public GeoCoordinate getCenter ()
This method retrieves the center of the bounding box of the given venue.
Returns:
An object containing the geographic coordinates of the center of the bounding box of the given venue.
public Content getContent ()
HERE Android SDK Developer's Guide
API Reference
2241
This method retrieves the Content object the given Venue instance.
Returns:
An object representing the venue content.
public String getId ()
This method retrieves a string which uniquely identifies the given venue.
Returns:
The unique identifier of the given Venue object.
public java.util.List <Level> getLevels ()
This method retrieves a list of Level objects for the given Venue . A Level consist of one or more OuterArea
objects.
Returns:
The list of Level objects.
public java.util.List <Space> getNearbySpaces (Space space, float radius)
This method retrieves spaces that intersect a circle around the center of a space.
Parameters:
space
The Space for which to find nearby spaces.
radius
The radius in meters of the circle around the center of the space inside of which to search for nearby
spaces.
Returns:
A (possibly empty) list of nearby spaces.
public java.util.List <Space> getSortedSpaces ()
This method retrieves the alphabetically ordered array of Space objects for the given Venue .
Returns:
The list of Space objects ordered alphabetically per level, starting from the lowest level.
public Space getSpace (String id)
This method retrieves the space or the facility as the Space object based on the given identifier inside this
Venue .
HERE Android SDK Developer's Guide
API Reference
2242
Parameters:
id
The string containing the Space identifier.
Returns:
An object representing the requested space or null if there is no match for the identifier.
See also:
getId()
public int hashCode ()
VenueAccount
The class VenueAccount is a member of com.here.android.mpa.venues3d .
Class Summary
public final class VenueAccount
extends java.lang.Object
This class represents a HERE account information used in venue service.
[For complete information, see the section Class Details]
See also:
VenueService
Method Summary
Table 1397: Methods in VenueAccount
Methods
public String getDescription ()
Returns a string which provides additional information about the given instance of VenueAccount .
public String getId ()
Returns a string which uniquely identifies the given instance of VenueAccount .
Class Details
This class represents a HERE account information used in venue service.
See also:
VenueService
HERE Android SDK Developer's Guide
API Reference
2243
Method Details
public String getDescription ()
Returns a string which provides additional information about the given instance of VenueAccount .
Returns:
A string containing the description of the object.
public String getId ()
Returns a string which uniquely identifies the given instance of VenueAccount .
Returns:
A string containing the unique identifier of the object.
VenueController
The class VenueController is a member of com.here.android.mpa.venues3d .
Class Summary
public final class VenueController
extends java.lang.Object
This class encapsulates interactions of a viewable Venue.
[For complete information, see the section Class Details]
See also:
addListener(VenueListener)
Constructor Summary
Table 1398: Constructors in VenueController
Constructors
VenueController (VenueControllerImpl impl)
Method Summary
Table 1399: Methods in VenueController
Methods
public void deselectSpace ()
This method deselects the currently selected space.
HERE Android SDK Developer's Guide
API Reference
2244
Methods
public Level getGroundLevel ()
This method retrieves an object representing the ground level.
public BaseLocation getLocation (PointF tapPoint, boolean preferSpace)
Returns the BaseLocation object based on the screen pixel coordinates.
public int getModelScale ()
public GeoCoordinate getNormalGeoCoordinate (GeoCoordinate scaledCoord)
This method returns normal geocoordinate from scaled geocoordinate used in Venue Zoom.
public GeoCoordinate getScaledGeoCoordinate (GeoCoordinate coord)
This method returns scaled geocoordinate to be used in Venue Zoom.
public Level getSelectedLevel ()
This method retrieves an object representing the selected level.
public Space getSelectedSpace ()
This method retrieves the selected Space or null if no space is currently selected.
public StyleSettings getStyleSettings ()
Returns StyleSettings object for the VenueController .
public StyleSettings getStyleSettings (Space space)
Returns StyleSettings object for the specific space.
public Venue getVenue ()
This method obtains the Venue object the given instance of VenueController represents.
public void selectLevel (Level level)
This method selects the level indicated by the caller.
public void selectSpace (Space space)
This method selects the space specified by the caller from the given Venue.
public void setStyleSettings (StyleSettings settings)
Sets StyleSettings object for the VenueController .
public void setStyleSettings (StyleSettings settings, Space space)
Sets StyleSettings object for the specific space.
public boolean useVenueZoom (boolean venueZoomInUse)
This method set Venue Zoom on or off.
Class Details
This class encapsulates interactions of a viewable Venue. Methods of this class allow clients to select and
deselect Levels and Spaces.
HERE Android SDK Developer's Guide
API Reference
2245
This class can not be instantiated directly. Instead an instance of this class is returned by
various map interaction operations (like tapping the venue in the map) for clients registered as a
VenueMapFragment.VenueListener with VenueMapFragment.
See also:
addListener(VenueListener)
Constructor Details
VenueController (VenueControllerImpl impl)
Parameters:
impl
Method Details
public void deselectSpace ()
This method deselects the currently selected space.
public Level getGroundLevel ()
This method retrieves an object representing the ground level.
Returns:
An object representing the ground level.
public BaseLocation getLocation (PointF tapPoint, boolean preferSpace)
Returns the BaseLocation object based on the screen pixel coordinates.
Parameters:
tapPoint
The screen pixel coordinates.
preferSpace
If true and user clicked on the Space, returns the SpaceLocation object, otherwise returns LevelLocation.
Returns:
The LevelLocation or SpaceLocation object, if taps point is inside the venue, the OutdoorLocation object
otherwise.
public int getModelScale ()
public GeoCoordinate getNormalGeoCoordinate (GeoCoordinate scaledCoord)
HERE Android SDK Developer's Guide
API Reference
2246
This method returns normal geocoordinate from scaled geocoordinate used in Venue Zoom. In Venue Zoom
mode coordinates need to be scaled in order to show map objects properly.
Parameters:
scaledCoord
Scaled coordinate to be converted to normal coodintate.
Returns:
Normal geocoordinate from scaled geocoordinate used in Venue Zoom.
public GeoCoordinate getScaledGeoCoordinate (GeoCoordinate coord)
This method returns scaled geocoordinate to be used in Venue Zoom. In Venue Zoom mode coordinates need
to be scaled in order to show map objects properly.
Parameters:
coord
Coordinate to be converted to scale coodintate.
Returns:
Scaled geocoordinate to be used in Venue Zoom.
public Level getSelectedLevel ()
This method retrieves an object representing the selected level.
Returns:
An object representing the selected level.
public Space getSelectedSpace ()
This method retrieves the selected Space or null if no space is currently selected.
Returns:
An object representing the selected space or null if no space is currently selected.
public StyleSettings getStyleSettings ()
Returns StyleSettings object for the VenueController . Style settings can change visual representation of
the VenueController , including colors for the shape and the label, the name and the icon.
Returns:
A StyleSettings object for the specific VenueController or null if style settings are not set.
public StyleSettings getStyleSettings (Space space)
HERE Android SDK Developer's Guide
API Reference
2247
Returns StyleSettings object for the specific space. Style settings can change visual representation of the
space, including colors for the shape and the label, the name and the icon.
Parameters:
space
A Space object for which style settings are applied.
Returns:
A StyleSettings object for the specific space or null if style settings are not set.
public Venue getVenue ()
This method obtains the Venue object the given instance of VenueController represents.
Returns:
An instance of Venue.
public void selectLevel (Level level)
This method selects the level indicated by the caller. The selected level is viewed as the topmost in the
venue. Levels on top of the selected venue are hidden. Levels below the selected venue are obscured by the
selected level.
Parameters:
level
A value indicating the level to select.
public void selectSpace (Space space)
This method selects the space specified by the caller from the given Venue.
Parameters:
space
An object indicating the space to select.
public void setStyleSettings (StyleSettings settings)
Sets StyleSettings object for the VenueController . Style settings can change visual representation of the
VenueController , including colors for the shape and the label, the name and the icon.
Parameters:
settings
A StyleSettings settings object.
HERE Android SDK Developer's Guide
API Reference
2248
public void setStyleSettings (StyleSettings settings, Space space)
Sets StyleSettings object for the specific space. Style settings can change visual representation of the space,
including colors for the shape and the label, the name and the icon.
Parameters:
settings
A StyleSettings settings object.
space
Space object for which style settings will be applied.
public boolean useVenueZoom (boolean venueZoomInUse)
This method set Venue Zoom on or off. Venue Zoom shows venues in enlarged mode. In this mode the map is
not visible but is replaced with a grey color.
In order to use Venue Zoom it must be enabled, and Map zoom level must be at least 18.
Use enableVenueZoom(boolean) to enable the feature.
Parameters:
venueZoomInUse
Defines whether Venue Zoom is in use or not.
Returns:
A boolean value indicating whether the transition was actually done.
VenueGestureListener
The class VenueGestureListener is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueGestureListener
implements com.here.android.mpa.mapping.MapGesture.OnGestureListener,
com.here.android.mpa.venues3d.VenueMapFragment.VenueListener
extends java.lang.Object
VenueGestureListener provides an application a possibility to use Venue Zoom with conventional pinch
zoom gesture.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2249
Constructor Summary
Table 1400: Constructors in VenueGestureListener
Constructors
VenueGestureListener (VenueLayerAdapter venueLayer, int pixelDensity)
Method Summary
Table 1401: Methods in VenueGestureListener
Methods
public boolean onDoubleTapEvent (PointF p)
public void onFloorChanged (Venue venue, Level level, Level level1)
public boolean onLongPressEvent (PointF p)
public void onLongPressRelease ()
public boolean onMapObjectsSelected (java.util.List <ViewObject> objects)
public void onMultiFingerManipulationEnd ()
public void onMultiFingerManipulationStart ()
public void onPanEnd ()
public void onPanStart ()
public void onPinchLocked ()
public boolean onPinchZoomEvent (float scaleFactor, PointF p)
public boolean onRotateEvent (float rotateAngle)
public void onRotateLocked ()
public void onSpaceDeselected (Venue venue, Space space)
public void onSpaceSelected (Venue venue, Space space)
public boolean onTapEvent (PointF p)
public boolean onTiltEvent (float angle)
public boolean onTwoFingerTapEvent (PointF p)
public void onVenueDeselected (Venue venue, DeselectionSource deselectionSource)
public void onVenueSelected (Venue venue)
public void onVenueTapped (Venue venue, float v, float v1)
public void onVenueVisibleInViewport (Venue venue, boolean b)
HERE Android SDK Developer's Guide
API Reference
2250
Class Details
VenueGestureListener provides an application a possibility to use Venue Zoom with conventional pinch
zoom gesture. Up to the maximum zoom level supported by Map, the gestures are handled by the current
default gesture handler. When zooming more in with pinch gesture, the Venue Zoom is activated. Zooming
out using pinch gesture will deactivate Venue Zoom and return back to normal zoom range.
Constructor Details
VenueGestureListener (VenueLayerAdapter venueLayer, int pixelDensity)
Parameters:
venueLayer
pixelDensity
Method Details
public boolean onDoubleTapEvent (PointF p)
Parameters:
p
public void onFloorChanged (Venue venue, Level level, Level level1)
Parameters:
venue
level
level1
public boolean onLongPressEvent (PointF p)
Parameters:
p
public void onLongPressRelease ()
public boolean onMapObjectsSelected (java.util.List <ViewObject> objects)
Parameters:
objects
public void onMultiFingerManipulationEnd ()
HERE Android SDK Developer's Guide
API Reference
2251
public void onMultiFingerManipulationStart ()
public void onPanEnd ()
public void onPanStart ()
public void onPinchLocked ()
public boolean onPinchZoomEvent (float scaleFactor, PointF p)
Parameters:
scaleFactor
p
public boolean onRotateEvent (float rotateAngle)
Parameters:
rotateAngle
public void onRotateLocked ()
public void onSpaceDeselected (Venue venue, Space space)
Parameters:
venue
space
public void onSpaceSelected (Venue venue, Space space)
Parameters:
venue
space
public boolean onTapEvent (PointF p)
Parameters:
p
HERE Android SDK Developer's Guide
API Reference
2252
public boolean onTiltEvent (float angle)
Parameters:
angle
public boolean onTwoFingerTapEvent (PointF p)
Parameters:
p
public void onVenueDeselected (Venue venue, DeselectionSource
deselectionSource)
Parameters:
venue
deselectionSource
public void onVenueSelected (Venue venue)
Parameters:
venue
public void onVenueTapped (Venue venue, float v, float v1)
Parameters:
venue
v
v1
public void onVenueVisibleInViewport (Venue venue, boolean b)
Parameters:
venue
b
VenueInfo
The class VenueInfo is a member of com.here.android.mpa.venues3d .
HERE Android SDK Developer's Guide
API Reference
2253
Class Summary
public final class VenueInfo
extends com.here.android.mpa.venues3d.SpatialObject, java.lang.Object
This class encapsulates the identification and location information for a Venue.
[For complete information, see the section Class Details]
Method Summary
Table 1402: Methods in VenueInfo
Methods
public GeoBoundingBox getBoundingBox ()
This method retrieves a bounding box enclosing the venue.
public boolean getIsAlternativeSource ()
This method returns true if the venue is located in an alternative source.
public String getName ()
This method retrieves the name of the venue.
Class Details
This class encapsulates the identification and location information for a Venue. An instance of the class is
returned by the search methods getVenuesIn(GeoBoundingBox) and getVenueById(String) of VenueService.
The Map can be centered, based on the geographic coordinates of the venue returned by getBoundingBox().
You can open a venue, using the venue identifier returned by getId() called on VenueInfo .
Method Details
public GeoBoundingBox getBoundingBox ()
This method retrieves a bounding box enclosing the venue. A bounding box is an area defined by the
minimum and maximum longitudes and latitudes of the venue.
Returns:
An object representing the bounding box that encloses the venue.
public boolean getIsAlternativeSource ()
This method returns true if the venue is located in an alternative source. More information about primary
and alternative sources can be found in setIsCombinedContent(boolean).
Returns:
A boolean containing the information if the venue is located in an alternative source.
HERE Android SDK Developer's Guide
API Reference
2254
public String getName ()
This method retrieves the name of the venue.
Returns:
A string containing the name of the venue.
VenueLayerAdapter
The interface VenueLayerAdapter is a member of com.here.android.mpa.venues3d .
Interface Summary
public abstract interface VenueLayerAdapter
An interface for 3D Venue related functions that both VenueMapFragment and VenueMapView implements.
[For complete information, see the section Interface Details]
Method Summary
Table 1403: Methods in VenueLayerAdapter
Methods
public abstract void addListener (VenueListener listener)
This method adds the VenueMapFragment.VenueListener object provided by the caller to the list of active listeners.
public abstract void addVenueZoomListener (VenueZoomListener listener)
Adds the VenueMapFragment.VenueZoomListener object to the list of active listeners.
public abstract boolean cancelVenueSelection ()
This method attempts to cancel all Venue loading and selection that may be currently in progress.
public abstract void deselectVenue ()
This method deselects the currently selected Venue.
public abstract Activity getActivity ()
This method retrieves an android.app.Activity object associated with this object.
public abstract CombinedNavigationManager getCombinedNavigationManager ()
This method retrieves a CombinedNavigationManager object, which can be used to navigate CombinedRoute objects.
public abstract Map getMap ()
This method retrieves a Map object associated with this object.
public abstract MapGesture getMapGesture ()
This method retrieves a MapGesture object associated with this object.
public abstract Margin getMargin ()
This method retrieves the margins for the current venue view in screen pixels.
HERE Android SDK Developer's Guide
API Reference
2255
Methods
public abstract VenueNavigationManager getNavigationManager ()
This method retrieves a VenueNavigationManager object, which can be used to navigate VenueRoute objects.
public abstract PositionIndicator getPositionIndicator ()
Returns the PositionIndicator instance that renders the current position with a marker.
public abstract RoutingController getRoutingController ()
This method retrieves a RoutingController object, which can be used to search and get IRouteSection objects.
public abstract Venue getSelectedVenue ()
This method retrieves the selected Venue object.
public abstract VenueController getVenueController (Venue venue)
This method retrieves the instance of VenueController for the Venue specified by the caller.
public abstract VenueService getVenueService ()
This method retrieves a VenueService object, which can be used to search and get Venue objects.
public abstract boolean isFloorChangingAnimationEnabled ()
This method retrieves a Boolean value indicating whether floor-change animation is enabled.
public abstract boolean isHideIconOnSelectedSpaceEnabled ()
Check if the icon on a space is hidden when the space is selected.
public abstract boolean isOpenModeEnabled ()
This method retrieves a Boolean indicating if the open mode is enabled.
public abstract boolean isVenueEnteringAnimationEnabled ()
This method retrieves a Boolean value indicating whether venue-entry animation is enabled.
public abstract boolean isVenueInViewportCallbackEnabled ()
This method obtains a Boolean value indicating whether onVenueVisibleInViewport(Venue, boolean) messages are sent to
objects registered as VenueMapFragment.VenueListener.
public abstract boolean isVenueLayerVisible ()
This method retrieves a Boolean indicating the visibility of the venues (the venue layer) on the map.
public abstract boolean isVenueVisible (String id)
This method checks if a Venue is visible.
public abstract void removeListener (VenueListener listener)
This method removes the VenueMapFragment.VenueListener object provided by the caller from the list of listeners, which
receive the venue and space related events.
public abstract void removeListener (VenueZoomListener listener)
Removes given VenueMapFragment.VenueZoomListener object from the list of listeners, which receive the Venue Zoom
related events.
public abstract VenueInfo selectAsync (String venueId, String spaceId)
This method selects a Venue and a Space within it in a 3D view mode.
HERE Android SDK Developer's Guide
API Reference
2256
Methods
public abstract boolean selectVenue (Venue venue)
This method selects the Venue in a 3D view mode.
public abstract VenueInfo selectVenueAsync (String id)
This method uses the id provided by the caller to select the corresponding venue in a 3D view mode.
public abstract void setFloorChangingAnimation (boolean enabled)
This method controls whether or not an animation is used on floor change.
public abstract void setHideIconOnSelectedSpaceEnabled (boolean value)
Control if the icon on a space should be hidden when the space is selected.
public abstract void setMargin (Margin value)
This method sets the margins for the current venue view in screen pixels.
public abstract void setOpenModeEnabled (boolean value)
This method sets a flag indicating whether or not the open mode is enabled.
public abstract void setVenueEnteringAnimation (boolean enabled)
This method enables or disables an animation used when the venue is opened.
public abstract void setVenueLayerVisible (boolean value)
This method sets a flag indicating whether or not the venue layer is visible.
public abstract void setVenuesInViewportCallback (boolean enabled)
This method a flag to indicate whether onVenueVisibleInViewport(Venue, boolean) messages are to be sent to objects
registered as VenueMapFragment.VenueListener.
Interface Details
An interface for 3D Venue related functions that both VenueMapFragment and VenueMapView implements.
This interface makes it easier to re-use code between VenueMapFragment and VenueMapView based UI
components.
Method Details
public abstract void addListener (VenueListener listener)
This method adds the VenueMapFragment.VenueListener object provided by the caller to the list of active
listeners. The VenueListener object contains method implementations for handling venue- and space-
related events, such as selecting and deselecting a venue.
Parameters:
listener
The VenueListener object to be added.
See also:
removeListener(VenueListener)
HERE Android SDK Developer's Guide
API Reference
2257
public abstract void addVenueZoomListener (VenueZoomListener listener)
Adds the VenueMapFragment.VenueZoomListener object to the list of active listeners. The
VenueZoomListener object contains method implementation for handling Venue Zoom activation and
deactivation notification.
Parameters:
listener
The VenueZoomListener object to be added.
See also:
removeListener(VenueZoomListener)
public abstract boolean cancelVenueSelection ()
This method attempts to cancel all Venue loading and selection that may be currently in progress.
Returns:
true if venue loading and selection actually have been cancelled, otherwise false.
public abstract void deselectVenue ()
This method deselects the currently selected Venue.
public abstract Activity getActivity ()
This method retrieves an android.app.Activity object associated with this object.
Returns:
An Activity object.
public abstract CombinedNavigationManager getCombinedNavigationManager ()
This method retrieves a CombinedNavigationManager object, which can be used to navigate CombinedRoute
objects.
Returns:
The CombinedNavigationManager object.
public abstract Map getMap ()
This method retrieves a Map object associated with this object.
Returns:
A Map object.
HERE Android SDK Developer's Guide
API Reference
2258
public abstract MapGesture getMapGesture ()
This method retrieves a MapGesture object associated with this object.
Returns:
A MapGesture object.
public abstract Margin getMargin ()
This method retrieves the margins for the current venue view in screen pixels.
Returns:
An object representing the venue view margins.
See also:
setMargin(Margin)
public abstract VenueNavigationManager getNavigationManager ()
This method retrieves a VenueNavigationManager object, which can be used to navigate VenueRoute objects.
Returns:
The VenueNavigationManager object.
public abstract PositionIndicator getPositionIndicator ()
Returns the PositionIndicator instance that renders the current position with a marker. The position indicator
should be used with PositioningManager.
Returns:
The PositionIndicator
public abstract RoutingController getRoutingController ()
This method retrieves a RoutingController object, which can be used to search and get IRouteSection objects.
Returns:
A RoutingController object, or null if initialization is not completed yet.
public abstract Venue getSelectedVenue ()
This method retrieves the selected Venue object.
Returns:
An object representing the selected venue, or null if no venue is selected.
HERE Android SDK Developer's Guide
API Reference
2259
public abstract VenueController getVenueController (Venue venue)
This method retrieves the instance of VenueController for the Venue specified by the caller.
Parameters:
venue
An instance of Venue for which to retrieve a venue controller object.
Returns:
An object representing the venue controller for the venue specified by the caller or null if the venue is not
assigned to a controller (there is no such venue on the map).
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public abstract VenueService getVenueService ()
This method retrieves a VenueService object, which can be used to search and get Venue objects.
Returns:
A VenueService object, or null if initialization is not completed yet.
public abstract boolean isFloorChangingAnimationEnabled ()
This method retrieves a Boolean value indicating whether floor-change animation is enabled.
Returns:
true if floor changing animation is enabled, otherwise false.
See also:
setFloorChangingAnimation(boolean)
public abstract boolean isHideIconOnSelectedSpaceEnabled ()
Check if the icon on a space is hidden when the space is selected.
Returns:
True if the icon on a selected space is hidden and false otherwise. The default is true.
public abstract boolean isOpenModeEnabled ()
This method retrieves a Boolean indicating if the open mode is enabled. By default the open mode is
disabled. In the open mode a user can see outer areas and spaces all the time. A selected floor and a floor
stack is always shown. Venues are selected automatically.
HERE Android SDK Developer's Guide
API Reference
2260
Returns:
The Boolean value which indicates if the open mode is enabled.
See also:
setOpenModeEnabled(boolean)
public abstract boolean isVenueEnteringAnimationEnabled ()
This method retrieves a Boolean value indicating whether venue-entry animation is enabled.
Returns:
true if the venue-entry animation is enabled, otherwise code false}.
See also:
setVenueEnteringAnimation(boolean)
public abstract boolean isVenueInViewportCallbackEnabled ()
This method obtains a Boolean value indicating whether onVenueVisibleInViewport(Venue, boolean)
messages are sent to objects registered as VenueMapFragment.VenueListener.
Returns:
true if the messages are sent, otherwise false.
public abstract boolean isVenueLayerVisible ()
This method retrieves a Boolean indicating the visibility of the venues (the venue layer) on the map.
Returns:
A Boolean value indicating if the venue layer is visible,
See also:
setVenueLayerVisible(boolean)
public abstract boolean isVenueVisible (String id)
This method checks if a Venue is visible. It can be used to check if the venue layer has loaded and displayed
a specific venue on the map.
Parameters:
id
A string containing the id of the venue to be checked.
Returns:
true to indicate that the venue is visible on the map, otherwise false.
HERE Android SDK Developer's Guide
API Reference
2261
See also:
getId()
public abstract void removeListener (VenueListener listener)
This method removes the VenueMapFragment.VenueListener object provided by the caller from the list of
listeners, which receive the venue and space related events.
Parameters:
listener
The VenueListener object to be removed.
See also:
addListener(VenueListener)
public abstract void removeListener (VenueZoomListener listener)
Removes given VenueMapFragment.VenueZoomListener object from the list of listeners, which receive the
Venue Zoom related events.
Parameters:
listener
The VenueZoomListener object to be removed.
See also:
addListener(VenueListener)
public abstract VenueInfo selectAsync (String venueId, String spaceId)
This method selects a Venue and a Space within it in a 3D view mode. The venue and space must match
their respective ids as provided by the caller. In the 3D view mode layers and spaces of the venue are visible
for the application user. The method is asynchronous, because the venue must be downloaded if it is not
already present in the cache. onVenueSelected(Venue) callback method is called when the venue have been
selected.
Parameters:
venueId
The id of the venue to be selected.
spaceId
The id of the space to be selected. If null, only the venue is selected.
Returns:
An object representing the venue info on success, null if no venue was found to match the supplied
identifier.
HERE Android SDK Developer's Guide
API Reference
2262
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
See also:
getId()
getId()
public abstract boolean selectVenue (Venue venue)
This method selects the Venue in a 3D view mode. In the 3D view mode, layers and spaces of the venue are
visible to the application user. This method opens an already donwloaded venue. onVenueSelected(Venue)
callback method is called when the venue has been selected.
Parameters:
venue
An object representing the venue to be selected.
Returns:
true, if the venue has been found on the map and opened, otherwise false.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public abstract VenueInfo selectVenueAsync (String id)
This method uses the id provided by the caller to select the corresponding venue in a 3D view mode.
In the 3D view mode, layers and spaces of the venue are visible for the application user. The method is
asynchronous, because the venue must be downloaded if it is not already present in the cache. The callback
method onVenueSelected(Venue) is called when the venue have been selected.
Parameters:
id
The identifier of the venue to be selected.
Returns:
An object representing the venue info on success, null if no venue was found to match the supplied
identifier.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
See also:
HERE Android SDK Developer's Guide
API Reference
2263
getId()
public abstract void setFloorChangingAnimation (boolean enabled)
This method controls whether or not an animation is used on floor change. Visible floors can be changed by
tapping one of them or by using the venue selector widget. By default animation is not used.
Parameters:
enabled
A Boolean value, true if the animation is to be enabled, otherwise false.
See also:
isFloorChangingAnimationEnabled()
public abstract void setHideIconOnSelectedSpaceEnabled (boolean value)
Control if the icon on a space should be hidden when the space is selected.
Parameters:
value
True if the icon on a selected space should be hidden and false otherwise. The default is true.
public abstract void setMargin (Margin value)
This method sets the margins for the current venue view in screen pixels. The defaults are (0, 0, 0, 0).
Parameters:
value
See also:
getMargin()
public abstract void setOpenModeEnabled (boolean value)
This method sets a flag indicating whether or not the open mode is enabled. By default the open mode is
disabled. In the open mode a user can see outer areas and spaces all the time. A selected floor and a floor
stack is always shown. Venues are selected automatically.
Updating the open mode is done in the background, so changes to this property may not be immediately
reflected in its value. Changes to this property will deselect a selected venue.
Parameters:
value
Boolean value which indicates if the open mode is enabled.
See also:
HERE Android SDK Developer's Guide
API Reference
2264
isOpenModeEnabled()
public abstract void setVenueEnteringAnimation (boolean enabled)
This method enables or disables an animation used when the venue is opened. A visible venue can be
entered (opened) by tapping on it. By default animation is not used.
Parameters:
enabled
A Boolean value, true if the animation is to be enabled, otherwise false.
See also:
isVenueEnteringAnimationEnabled()
public abstract void setVenueLayerVisible (boolean value)
This method sets a flag indicating whether or not the venue layer is visible. By default venues are visible.
Parameters:
value
A Boolean value indicating if the venues layer is visible, true to make the layer visible, false to hide
the layer.
See also:
isVenueLayerVisible()
public abstract void setVenuesInViewportCallback (boolean enabled)
This method a flag to indicate whether onVenueVisibleInViewport(Venue, boolean) messages are to be sent to
objects registered as VenueMapFragment.VenueListener. By default the message is not sent.
Parameters:
enabled
A Boolean, true if the messages are to be sent, otherwise false.
VenueManeuver
The class VenueManeuver is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueManeuver
extends java.lang.Object
HERE Android SDK Developer's Guide
API Reference
2265
This class represents a single route maneuver of an indoor route section.
[For complete information, see the section Class Details]
See also:
VenueRoute
Nested Class Summary
Table 1404: Nested Classes in VenueManeuver
Nested Classes
public static final enumeration VenueManeuver.ActionType
This enumeration defines identifiers for enter/exit action types.
public static final enumeration VenueManeuver.ConnectorType
This enumeration defines values that describe a connector type from one space to other.
Method Summary
Table 1405: Methods in VenueManeuver
Methods
public boolean equals (Object o)
public ActionType getActionType ()
Returns an VenueManeuver.ActionType for this maneuver.
public int getAngle ()
The angle in degrees from end of the start road to the start of the end road.
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the route subsegment the VenueManeuver belongs to.
public ConnectorType getConnectorType ()
Returns a VenueManeuver.ConnectorType for this maneuver.
public float getDistanceFromPreviousManeuver ()
Returns a distance of this maneuver from possible previous maneuver.
public float getDistanceFromStart ()
Returns a distance of this maneuver from the start of the route section.
public float getDistanceToNextManeuver ()
Returns a distance of this maneuver to possible next maneuver.
public int getFloorIndex ()
Returns a floor index where maneuver happens.
public GeoCoordinate getGeoCoordinate ()
Returns a location a GeoCoordinate of this maneuver.
HERE Android SDK Developer's Guide
API Reference
2266
Methods
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of this maneuver.
public int getMapOrientation ()
Gets the map orientation at the start of the maneuver, in degrees.
public String getNaturalGuidancePOI ()
Gets the name of the natural guidance POI.
public static float getNaturalGuidanceRadius ()
Gets the search radius for natural guidance.
public Space getSpace ()
Returns an Space object related to this maneuver.
public VenueManeuver getTargetManeuver ()
Returns a target VenueManeuver for a series of connectors of the same type (elevator, escalator etc.) which are going in the
same direction.
public Turn getTurn ()
Gets the Maneuver.Turn required to complete the maneuver.
public int hashCode ()
public static void setNaturalGuidanceRadius (float radius)
Sets the search radius for natural guidance.
Class Details
This class represents a single route maneuver of an indoor route section.
See also:
VenueRoute
Method Details
public boolean equals (Object o)
Parameters:
o
public ActionType getActionType ()
Returns an VenueManeuver.ActionType for this maneuver.
Returns:
An action id.
HERE Android SDK Developer's Guide
API Reference
2267
public int getAngle ()
The angle in degrees from end of the start road to the start of the end road. Angle has a value from 0, 360,
north is up, clockwise.
Note: a returned value of zero represents the end road that continues in the same direction as the start road.
Returns:
The angle in degrees
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the route subsegment the VenueManeuver belongs to.
Returns:
A GeoBoundingBox object.
public ConnectorType getConnectorType ()
Returns a VenueManeuver.ConnectorType for this maneuver.
Returns:
A connector type.
public float getDistanceFromPreviousManeuver ()
Returns a distance of this maneuver from possible previous maneuver.
Returns:
A distance in meters.
public float getDistanceFromStart ()
Returns a distance of this maneuver from the start of the route section.
Returns:
A distance in meters.
public float getDistanceToNextManeuver ()
Returns a distance of this maneuver to possible next maneuver.
Returns:
A distance in meters.
HERE Android SDK Developer's Guide
API Reference
2268
public int getFloorIndex ()
Returns a floor index where maneuver happens.
Returns:
A floor index.
public GeoCoordinate getGeoCoordinate ()
Returns a location a GeoCoordinate of this maneuver.
Returns:
A geolocation of the maneuver.
public java.util.List <GeoCoordinate> getGeometry ()
Returns the geometry of this maneuver.
Returns:
The geometry of the maneuver.
public int getMapOrientation ()
Gets the map orientation at the start of the maneuver, in degrees.
Note: a returned value of zero represents true-north, with increasing values representing a clockwise
progression of map orientation.
Returns:
The orientation
public String getNaturalGuidancePOI ()
Gets the name of the natural guidance POI.
Returns:
The name of the natural guidance POI or the empty string.
public static float getNaturalGuidanceRadius ()
Gets the search radius for natural guidance.
Returns:
The search radius for natural guidance in meters.
HERE Android SDK Developer's Guide
API Reference
2269
public Space getSpace ()
Returns an Space object related to this maneuver.
Returns:
An space object.
public VenueManeuver getTargetManeuver ()
Returns a target VenueManeuver for a series of connectors of the same type (elevator, escalator etc.)
which are going in the same direction. We accept some links between connectors, like in case of stairs or
escalators. For example, if the user enters an elevator, then the target maneuver will be the exit from it.
Otherwise returns null.
Returns:
An VenueManeuver object.
public Turn getTurn ()
Gets the Maneuver.Turn required to complete the maneuver.
Returns:
The Maneuver.Turn
public int hashCode ()
public static void setNaturalGuidanceRadius (float radius)
Sets the search radius for natural guidance.
Parameters:
radius
The search radius for natural guidance in meters.
ActionType
The enumeration ActionType is a member of com.here.android.mpa.venues3d.VenueManeuver.
Enumeration Summary
public static final enumeration VenueManeuver.ActionType
extends java.lang.Enum, java.lang.Object
This enumeration defines identifiers for enter/exit action types.
HERE Android SDK Developer's Guide
API Reference
2270
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1406: Enum Constants in ActionType
Fields
public static final ActionType NO_ACTION
No action.
public static final ActionType ENTER
Enter action.
public static final ActionType EXIT
Exit action.
Method Summary
Table 1407: Methods in ActionType
Methods
public static ActionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueManeuver.ActionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines identifiers for enter/exit action types.
Enum Constant Details
public static final ActionType NO_ACTION
No action.
public static final ActionType ENTER
Enter action.
public static final ActionType EXIT
Exit action.
HERE Android SDK Developer's Guide
API Reference
2271
Method Details
public static ActionType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueManeuver.ActionType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
ConnectorType
The enumeration ConnectorType is a member of com.here.android.mpa.venues3d.VenueManeuver.
Enumeration Summary
public static final enumeration VenueManeuver.ConnectorType
extends java.lang.Enum, java.lang.Object
This enumeration defines values that describe a connector type from one space to other.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1408: Enum Constants in ConnectorType
Fields
public static final ConnectorType ELEVATOR
An elevator.
public static final ConnectorType ESCALATOR
An escalator.
public static final ConnectorType STAIRS
Stairs.
public static final ConnectorType SKYWALK
A skywalk.
public static final ConnectorType SHUTTLE
A shuttle.
HERE Android SDK Developer's Guide
API Reference
2272
Fields
public static final ConnectorType MOVING_SIDEWALK
A moving sidewalk.
public static final ConnectorType RAMP
A ramp.
public static final ConnectorType OTHER_CATEGORY
An other connector.
public static final ConnectorType NO_CONNECTOR
Not a connector.
Method Summary
Table 1409: Methods in ConnectorType
Methods
public static ConnectorType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueManeuver.ConnectorType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
This enumeration defines values that describe a connector type from one space to other.
Enum Constant Details
public static final ConnectorType ELEVATOR
An elevator.
public static final ConnectorType ESCALATOR
An escalator.
public static final ConnectorType STAIRS
Stairs.
public static final ConnectorType SKYWALK
A skywalk.
HERE Android SDK Developer's Guide
API Reference
2273
public static final ConnectorType SHUTTLE
A shuttle.
public static final ConnectorType MOVING_SIDEWALK
A moving sidewalk.
public static final ConnectorType RAMP
A ramp.
public static final ConnectorType OTHER_CATEGORY
An other connector.
public static final ConnectorType NO_CONNECTOR
Not a connector.
Method Details
public static ConnectorType valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueManeuver.ConnectorType[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VenueMapFragment
The class VenueMapFragment is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueMapFragment
implements com.here.android.mpa.venues3d.VenueLayerAdapter
HERE Android SDK Developer's Guide
API Reference
2274
extends com.here.android.mpa.mapping.MapFragment, java.lang.Object
This class extends MapFragment and adds support for 3D venues.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1410: Nested Classes in VenueMapFragment
Nested Classes
public static abstract interface VenueMapFragment.VenueListener
public static abstract interface VenueMapFragment.VenueZoomListener
Represents a listener to provide notification of the venue service's status upon its initialization.
Constructor Summary
Table 1411: Constructors in VenueMapFragment
Constructors
VenueMapFragment ()
Constructor
Method Summary
Table 1412: Methods in VenueMapFragment
Methods
public void addListener (VenueListener listener)
public void addVenueZoomListener (VenueZoomListener listener)
public boolean cancelVenueSelection ()
public void deselectVenue ()
public CombinedNavigationManager getCombinedNavigationManager ()
public Margin getMargin ()
public VenueNavigationManager getNavigationManager ()
public PositionIndicator getPositionIndicator ()
public RoutingController getRoutingController ()
public Venue getSelectedVenue ()
public VenueController getVenueController (Venue venue)
public VenueService getVenueService ()
HERE Android SDK Developer's Guide
API Reference
2275
Methods
public void init (OnEngineInitListener listener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.5.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (ApplicationContext context, OnEngineInitListener listener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (OnEngineInitListener listener, VenueServiceListener serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (Context context, OnEngineInitListener listener, VenueServiceListener
serviceListener)
Deprecated: As of SDK 3.5.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (ApplicationContext context, OnEngineInitListener listener, VenueServiceListener
serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (Context context, MapVariant variant, OnEngineInitListener listener,
VenueServiceListener serviceListener)
Deprecated: As of SDK 3.5.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public void init (ApplicationContext context, MapVariant variant, OnEngineInitListener listener,
VenueServiceListener serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view rectangle.
public boolean isFloorChangingAnimationEnabled ()
public boolean isHideIconOnSelectedSpaceEnabled ()
public boolean isOpenModeEnabled ()
public boolean isVenueEnteringAnimationEnabled ()
public boolean isVenueInViewportCallbackEnabled ()
public boolean isVenueLayerVisible ()
public boolean isVenueVisible (String id)
public void onDestroy ()
public void onPause ()
public void onResume ()
public void removeListener (VenueListener listener)
public void removeListener (VenueZoomListener listener)
HERE Android SDK Developer's Guide
API Reference
2276
Methods
public VenueInfo selectAsync (String venueId, String spaceId)
public boolean selectVenue (Venue venue)
public VenueInfo selectVenueAsync (String id)
public void setFloorChangingAnimation (boolean enabled)
public void setHideIconOnSelectedSpaceEnabled (boolean value)
public void setMargin (Margin value)
public void setOpenModeEnabled (boolean value)
public void setVenueEnteringAnimation (boolean enabled)
public void setVenueLayerVisible (boolean value)
public void setVenuesInViewportCallback (boolean enabled)
Class Details
This class extends MapFragment and adds support for 3D venues. It allows Venues such as shopping malls
and airports to be shown on the map as interactive 3D models. In addition, it enables the display of spaces
inside venues and of venue access information (such as information about entrances).
An instance of VenueMapFragment must be initialized by calling its init(OnEngineInitListener,
VenueServiceListener) method. To enable interactive use an instance of VenueMapFragment , add
listeners for relevant events to the it as shown in the example below.
VenueMapFragment mapFragment = (VenueMapFragment)
getFragmentManager().findFragmentById(R.id.map_fragment); mapFragment.init(null, new
VenueServiceListener() {
public void onInitializationCompleted(InitStatus result) {
if (result == InitStatus.ONLINE_SUCCESS ||
result == InitStatus.OFFLINE_SUCCESS)
{
mapFragment.addListener(venueListener);
}
} public void onGetVenueCompleted(Venue venue) {
}
}); // Venue can then be opened on a tap event:
public void onVenueTapped(Venue venue, float x, float y) {
mapFragment.openVenue(venue);
}
See MapFragment API documentation for more information about the life cycle of the fragment and how to
use it in a layout file.
A VenueMapFragment is an add-on to the base map functionality with its own content loading and cache.
For this reason, if a fragment is not already present in the cache, it needs to be downloaded before it can be
displayed and therefore a small delay may occur before the venue appears on the the map.
HERE Android SDK Developer's Guide
API Reference
2277
Constructor Details
VenueMapFragment ()
Constructor
Method Details
public void addListener (VenueListener listener)
Parameters:
listener
public void addVenueZoomListener (VenueZoomListener listener)
Parameters:
listener
public boolean cancelVenueSelection ()
public void deselectVenue ()
public CombinedNavigationManager getCombinedNavigationManager ()
public Margin getMargin ()
public VenueNavigationManager getNavigationManager ()
public PositionIndicator getPositionIndicator ()
public RoutingController getRoutingController ()
public Venue getSelectedVenue ()
public VenueController getVenueController (Venue venue)
Parameters:
HERE Android SDK Developer's Guide
API Reference
2278
venue
public VenueService getVenueService ()
public void init (OnEngineInitListener listener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Note that even after engine initialization, most VenueMapFragment features
cannot be used until VenueService is ready. Listen for this ready status by using
VenueServiceListener.onInitializationCompleted(InitStatus).
Due to this requirement, it is recommended to use init(OnEngineInitListener,
VenueServiceListener) for most cases instead.
Parameters:
listener
See also:
init(OnEngineInitListener, VenueServiceListener)
public void init (Context context, OnEngineInitListener listener)
Deprecated: As of SDK 3.5.
Use VenueMapFragment#init(ApplicationContext, OnEngineInitListener) instead.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Note that even after engine initialization, most VenueMapFragment features
cannot be used until VenueService is ready. Listen for this ready status by using
VenueServiceListener.onInitializationCompleted(InitStatus).
Due to this requirement, it is recommended to use init(ApplicationContext,
OnEngineInitListener, VenueServiceListener) for most cases instead.
Parameters:
context
listener
See also:
init(ApplicationContext, OnEngineInitListener, VenueServiceListener)
HERE Android SDK Developer's Guide
API Reference
2279
public void init (ApplicationContext context, OnEngineInitListener listener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Note that even after engine initialization, most VenueMapFragment features
cannot be used until VenueService is ready. Listen for this ready status by using
VenueServiceListener.onInitializationCompleted(InitStatus).
Due to this requirement, it is recommended to use init(ApplicationContext,
OnEngineInitListener, VenueServiceListener) for most cases instead.
Parameters:
context
listener
See also:
init(ApplicationContext, OnEngineInitListener, VenueServiceListener)
public void init (OnEngineInitListener listener, VenueServiceListener
serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle. Users of VenueMapFragment should call this method after the fragment is first attached to its
activity.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
This method can be used for VenueMapFragment objects that are created programatically or declared in a
layout XML file.
Parameters:
listener
A OnEngineInitListener object that will be called when VenueMapFragment initialization is finished. A
null object can be supplied if the caller does not require any notification when initialization completes.
serviceListener
A VenueService.VenueServiceListener object that will be called when VenueService initialization
is finished. Venue related calls should be made only after the user receives the callback
VenueServiceListener.onInitializationCompleted(InitStatus). A null object can be supplied if the caller
does not require any notification when initialization completes.
See also:
OnEngineInitListener
VenueService.VenueServiceListener
init(ApplicationContext, OnEngineInitListener)
HERE Android SDK Developer's Guide
API Reference
2280
init(ApplicationContext, OnEngineInitListener)
init(ApplicationContext, OnEngineInitListener, VenueServiceListener)
public void init (Context context, OnEngineInitListener listener,
VenueServiceListener serviceListener)
Deprecated: As of SDK 3.5.
Use VenueMapFragment#init(ApplicationContext, OnEngineInitListener, VenueServiceListener) instead.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle. Users of VenueMapFragment should call this method after the fragment is first attached to its
activity.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
Parameters:
context
The application context of this fragment.
listener
A OnEngineInitListener object that will be called when VenueMapFragment initialization is finished. A
null object can be supplied if the caller does not require any notification when initialization completes.
serviceListener
A VenueService.VenueServiceListener object that will be called when VenueService initialization
is finished. Venue related calls should be made only after the user receives the callback
VenueServiceListener.onInitializationCompleted(InitStatus). A null object can be supplied if the caller
does not require any notification when initialization completes.
See also:
OnEngineInitListener
VenueService.VenueServiceListener
init(ApplicationContext, OnEngineInitListener)
init(OnEngineInitListener)
init(OnEngineInitListener, VenueServiceListener)
public void init (ApplicationContext context, OnEngineInitListener listener,
VenueServiceListener serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle. Users of VenueMapFragment should call this method after the fragment is first attached to its
activity.
This method will initialize MapEngine with GLOBAL map variant on first SDK usage and with stored map
variant on sub-sequent usages.
HERE Android SDK Developer's Guide
API Reference
2281
Parameters:
context
ApplicationContext to be used during initialization.
listener
A OnEngineInitListener object that will be called when VenueMapFragment initialization is finished. A
null object can be supplied if the caller does not require any notification when initialization completes.
serviceListener
A VenueService.VenueServiceListener object that will be called when VenueService initialization
is finished. Venue related calls should be made only after the user receives the callback
VenueServiceListener.onInitializationCompleted(InitStatus). A null object can be supplied if the caller
does not require any notification when initialization completes.
See also:
OnEngineInitListener
VenueService.VenueServiceListener
init(ApplicationContext, OnEngineInitListener)
init(OnEngineInitListener)
init(OnEngineInitListener, VenueServiceListener)
public void init (Context context, MapVariant variant, OnEngineInitListener
listener, VenueServiceListener serviceListener)
Deprecated: As of SDK 3.5.
Use VenueMapFragment.init(ApplicationContext, MapVariant, OnEngineInitListener, VenueServiceListener)
instead.
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle. Users of VenueMapFragment should call this method after the fragment is first attached to its
activity.
This method can be used for VenueMapFragment objects that are created programatically or declared in a
layout XML file.
This method can configure map variant which will be used by MapEngine. If initialization fails,
OPERATION_NOT_ALLOWED will be reported. Currently the following variants are supported:
- MapVariant#GLOBAL - initialize MapEngine to use international map variant;
- MapVariant#KOREA - initialize MapEngine to use Korean map variant;
- null - initialize MapEngine to use stored map variant or international map variant for first run.
This method is used to configure MapEngine to use certain map variant. If MapEngine was already
configured and passed variant differs, an error will be reported and initialization fails.
Parameters:
context
The application context of this fragment.
HERE Android SDK Developer's Guide
API Reference
2282
variant
Map variant to use.
listener
A OnEngineInitListener object that will be called when VenueMapFragment initialization is finished. A
null object can be supplied if the caller does not require any notification when initialization completes.
serviceListener
A VenueService.VenueServiceListener object that will be called when VenueService initialization
is finished. Venue related calls should be made only after the user receives the callback
VenueServiceListener.onInitializationCompleted(InitStatus). A null object can be supplied if the caller
does not require any notification when initialization completes.
See also:
OnEngineInitListener
VenueService.VenueServiceListener
init(ApplicationContext, OnEngineInitListener)
init(OnEngineInitListener)
init(OnEngineInitListener, VenueServiceListener)
public void init (ApplicationContext context, MapVariant variant,
OnEngineInitListener listener, VenueServiceListener serviceListener)
Initializes the MapEngine and VenueService and displays a map that occupies the entire MapFragment's view
rectangle. Users of VenueMapFragment should call this method after the fragment is first attached to its
activity.
This method can be used for VenueMapFragment objects that are created programatically or declared in a
layout XML file.
This method can configure map variant which will be used by MapEngine. If initialization fails,
OPERATION_NOT_ALLOWED will be reported. Currently the following variants are supported:
- MapVariant#GLOBAL - initialize MapEngine to use international map variant;
- MapVariant#KOREA - initialize MapEngine to use Korean map variant;
- null - initialize MapEngine to use stored map variant or international map variant for first run.
This method is used to configure MapEngine to use certain map variant. If MapEngine was already
configured and passed variant differs, an error will be reported and initialization fails.
Parameters:
context
ApplicationContext to be used during initialization.
variant
Map variant to use.
listener
HERE Android SDK Developer's Guide
API Reference
2283
A OnEngineInitListener object that will be called when VenueMapFragment initialization is finished. A
null object can be supplied if the caller does not require any notification when initialization completes.
serviceListener
A VenueService.VenueServiceListener object that will be called when VenueService initialization
is finished. Venue related calls should be made only after the user receives the callback
VenueServiceListener.onInitializationCompleted(InitStatus). A null object can be supplied if the caller
does not require any notification when initialization completes.
See also:
OnEngineInitListener
VenueService.VenueServiceListener
init(ApplicationContext, OnEngineInitListener)
init(OnEngineInitListener)
init(OnEngineInitListener, VenueServiceListener)
public boolean isFloorChangingAnimationEnabled ()
public boolean isHideIconOnSelectedSpaceEnabled ()
public boolean isOpenModeEnabled ()
public boolean isVenueEnteringAnimationEnabled ()
public boolean isVenueInViewportCallbackEnabled ()
public boolean isVenueLayerVisible ()
public boolean isVenueVisible (String id)
Parameters:
id
public void onDestroy ()
public void onPause ()
HERE Android SDK Developer's Guide
API Reference
2284
public void onResume ()
public void removeListener (VenueListener listener)
Parameters:
listener
public void removeListener (VenueZoomListener listener)
Parameters:
listener
public VenueInfo selectAsync (String venueId, String spaceId)
Parameters:
venueId
spaceId
public boolean selectVenue (Venue venue)
Parameters:
venue
public VenueInfo selectVenueAsync (String id)
Parameters:
id
public void setFloorChangingAnimation (boolean enabled)
Parameters:
enabled
public void setHideIconOnSelectedSpaceEnabled (boolean value)
Parameters:
value
public void setMargin (Margin value)
HERE Android SDK Developer's Guide
API Reference
2285
Parameters:
value
public void setOpenModeEnabled (boolean value)
Parameters:
value
public void setVenueEnteringAnimation (boolean enabled)
Parameters:
enabled
public void setVenueLayerVisible (boolean value)
Parameters:
value
public void setVenuesInViewportCallback (boolean enabled)
Parameters:
enabled
VenueListener
The interface VenueListener is a member of com.here.android.mpa.venues3d.VenueMapFragment.
Interface Summary
public static abstract interface VenueMapFragment.VenueListener
[For complete information, see the section Interface Details]
Method Summary
Table 1413: Methods in VenueListener
Methods
public abstract void onFloorChanged (Venue venue, Level oldLevel, Level newLevel)
This callback method is triggered when a floor is changed.
public abstract void onSpaceDeselected (Venue venue, Space space)
This callback method is triggered when a space is deselected.
HERE Android SDK Developer's Guide
API Reference
2286
Methods
public abstract void onSpaceSelected (Venue venue, Space space)
This callback method is triggered when a space is tapped.
public abstract void onVenueDeselected (Venue venue, DeselectionSource source)
This callback method is triggered when a venue is deselected.
public abstract void onVenueSelected (Venue venue)
This callback method is triggered when a venue is selected.
public abstract void onVenueTapped (Venue venue, float x, float y)
This callback method is triggered when a venue is tapped.
public abstract void onVenueVisibleInViewport (Venue venue, boolean visible)
This callback method is triggered when a venue becomes visible to triggering area, or when a venue disappears from the
triggering area.
Interface Details
Method Details
public abstract void onFloorChanged (Venue venue, Level oldLevel, Level
newLevel)
This callback method is triggered when a floor is changed.
Parameters:
venue
The Venue where the floor is changed.
oldLevel
The previously selected Level.
newLevel
The currently selected Level.
public abstract void onSpaceDeselected (Venue venue, Space space)
This callback method is triggered when a space is deselected.
Parameters:
venue
The Venue with deselected space.
space
The deselected Space.
public abstract void onSpaceSelected (Venue venue, Space space)
HERE Android SDK Developer's Guide
API Reference
2287
This callback method is triggered when a space is tapped.
Parameters:
venue
The Venue with selected space.
space
The selected Space.
public abstract void onVenueDeselected (Venue venue, DeselectionSource source)
This callback method is triggered when a venue is deselected.
Parameters:
venue
The deselected Venue.
source
The source which has called deselection of the venue.
public abstract void onVenueSelected (Venue venue)
This callback method is triggered when a venue is selected.
Parameters:
venue
The selected Venue.
public abstract void onVenueTapped (Venue venue, float x, float y)
This callback method is triggered when a venue is tapped.
Parameters:
venue
The tapped Venue.
x
The x screen position on the tapped point.
y
The y screen position on the tapped point.
public abstract void onVenueVisibleInViewport (Venue venue, boolean
visible)
HERE Android SDK Developer's Guide
API Reference
2288
This callback method is triggered when a venue becomes visible to triggering area, or when a venue
disappears from the triggering area. The triggering area is centered to the viewport. The width of the
triggering area is * 2/3 of the screen width and its height is the same as the width.
Parameters:
venue
The Venue object or null if there are no visible venues nearby.
visible
A flag indicating if the venue is visible or not.
VenueZoomListener
The interface VenueZoomListener is a member of com.here.android.mpa.venues3d.VenueMapFragment.
Interface Summary
public static abstract interface VenueMapFragment.VenueZoomListener
Represents a listener to provide notification of the venue service's status upon its initialization.
[For complete information, see the section Interface Details]
Method Summary
Table 1414: Methods in VenueZoomListener
Methods
public abstract void onVenueZoomUpdated (Venue venue, boolean active)
This callback method is triggered when Venue Zoom is activate or deactivated.
Interface Details
Represents a listener to provide notification of the venue service's status upon its initialization.
Method Details
public abstract void onVenueZoomUpdated (Venue venue, boolean active)
This callback method is triggered when Venue Zoom is activate or deactivated.
Parameters:
venue
The Venue object or null where activation or deactivation happened.
active
A flag indicating if Venue Zoom is active or not.
HERE Android SDK Developer's Guide
API Reference
2289
VenueMapView
The class VenueMapView is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueMapView
implements com.here.android.mpa.venues3d.VenueLayerAdapter
extends com.here.android.mpa.mapping.MapView, java.lang.Object
This class adds support for 3D venues to a map view.
[For complete information, see the section Class Details]
Constructor Summary
Table 1415: Constructors in VenueMapView
Constructors
VenueMapView (Context context)
Constructor that initializes the context.
VenueMapView (Context context, AttributeSet attrs)
Constructor that initializes the context and a set of attributes.
Method Summary
Table 1416: Methods in VenueMapView
Methods
public void addListener (VenueListener listener)
public void addVenueZoomListener (VenueZoomListener listener)
public boolean cancelVenueSelection ()
public void deselectVenue ()
public Activity getActivity ()
public CombinedNavigationManager getCombinedNavigationManager ()
public Margin getMargin ()
public VenueNavigationManager getNavigationManager ()
public PositionIndicator getPositionIndicator ()
public RoutingController getRoutingController ()
public Venue getSelectedVenue ()
HERE Android SDK Developer's Guide
API Reference
2290
Methods
public VenueController getVenueController (Venue venue)
public VenueService getVenueService ()
public void init (Activity activity, VenueServiceListener serviceListener)
Initializes the VenueMapView and VenueService and displays a map that occupies the entire view rectangle.
public boolean isFloorChangingAnimationEnabled ()
public boolean isHideIconOnSelectedSpaceEnabled ()
public boolean isOpenModeEnabled ()
public boolean isVenueEnteringAnimationEnabled ()
public boolean isVenueInViewportCallbackEnabled ()
public boolean isVenueLayerVisible ()
public boolean isVenueVisible (String id)
public void onPause ()
public void onResume ()
public void removeListener (VenueListener listener)
public void removeListener (VenueZoomListener listener)
public VenueInfo selectAsync (String venueId, String spaceId)
public boolean selectVenue (Venue venue)
public VenueInfo selectVenueAsync (String id)
public void setFloorChangingAnimation (boolean enabled)
public void setHideIconOnSelectedSpaceEnabled (boolean value)
public void setMargin (Margin value)
public void setOpenModeEnabled (boolean value)
public void setVenueEnteringAnimation (boolean enabled)
public void setVenueLayerVisible (boolean value)
public void setVenuesInViewportCallback (boolean enabled)
Class Details
This class adds support for 3D venues to a map view. It allows Venues such as shopping malls and airports
to be shown on the map as interactive 3D models. In addition, it enables the display of spaces inside venues
and of venue access information (such as information about entrances).
HERE Android SDK Developer's Guide
API Reference
2291
An instance of VenueMapFragment must be initialized by calling its init(Activity,
VenueService.VenueServiceListener) method. To enable interactive use an instance of VenueMapLayer , add
listeners for relevant events to the it as shown in the example below.
VenueMapView m_mapView;
Map m_map; public void onCreate(Bundle savedInstanceState) {
// ...other initializations...
m_mapView = (VenueMapView) findViewById(R.id.mapcanvas);
MapEngine.getInstance().init(this, m_listener);
// ... other initializations...
} private OnEngineInitListener m_listener = new
OnEngineInitListener() {
// ...other initializations...
m_map = new Map();
m_mapView.setMap(m_map);
m_mapView.init(m_activity, m_venueServiceListener);
// ...other initializations...
} private VenueServiceListener m_venueServiceListener = new
VenueServiceListener() {</body>
Constructor Details
VenueMapView (Context context)
Constructor that initializes the context.
Parameters:
context
Context of the MapView.
VenueMapView (Context context, AttributeSet attrs)
Constructor that initializes the context and a set of attributes.
Parameters:
context
Context of the MapView.
attrs
An AttributeSet representing attributes of the MapView.
Method Details
public void addListener (VenueListener listener)
Parameters:
listener
HERE Android SDK Developer's Guide
API Reference
2292
public void addVenueZoomListener (VenueZoomListener listener)
Parameters:
listener
public boolean cancelVenueSelection ()
public void deselectVenue ()
public Activity getActivity ()
public CombinedNavigationManager getCombinedNavigationManager ()
public Margin getMargin ()
public VenueNavigationManager getNavigationManager ()
public PositionIndicator getPositionIndicator ()
public RoutingController getRoutingController ()
public Venue getSelectedVenue ()
public VenueController getVenueController (Venue venue)
Parameters:
venue
public VenueService getVenueService ()
public void init (Activity activity, VenueServiceListener serviceListener)
Initializes the VenueMapView and VenueService and displays a map that occupies the entire view rectangle.
Note that even after initialization, most VenueMapView features cannot be used until VenueService is
ready. Listen for this ready status by using onInitializationCompleted(VenueService.InitStatus).
HERE Android SDK Developer's Guide
API Reference
2293
Parameters:
activity
The host activity.
serviceListener
Listener for the ready status.
public boolean isFloorChangingAnimationEnabled ()
public boolean isHideIconOnSelectedSpaceEnabled ()
public boolean isOpenModeEnabled ()
public boolean isVenueEnteringAnimationEnabled ()
public boolean isVenueInViewportCallbackEnabled ()
public boolean isVenueLayerVisible ()
public boolean isVenueVisible (String id)
Parameters:
id
public void onPause ()
public void onResume ()
public void removeListener (VenueListener listener)
Parameters:
listener
public void removeListener (VenueZoomListener listener)
Parameters:
HERE Android SDK Developer's Guide
API Reference
2294
listener
public VenueInfo selectAsync (String venueId, String spaceId)
Parameters:
venueId
spaceId
public boolean selectVenue (Venue venue)
Parameters:
venue
public VenueInfo selectVenueAsync (String id)
Parameters:
id
public void setFloorChangingAnimation (boolean enabled)
Parameters:
enabled
public void setHideIconOnSelectedSpaceEnabled (boolean value)
Parameters:
value
public void setMargin (Margin value)
Parameters:
value
public void setOpenModeEnabled (boolean value)
Parameters:
value
public void setVenueEnteringAnimation (boolean enabled)
Parameters:
enabled
HERE Android SDK Developer's Guide
API Reference
2295
public void setVenueLayerVisible (boolean value)
Parameters:
value
public void setVenuesInViewportCallback (boolean enabled)
Parameters:
enabled
VenueNavigationManager
The class VenueNavigationManager is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueNavigationManager
extends java.lang.Object
A navigation manager class that provides guidance advice and information along an indoor route.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1417: Nested Classes in VenueNavigationManager
Nested Classes
public static final enumeration VenueNavigationManager.NavigationState
The possible states of VenueNavigationManager .
public static final enumeration VenueNavigationManager.TrackingMode
The mode that is used when map tracking is enabled.
public static final enumeration VenueNavigationManager.TrackingTilt
The tilt that is used when map tracking is enabled.
public static abstract interface VenueNavigationManager.VenueNavigationManagerListener
An interface for responding to navigation events sent by the VenueNavigationManager .
HERE Android SDK Developer's Guide
API Reference
2296
Field Summary
Table 1418: Fields in VenueNavigationManager
Fields
public static final float INVALID_DISTANCE_VALUE
Represents an invalid distance value.
public static final long INVALID_TIME_INTERVAL_VALUE
Represents an invalid time interval value.
Method Summary
Table 1419: Methods in VenueNavigationManager
Methods
public void addListener (VenueNavigationManagerListener listener)
Adds a listener to the navigation manager.
public boolean areBeepsEnabled ()
public float getAverageSpeed ()
Returns the current average speed in the current navigation session.
public VenueManeuver getCurrentManeuver ()
Returns the current, upcoming VenueManeuver in the current navigation session.
public float getDistanceFromStart ()
Returns the current distance from the start point of navigation.
public float getDistanceToCurrentManeuver ()
Returns the remaining distance to the current VenueManeuver.
public float getDistanceToDestination ()
Returns the current distance to destination.
public float getDistanceToNextManeuver ()
Returns the remaining distance to the next VenueManeuver after the current one.
public float getManeuverZoomDistance ()
Gets the distance from the maneuver at which the maneuver zoom is active.
public float getManeuverZoomLevel ()
Gets the level to which to zoom in when the maneuver zoom is active.
public TrackingMode getMapTrackingMode ()
Returns map tracking mode.
public TrackingTilt getMapTrackingTilt ()
Returns how the map is tilted when map tracking is enabled.
HERE Android SDK Developer's Guide
API Reference
2297
Methods
public NavigationState getNavigationState ()
Gets the current state of the navigation related to the tracked route.
public VenueManeuver getNextManeuver ()
Returns the next VenueManeuver after the current VenueManeuver in the current navigation session.
public long getReroutingTimeout ()
Returns the time interval in seconds, after which the route will be recalculated in case the user moves far away from the
current route.
public long getTimeToArrival ()
Returns the number of seconds that remain to travel to the destination, or INVALID_TIME_INTERVAL_VALUE on error.
public float getTravelledDistance ()
Returns the travelled distance in the current navigation session.
public VenueLayerAdapter getVenueLayer ()
public boolean isManeuverZoomEnabled ()
Returns wether zooming in on maneuvers is enabled during navigation.
public boolean isMapTrackingEnabled ()
Returns true , if @code VenueNavigationManager is allowed to automatically update map position as navigation
progresses, false otherwise.
public boolean isPaused ()
Returns true , if current navigation is paused, false otherwise.
public boolean isVibrationEnabled ()
Returns whether device vibration is enabled during navigation.
public void pause (boolean value)
When set to true , the current navigation will be paused (if any).
public void removeListener (VenueNavigationManagerListener listener)
Removes a listener from the navigation manager.
public void setBeepsEnabled (boolean enabled)
Enables/disables device beep sounds during navigation.
public void setManeuverZoomDistance (float distance)
Sets the distance from the maneuver at which the maneuver zoom is active.
public void setManeuverZoomEnabled (boolean enabled)
Enables/disables zooming in on maneuvers during navigation.
public void setManeuverZoomLevel (float level)
Sets the level to which to zoom in when the maneuver zoom is active.
public void setMapTrackingEnabled (boolean value)
Allows the VenueNavigationManager to automatically update map position as navigation progresses.
HERE Android SDK Developer's Guide
API Reference
2298
Methods
public void setMapTrackingMode (TrackingMode value)
Controls how the map is moved and rotated when map tracking is enabled.
public void setMapTrackingTilt (TrackingTilt value)
Controls how the map is tilted when map tracking is enabled.
public void setReroutingTimeout (long timeoutInSeconds)
Sets the rerouting timeout in seconds.
public void setVibrationEnabled (boolean enabled)
Enables/disables device vibration during navigation.
public boolean start (VenueRoute routeSection, CombinedRoute route)
Starts a turn-by-turn navigation session using the specified venue route section.
public boolean start (LinkingRoute routeSection, CombinedRoute route)
Starts a turn-by-turn navigation session using the specified linking route section.
public void stop ()
Stops a turn-by-turn navigation session started via start(VenueRoute, CombinedRoute).
Class Details
A navigation manager class that provides guidance advice and information along an indoor route.
Field Details
public static final float INVALID_DISTANCE_VALUE
Represents an invalid distance value.
See also:
getDistanceFromStart()
getDistanceToCurrentManeuver()
getDistanceToDestination()
getDistanceToNextManeuver()
public static final long INVALID_TIME_INTERVAL_VALUE
Represents an invalid time interval value.
See also:
getTimeToArrival()
HERE Android SDK Developer's Guide
API Reference
2299
Method Details
public void addListener (VenueNavigationManagerListener listener)
Adds a listener to the navigation manager. The listener must implement the
VenueNavigationManager.VenueNavigationManagerListener interface. The listener receives event callbacks
containing information about the current navigation session.
Parameters:
listener
The VenueNavigationManager.VenueNavigationManagerListener object to be added.
public boolean areBeepsEnabled ()
Returns:
Whether beep sounds are enabled during navigation.
See also:
setBeepsEnabled(boolean)
public float getAverageSpeed ()
Returns the current average speed in the current navigation session.
Returns:
average speed in m/s.
public VenueManeuver getCurrentManeuver ()
Returns the current, upcoming VenueManeuver in the current navigation session.
Returns:
The upcoming VenueManeuver. Can be null, if navigation hasn't been started.
public float getDistanceFromStart ()
Returns the current distance from the start point of navigation.
Returns:
the distance from the start point in meters. Returns INVALID_DISTANCE_VALUE if an error occurred or
navigation hasn't been started.
public float getDistanceToCurrentManeuver ()
Returns the remaining distance to the current VenueManeuver.
HERE Android SDK Developer's Guide
API Reference
2300
Returns:
the distance to the current VenueManeuver in meters. Returns INVALID_DISTANCE_VALUE if an error occured
or if the upcoming maneuver is not available yet.
See also:
getCurrentManeuver()
public float getDistanceToDestination ()
Returns the current distance to destination.
Returns:
the distance to destination in meters. Returns INVALID_DISTANCE_VALUE if an error occurred or navigation
hasn't been started.
public float getDistanceToNextManeuver ()
Returns the remaining distance to the next VenueManeuver after the current one.
Returns:
the distance to the next VenueManeuver in meters. Returns INVALID_DISTANCE_VALUE if an error occurred or
if the next maneuver is not available yet.
See also:
getNextManeuver()
public float getManeuverZoomDistance ()
Gets the distance from the maneuver at which the maneuver zoom is active.
Returns:
The distance to the maneuver in meters.
public float getManeuverZoomLevel ()
Gets the level to which to zoom in when the maneuver zoom is active.
Returns:
The zoom level.
public TrackingMode getMapTrackingMode ()
Returns map tracking mode. The default value is FOLLOW.
Returns:
HERE Android SDK Developer's Guide
API Reference
2301
How the map is moved and rotated when map tracking is enabled.
public TrackingTilt getMapTrackingTilt ()
Returns how the map is tilted when map tracking is enabled. The default value is TILT3D.
Returns:
How the map is tilted when map tracking is enabled.
public NavigationState getNavigationState ()
Gets the current state of the navigation related to the tracked route.
Returns:
The current state of the navigation related to the tracked route.
public VenueManeuver getNextManeuver ()
Returns the next VenueManeuver after the current VenueManeuver in the current navigation session.
Returns:
The next VenueManeuver after the current one. Can be null, if navigation hasn't been started or when the
current VenueManeuver is the last one.
See also:
getCurrentManeuver()
public long getReroutingTimeout ()
Returns the time interval in seconds, after which the route will be recalculated in case the user moves far
away from the current route. When the user significantly deviates from the specified route, a new route will
be calculated starting from the user's current position after this timeout expires.
Returns:
The time interval in seconds, after which the route will be recalculated in case the user moves far away from
the current route.
See also:
setReroutingTimeout(long)
onRerouteBegin()
public long getTimeToArrival ()
Returns the number of seconds that remain to travel to the destination, or INVALID_TIME_INTERVAL_VALUE on
error.
HERE Android SDK Developer's Guide
API Reference
2302
Returns:
The number of seconds that remain to travel to the destination.
public float getTravelledDistance ()
Returns the travelled distance in the current navigation session.
Returns:
travelled distance in meters.
public VenueLayerAdapter getVenueLayer ()
Returns:
The VenueLayerAdapter object for this instance of navigation manager.
public boolean isManeuverZoomEnabled ()
Returns wether zooming in on maneuvers is enabled during navigation.
Returns:
true if zooming in on maneuvers is enabled during navigation, and false otherwise.
public boolean isMapTrackingEnabled ()
Returns true , if @code VenueNavigationManager is allowed to automatically update map position as
navigation progresses, false otherwise. By default returns true .
Returns:
true, if @code VenueNavigationManager is allowed to automatically update map position as navigation
progresses, false otherwise.
public boolean isPaused ()
Returns true , if current navigation is paused, false otherwise.
Returns:
true, if current navigation is paused, false otherwise.
public boolean isVibrationEnabled ()
Returns whether device vibration is enabled during navigation.
Returns:
true if device vibration is enabled during navigation.
HERE Android SDK Developer's Guide
API Reference
2303
See also:
setVibrationEnabled(boolean)
public void pause (boolean value)
When set to true , the current navigation will be paused (if any). When set to false , the current navigation
will resume if previously paused. This has no effect if there is no navigation currently in progress.
Parameters:
value
When set to true, the current navigation will be paused (if any).
public void removeListener (VenueNavigationManagerListener listener)
Removes a listener from the navigation manager. The listener must implement the
VenueNavigationManager.VenueNavigationManagerListener interface. The listener receives event callbacks
containing information about the current navigation session.
Parameters:
listener
The VenueNavigationManager.VenueNavigationManagerListener object to be removed.
public void setBeepsEnabled (boolean enabled)
Enables/disables device beep sounds during navigation. If enabled, these will be triggered on specific
navigation events, like maneuver change, rerouting, reaching destination, etc.
Parameters:
enabled
Flag to indicate the enable state of device beep sounds.
See also:
areBeepsEnabled()
public void setManeuverZoomDistance (float distance)
Sets the distance from the maneuver at which the maneuver zoom is active.
Parameters:
distance
The distance to the maneuver in meters.
public void setManeuverZoomEnabled (boolean enabled)
HERE Android SDK Developer's Guide
API Reference
2304
Enables/disables zooming in on maneuvers during navigation.
Parameters:
enabled
Flag to indicate the enable state of maneuver zooming.
public void setManeuverZoomLevel (float level)
Sets the level to which to zoom in when the maneuver zoom is active.
Parameters:
level
The zoom level.
public void setMapTrackingEnabled (boolean value)
Allows the VenueNavigationManager to automatically update map position as navigation progresses.
Parameters:
value
true to enable map tracking, false otherwise.
public void setMapTrackingMode (TrackingMode value)
Controls how the map is moved and rotated when map tracking is enabled.
Parameters:
value
VenueNavigationManager.TrackingMode value to define how the map is moved when map tracking is
enabled.
public void setMapTrackingTilt (TrackingTilt value)
Controls how the map is tilted when map tracking is enabled. In 2D and 3D modes, the map will automatically
be tilted back appropriately when the tilt value is changed. In Custom mode, the tilt will not be changed. Use
custom mode to allow the map to be manually tilted during navigation or to set the tilt to a fixed custom
value.
Parameters:
value
VenueNavigationManager.TrackingTilt value to define how the map is tilted when map tracking is
enabled.
public void setReroutingTimeout (long timeoutInSeconds)
HERE Android SDK Developer's Guide
API Reference
2305
Sets the rerouting timeout in seconds. This is the time interval in seconds, after which the route will be
recalculated in case the user moves far away from the current route
Parameters:
timeoutInSeconds
Time interval in seconds.
See also:
getReroutingTimeout()
public void setVibrationEnabled (boolean enabled)
Enables/disables device vibration during navigation. If enabled, vibration will be triggered on specific
navigation events, like maneuver change, rerouting, reaching destination, etc.
Parameters:
enabled
Flag to indicate the enable state of device vibration.
Throws:
AccessControlException
in case when there are no android.permission.VIBRATE permission granted.
public boolean start (VenueRoute routeSection, CombinedRoute route)
Starts a turn-by-turn navigation session using the specified venue route section.
Parameters:
routeSection
The venue route section to navigate.
route
The route used to navigate.
Returns:
True if started successfully and false otherwise, indicating that the venue route section is invalid or the
navigation is already running.
public boolean start (LinkingRoute routeSection, CombinedRoute route)
Starts a turn-by-turn navigation session using the specified linking route section.
Parameters:
routeSection
The linking route section to navigate.
route
HERE Android SDK Developer's Guide
API Reference
2306
The route used to navigate.
Returns:
True if started successfully and false otherwise, indicating that the venue route section is invalid or the
navigation is already running.
public void stop ()
Stops a turn-by-turn navigation session started via start(VenueRoute, CombinedRoute).
NavigationState
The enumeration NavigationState is a member of com.here.android.mpa.venues3d.VenueNavigationManager.
Enumeration Summary
public static final enumeration VenueNavigationManager.NavigationState
extends java.lang.Enum, java.lang.Object
The possible states of VenueNavigationManager .
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1420: Enum Constants in NavigationState
Fields
public static final NavigationState IDLE
No navigation is in progress.
public static final NavigationState RUNNING
Navigation is in progress and active.
public static final NavigationState PAUSED
Navigation is in progress but not currently active.
Method Summary
Table 1421: Methods in NavigationState
Methods
public static NavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
HERE Android SDK Developer's Guide
API Reference
2307
Methods
public static VenueNavigationManager.NavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The possible states of VenueNavigationManager .
Enum Constant Details
public static final NavigationState IDLE
No navigation is in progress.
public static final NavigationState RUNNING
Navigation is in progress and active.
public static final NavigationState PAUSED
Navigation is in progress but not currently active.
Method Details
public static NavigationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueNavigationManager.NavigationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrackingMode
The enumeration TrackingMode is a member of com.here.android.mpa.venues3d.VenueNavigationManager.
Enumeration Summary
public static final enumeration VenueNavigationManager.TrackingMode
HERE Android SDK Developer's Guide
API Reference
2308
extends java.lang.Enum, java.lang.Object
The mode that is used when map tracking is enabled.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1422: Enum Constants in TrackingMode
Fields
public static final TrackingMode FOLLOW
Pan and rotate as object moves.
public static final TrackingMode NORTH_UP
Only pan to follow object.
public static final TrackingMode FREE_ROTATION
Only pan to follow object.
Method Summary
Table 1423: Methods in TrackingMode
Methods
public int getValue ()
public static TrackingMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueNavigationManager.TrackingMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The mode that is used when map tracking is enabled.
Enum Constant Details
public static final TrackingMode FOLLOW
Pan and rotate as object moves.
public static final TrackingMode NORTH_UP
Only pan to follow object. Fix orientation to north.
public static final TrackingMode FREE_ROTATION
HERE Android SDK Developer's Guide
API Reference
2309
Only pan to follow object. Free rotation mode.
Method Details
public int getValue ()
public static TrackingMode valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueNavigationManager.TrackingMode[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
TrackingTilt
The enumeration TrackingTilt is a member of com.here.android.mpa.venues3d.VenueNavigationManager.
Enumeration Summary
public static final enumeration VenueNavigationManager.TrackingTilt
extends java.lang.Enum, java.lang.Object
The tilt that is used when map tracking is enabled.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1424: Enum Constants in TrackingTilt
Fields
public static final TrackingTilt TILT2D
The map will be automatically tilted to a 2D perspective.
public static final TrackingTilt TILT3D
The map will be automatically tilted to a 3D perspective.
public static final TrackingTilt CUSTOM
The map tilt will not be changed.
HERE Android SDK Developer's Guide
API Reference
2310
Method Summary
Table 1425: Methods in TrackingTilt
Methods
public int getValue ()
public static TrackingTilt valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueNavigationManager.TrackingTilt[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The tilt that is used when map tracking is enabled.
Enum Constant Details
public static final TrackingTilt TILT2D
The map will be automatically tilted to a 2D perspective.
public static final TrackingTilt TILT3D
The map will be automatically tilted to a 3D perspective.
public static final TrackingTilt CUSTOM
The map tilt will not be changed.
Method Details
public int getValue ()
public static TrackingTilt valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueNavigationManager.TrackingTilt[] values ()
HERE Android SDK Developer's Guide
API Reference
2311
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VenueNavigationManagerListener
The interface VenueNavigationManagerListener is a member of
com.here.android.mpa.venues3d.VenueNavigationManager.
Interface Summary
public static abstract interface VenueNavigationManager.VenueNavigationManagerListener
An interface for responding to navigation events sent by the VenueNavigationManager .
[For complete information, see the section Interface Details]
Method Summary
Table 1426: Methods in VenueNavigationManagerListener
Methods
public abstract void onCurrentManeuverChanged (VenueManeuver maneuver, VenueManeuver
nextManeuver)
Called when the current (upcoming) maneuver is updated.
public abstract void onDestinationReached ()
Called when the destination of turn-by-turn navigation is reached.
public abstract void onPositionLost ()
Called when the navigation manager loses its indoor position.
public abstract void onPositionRestored ()
Called when the navigation manager finds its indoor position.
public abstract void onRerouteBegin ()
Called when rerouting is triggered due to the user leaving the current route section.
public abstract void onRerouteEnd ()
Called when rerouting, due to the user leaving the current route section, has finished.
public abstract void onRouteSectionUpdated (VenueRoute routeSection, CombinedRoute combinedRoute)
Called when a change is made to the route section being navigated.
Interface Details
An interface for responding to navigation events sent by the VenueNavigationManager .
HERE Android SDK Developer's Guide
API Reference
2312
Method Details
public abstract void onCurrentManeuverChanged (VenueManeuver maneuver,
VenueManeuver nextManeuver)
Called when the current (upcoming) maneuver is updated. The "current" maneuver is the upcoming, or next,
maneuver to be taken. The "next" maneuver is actually the maneuver to be taken after the current maneuver.
Parameters:
maneuver
The current (upcoming) maneuver to be made.
nextManeuver
The maneuver to be made AFTER THE CURRENT MANEUVER.
public abstract void onDestinationReached ()
Called when the destination of turn-by-turn navigation is reached.
public abstract void onPositionLost ()
Called when the navigation manager loses its indoor position.
public abstract void onPositionRestored ()
Called when the navigation manager finds its indoor position.
public abstract void onRerouteBegin ()
Called when rerouting is triggered due to the user leaving the current route section. If a new route
section is successfully calculated, it is immediately applied to the current navigation session and
onRouteSectionUpdated(VenueRoute, CombinedRoute) is called. After rerouting, the onRerouteEnd() is called.
public abstract void onRerouteEnd ()
Called when rerouting, due to the user leaving the current route section, has finished. This method just
means an attempt to reroute finished and does not guarantee that a new route was successfully created.
public abstract void onRouteSectionUpdated (VenueRoute routeSection,
CombinedRoute combinedRoute)
Called when a change is made to the route section being navigated. This can occur after successful rerouting
due to the user leaving the current route (see onRerouteBegin()).
Parameters:
HERE Android SDK Developer's Guide
API Reference
2313
routeSection
VenueRoute representing the route section that was set.
combinedRoute
CombinedRoute representing the current route.
VenueRoute
The class VenueRoute is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueRoute
implements com.here.android.mpa.venues3d.IRouteSection
extends java.lang.Object
Represents a section of the route which is inside a venue.
[For complete information, see the section Class Details]
See also:
LinkingRoute
OutdoorRoute
Method Summary
Table 1427: Methods in VenueRoute
Methods
public boolean equals (Object o)
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the venue route.
public GeoBoundingBox getBoundingBox (Level level)
Gets the GeoBoundingBox of the venue route on the given Level .
public int getLength ()
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
public Venue getVenue ()
Gets the Venue where venue route is located.
public java.util.List <VenueManeuver> getVenueManeuvers ()
Returns a list of VenueManeuver obects of this route section.
public int hashCode ()
HERE Android SDK Developer's Guide
API Reference
2314
Class Details
Represents a section of the route which is inside a venue. The route can contain sections that are inside
venue, outside venue, and link sections that typically connects indoor and outdoor locations together.
See also:
LinkingRoute
OutdoorRoute
Method Details
public boolean equals (Object o)
Parameters:
o
public GeoBoundingBox getBoundingBox ()
Gets the GeoBoundingBox of the venue route.
Returns:
A GeoBoundingBox object.
public GeoBoundingBox getBoundingBox (Level level)
Gets the GeoBoundingBox of the venue route on the given Level .
Parameters:
level
The level for which to return the bounding box.
Returns:
A GeoBoundingBox object. Returns null if the route does not touch the given level.
public int getLength ()
public RouteSectionType getRouteSectionType ()
Returns IRouteSection.RouteSectionType of this route section.
public Venue getVenue ()
Gets the Venue where venue route is located.
Returns:
HERE Android SDK Developer's Guide
API Reference
2315
A Venue object.
public java.util.List <VenueManeuver> getVenueManeuvers ()
Returns a list of VenueManeuver obects of this route section.
Returns:
A list of maneuver objects.
public int hashCode ()
VenueRouteOptions
The class VenueRouteOptions is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueRouteOptions
extends java.lang.Object
Defines routing options used in indoor routing.
[For complete information, see the section Class Details]
See also:
RoutingController
Constructor Summary
Table 1428: Constructors in VenueRouteOptions
Constructors
VenueRouteOptions ()
Constructs a VenueRouteOptions object.
Method Summary
Table 1429: Methods in VenueRouteOptions
Methods
public boolean areCorridorsPreferred ()
Returns if corridors are preferred.
public boolean areElevatorsAllowed ()
Checks whether Elevators are allowed.
HERE Android SDK Developer's Guide
API Reference
2316
Methods
public boolean areEscalatorsAllowed ()
Checks whether Escalators are allowed.
public boolean areGroundEntrancesPreferred ()
Returns if ground entrances are preferred.
public boolean areRampsAllowed ()
Checks whether Ramps are allowed.
public boolean areStairsAllowed ()
Checks whether Stairs are allowed.
public int getColor (RouteSectionType route_type)
Returns color of the route line for the given IRouteSection.RouteSectionType.
public int getConnectorColor ()
Returns color of the route line for an accessor connection.
public boolean getFlagsVisible ()
Returns visiblity status of flags indicating the start and end points of a route.
public boolean getIconsVisible ()
Returns visiblity status of icons indicating entrances and access methods (e.g.
public double getIndoorRouteWidth ()
Gets a line width for indoor route section of the route.
public int getOutdoorRouteWidth ()
Gets a line width for outdoor route section of the route.
public RouteOptions getRouteOptions ()
Returns RouteOptions related to this instance.
public boolean getRouteVisible (RouteSectionType route_type)
Returns visiblity status of given IRouteSection.RouteSectionType.
public boolean isAutoParkingEnabled ()
Returns auto parking status.
public void setAutoParkingEnabled (boolean enabled)
Sets auto parking status.
public void setColor (RouteSectionType route_type, int a, int r, int g, int b)
Sets color of the route line for the given IRouteSection.RouteSectionType.
public void setConnectorColor (int a, int r, int g, int b)
Sets color of the route line for an accessor connection.
public void setCorridorsPreferred (boolean enabled)
Sets if corridors are preferred.
HERE Android SDK Developer's Guide
API Reference
2317
Methods
public void setElevatorsAllowed (boolean value)
Sets whether Elevators are allowed.
public void setEscalatorsAllowed (boolean value)
Sets whether Escalators are allowed.
public void setFlagsVisible (boolean visible)
Sets visiblity status of flags indicating the start and end points of a route.
public void setGroundEntrancesPreferred (boolean enabled)
Sets if ground entrances are preferred.
public void setIconsVisible (boolean visible)
Sets visiblity status of possible icons along a route.
public void setIndoorRouteWidth (double width)
Set a line width for indoor route section of the route.
public void setOutdoorRouteWidth (int width)
Set a line width for outdoor route section of the route.
public void setRampsAllowed (boolean value)
Sets whether Ramps are allowed.
public void setRouteOptions (RouteOptions options)
Sets RouteOptions related to this instance.
public void setRouteVisible (RouteSectionType route_type, boolean visible)
Sets visiblity status for given IRouteSection.RouteSectionType.
public void setStairsAllowed (boolean value)
Sets whether Stairs are allowed.
Class Details
Defines routing options used in indoor routing.
See also:
RoutingController
Constructor Details
VenueRouteOptions ()
Constructs a VenueRouteOptions object.
Method Details
public boolean areCorridorsPreferred ()
HERE Android SDK Developer's Guide
API Reference
2318
Returns if corridors are preferred. If true, routing algorithm will try to follow corridors without going through
spaces (shops, rooms etc.).
Returns:
Corridors are preferred.
See also:
setCorridorsPreferred(boolean)
public boolean areElevatorsAllowed ()
Checks whether Elevators are allowed.
Returns:
true if allowed otherwise false.
public boolean areEscalatorsAllowed ()
Checks whether Escalators are allowed.
Returns:
true if allowed otherwise false.
public boolean areGroundEntrancesPreferred ()
Returns if ground entrances are preferred. If true, routing algorithm will try to enter venue through ground
entrances. Otherwise all entrances will be used equally.
Returns:
Ground entrances are preferred.
See also:
setGroundEntrancesPreferred(boolean)
public boolean areRampsAllowed ()
Checks whether Ramps are allowed.
Returns:
true if allowed otherwise false.
public boolean areStairsAllowed ()
Checks whether Stairs are allowed.
Returns:
HERE Android SDK Developer's Guide
API Reference
2319
true if allowed otherwise false.
public int getColor (RouteSectionType route_type)
Returns color of the route line for the given IRouteSection.RouteSectionType.
Parameters:
route_type
Color of given IRouteSection.RouteSectionType will be returned.
Returns:
A color as 32-bit integer. Format is (in hex): 0xAARRGGBB.
See also:
setColor(RouteSectionType, int, int, int, int)
public int getConnectorColor ()
Returns color of the route line for an accessor connection.
Returns:
A color as 32-bit integer. Format is (in hex): 0xAARRGGBB.
See also:
setConnectorColor(int, int, int, int)
public boolean getFlagsVisible ()
Returns visiblity status of flags indicating the start and end points of a route.
Returns:
true is visible, otherwise false.
See also:
setFlagsVisible(boolean)
public boolean getIconsVisible ()
Returns visiblity status of icons indicating entrances and access methods (e.g. stairs, elevators etc.) along the
route. For example if the route leads to a different level via stairs, that is indicated by the stairs icon.
Returns:
true is visible, otherwise false.
See also:
setIconsVisible(boolean)
HERE Android SDK Developer's Guide
API Reference
2320
public double getIndoorRouteWidth ()
Gets a line width for indoor route section of the route.
Returns:
A route line width in meters.
See also:
setIndoorRouteWidth(double)
public int getOutdoorRouteWidth ()
Gets a line width for outdoor route section of the route.
Returns:
A route line width in meters.
See also:
setOutdoorRouteWidth(int)
public RouteOptions getRouteOptions ()
Returns RouteOptions related to this instance.
Returns:
The route options.
See also:
setRouteOptions(RouteOptions)
public boolean getRouteVisible (RouteSectionType route_type)
Returns visiblity status of given IRouteSection.RouteSectionType.
Parameters:
route_type
Visiblity status of given IRouteSection.RouteSectionType will be returned.
Returns:
true is visible, otherwise false
See also:
setRouteVisible(RouteSectionType, boolean)
public boolean isAutoParkingEnabled ()
HERE Android SDK Developer's Guide
API Reference
2321
Returns auto parking status. If auto parking is enabled and there is no manually selected valid parking lots,
routing algorithm will automatically select best parking lots and will make route through them.
Returns:
Auto parking status.
See also:
setAutoParkingEnabled(boolean)
public void setAutoParkingEnabled (boolean enabled)
Sets auto parking status.
Parameters:
enabled
true if auto parking is enabled, false otherwise.
See also:
isAutoParkingEnabled()
public void setColor (RouteSectionType route_type, int a, int r, int g, int
b)
Sets color of the route line for the given IRouteSection.RouteSectionType.
Parameters:
route_type
Color of given IRouteSection.RouteSectionType will be set.
a
An opacity of the color
r
A red component of the color
g
A green component of the color
b
A blue component of the color
See also:
getColor(RouteSectionType)
public void setConnectorColor (int a, int r, int g, int b)
Sets color of the route line for an accessor connection.
Parameters:
HERE Android SDK Developer's Guide
API Reference
2322
a
An opacity of the color
r
A red component of the color
g
A green component of the color
b
A blue component of the color
See also:
getConnectorColor()
public void setCorridorsPreferred (boolean enabled)
Sets if corridors are preferred. If true, routing algorithm will try to follow corridors without going through
spaces (shops, rooms etc.).
Parameters:
enabled
true if corridors are preferred, false otherwise.
See also:
areCorridorsPreferred()
public void setElevatorsAllowed (boolean value)
Sets whether Elevators are allowed.
Use conformsConnectorOptions() to verify if calculated route conforms this option.
Parameters:
value
Use true if allowed, otherwise false.
public void setEscalatorsAllowed (boolean value)
Sets whether Escalators are allowed.
Use conformsConnectorOptions() to verify if calculated route conforms this option.
Parameters:
value
Use true if allowed, otherwise false.
HERE Android SDK Developer's Guide
API Reference
2323
public void setFlagsVisible (boolean visible)
Sets visiblity status of flags indicating the start and end points of a route.
Parameters:
visible
Set true to get flags visible, otherwise false
See also:
getFlagsVisible()
public void setGroundEntrancesPreferred (boolean enabled)
Sets if ground entrances are preferred. If true, routing algorithm will try to enter venue through ground
entrances. Otherwise all entrances will be used equally.
Parameters:
enabled
true if ground entrances are preferred, false otherwise.
See also:
areGroundEntrancesPreferred()
public void setIconsVisible (boolean visible)
Sets visiblity status of possible icons along a route.
Parameters:
visible
true to get icons visible, otherwise false.
See also:
getIconsVisible()
public void setIndoorRouteWidth (double width)
Set a line width for indoor route section of the route.
Parameters:
width
A route line width in meters. Minimum value is 0.01 and maximum value is 3.0. Default value is 1.2.
See also:
getIndoorRouteWidth()
HERE Android SDK Developer's Guide
API Reference
2324
public void setOutdoorRouteWidth (int width)
Set a line width for outdoor route section of the route.
Parameters:
width
A route line width in meters. Minimum value is 1 and maximum value is 100. Default value is 10.
See also:
getOutdoorRouteWidth()
public void setRampsAllowed (boolean value)
Sets whether Ramps are allowed.
Use conformsConnectorOptions() to verify if calculated route conforms this option.
Parameters:
value
Use true if allowed, otherwise false.
public void setRouteOptions (RouteOptions options)
Sets RouteOptions related to this instance.
Parameters:
options
The route options.
See also:
getRouteOptions()
public void setRouteVisible (RouteSectionType route_type, boolean visible)
Sets visiblity status for given IRouteSection.RouteSectionType.
Parameters:
route_type
Set visibility status for given route section type.
visible
Set true to get the route section visible, otherwise false
See also:
getRouteVisible(RouteSectionType)
HERE Android SDK Developer's Guide
API Reference
2325
public void setStairsAllowed (boolean value)
Sets whether Stairs are allowed.
Use conformsConnectorOptions() to verify if calculated route conforms this option.
Parameters:
value
Use true if allowed, otherwise false.
VenueService
The class VenueService is a member of com.here.android.mpa.venues3d .
Class Summary
public final class VenueService
extends java.lang.Object
VenueService offers methods to search for venues and to get Venue objects based on search.
[For complete information, see the section Class Details]
Nested Class Summary
Table 1430: Nested Classes in VenueService
Nested Classes
public static final enumeration VenueService.InitStatus
Represents values that describe the initialization status of the VenueService.
public static abstract interface VenueService.VenueAuthenticationListener
Represents a listener to provide notification of the venue authentication event.
public static abstract interface VenueService.VenueLoadListener
Represents a listener to provide notification of the venue load events.
public static final enumeration VenueService.VenueLoadStatus
Represents values that describe the venue load status of the VenueService.
public static abstract interface VenueService.VenueServiceClearCacheListener
Represents a listener to provide notification of the venue service's status upon its cache clearing.
public static abstract interface VenueService.VenueServiceListener
Represents a listener to provide notification of the venue service's status upon its initialization.
public static abstract interface VenueService.VenueServiceStopListener
Represents a listener to provide notification of the venue service's status upon its stopping.
HERE Android SDK Developer's Guide
API Reference
2326
Method Summary
Table 1431: Methods in VenueService
Methods
public void addListener (VenueServiceListener listener)
Adds VenueService.VenueServiceListener object to VenueService object.
public void addVenueLoadListener (VenueLoadListener listener)
Adds VenueService.VenueLoadListener object to VenueService object.
public void authenticate (VenueAuthenticationListener listener)
Starts VenueService authentication asynchronously, without starting VenueService .
public static VenueService createAdditionalService (Context context)
Creates an additional instance of VenueService class.
public void enableVenueZoom (boolean enable)
Enables or disables Venue Zoom.
public VenueAccount getActiveVenueAccount ()
Returns the active VenueAccount, if any exists, or null otherwise.
public InitStatus getInitStatus ()
Returns status of starting the VenueService .
public static VenueService getInstance (Context context)
Gets an main instance of this class.
public java.util.List <VenueAccount> getVenueAccounts ()
Returns all available VenueAccount objects, if any.
public void getVenueAsync (VenueInfo venue)
Asynchronously gets the Venue object that is specified by the given VenueInfo object.
public VenueInfo getVenueAt (GeoCoordinate point)
Searches for a venue near the given GeoCoordinate.
public VenueInfo getVenueAt (GeoCoordinate point, float radius)
Searches for a venue near the given GeoCoordinate.
public VenueInfo getVenueById (String id)
Searches for a venue by the given venue identifier.
public void getVenuesAsync (java.util.List <VenueInfo> venues)
Asynchronously gets the Venue object that is specified by the given list of VenueInfo objects.
public void getVenuesAsync (java.util.List <VenueInfo> venues, GeoCoordinate center)
Asynchronously gets the Venue object that is specified by the given list of VenueInfo objects.
public java.util.List <VenueInfo> getVenuesAt (GeoCoordinate point)
Searches for venues at a given GeoCoordinate.
HERE Android SDK Developer's Guide
API Reference
2327
Methods
public java.util.List <VenueInfo> getVenuesAt (GeoCoordinate point, float radius)
Searches for venues near the given GeoCoordinate.
public void getVenuesGentlyAsync (java.util.List <VenueInfo> venues, GeoCoordinate center)
public java.util.List <VenueInfo> getVenuesIn (GeoBoundingBox searchBox)
Searches for venues inside the given GeoBoundingBox.
public boolean isCombinedContent ()
Gets a value indicating whether the HERE SDK and the HERE private 3D venue content will be used together.
public boolean isDevEnv ()
Gets a value indicating whether the development or another backend is used.
public boolean isPrivateContent ()
Gets a value indicating whether the HERE SDK or the HERE private 3D venue content is to be used.
public boolean isSDKContent ()
Gets a value indicating whether the HERE SDK or the HERE SUITE content is used.
public boolean isTestEnv ()
Gets a value indicating whether a normal or a test backend is used.
public boolean isVenueZoomEnabled ()
Returns boolean value indicating whether Venue Zoom is enabled or not.
public void removeListener (VenueServiceListener listener)
Removes given VenueService.VenueServiceListener object from the list of listeners, which receive the Venue related events.
public void removeVenueLoadListener (VenueLoadListener listener)
Removes given VenueService.VenueLoadListener object from the list of listeners, which receive the Venue load events.
public boolean setActiveVenueAccount (VenueAccount account)
Sets an active VenueAccount object.
public void setDevEnv (boolean useDevEnv)
Sets a value indicating whether the development or another backend is used.
public void setHereAccountToken (String token)
Sets a HERE account token.
public void setIsCombinedContent (boolean isCombinedContent)
Sets a value indicating whether the HERE SDK and the HERE private 3D venue content will be used together.
public void setPrivateContent (boolean isPrivateContent)
Sets a value indicating whether the HERE SDK or the HERE private 3D venue content is to be used.
public void setTestEnv (boolean useTestEnv)
Sets a value indicating whether a normal or a test backend is used.
public void startAsync ()
Starts VenueService asynchronously.
HERE Android SDK Developer's Guide
API Reference
2328
Methods
public static void stopAndClearCache (VenueServiceClearCacheListener listener)
Clears cached data including all downloaded venues.
public void stopAsync (VenueServiceStopListener stopListener)
Stops VenueService asynchronously.
Class Details
VenueService offers methods to search for venues and to get Venue objects based on search. Use of this
object does not necessitate Map involvement.
This class can not be instantiated directly. Use getInstance(Context) method to get an instance of the class
instead.
Method Details
public void addListener (VenueServiceListener listener)
Adds VenueService.VenueServiceListener object to VenueService object.
Parameters:
listener
The VenueServiceListener object to be added.
public void addVenueLoadListener (VenueLoadListener listener)
Adds VenueService.VenueLoadListener object to VenueService object.
Parameters:
listener
The VenueLoadListener object to be added.
public void authenticate (VenueAuthenticationListener listener)
Starts VenueService authentication asynchronously, without starting VenueService . Can be used to
retrieve information about available @link VenueAccount object for current HERE account.
An authentication status is returned to the object registered as VenueService.VenueAuthenticationListener.
Parameters:
listener
VenueService.VenueAuthenticationListener object which will be called after authentication is done.
See also:
setHereAccountToken(String)
getActiveVenueAccount()
HERE Android SDK Developer's Guide
API Reference
2329
getVenueAccounts()
setActiveVenueAccount(VenueAccount)
public static VenueService createAdditionalService (Context context)
Creates an additional instance of VenueService class.
Parameters:
context
Android application android.content.Contex.
Returns:
Instance of VenueService class.
public void enableVenueZoom (boolean enable)
Enables or disables Venue Zoom. Venue Zoom allows bigger zoom levels for opened venues. By default
Venue Zoom is not used. In order to view a particular venue in Venue Zoom mode, use VenueGestureListener.
Alternatively, use useVenueZoom(boolean).
Parameters:
enable
if true, Venue Zoom is enabled, otherwise not.
See also:
isVenueZoomEnabled()
public VenueAccount getActiveVenueAccount ()
Returns the active VenueAccount, if any exists, or null otherwise. A VenueAccount object only exists if the
user is authenticated with a HERE account token and if the account is connected to at least one private
content sources. If an account has been made active by a call to setActiveVenueAccount(VenueAccount), that
account is returned. Otherwise, the first account in the list of accounts is returned. VenueService will use
this account only if private content is active.
Returns:
VenueAccount object if any exist, and null otherwise.
See also:
setHereAccountToken(String)
authenticate(VenueAuthenticationListener)
getVenueAccounts()
setActiveVenueAccount(VenueAccount)
HERE Android SDK Developer's Guide
API Reference
2330
public InitStatus getInitStatus ()
Returns status of starting the VenueService .
Returns:
the VenueService.InitStatus of starting the VenueService.
public static VenueService getInstance (Context context)
Gets an main instance of this class.
Parameters:
context
Android application android.content.Contex.
Returns:
Instance of VenueService class.
public java.util.List <VenueAccount> getVenueAccounts ()
Returns all available VenueAccount objects, if any. The VenueAccount object exists only if the user is
authenticated with a HERE account token and if this account is connected to at least one private content
sources.
Returns:
The array of VenueAccount, if any available, empty list otherwise.
See also:
setHereAccountToken(String)
authenticate(VenueAuthenticationListener)
getActiveVenueAccount()
setActiveVenueAccount(VenueAccount)
public void getVenueAsync (VenueInfo venue)
Asynchronously gets the Venue object that is specified by the given VenueInfo object.
Use addListener(VenueServiceListener) to add object implementing listener for loading completion.
Parameters:
venue
The VenueInfo specifying venue to be get.
Throws:
AccessControlException
HERE Android SDK Developer's Guide
API Reference
2331
Access to this operation is denied. Contact your HERE representative for more information.
public VenueInfo getVenueAt (GeoCoordinate point)
Searches for a venue near the given GeoCoordinate.
Parameters:
point
Defines a point near which venue is searching.
Returns:
The closest VenueInfo to the specified point or null if there is no any
public VenueInfo getVenueAt (GeoCoordinate point, float radius)
Searches for a venue near the given GeoCoordinate.
Parameters:
point
Defines a point near which a venue is searching.
radius
Defines a radius in meters where to search a venue.
Returns:
The closest VenueInfo to the specified point or null if there is no any
public VenueInfo getVenueById (String id)
Searches for a venue by the given venue identifier.
Parameters:
id
The venue identifier to be searched.
Returns:
VenueInfo representing the found venue. Null if no venue found with the given identifier.
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
See also:
getId()
HERE Android SDK Developer's Guide
API Reference
2332
public void getVenuesAsync (java.util.List <VenueInfo> venues)
Asynchronously gets the Venue object that is specified by the given list of VenueInfo objects.
Use addListener(VenueServiceListener) to add object implementing listener for loading completion.
Parameters:
venues
The list of VenueInfo specifying venues to be get.
Throws:
IllegalArgumentException
if the list of venues is null or empty.
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public void getVenuesAsync (java.util.List <VenueInfo> venues, GeoCoordinate
center)
Asynchronously gets the Venue object that is specified by the given list of VenueInfo objects.
Use addListener(VenueServiceListener) to add object implementing listener for loading completion.
Parameters:
venues
The list of VenueInfo specifying venues to be get.
center
The center GeoCoordinate. The closest venue to the center will be loaded first.
Throws:
IllegalArgumentException
if the list of venues is null or empty.
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public java.util.List <VenueInfo> getVenuesAt (GeoCoordinate point)
Searches for venues at a given GeoCoordinate.
Parameters:
point
Defines a point at which venues are searching.
Returns:
The array of VenueInfo found at the specified point
HERE Android SDK Developer's Guide
API Reference
2333
public java.util.List <VenueInfo> getVenuesAt (GeoCoordinate point, float
radius)
Searches for venues near the given GeoCoordinate.
Parameters:
point
Defines a point near which venues are searching.
radius
Defines a radius in meters where to search venues.
Returns:
The array of VenueInfo found near the specified point
public void getVenuesGentlyAsync (java.util.List <VenueInfo> venues,
GeoCoordinate center)
Parameters:
venues
center
public java.util.List <VenueInfo> getVenuesIn (GeoBoundingBox searchBox)
Searches for venues inside the given GeoBoundingBox.
Parameters:
searchBox
Defines an area in which venues are searching.
Returns:
The array of VenueInfo found inside the specified area
Throws:
AccessControlException
Access to this operation is denied. Contact your HERE representative for more information.
public boolean isCombinedContent ()
Gets a value indicating whether the HERE SDK and the HERE private 3D venue content will be used together.
By default combined content is not used.
If VenueService is using private content, then data from the private content will be used as the primary
source, and HERE SDK data as an alternative one. Otherwise HERE SDK content will be the primary source
HERE Android SDK Developer's Guide
API Reference
2334
of data and the private content will be an alternative one. This method needs to be called before starting
VenueService with startAsync() or, if available, VenueMapLayer with VenueMapLayer#startAsync().
Returns:
true if the HERE SDK and the HERE private 3D venue content will be used together, flase otherwise.
public boolean isDevEnv ()
Gets a value indicating whether the development or another backend is used. The backend specified by
setTestEnv is used by default.
Returns:
true if development backend is used, false otherwise.
public boolean isPrivateContent ()
Gets a value indicating whether the HERE SDK or the HERE private 3D venue content is to be used. The HERE
SDK content is used by default.
Returns:
true if HERE private 3D venue content is used, false otherwise.
public boolean isSDKContent ()
Gets a value indicating whether the HERE SDK or the HERE SUITE content is used. The HERE SDK content is
used by default.
Returns:
true if the HERE SDK content is set, otherwise the HERE SUITE content is used.
public boolean isTestEnv ()
Gets a value indicating whether a normal or a test backend is used. The normal backend is used by default.
The value returned by this method is irrelevant when isDevEnv() returns true, because then the development
environment is used.
Returns:
true if a test backend is used, false otherwise.
public boolean isVenueZoomEnabled ()
Returns boolean value indicating whether Venue Zoom is enabled or not.
Returns:
true if Venue Zoom is enabled, otherwise false.
HERE Android SDK Developer's Guide
API Reference
2335
See also:
enableVenueZoom(boolean)
public void removeListener (VenueServiceListener listener)
Removes given VenueService.VenueServiceListener object from the list of listeners, which receive the Venue
related events.
Parameters:
listener
The VenueServiceListener object to be removed.
public void removeVenueLoadListener (VenueLoadListener listener)
Removes given VenueService.VenueLoadListener object from the list of listeners, which receive the Venue
load events.
Parameters:
listener
The VenueLoadListener object to be removed.
public boolean setActiveVenueAccount (VenueAccount account)
Sets an active VenueAccount object. In case of success, the user can restart the current VenueService
object with the startAsync() method to switch to another private content source, related to the new active
VenueAccount object. VenueService will use this account only if private content is activated.
Parameters:
account
VenueAccount object which needs to be active.
Returns:
true if VenueAccount was set successfully, false otherwise.
See also:
setHereAccountToken(String)
authenticate(VenueAuthenticationListener)
getActiveVenueAccount()
getVenueAccounts()
HERE Android SDK Developer's Guide
API Reference
2336
public void setDevEnv (boolean useDevEnv)
Sets a value indicating whether the development or another backend is used. By default, the backend
specified by setTestEnv is used.
This method needs to be called before starting VenueService with startAsync() or, if available,
VenueMapLayer with VenueMapLayer#startAsync(). If VenueService is already running, stop it first using
stopAsync(VenueService.VenueServiceStopListener), and then after calling this method, start it again using
startAsync().
Parameters:
useDevEnv
if true, development environment is set, otherwise the environment specified by setTestEnv is used.
public void setHereAccountToken (String token)
Sets a HERE account token. In case of valid token and if private content is used, VenueService will be using
private bucket of a HERE account instead of private bucket of the app.
Parameters:
token
HERE account token. Can be null. In this case the token is removed.
public void setIsCombinedContent (boolean isCombinedContent)
Sets a value indicating whether the HERE SDK and the HERE private 3D venue content will be used together.
By default combined content is not used.
If VenueService is using private content, then data from the private content will be used as the primary
source, and HERE SDK data as an alternative one. Otherwise HERE SDK content will be the primary source
of data and the private content will be an alternative one. This method needs to be called before starting
VenueService with startAsync() or, if available, VenueMapLayer with VenueMapLayer#startAsync(). If
VenueService is already running, stop it first using stopAsync(VenueService.VenueServiceStopListener), and
then after calling this method, start it again using startAsync().
Parameters:
isCombinedContent
if true, the combined content is set, otherwise one source of data will be used.
public void setPrivateContent (boolean isPrivateContent)
Sets a value indicating whether the HERE SDK or the HERE private 3D venue content is to be used. The HERE
SDK content is used by default.
This method needs to be called before starting VenueService with startAsync() or, if available,
VenueMapLayer with VenueMapLayer#startAsync(). If VenueService is already running, stop it first using
HERE Android SDK Developer's Guide
API Reference
2337
stopAsync(VenueService.VenueServiceStopListener), and then after calling this method, start it again using
startAsync().
Parameters:
isPrivateContent
if true, the PRIVATE content is set, otherwise the HERE SDK content is used.
public void setTestEnv (boolean useTestEnv)
Sets a value indicating whether a normal or a test backend is used. The normal backend is used by default. If
setDevEnv has been set to true, this setting is meaningless, as the development environment will be used.
This method needs to be called before starting VenueService with startAsync() or, if available,
VenueMapLayer with VenueMapLayer#startAsync(). If VenueService is already running, stop it first using
stopAsync(VenueService.VenueServiceStopListener), and then after calling this method, start it again using
startAsync().
Parameters:
useTestEnv
if true, test environment is set, otherwise normal environment is used.
public void startAsync ()
Starts VenueService asynchronously. The method will do nothing if VenueService is already initialized
with status ONLINE_SUCCESS.
An initialization status is returned to objects registered as VenueService.VenueServiceListener.
public static void stopAndClearCache (VenueServiceClearCacheListener listener)
Clears cached data including all downloaded venues. All running instances of VenueService will be
stopped asynchronously and locked ( getInitStatus() will return LOCKED during the operation). After cache is
cleared, VenueService needs to be started again using startAsync().
Parameters:
listener
VenueServiceClearCacheListener#onVenueServiceCacheCleared() is called when cache is
cleared.
public void stopAsync (VenueServiceStopListener stopListener)
Stops VenueService asynchronously. The callback interface given as a parameter will be called when
the service has been stopped and Venue loading is not happening any more. Use startAsync() to start
VenueService again.
HERE Android SDK Developer's Guide
API Reference
2338
Parameters:
stopListener
VenueServiceStopListener#onVenueServiceStopped() is called when Venue loading has been
stopped.
InitStatus
The enumeration InitStatus is a member of com.here.android.mpa.venues3d.VenueService.
Enumeration Summary
public static final enumeration VenueService.InitStatus
extends java.lang.Enum, java.lang.Object
Represents values that describe the initialization status of the VenueService.
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1432: Enum Constants in InitStatus
Fields
public static final InitStatus ONLINE_SUCCESS
The VenueService successfully authenticate on the server and initialized data.
public static final InitStatus OFFLINE_SUCCESS
The VenueService failed to authenticate on the server, but successfully initialized previously cached data.
public static final InitStatus AUTH_FAILED
The VenueService failed to authenticate on the server and there is no previously cached data.
public static final InitStatus INIT_STYLES_FAILED
The VenueService failed to initialize styles.
public static final InitStatus INIT_ICONS_FAILED
The VenueService failed to initialize icons.
public static final InitStatus INIT_INDEX_FAILED
The VenueService failed to initialize index file.
public static final InitStatus ONLINE_FAILED
The VenueService failed to authenticate on the server.
public static final InitStatus NOT_STARTED
The initialization wasn't started.
HERE Android SDK Developer's Guide
API Reference
2339
Fields
public static final InitStatus IN_PROGRESS
The initialization in progress.
public static final InitStatus LOCKED
The VenueService is locked with the method stopAndClearCache(VenueService.VenueServiceClearCacheListener).
Method Summary
Table 1433: Methods in InitStatus
Methods
public static InitStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueService.InitStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values that describe the initialization status of the VenueService.
Enum Constant Details
public static final InitStatus ONLINE_SUCCESS
The VenueService successfully authenticate on the server and initialized data.
public static final InitStatus OFFLINE_SUCCESS
The VenueService failed to authenticate on the server, but successfully initialized previously cached data.
public static final InitStatus AUTH_FAILED
The VenueService failed to authenticate on the server and there is no previously cached data.
public static final InitStatus INIT_STYLES_FAILED
The VenueService failed to initialize styles.
public static final InitStatus INIT_ICONS_FAILED
The VenueService failed to initialize icons.
public static final InitStatus INIT_INDEX_FAILED
HERE Android SDK Developer's Guide
API Reference
2340
The VenueService failed to initialize index file.
public static final InitStatus ONLINE_FAILED
The VenueService failed to authenticate on the server. If OFFLINE_SUCCESS has been previously received,
the previously cached data is in use. Otherwise VenueService failed to initialise.
public static final InitStatus NOT_STARTED
The initialization wasn't started.
public static final InitStatus IN_PROGRESS
The initialization in progress.
public static final InitStatus LOCKED
The VenueService is locked with the method
stopAndClearCache(VenueService.VenueServiceClearCacheListener). VenueService can't be started until
status will be changed to NOT_STARTED.
Method Details
public static InitStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueService.InitStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VenueAuthenticationListener
The interface VenueAuthenticationListener is a member of com.here.android.mpa.venues3d.VenueService.
Interface Summary
public static abstract interface VenueService.VenueAuthenticationListener
HERE Android SDK Developer's Guide
API Reference
2341
Represents a listener to provide notification of the venue authentication event.
[For complete information, see the section Interface Details]
Method Summary
Table 1434: Methods in VenueAuthenticationListener
Methods
public abstract void onAuthenticationCompleted (boolean result, String errorMessage)
On VenueService authentication callback.
Interface Details
Represents a listener to provide notification of the venue authentication event.
Method Details
public abstract void onAuthenticationCompleted (boolean result, String
errorMessage)
On VenueService authentication callback.
Parameters:
result
The boolean value which represents the authentication result. Returns true, if authentication finished
successfully, false otherwise.
errorMessage
The String message which returns an error information from the http response in case of failure.
VenueLoadListener
The interface VenueLoadListener is a member of com.here.android.mpa.venues3d.VenueService.
Interface Summary
public static abstract interface VenueService.VenueLoadListener
Represents a listener to provide notification of the venue load events.
[For complete information, see the section Interface Details]
HERE Android SDK Developer's Guide
API Reference
2342
Method Summary
Table 1435: Methods in VenueLoadListener
Methods
public abstract void onVenueLoadCompleted (Venue venue, VenueInfo info, VenueLoadStatus status)
On Venue loading completed callback.
Interface Details
Represents a listener to provide notification of the venue load events.
Method Details
public abstract void onVenueLoadCompleted (Venue venue, VenueInfo info,
VenueLoadStatus status)
On Venue loading completed callback.
If the venue exists in the cache, and there is an updated version available online, this callback function is
called two times for one venue. You can check whether the venue given as a parameter is an updated version
of a venue already received by comparing them using equals(Object) method, or comparing uniques id's of
the venues.
Parameters:
venue
The loaded Venue. Is null if the venue loading fails.
info
The VenueInfo object related to requested Venue.
status
The VenueService.VenueLoadStatus of the Venue.
VenueLoadStatus
The enumeration VenueLoadStatus is a member of com.here.android.mpa.venues3d.VenueService.
Enumeration Summary
public static final enumeration VenueService.VenueLoadStatus
extends java.lang.Enum, java.lang.Object
Represents values that describe the venue load status of the VenueService.
[For complete information, see the section Enumeration Details]
HERE Android SDK Developer's Guide
API Reference
2343
Enum Constant Summary
Table 1436: Enum Constants in VenueLoadStatus
Fields
public static final VenueLoadStatus ONLINE_SUCCESS
The VenueService successfully downloaded the venue.
public static final VenueLoadStatus OFFLINE_SUCCESS
The VenueService successfully returned the cached venue.
public static final VenueLoadStatus FAILED
The VenueService failed to deliver the venue.
Method Summary
Table 1437: Methods in VenueLoadStatus
Methods
public static VenueLoadStatus valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueService.VenueLoadStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
Represents values that describe the venue load status of the VenueService.
Enum Constant Details
public static final VenueLoadStatus ONLINE_SUCCESS
The VenueService successfully downloaded the venue.
public static final VenueLoadStatus OFFLINE_SUCCESS
The VenueService successfully returned the cached venue.
public static final VenueLoadStatus FAILED
The VenueService failed to deliver the venue. The reasons why VenueService failed is unknown.
Method Details
public static VenueLoadStatus valueOf (String name)
HERE Android SDK Developer's Guide
API Reference
2344
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueService.VenueLoadStatus[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
VenueServiceClearCacheListener
The interface VenueServiceClearCacheListener is a member of com.here.android.mpa.venues3d.VenueService.
Interface Summary
public static abstract interface VenueService.VenueServiceClearCacheListener
Represents a listener to provide notification of the venue service's status upon its cache clearing.
[For complete information, see the section Interface Details]
Method Summary
Table 1438: Methods in VenueServiceClearCacheListener
Methods
public abstract void onVenueServiceCacheCleared ()
This callback is called after cache was cleared using stopAndClearCache(VenueService.VenueServiceClearCacheListener).
Interface Details
Represents a listener to provide notification of the venue service's status upon its cache clearing.
Method Details
public abstract void onVenueServiceCacheCleared ()
This callback is called after cache was cleared using
stopAndClearCache(VenueService.VenueServiceClearCacheListener).
VenueServiceListener
The interface VenueServiceListener is a member of com.here.android.mpa.venues3d.VenueService.
HERE Android SDK Developer's Guide
API Reference
2345
Interface Summary
public static abstract interface VenueService.VenueServiceListener
Represents a listener to provide notification of the venue service's status upon its initialization.
[For complete information, see the section Interface Details]
Method Summary
Table 1439: Methods in VenueServiceListener
Methods
public abstract void onGetVenueCompleted (Venue venue)
Deprecated: As of SDK 3.3.
On Venue loading completed callback.
public abstract void onInitializationCompleted (InitStatus result)
On VenueService initialization callback.
Interface Details
Represents a listener to provide notification of the venue service's status upon its initialization.
Method Details
public abstract void onGetVenueCompleted (Venue venue)
Deprecated: As of SDK 3.3.
Use VenueService.VenueLoadListener instead.
On Venue loading completed callback.
If the venue exists in the cache, and there is an updated version available online, this callback function is
called two times for one venue. You can check whether the venue given as a parameter is an updated version
of a venue already received by comparing them using equals(Object) method, or comparing uniques id's of
the venues.
Parameters:
venue
The loaded Venue.
public abstract void onInitializationCompleted (InitStatus result)
On VenueService initialization callback.
Parameters:
result
The VenueService.InitStatus enum which represent current status of the service.
HERE Android SDK Developer's Guide
API Reference
2346
VenueServiceStopListener
The interface VenueServiceStopListener is a member of com.here.android.mpa.venues3d.VenueService.
Interface Summary
public static abstract interface VenueService.VenueServiceStopListener
Represents a listener to provide notification of the venue service's status upon its stopping.
[For complete information, see the section Interface Details]
Method Summary
Table 1440: Methods in VenueServiceStopListener
Methods
public abstract void onVenueServiceStopped ()
This callback is called after Venue loading has been stopped using stopAsync(VenueService.VenueServiceStopListener) and
no more venues are being loaded any more.
Interface Details
Represents a listener to provide notification of the venue service's status upon its stopping.
Method Details
public abstract void onVenueServiceStopped ()
This callback is called after Venue loading has been stopped using
stopAsync(VenueService.VenueServiceStopListener) and no more venues are being loaded any more.
VenueSimulatedLocationSource
The class VenueSimulatedLocationSource is a member of com.here.android.mpa.venues3d .
Class Summary
public class VenueSimulatedLocationSource
extends com.here.android.mpa.common.LocationDataSource, java.lang.Object
Represents a position data source which is able to simulate indoor positioning based on a provided
VenueRoute object.
[For complete information, see the section Class Details]
HERE Android SDK Developer's Guide
API Reference
2347
Nested Class Summary
Table 1441: Nested Classes in VenueSimulatedLocationSource
Nested Classes
public static final enumeration VenueSimulatedLocationSource.SimulationState
The possible states of VenueSimulatedLocationSource .
Constructor Summary
Table 1442: Constructors in VenueSimulatedLocationSource
Constructors
VenueSimulatedLocationSource (VenueRoute routeSection, double speed, boolean distortionEnabled)
Constructs a simulated location source object.
VenueSimulatedLocationSource (LinkingRoute routeSection, double speed, boolean distortionEnabled)
Constructs a simulated location source object.
Method Summary
Table 1443: Methods in VenueSimulatedLocationSource
Methods
public int getGpsStatus ()
public int getIndoorStatus ()
public Location getLastKnownLocation ()
public int getNetworkStatus ()
public SimulationState getSimulationState ()
Gets the current state of the simulation related to the tracked route.
public double getUpdatesInterval ()
public boolean isPaused ()
Returns true , if current simulation is paused, false otherwise.
public void pause (boolean value)
When set to true , the current simulation will be paused (if any).
public void setUpdatesInterval (double seconds)
Changes the interval between two consecutive simulated indoor position changes.
public boolean start (LocationMethod method)
public void stop ()
HERE Android SDK Developer's Guide
API Reference
2348
Class Details
Represents a position data source which is able to simulate indoor positioning based on a provided
VenueRoute object.
Constructor Details
VenueSimulatedLocationSource (VenueRoute routeSection, double speed, boolean
distortionEnabled)
Constructs a simulated location source object.
Parameters:
routeSection
The venue route section for which to simulate the location.
speed
The speed at which the simulated location changes in meters per second.
distortionEnabled
If enabled, each generated position will be distorted with some random factor
VenueSimulatedLocationSource (LinkingRoute routeSection, double speed,
boolean distortionEnabled)
Constructs a simulated location source object.
Parameters:
routeSection
The linking route section for which to simulate the location.
speed
The speed at which the simulated location changes in meters per second.
distortionEnabled
If enabled, each generated position will be distorted with some random factor
Method Details
public int getGpsStatus ()
public int getIndoorStatus ()
public Location getLastKnownLocation ()
HERE Android SDK Developer's Guide
API Reference
2349
public int getNetworkStatus ()
public SimulationState getSimulationState ()
Gets the current state of the simulation related to the tracked route.
public double getUpdatesInterval ()
Returns:
Interval in seconds between two consecutive updates of simulated indoor positions.
See also:
setUpdatesInterval(double)
public boolean isPaused ()
Returns true , if current simulation is paused, false otherwise.
Returns:
true, if current simulation is paused, false otherwise.
public void pause (boolean value)
When set to true , the current simulation will be paused (if any). When set to false , the current simulation
will resume if previously paused. This has no effect if there is no simulation currently in progress.
Parameters:
value
When set to true, the current simulation will be paused (if any).
public void setUpdatesInterval (double seconds)
Changes the interval between two consecutive simulated indoor position changes. This affects the
smoothness of simulation.
Parameters:
seconds
Time in seconds
public boolean start (LocationMethod method)
Parameters:
method
HERE Android SDK Developer's Guide
API Reference
2350
public void stop ()
SimulationState
The enumeration SimulationState is a member of
com.here.android.mpa.venues3d.VenueSimulatedLocationSource.
Enumeration Summary
public static final enumeration VenueSimulatedLocationSource.SimulationState
extends java.lang.Enum, java.lang.Object
The possible states of VenueSimulatedLocationSource .
[For complete information, see the section Enumeration Details]
Enum Constant Summary
Table 1444: Enum Constants in SimulationState
Fields
public static final SimulationState IDLE
No simulation is in progress.
public static final SimulationState RUNNING
Simulation is in progress and active.
public static final SimulationState PAUSED
Simulation is in progress but not currently active.
Method Summary
Table 1445: Methods in SimulationState
Methods
public static SimulationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
public static VenueSimulatedLocationSource.SimulationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.
Enumeration Details
The possible states of VenueSimulatedLocationSource .
HERE Android SDK Developer's Guide
API Reference
2351
Enum Constant Details
public static final SimulationState IDLE
No simulation is in progress.
public static final SimulationState RUNNING
Simulation is in progress and active.
public static final SimulationState PAUSED
Simulation is in progress but not currently active.
Method Details
public static SimulationState valueOf (String name)
This method retrieves the enumeration value that matches the name specified by the caller.
Parameters:
name
A string containing the name of the enumeration member whose value is to be retrieved.
public static VenueSimulatedLocationSource.SimulationState[] values ()
This method retrieves an array of constants of the given enum type in the order in which they are declared.

Navigation menu