<datasets_uri>/{datasetName}[.<format>]
The dataset resource represents a dataset. By sending GET request to dataset resource, you can get the description information of this dataset({datasetName}).By sending DELETE request, you can delete this dataset.
Supported Methods:
Supported output formats: rjson, json, html, xml.
Implement the HTTP request on the following URI, where supermapiserver is the server name, with rjson being the output format.
http://supermapiserver:8090/iserver/services/datacatalog/rest/datacatalog/relationship/datasets/{datasetName}.rjson
Gets the detail information of dataset.
The structure of the response resource representation after implementing the GET request on the dataset resource will be as follows:
Field | Type | Description |
datasetInfo | DatasetInfo | Detail information of dataset. |
childUriList | List<String> | the child resource list. |
supportAttachments | boolean | Whether it supports attachments. |
supportFeatureMetadatas | boolean | Whether it supports to get feature meta data. |
The detail information of dataset( the structure of DatasetInfo ):
Field | Type | Description |
name | String | Dataset name, which is the unique identification of dataset. This identification is not case-sensitive |
description | String | The descriptive information of dataset. |
type | DatasetType | Dataset type. Currently supported dataset types include: DatasetVector like property dataset,point dataset,EPS point dataset, line dataset, EPS line dataset, region dataset, EPS region dataset, EPS text dataset, CAD dataset; DatasetGrid; DatasetImage and DatasetNetwork. |
bounds | Rectangle2D | dataset bounds. For DatasetVector, bounds is the minimum circumscribed rectangle; For DatasetGrid and DatasetImage, bounds is the Geographic bounds of current dataset. |
dataSourceName | String | The name of datasource which the dataset belongs. |
encodeType | EncodeType | Dataset encode type used when it's compressed for storage. |
isReadOnly | boolean | Whether the dataset is readonly. |
prjCoordSys | PrjCoordSys | The projected coordinate system of dataset. |
tableName | String | Table name. For datasource of database engine type, it recommends the table name in database corresponding to the dataset; For datasource of file type, it recommends storage property table name of the dataset(Datasource of file type stores geometry data in .sdb file and property data in .sdd file). |
charset | Charset | Charset of DatasetVector. It exists only when the resource identification is DatasetVector. |
isFileCache | boolean | Whether to store cache with file format. This parameter only works for datasource of database. |
recordCount | int | Record count of DatasetVector. It exists only when the resource identification is DatasetVector. |
Execute GET request to example dataset resource: http://supermapiserver:8090/iserver/services/datacatalog/rest/datacatalog/relationship/datasets/test.rjson. The returned representation is as follows:
{
"childUriList": [],
"datasetInfo": {
"bounds": {
"bottom": 0,
"left": 0,
"leftBottom": {
"x": 0,
"y": 0
},
"right": 0,
"rightTop": {
"x": 0,
"y": 0
},
"top": 0
},
"charset": "UTF8",
"dataSourceName": "supermap1_pg",
"datasourceConnectionInfo": {
"alias": "supermap1_pg",
"connect": false,
"dataBase": "supermap1",
"driver": "PostgreSQL ANSI",
"engineType": "POSTGRESQL",
"exclusive": false,
"openLinkTable": false,
"password": "supermap",
"readOnly": false,
"server": "169.254.51.25",
"user": "postgres"
},
"description": "",
"encodeType": "NONE",
"isFileCache": false,
"isReadOnly": false,
"name": "test",
‘prjCoordSys": {
“coordSystem": null,
”coordUnit": "METER",
“distanceUnit": "METER",
"epsgCode": -1000,
”name": "Planar Coordinate System---m",
“projection": null,
”projectionParam": null,
“type": "PCS_NON_EARTH"
},
”recordCount": 0,
“tableName": "SMDTV_1",
”type": "POINT"
},
“supportAttachments": false,
”supportFeatureMetadatas": false
}
Deletes a specified dataset.
Execute DELETE request on dataset resource to delete dataset. The representation of the operation result is as follows:
Field | Type | Description |
succeed | boolean | Whether it's successful to delete data. |
error | HttpError | Error information. If the operation is successful, the field does not exist. |
Execute DELET request on dataset resource: http://supermapiserver:8090/iserver/services/datacatalog/rest/datacatalog/relationship/datasets/test.rjson to delete test dataset. The representation returned in rjson format when it successfully executed.
{"succeed": true}
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 contained in response headers, without having to transport the entire content. The meta-information includes the media-type, content-encoding, transfer-encoding, content-length, etc.
HEAD request can be used to check whether the dataset resource exists, or whether the the client has the permission to access it. It can also determine if the dataset resource supports an output format <format> if performed on a URI with .<format> included.