maps.nyc.gov

Class: LayerMgr

nyc.ol.control.LayerMgr

new LayerMgr(options)

Class that provides layer swiping effect
Parameters:
Name Type Description
options nyc.ol.control.LayerPicker.Options Constructor options
Source:

Extends

Members

controls :Array.<nyc.Choice>

The layer picker controls
Type:
Inherited From:
Source:

layerGroups :Array.<nyc.ol.control.LayerPicker.LayerGroup>

The layer groups displayed on the picker
Type:
Inherited From:
Source:

map :ol.Map

The map from which layers can be picked
Type:
  • ol.Map
Inherited From:
Source:

Methods

clear()

Turn off all layers
Source:

getButtonHtml() → {string}

Provides an HTML string for creating a menu actuator when a DOM target is not provided to the constructor
Overrides:
Source:
Returns:
Type
string

getLayerGoupsFromMap(map) → {Array.<nyc.ol.control.LayerPicker.LayerGroup>}

Provides layer groups from the map when they are not provided to the constructor
Parameters:
Name Type Description
map ol.Map
Overrides:
Source:
Returns:
Type
Array.<nyc.ol.control.LayerPicker.LayerGroup>

(abstract) getLayers() → {Object.<string, ol.layer.Base>}

Return a map of layers by name
Inherited From:
Source:
Returns:
Type
Object.<string, ol.layer.Base>

getMenuClass() → {string}

Provides an HTML DOM element class for menu creation when a DOM target is not provided to the constructor
Overrides:
Source:
Returns:
Type
string

(abstract) loadedGroup(control, group, layers)

Provides notification that layers form a group namespace have been added
Parameters:
Name Type Description
control nyc.Choice
group Object
layers Array.<ol.layer.Base>
Overrides:
Source: