UNPKG

bcgis-type

Version:

The SDK is based on Cesium for secondary development of 2, 3D all-in-one WebGis application framework, the framework optimizes the use of Cesium and add some additional features, designed for developers to quickly build WebGis applications.

66 lines (65 loc) 3.04 kB
export default class MVTImageryProvider { _destroyed: boolean; ready: boolean; tilingScheme: any; rectangle: any; tileSize: any; tileWidth: any; tileHeight: any; maximumLevel: any; minimumLevel: any; tileDiscardPolicy: any; _error: Cesium.Event; credit: any; proxy: any; hasAlphaChannel: any; sourceFilter: any; _accessToken: any; _enablePickFeatures: any; readyPromise: Promise<boolean>; _style: any; mapboxRenderer: any; /** * create a MVTImageryProvider Object * @param {MVTImageryProviderOptions} options MVTImageryProvider options as follow: * @param {Resource | string | StyleSpecification} options.style - mapbox style object or url Resource. * @param {string} options.accessToken - mapbox style accessToken. * @param {RequestTransformFunction} options.transformRequest - use transformRequest to modify tile requests. * @param {Number} [options.tileSize = 256] - can be 256 or 512. defaults to 256. * @param {Number} [options.maximumLevel = 18] - if cesium zoom level exceeds maximumLevel, layer will be invisible, defaults to 18. * @param {Number} [options.minimumLevel = 0] - if cesium zoom level belows minimumLevel, layer will be invisible, defaults to 0. * @param {Boolean} [options.showCanvas = false] - if show canvas for debug. * @param {Boolean} [options.enablePickFeatures = true] - enable pickFeatures or not, defaults to true. * @param {Function} options.sourceFilter - sourceFilter is used to filter which source participate in pickFeature process. * @param {WebMercatorTilingScheme | GeographicTilingScheme} [options.tilingScheme = WebMercatorTilingScheme] - Cesium tilingScheme, defaults to WebMercatorTilingScheme(EPSG: 3857). * @param {Credit} options.credit - A credit contains data pertaining to how to display attributions/credits for certain content on the screen. * @example * const imageryProvider = new MVTImageryProvider({ style: 'https://demotiles.maplibre.org/style.json' }); */ constructor(options: any); /** * get mapbox style json obj */ get style(): any; get isDestroyed(): boolean; /** * Gets an event that will be raised if an error is encountered during processing. * @memberof GeoJsonDataSource.prototype * @type {Event} */ get errorEvent(): Cesium.Event<(...args: any[]) => void>; _build(url: any, options?: any): Promise<void>; static fromUrl(url: any, options?: {}): Promise<MVTImageryProvider>; _preLoad(data: any): Promise<any>; _createTile(): HTMLCanvasElement; /** * reset tile cache */ _resetTileCache(): void; _getTilesSpec(coord: any, source: any): any[]; requestImage(x: any, y: any, level: any, releaseTile?: boolean): Promise<unknown>; pickFeatures(x: any, y: any, zoom: any, longitude: any, latitude: any): any; destroy(): void; }