<dataset_uri>/SpatialQuery3D[.<format>]
Used to perform 3D spatial query on datasets. By sending a POST request on this resource, a 3D spatial query result resource will be created, from which you can get the specific result.
Supported methods:
Supported output formats: RJSON, JSON, HTML, XML.
Execute HTTP request on the following URI, here we take rjosn as the output format as an example. Where, supermapiserver is the server name.
http://supermapiserver:8090/iserver/services/spatialAnalysis-BIM2/restjsr/spatialanalyst/datasets/结构柱%408ExportModel/SpatialQuery3D.rjson
Returns a form for performing POST request.
Performing a POST request on the current resource with the needed parameters, a 3D spatial query result resource will be created.
When the operate object is dataset, parameters passed in the request body should contain:
Field | Type | Definition |
operateDataset | String | [Required] The operate dataset used to perform 3D spatial query. The type is model dataset. |
operateDatasetFilter | QueryParameter | The filter conditions performed on operate dataset. Only the objects that meet the filter condition can participate the 3D spatial analysis. The filter includes attribute and ID filters. |
sourceDatasetFilter | QueryParameter | The filter conditions performed on source dataset. Only the objects that meet the filter condition can participate the 3D spatial analysis. The filter includes attribute and ID filters. |
positionMode | PositionMode | [Required] The specified spatial relation types, including UNKNOWN, IDENTICAL, DISJOINT, INTERSECTS, WITHIN, CONTAINS, INTERSECTSORCONTAINS. |
resultSetting | DatasetSpatialQuery3DResultSetting | The settings for 3D spatial analysis result. |
When the operate object is geometry, parameters passed in the request body should contain:
Field | Type | Definition |
operateRegion | Geometry | [Required] The operate geometric polygon used to perform 3D spatial query. |
bottomAltitude | double | The bottom altitude of the specified geometry. |
extendedHeight | double | The extending height of the specified geometry. |
sourceDatasetFilter | QueryParameter | The filter condition on source dataset, including attribute filter and ID filter. Only the objects that meet the filter condition can participate the 3D spatial analysis. |
positionMode | PositionMode | [Required] The specified spatial relation types, including UNKNOWN, IDENTICAL, DISJOINT, INTERSECTS, WITHIN, CONTAINS, INTERSECTSORCONTAINS. |
resultSetting | DatasetSpatialQuery3DResultSetting | The settings for 3D spatial analysis result. |
The normal response code is 201. Response fields:
Field | Type | Description |
postResultType | postResultType | The result type of POST requests. It shows what operations have done to the target resource. |
newResourceID | String | The ID of the analysis result resource. |
succeed |
boolean | Marks whether the analysis is successful. |
newResourceLocation |
String | The URI of the new created resource. |
On SpatialQuery3D resource: http://supermapiserver:8090/iserver/services/spatialAnalysis-BIM2/restjsr/spatialanalyst/datasets/结构柱%408ExportModel/SpatialQuery3D.rjson, choose a dataset as the operate object, perform a POST request with the following parameters as the request body:
{
"operateDataset":"结构柱@8ExportModel",
"operateDatasetFilter":{"attributeFilter":"", "ids":[15, 21]},
"sourceDatasetFilter":{"attributeFilter":"", "ids":[20]},
"positionMode":"INTERSECTS"
}
the returned resource description in rjson format is as follows:
{
"postResultType":"CreateChild",
"newResourceID":"2fe735b026974a13a1bbf00ac710ddef_57c2f72f83364db5903659dcd5faa92d",
"succeed":true,
"newResourceLocation":"http://localhost:8090/iserver/services/spatialAnalysis-BIM2/restjsr/spatialanalyst/datasets/%E7%BB%93%E6%9E%84%E6%9F%B1@8ExportModel/SpatialQuery3D/2fe735b026974a13a1bbf00ac710ddef_57c2f72f83364db5903659dcd5faa92d"
}
On SpatialQuery3D resource: http://supermapiserver:8090/iserver/services/spatialAnalysis-BIM2/restjsr/spatialanalyst/datasets/结构柱%408ExportModel/SpatialQuery3D.rjson, choose a geometric polygon as the operate object, perform a POST request with the following parameters as the request body:
{
"operateRegion":{"type":"REGION", "points":[{"x":23, "y":23}, {"x":33, "y":35}, {"x":43, "y":22}]},
"bottomAltitude":"1",
"extendedHeight":"1",
"sourceDatasetFilter":{"attributeFilter":""},
"positionMode":"UNKNOWN"
}
the returned resource description in rjson format is as follows:
{
"postResultType":"CreateChild",
"newResourceID":"2fe735b026974a13a1bbf00ac710ddef_3310319ae0a54cc9aa4e79079af9bd1b",
"succeed":true,
"newResourceLocation":"http://localhost:8090/iserver/services/spatialAnalysis-BIM2/restjsr/spatialanalyst/datasets/%E7%BB%93%E6%9E%84%E6%9F%B1@8ExportModel/SpatialQuery3D/2fe735b026974a13a1bbf00ac710ddef_3310319ae0a54cc9aa4e79079af9bd1b"
}
Returns the same HTTP response header as the GET request, but no response entity, which can be used to retrieve the meta data contained in response message header without having to transmit the entire response content. Meta data information includes media type, character coding, compression coding, entity content length, etc.
HEAD request is used to determine whether the SpatialQuery3D resource exists, or if the user has the authority to access it. By executing an HEAD request with a .<format> URI, you can quickly determine whether the SpatialQuery3D resource supports the <format> representation.