data


URI

<root_uri>/data[.<format>]

After starting the SuperMap iServer, the default URI to access REST services is http://<server>:8090/iserver/services/data-world/rest/data.

Supported methods

GET, HEAD

Parent resource

root

Child resources

coordTransfer, datasources, featureResults

Introduction

The data resource is the entrance to data query and data operations, providing the resource information about the datasource collection and the data query functionality.

Supported methods:

Supported output formats: rjson, json, html, xml.

GIS Services Resource Hierarchy

root data

HTTP request methods

Implement the HTTP request on the following URI, where supermapiserver is the server name, and get the response in rjson format.

http://supermapiserver:8090/iserver/services/cluster/availableServices.rjson

Get request

Gets the list of child resource information, including the datasource collection resource, data query resource, etc. The information about the child resources include resource name, URI, etc.

Request parameters

None.

Response structure

When implementing the GET request on the data resource, in the entity body of the response message is a descriptive set for the child resources. The structure for each child resource is as follows:

Field Type Description
name String Te resource name.
path String The access path of the resource.
resourceConfigID String The configuration item ID of the resource.
resourceType String The resource type.
supportedMediaTypes String[] The media-type of the supported representation.

Example usage

Implement the GET request on the data resource and get the response in rjson format, as shown below.

[

    {

        "name": "datasources",

        "path": "http://supermapiserver:8090/iserver/services/data-world/rest/data/datasources",

        "resourceConfigID": "datasources",

        "resourceType": "CatalogList",

        "supportedMediaTypes": [

            "application/xml",

            "text/xml",

            "application/json",

            "application/rjson",

            "text/html",

            "application/jsonp",

            "application/x-java-serialized-object"

        ]

    },

    {

        "name": "featureResults",

        "path": "http://supermapiserver:8090/iserver/services/data-world/rest/data/featureResults",

        "resourceConfigID": "featureResults",

        "resourceType": "ArithResultSetResource",

        "supportedMediaTypes": [

            "application/xml",

            "text/xml",

            "application/json",

            "application/rjson",

            "text/html",

            "application/jsonp",

            "application/x-java-serialized-object"

        ]

    }

]

HEAD Request

Asks for the response identical to the one that would correspond to a GET request, but without the response body. This is useful for retrieving meta-information written in response headers, without having to transport the entire content. The meta-information includes the media-type, content-encoding, transfer-encoding, content-length, etc.

The HEAD request helps check the existence of the data resource and whether it can be accessed by the client. By implementing the HEAD request on the URI, with .<format> appended to the end, we can quickly get to know whether the data resource supports the representation in <format> or not.

See