ui/locations/entries/pin

The pin entry module exports the pin method as mapp.ui.locations.entries.pin()

Dictionary entries:

  • pin

Requires

Methods

(async, inner) getExtent(entry) → {Promise.<Array>}

Calculates the extent of the pin. Applies a buffer if one has been supplied to the pin.

Parameters:
NameTypeDescription
entryinfoj-entry

type:pin entry.

Properties
NameTypeAttributesDescription
entry.bufferboolean | number<optional>

a value to buffer the pin with or just true for a default of 200.

Returns:

an array representing an openlayers extent.

Type: 
Promise.<Array>

(inner) hide()

Removes the entry.L from the location.layer.mapview.

(inner) pin(entry) → {HTMLElement}

Places a pin on the selected location on the map. A checkbox is supplied to turn the pin on and off.

The pin will be styled by the entry.style property if provided. Otherwise the location.pinStyle assigned by the locations listview method will be used. A location may not have a pinStyle if no listview has been configured for the mapview.

Parameters:
NameTypeDescription
entryinfoj-entry

type:pin entry.

Properties
NameTypeAttributesDescription
entry.locationlocation

The entry location.

entry.valuearray

An array containing entrys' co-ordinates.

entry.labelstring<optional>

Label for checkbox element.

entry.displayboolean<optional>

The pin display flag.

entry.sridstring<optional>

The srid of the pin.

entry.zIndexinteger<optional>

The html layer on which the pin should display.

entry.styleobject<optional>

Style properties of the pin which may include a scale.

Returns:

Location pin and display checkbox.

Type: 
HTMLElement