模块:ol/source/UTFGrid

ol/source/UTFGrid


UTFGrid

类型定义

Options{Object}

属性:
Name Type 描述
preemptive boolean
(defaults to true)

如果trueUTFGrid源依据瓦片可见性加载瓦片,这提升了响应速度,但增加了网络流量。请注意,如果设置为false(懒加载),你需要传递true作为requestforDataAtCoordinateAndResolution否则,将无法加载任何数据。

jsonp boolean
(defaults to false)

使用带回调函数的JSONP加载TileJSON。当服务器不支持CORS时,该方法非常有效。

tileJSON Config | undefined

此源的 TileJSON 配置。若未提供,url必须进行配置。

url string | undefined

提供此源配置的 TileJSON 端点。请求将通过 JSONP 发出。如果没有提供,tileJSON必须配置。

wrapX boolean
(defaults to true)

是否水平环绕世界。

zDirection number | NearestDirectionFunction
(defaults to 0)

在整数缩放级别之间,选择是否使用更高或更低缩放级别的瓦片。参见getZForResolution.

UTFGridJSON{Object}

属性:
Name Type 描述
grid Array.<string>

网格。

keys Array.<string>

键。

data Object.<string, Object> | undefined

可选数据。