maps.nyc.gov

Class: Basemap

nyc.ol.Basemap(options, preloadopt)

new Basemap(options, preloadopt)

Class that provides an ol.Map with base layers and labels
Parameters:
Name Type Attributes Default Description
options Object Constructor options
preload number <optional>
0 Preload option for base layer
Mixes In:
Source:
See:

Extends

  • ol.Map

Members

(static, constant) CENTER :ol.Coordinate

The center of New York City
Type:
  • ol.Coordinate
Source:

(static, constant) EXTENT :ol.Extent

The bounds of New York City
Type:
  • ol.Extent
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:

Methods

getBaseLayers() → {nyc.Basemap.BaseLayers}

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

getStorage() → {nyc.ol.storage.Local}

Get the storage used for laoding and saving data
Source:
Returns:
srorage
Type
nyc.ol.storage.Local

hidePhoto()

Hide photo layer
Source:

showLabels(labelType)

Show the specified label layer
Parameters:
Name Type Description
labelType nyc.Basemap.BaseLayers 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:

Options

Object type to hold constructor options for nyc.Basemap
Type:
  • Object
Properties:
Name Type Description
target Element | JQuery | string The target DOM node for creating the map
Mixes In:
Source:

nyc-lib: Class: Basemap

maps.nyc.gov

Class: Basemap

nyc.ol.Basemap(options, preloadopt)

new Basemap(options, preloadopt)

Class that provides an ol.Map with base layers and labels
Parameters:
Name Type Attributes Default Description
options Object Constructor options
preload number <optional>
0 Preload option for base layer
Mixes In:
Source:
See:

Extends

  • ol.Map

Members

(static, constant) CENTER :ol.Coordinate

The center of New York City
Type:
  • ol.Coordinate
Source:

(static, constant) EXTENT :ol.Extent

The bounds of New York City
Type:
  • ol.Extent
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:

Methods

getBaseLayers() → {nyc.Basemap.BaseLayers}

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

getStorage() → {nyc.ol.storage.Local}

Get the storage used for laoding and saving data
Source:
Returns:
srorage
Type
nyc.ol.storage.Local

hidePhoto()

Hide photo layer
Source:

showLabels(labelType)

Show the specified label layer
Parameters:
Name Type Description
labelType nyc.Basemap.BaseLayers 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:

Options

Object type to hold constructor options for nyc.Basemap
Type:
  • Object
Properties:
Name Type Description
target Element | JQuery | string The target DOM node for creating the map
Mixes In:
Source: