URI
<webPrinting_uri>/v1[.<format>]
Supported methods
Parent resource
Child resources
layoutTemplates、webPrintingJobs
Introduction
v1 资源表示 Web 打印服务的接口版本是 v1。
Supported methods:
- GET:获取 Web 打印服务 v1版本支持的所有子资源。
- HEAD:检查 v1 resource exists, or if there is permission to access v1 资源。
Supported output formats:RJSON、JSON、HTML、XML。
GIS Services Resource Hierarchy
HTTP Request Methods
对如下 URI 执行 HTTP 请求,以 rjson 输出格式为例加以说明,其中,supermapiserver 是服务器名。
http://supermapiserver:8090/iserver/services/webprinting/rest/webprinting/v1.rjson
GET 请求
获取 Web 打印服务 v1版本支持的所有子资源。
Response structure
对 v1 资源执行 GET 请求,在响应体里是一个子资源描述集,其中单个子资源描述的结构如下:
| 字段 | 类型 | 说明 |
| name | String | 资源的名称。 |
| url | String | 资源访问的 url。 |
Example of response
对 v1 资源:http://supermapiserver:8090/iserver/services/webprinting/rest/webprinting/v1.rjson,执行 GET 请求,返回 rjson 格式的资源描述如下:
[
{
"name": "jobs",
"url": "http://192.168.120.40:8091/iserver/services/webprinting/rest/webprinting/v1/jobs"
},
{
"name": "layouts",
"url": "http://192.168.120.40:8091/iserver/services/webprinting/rest/webprinting/v1/layouts"
}
]
HEAD 请求
Returns the same HTTP response headers as a GET request, but without the response body. This allows retrieving meta-information from the response headers without transporting the entire content. The meta-information includes the media type,字符编码,压缩编码,实体内容长度等。
A HEAD request can be used to check if v1 资源是否存在,或者客户端是否有权限访问 v1 资源。通过对加.<format>的 URI 执行 HEAD 请求,还可以快速判断 v1 资源是否支持<format>格式的表述。
See
- webPrinting、layoutTemplates、webPrintingJobs
- 客户端构建 REST 请求
- Status Codes
- SuperMap iServer REST API 表述格式介绍
- GIS Services Resource Hierarchy