Skip to main content

Class: default

The main pmtile custom source

Param

Hierarchy

  • VectorTileSourceImpl

    default

Constructors

constructor

new default(...args): default

Parameters

NameType
...args[id: string, implementation: PmTilesOptions, dispatcher: any, eventedParent: any]

Returns

default

Overrides

VectorTileSourceImpl.constructor

Defined in

index.ts:187

Properties

_collectResourceTiming

_collectResourceTiming: boolean = false

Defined in

index.ts:166


_dataType

_dataType: string

Defined in

index.ts:162


_implementation

_implementation: PmTilesOptions

Defined in

index.ts:163


_instance

_instance: PMTiles

Defined in

index.ts:165


_loaded

_loaded: boolean

Defined in

index.ts:160


_protocol

_protocol: Protocol

Defined in

index.ts:164


_tileJSONRequest

_tileJSONRequest: undefined | Promise<any>

Defined in

index.ts:167


_tileWorkers

_tileWorkers: Object

Index signature

▪ [string: string]: any

Defined in

index.ts:161


attribution

attribution: undefined | string

Defined in

index.ts:143


contentType

contentType: string

Defined in

index.ts:171


dispatcher

dispatcher: any

Defined in

index.ts:155


fire

fire: Function

Defined in

index.ts:153


header: any

Defined in

index.ts:170


id

id: string

Defined in

index.ts:138


loadTile

loadTile: (tile: Tile, callback: Callback<void>) => void

Type declaration

▸ (tile, callback): void

Parameters
NameType
tileTile
callbackCallback<void>
Returns

void

Defined in

index.ts:168


map

map: MapboxMap

Defined in

index.ts:145


maxTileCacheSize

maxTileCacheSize: undefined | number

Defined in

index.ts:150


maxzoom

maxzoom: number

Defined in

index.ts:141


minTileCacheSize

minTileCacheSize: undefined | number

Defined in

index.ts:149


minzoom

minzoom: number

Defined in

index.ts:140


promoteId

promoteId: undefined | string

Defined in

index.ts:151


reparseOverscaled

reparseOverscaled: boolean

Defined in

index.ts:156


roundZoom

roundZoom: boolean = true

Defined in

index.ts:147


scheme

scheme: string

Defined in

index.ts:139


scope

scope: undefined | string

Defined in

index.ts:154


setEventedParent

setEventedParent: any

Defined in

index.ts:157


tileBounds

tileBounds: undefined | TileBounds

Defined in

index.ts:148


tileSize

tileSize: number

Defined in

index.ts:142


tileType

tileType: TileType

Defined in

index.ts:169


tiles

tiles: string[]

Defined in

index.ts:144


type

type: string = 'vector'

Defined in

index.ts:152


SOURCE_TYPE

Static SOURCE_TYPE: string = SOURCE_TYPE

Defined in

index.ts:136

Methods

hasTile

hasTile(tileID): boolean

Parameters

NameType
tileIDTileID

Returns

boolean

Defined in

index.ts:229


load

load(callback?): void

Parameters

NameType
callback?Callback<void>

Returns

void

Defined in

index.ts:232


loadRasterTile

loadRasterTile(tile, callback): void

Parameters

NameType
tileTile
callbackCallback<void>

Returns

void

Defined in

index.ts:403


loadRasterTileData

loadRasterTileData(tile, data): void

Parameters

NameType
tileTile
dataany

Returns

void

Defined in

index.ts:399


loadVectorTile

loadVectorTile(tile, callback): void

Parameters

NameType
tileTile
callbackCallback<void>

Returns

void

Defined in

index.ts:306


loaded

loaded(): boolean

Returns

boolean

Defined in

index.ts:303


zoomToExtent

zoomToExtent(): void

Returns

void

Defined in

index.ts:219


getMetadata

getMetadata(url): Promise<any>

Parameters

NameTypeDescription
urlstringThe pmTiles URL

Returns

Promise<any>

A Json object of the PmTile's metadata

Defined in

index.ts:178