Class: VectorTile

ol.VectorTile


Extends

Methods

getExtent(){ol.Extent}

src/ol/vectortile.js, line 97

Gets the extent of the vector tile.

Returns:
The extent.

getFeatures(){Array.<(ol.Feature|ol.render.Feature)>}

src/ol/vectortile.js, line 118

Get the features for this tile. Geometries will be in the projection returned by ol.VectorTile#getProjection.

Returns:
Features.

getFormat(){ol.format.Feature}

src/ol/vectortile.js, line 107

Get the feature format assigned for reading this tile's features.

Returns:
Feature format.

getProjection(){ol.proj.Projection}

src/ol/vectortile.js, line 137

Get the feature projection of features returned by ol.VectorTile#getFeatures.

Returns:
Feature projection.

getTileCoord(){ol.TileCoord} inherited

src/ol/tile.js, line 153

Get the tile coordinate for this tile.

Returns:
The tile coordinate.

load() inherited

src/ol/tile.js, line 180

Load the image or retry if loading previously failed. Loading is taken care of by the tile queue, and calling this method is only needed for preloading or for reloading in case of an error.

setExtent(extent)

src/ol/vectortile.js, line 197

Function for use in an ol.source.VectorTile's tileLoadFunction. Sets the extent of the vector tile. This is only required for tiles in projections with tile-pixels as units. The extent should be set to [0, 0, tilePixelSize, tilePixelSize], where tilePixelSize is calculated by multiplying the tile size with the tile pixel ratio. For sources using ol.format.MVT as feature format, the ol.format.MVT#getLastExtent method will return the correct extent. The default is [0, 0, 4096, 4096].

Name Type Description
extent ol.Extent

The extent.

setFeatures(features)

src/ol/vectortile.js, line 208

Function for use in an ol.source.VectorTile's tileLoadFunction. Sets the features for the tile.

Name Type Description
features Array.<ol.Feature>

Features.

setLoader(loader)

src/ol/vectortile.js, line 241

Set the feature loader for reading this tile's features.

Name Type Description
loader ol.FeatureLoader

Feature loader.

setProjection(projection)

src/ol/vectortile.js, line 221

Function for use in an ol.source.VectorTile's tileLoadFunction. Sets the projection of the features that were added with ol.VectorTile#setFeatures.

Name Type Description
projection ol.proj.Projection

Feature projection.