HERE Android SDK Developer's Guide

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.

[For complete information, see the section Class Details]

See also:

setTheme(ClusterTheme)

Constructor Summary

Table 1. 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 2. 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

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

    if range or style is null

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.