Class Labels

Methods

  • Adds a label (Label) to the map.

    Parameters

    Returns Label

    The created label, or undefined if creation failed.

    map.Labels.add(space, 'Welcome', { appearance: { color: 'blue' } });
    
  • Automatically adds all the labels (Label) to the map.

    The text, appearance, priority, etc. of the labels will be automatically determined based on the external data.

    Returns Label[]

    // Add all the labels to the map
    map.Labels.all();
  • Removes a label (Label) from the map.

    Parameters

    • label: Label

      The label which should be removed.

    Returns void

    mapView.Labels.remove(space);
    
  • Removes all the labels (Label) from the map.

    Returns Label[]

    map.Labels.removeAll();