Maps API for JavaScript Developer's Guide

H.service.MapTileService

Class Summary

Extends: H.util.EventTarget

Implements: H.service.IConfigurable

This class encapsulates a map tile end point of the HERE Map Tile API.

[ For full details, see the Class Details ]

Method Summary

Table 1. Methods
Methods

getType () : {string}

This method returns the map tile type provided by this service.

getVersion () : {string}

This method returns the map tile service's newest version hash.

getInfo () : {(H.service.MapTileService.Info | undefined)}

This method returns the map tile service's meta information. The method will return an object once the map tile service's data has been fetched.

createTileProvider (tileType, scheme, tileSize, format, opt_additionalParameters, opt_options) : {H.map.provider.ImageTileProvider}

This method creates a tile provider which uses the specified map tiles. This provider can be used as a data source for an ImageTileLayer.

createTileLayer (tileType, scheme, tileSize, format, opt_additionalParameters, opt_opacity, opt_dark, opt_options) : {H.map.layer.TileLayer}

This method creates a tile layer. This layer can be used as a layer on a map's data model.

configure (appId, appCode, useHTTPS, useCIT, opt_baseUrl) : {H.service.IConfigurable}

This methods receive configuration parameters from the platform, that can be used by the object implementing the interface.

Events Summary

Table 2. Events
Events

infoupdate : {H.util.Event}

This event is fired when the service's info resource was successfully retrieved and processed.

versionupdate : {H.util.Event}

This event is fired when the service's version hash was successfully updated.

copyrightupdate : {H.util.Event}

This event is fired when the service's copyrights were successfully retrieved.

Class Description

This class encapsulates a map tile end point of the HERE Map Tile API.

An instance of this class can be retrieved by calling the factory method on a platform instance. H.service.Platform#getMapTileService.

Example

// assuming that platform and map was already instantiated
var maptiler = platform.getMapTileService({type: 'aerial'}),
  tileLayer = maptiler.createTileLayer('maptile', 'hybrid.day', 256, 'jpg');
map.setBaseLayer(tileLayer);

Constructor Details

H.service.MapTileService(opt_options)

Parameters:
 
opt_options:
{H.service.MapTileService.Options=} [optional]
 

Method Details

getType () : {string}

This method returns the map tile type provided by this service.

Returns:
 
{string}
the map tile type

getVersion () : {string}

This method returns the map tile service's newest version hash.

Returns:
 
{string}
meta information for this map tile service

getInfo () : {(H.service.MapTileService.Info | undefined)}

This method returns the map tile service's meta information. The method will return an object once the map tile service's data has been fetched.

Returns:
 
{(H.service.MapTileService.Info | undefined)}
meta information for this map tile service

createTileProvider (tileType, scheme, tileSize, format, opt_additionalParameters, opt_options) : {H.map.provider.ImageTileProvider}

This method creates a tile provider which uses the specified map tiles. This provider can be used as a data source for an ImageTileLayer.

Parameters:
 
tileType:
{string}
 
the tile type
scheme:
{string}
 
the tile scheme
tileSize:
{number}
 
the tile size
format:
{string}
 
the tile image format
opt_additionalParameters:
{H.service.ServiceParameters=} [optional]
 
a hash of additional parameters to be sent to the HERE Map Tile API with each tile request.
opt_options:
{H.service.TileProviderOptions=} [optional]
 
additional set of options for the provider
Returns:
 
{H.map.provider.ImageTileProvider}
the image tile provider

createTileLayer (tileType, scheme, tileSize, format, opt_additionalParameters, opt_opacity, opt_dark, opt_options) : {H.map.layer.TileLayer}

This method creates a tile layer. This layer can be used as a layer on a map's data model.

Parameters:
 
tileType:
{string}
 
the tile type
scheme:
{string}
 
the tile scheme
tileSize:
{number}
 
the tile size
format:
{string}
 
the tile image format
opt_additionalParameters:
{H.service.ServiceParameters=} [optional]
 
a hash of additional parameters to be sent to the HERE Map Tile API with each tile request.
opt_opacity:
{number=} [optional]
 
The opacity of this layer
opt_dark:
{boolean=} [optional]
 
Indicates whether the content of this layer is mainly dark, default is false See also H.Map.Options#autoColor
opt_options:
{H.service.TileProviderOptions=} [optional]
 
additional set of options for the provider
Returns:
 
{H.map.layer.TileLayer}
the tile layer

configure (appId, appCode, useHTTPS, useCIT, opt_baseUrl) : {H.service.IConfigurable}

This methods receive configuration parameters from the platform, that can be used by the object implementing the interface.

Parameters:
 
appId:
{string}
 
The application ID to identify the client against the platform (mandatory to provide)
appCode:
{string}
 
The application code to identify the client against the platform (mandatory to provide)
useHTTPS:
{boolean}
 
Indicates whether secure communication should be used, default is false
useCIT:
{boolean}
 
Indicates whether the Customer Integration Testing should be used, default is false
opt_baseUrl:
{H.service.Url=} [optional]
 
The base URL of the platform, default is http://api.here.com. Note that if useHTTPS flag is passed it will override the URL scheme specified in the opt_baseUrl to use HTTPS.
Returns:
 
{H.service.IConfigurable}

Event Details

infoupdate: {H.util.Event}

This event is fired when the service's info resource was successfully retrieved and processed.

versionupdate: {H.util.Event}

This event is fired when the service's version hash was successfully updated.

copyrightupdate: {H.util.Event}

This event is fired when the service's copyrights were successfully retrieved.

You cannot use this account to purchase a commercial plan on Developer Portal, as it is already associated to plans with different payment methods.

To purchase a commercial plan on Developer Portal, please register for or sign in with a different HERE Account.

Something took longer than expected.

The project should be available soon under your projects page.

Sorry, our services are not available in this region.

Something seems to have gone wrong. Please try again later.

We've detected that your account is set to Australian Dollars (AUD).
Unfortunately, we do not offer checkouts in AUD anymore.
You can continue using your current plan as normal, but to subscribe to one of our new plans,
please register for a new HERE account or contact us for billing questions on selfservesupport@here.com.