<directories_uri>/verification[.<format>]
dirNameVerify resource is to verify whether there are the same directory names at the same level under the same root. This method needs administrator permission. Please make sure that the administration is in login status.
Supported Methods:
Supported output formats: rjson, json, HTML, XML.
Implement the HTTP request on the following URI, where supermapiportal is the server name, with rjson being the output format.
http://supermapiportal:8090/iportal/web/directories/verification.rjson
Verify whether there are the same directory names at the same level under the same root.
Execute POST request on dirNameVerify resource, and verify whether there are the same directory names at the same level under the same root. It is composed by following fields:
Name | Type | Description |
dirName |
String | [Required] Name of the directory. |
dirType | DirectoryResourceType | Directory type. It is required when verifying root directory names. It is optional, if the value is null when creating a child directory. By default, the directory type is the same with the parent directory. |
parentDirId | Integer | Parent directory ID. It is optional when verifying a child directory; if the value is null or the parameter isn't transferred when verifying a child directory. |
The structure of the response resource representation is as follows:
Field | Type | Description |
succeed | boolean | Verify whether the directory name exist or not. If it is true, there is a same directory name exists; otherwise, fales. |
error | Httperror | Error information. This field will not be displayed if the directory name is verified successfully. |
Exectue PUT request on dirNameVerify resource http://localhost:8090/iportal/web/directories/verification.rjson, and verify whether a same directory name exists. The reqeust body is as follows:
{
"dirName": "Land use",
"dirType": "MAP"
}
The returned resource representation in rjson format is as follows:
{"succeed": true}