GetTile Request |
SuperMap iServer WMTS server provides the implementing of REST and KVP, that is, two methods of GetTile request:
The KVP encoding request of GetTile operation should specify the server and version parameters, see on the following:
Table 1 KVP request paraneters of GetTile
ParameterName | Whether it is required | Description |
Service=WMTS |
Mandatory |
Service type. Request WMTS service and shall be "WMTS". |
Request=GetTile |
Mandatory |
Request names. Requests the GetCapabilities operation, and the request name needs to be set as "GetCapabilities". |
Version=1.0.0 |
Mandatory |
Version numbers. Now the version number of WMTS is 1.0.0. |
Layer |
Mandatory |
The name of request layer. Mandatory and only. |
Style |
Mandatory |
Style Style requested must be listed in Capabilities documents. Now SuperMap iServer only provides the default style, so the value can be ignored or set as default. |
Format |
Mandatory |
Format. The mandatory and only resource format that want to. SuperMap iServer current supports png format. |
TileMatrixSet |
Mandatory |
Tile matrix set. Mandatory and only. |
TileMatrix |
Mandatory |
Tile matrix set. Mandatory and only. |
TileRow |
Mandatory |
Tile rows requested. Row values of the tile matrix are 0, 1... MatrixHeight-1 successively from the top to the bottom. |
TileCol |
Mandatory |
Tile rows requested. Column values of the tile matrix are 0, 1... MatrixWidth-1 successively from the left to the right. |
Request methods of the GetCapabilities operation are as follows:
<ServiceRoot>?SERVICE=WMTS&REQUEST=GetTile&VERSION=version&Layer=&Style=&Format=&TileMatrixSet=&TileMatrix=&TileRow=&TileCol=
For example, after local SuperMap iServer starting WMTS 1.0.0 service successfully, URI requesting GetTile resource is: http://localhost:8090/iserver/services/map-world/wmts100?SERVICE=WMTS&REQUEST=GetTile&VERSION=1.0.0&Layer=World+Map&Style=default&Format=image/png&TileMatrixSet=GlobalCRS84Scale_World+Map&TileMatrix=2&TileRow=0&TileCol=0.
Please refer to Response example to see the result.
The REST of GetCapabilities operation corresponding to ServiceMetadata resource through get request and the two request URI of ServiceMetadata resources shown on the following:
<ServiceRoot>/{layer}/{style}/{TileMatrixSet}/{TileMatrix}/{TileRow}/{TileCol}[.Format]
<ServiceRoot>/{layer}/{TileMatrixSet}/{TileMatrix}/{TileRow}/{TileCol}[.Format]
ServiceRoot is the root URI of the service, please see Setting the Service URI. Format is the output format of the pictures, and the format SuperMap iServer supporting now is png.
The service metadata document of the resource-oriented framework contains a list of layer elements, and each layer element consists of one or multiple part element of <ResourceURL>, using to specify URI template accessing Tile resources. <ResourceURL> contains three attributes of Format, ResourceType and Template. According to specified formats in Template, gives specific URI, that is, can standardize HTTP Get way to request Tile resources. Specific descriptions of three attributes of <ResourceURL> are shown in the table below:
Table 2 required URI parameters for the request of Tile resources
ParameterName | Description |
Format | Format. Resource format intending to acquire, and must be sole. |
ResourceType | Resource Type. Be tile here. |
Template | URI template. See Table 2 for specific contents. |
Table 3 URL Template parameters
ParameterName | Description |
Layer | Layer name requested. Must be sole. |
Style | Style. Style requested must be listed in Capabilities documents. Now SuperMap iServer only provides the default style, so the value can be ignored or set as default. |
Dimension | Identifier of dimensions. If defining multiple dimensions, it must define a Dimension element for each dimension. Now SuperMap iServer doesn't support the function of multiple dimensions. |
TileMatrixSet | Name of tile matrix set, must exist and be sole. |
TileMatrix | Tile matrix, must exist and be sole. |
TileRow | Tile rows requested, and row values of the tile matrix are 0, 1... MatrixHeight-1 successively from the top to the bottom. |
TileCol | Tile column requested, and column values of the tile matrix are 0, 1... MatrixWidth-1 successively from the left to the right. |
For example, after local SuperMap iServer starting WMTS 1.0.0 service successfully, URI requesting ServiceMetadata resource is: http://localhost:8090/iserver/services/map-world/wmts100/World+Map/default/GlobalCRS84Scale_World+Map/2/0/0.png.
Please refer to Response example to see the result.