maps.nyc.gov

Class: Basemap

nyc.leaf.Basemap

new Basemap(target)

Class that provides an L.Map with base layers and labels
Parameters:
Name Type Description
target Element | JQuery | string The target DOM node for creating the map
Mixes In:
Source:
See:

Extends

  • L.Map

Members

(static, constant) CENTER :L.LatLng

The center of New York City
Type:
  • L.LatLng
Source:

(static, constant) EXTENT :L.LatLngBounds

The bounds of New York City
Type:
  • L.LatLngBounds
Source:

LabelType :string

Enumerator for label types
Type:
  • string
Properties:
Name Type Description
BASE string Label type for base layer
PHOTO string Label type for photo layer
Mixes In:
Source:

map :L.Map

Type:
  • L.Map
Source:

Methods

getBaseLayers() → {nyc.Basemap.BaseLayers}

Returns the base layers
Source:
Returns:
Type
nyc.Basemap.BaseLayers

hidePhoto()

Hide photo layer
Source:

showLabels(labelType)

Show photo layer
Parameters:
Name Type Description
labelType nyc.Basemap.LabelType The label type to show
Source:

showPhoto(layer)

Show photo layer
Parameters:
Name Type Description
layer number The photo year to show
Source:

Type Definitions

BaseLayers

Object type to hold base layers
Type:
  • Object
Properties:
Name Type Description
base Object The base layer
labels Object.<string, (ol.layer.Base|L.Layer)> The label layers
photos Object.<string, (ol.layer.Base|L.Layer)> The photo layers
Mixes In:
Source: