Class: LayerListView

LayerListView()

A Layer List shows a collection of Map Assets, like imagery and vector layers. Each Map Asset in the collection is rendered as a single item in the list. Each item can be clicked for more details.

Screenshot

Constructor

new LayerListView()

Since:
  • 2.18.0
Source:

Extends

  • Backbone.View

Members

className :string

The HTML classes to use for this view's element
Type:
  • string
Source:

collection :MapAssets

The collection of layers to display in the list
Type:
Source:

events :Object

The events this view will listen to and the associated function to call.
Type:
  • Object
Source:

isCategorized :boolean

Whether the layer list is a under a category. Flat layer list and categorized layer list are styled differently.
Type:
  • boolean
Source:

template :Underscore.template

The primary HTML template for this view
Type:
  • Underscore.template
Source:

type :string

The type of View this is
Type:
  • string
Source:

Methods

initialize(optionsopt)

Executed when a new LayerListView is created
Parameters:
Name Type Attributes Description
options Object <optional>
A literal object with options to pass to the view
Source:

removeListeners()

Remove any event listeners on the collection
Since:
  • 2.27.0
Source:

render() → {LayerListView}

Renders this view
Source:
Returns:
Returns the rendered view element
Type
LayerListView
Searches and only displays layers that match the text.
Parameters:
Name Type Attributes Description
text string <optional>
The search text from user input.
Source:
Returns:
- True if a layer item matches the text
Type
boolean

setListeners()

Add or remove items from the list when the collection changes
Since:
  • 2.27.0
Source: