Class: Service

new H.service.metaInfo.Service (opt_options) Deprecated : since 3.1.40.0

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

It's not allowed to call the constructor directly (an IllegalOperationError is thrown). Instead an instance of this Service can be retrieved by calling the factory method H.service.Platform#getMetaInfoService on a platform instance.

Name Type Description
opt_options H.service.metaInfo.Service.Options optional

The configuration options for the service

Throws:

Extends

Members

H.service.metaInfo.Service.CONFIG_KEY string staticconstant

The property name to use when specifying options for this service within the H.service.Platform.Options#servicesConfig.

getInfo

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

Methods

addEventListener (type, handler, opt_capture, opt_scope) inherited

This method adds a listener for a specific event.

Note that to prevent potential memory leaks, you must either call removeEventListener or dispose on the given object when you no longer need it.

Name Type Description
type string

The name of the event

handler function

An event handler function

opt_capture boolean optional

true indicates that the method should listen in the capture phase (bubble otherwise)

opt_scope Object optional

An object defining the scope for the handler function

addOnDisposeCallback (callback, opt_scope) inherited

This method adds a callback which is triggered when the EventTarget object is being disposed.

Name Type Description
callback function

The callback function.

opt_scope Object optional

An optional scope for the callback function

createTileLayer (tileSize, pixelRatio, opt_categoryFilter, opt_additionalParameters, opt_tileType, opt_scheme)H.map.layer.TileLayer

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

Name Type Description
tileSize number

The tile size

pixelRatio number

The tile's pixel ratio, should be aligned with base map tile

opt_categoryFilter Array.<string> optional

A list of meta-info category names which should be suppressed. See Metainfo Tile for valid category names.

opt_additionalParameters H.service.ServiceParameters optional

Additional parameters for the meta info service

opt_tileType string optional

The tile type (default is "maptile")

opt_scheme string optional

The scheme for which the meta info tiles a requested (default is "normal.day")

Returns:
Type Description
H.map.layer.TileLayer The tile layer

createTileProvider (tileSize, pixelRatio, opt_categoryFilter, opt_additionalParameters, opt_tileType, opt_scheme)H.map.provider.TileProvider

This method creates a tile provider which uses the meta info tile backend. This provider can be used as a data source for an TileLayer.

Name Type Description
tileSize number

The tile size

pixelRatio number

The pixel ratio to use for over-sampling in cases of high-resolution displays

opt_categoryFilter Array.<string> optional

A list of meta-info category names which should be suppressed. See Metainfo Tile for valid category names.

opt_additionalParameters H.service.ServiceParameters optional

Additional parameters for the meta info service

opt_tileType string optional

The tile type (default is "maptile")

opt_scheme string optional

The scheme for which the meta info tiles a requested (default is "normal.day")

Returns:
Type Description
H.map.provider.TileProvider The tile provider

dispatchEvent (evt) inherited

This method dispatches an event on the EventTarget object.

Name Type Description
evt H.util.Event | string

An object representing the event or a string with the event name

dispose () inherited

This method removes listeners from the given object. Classes that extend EventTarget may need to override this method in order to remove references to DOM Elements and additional listeners.

This method returns the configured service URL.

Returns:
Type Description
H.service.Url

getVersion ()string

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

Returns:
Type Description
string meta information for this map tile service

removeEventListener (type, handler, opt_capture, opt_scope) inherited

This method removes a previously added listener from the EventTarget instance.

Name Type Description
type string

The name of the event

handler function

A previously added event handler

opt_capture boolean optional

true indicates that the method should listen in the capture phase (bubble otherwise)

opt_scope Object optional

An object defining the scope for the handler function

Type Definitions

H.service.metaInfo.Service.Info Object

This type describes the map tile service's meta information.

Properties:
Name Type Description
maps Object.<string, Object>
schemes Object.<string, Object>
tiletypes Object.<string, Object>
formats Object.<string, Object>
resolutions Object.<string, Object>
languages Object.<string, Object>

H.service.metaInfo.Service.Options Object

This type encapsulates configuration options for an instance of a MetaInfo service.

Properties:
Name Type Argument Description
baseUrl H.service.Url <optional>

The base URL of the MetaInfo service. If supplied, it overrides all defaults (either coming from platform or service internals) including authentication params

subDomain string <optional>

The subdomain of the map tile service relative to the platform's base URL, the default is "maps"

path string <optional>

The path of the map tile service, the default is "maptile/2.1"

headers Object <optional>

A map of HTTP headers to be sent with each request made by the service

type string <optional>

The type of the map tile service to communicate with, e.g. 'base' (default), 'aerial', etc. (Refer to HERE Map Tile API documentation for available types)

version string <optional>

The map version hash to use for retrieving tiles, the default is "newest" and will be automatically updated

Events

copyrightupdate

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

Type:

infoupdate

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

Type:

versionupdate

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

Type: