Class: WMTS

.Service. WMTS

OGC-WMTS服务类。继承GeoGlobe.Service类。

new WMTS()

Source:
View2D/Service/WMTS.js

Methods


getCapabilities(successFn, failFn)

获取服务能力描述信息。
Parameters:
Name Type Description
successFn function 请求成功的回调函数。
failFn function 请求失败的回调函数。
Source:
View2D/Service/WMTS.js

getCapabilitiesForRest(successFn, failFn)

WMTS-RESTful的获取服务能力描述信息。
Parameters:
Name Type Description
successFn function 请求成功的回调函数。
failFn function 请求失败的回调函数。
Source:
View2D/Service/WMTS.js

getTile(params, service, version, layer, style, format, TileMatrixSet, TileMatrix, TileRow, TileCol)

获取瓦片内容操作。
Parameters:
Name Type Description
params Object 请求参数,具体内容参考OGC-WMTS标准。
service String 默认值是"WMTS"。
version String 默认值是"1.0.0"。
layer String 必选 图层标示。
style String 必选 图层样式标示。
format String 默认值是"image/png"。
TileMatrixSet String 必选 矩阵集。
TileMatrix String 必选 矩阵。
TileRow Integer 必选 瓦片行号。
TileCol Integer 必选 瓦片列号。
Source:
View2D/Service/WMTS.js
Returns:
- 瓦片内容图片地址。
Type
String
Example
(code)
var url = wmtsService.getTile({
    layer: "dgdom0624",
    style: "dgdom0624",
    TileMatrixSet: "Matrix_0",
    TileMatrix: "12",
    TileRow: 761,
    TileCol: 3342
});
(end)

getTileForRest(params)

WMTS-RESTful的获取瓦片内容操作。
Parameters:
Name Type Description
params Object 请求参数,具体内容参考OGC-WMTS标准。
Source:
View2D/Service/WMTS.js
Returns:
- 瓦片内容图片地址。 layer {String} - 必选 图层标示。 style {String} - 必选 图层样式标示。 format {String} - 必选 瓦片图片格式。默认值是"image/png"。 TileMatrixSet {String} - 必选 矩阵集。 TileMatrix {String} - 必选 矩阵。 TileRow {Integer} - 必选 瓦片行号。 TileCol Integer} - {必选 瓦片列号。
Type
String
Example
(code)
var url = wmtsService.getTile({
    layer: "dgdom0624",
    style: "dgdom0624",
    TileMatrixSet: "Matrix_0",
    TileMatrix: "12",
    TileRow: 761,
    TileCol: 3342
});
(end)

initialize(name, url, options)

GeoGlobe.Service.WMTS类的构造函数。
Parameters:
Name Type Description
name String 服务名称。
url String 服务地址。
options Object 实例的选项设置,此参数可选。
Source:
View2D/Service/WMTS.js

isExist()

将向服务发送“GetCapabilities”同步请求,以检测服务是否存在。 注意,本方法只能验证服务是否存在,并不能保证实际功能完全正常。
Source:
View2D/Service/WMTS.js
Returns:
- 服务是否存在。
Type
Boolean