Data Lens Developer's Guide

SpatialLayer

Class Summary

Extends: H.map.layer.TileLayer

Renders vector tiles using data-driven styles

[ For full details, see the Constructor Details ]

Class Description

This layer binds the spatial data and user data, all provided by the Data Lens REST API. The layer renders geometry features using data-driven styles.

Constructor Details

H.datalens.SpatialLayer ()

Property Details

static DEFAULT_STATE

static Spatial

static defaultDataToRows

Default value for dataToRows callback option. It represents each row as an object where property names correspond to data column names.
var layer = new H.datalens.SpatialLayer(
   dataProvider,
   spatialProvider,
   {
     dataToRows: function(data) {
       return H.datalens.SpatialLayer.defaultDataToRows(
         data
       ).filter(function() {
         ...
       })
     },
     ...
   }
);

Method Details

redraw ()

Forces re-rendering of the layer. When the callbacks passed to the layer options are not pure functions, you can call this method to force re-rendering.

updateSpatialStyle (spatial, state)

This method changes the state of a map object; for example, style on mouse event.

Parameters:
 
spatial :
{ H.map.Object }
object
state :
{ H.datalens.SpatialLayer.StyleState }

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.