public class GetFeaturesByGeometryParameters extends GetFeaturesParametersBase
数据集几何查询参数类。
几何查询就是查询与指定几何对象符合一定空间关系的矢量要素。该类主要用于设置对数据集进行几何查询的参数,包括几何对象、空间关系、要查询的数据集集合等。
限定符和类型 | 字段和说明 |
---|---|
java.lang.String |
attributeFilter
几何查询属性过滤条件,相当于 SQL 语句中的 WHERE 子句。
|
java.lang.String[] |
fields
设置结果返回字段。
|
Geometry |
geometry
用于几何查询的几何对象,必设参数。
|
SpatialQueryMode |
spatialQueryMode
空间查询模式常量,必设参数。
|
datasetNames, fromIndex, returnContent, toIndex
构造器和说明 |
---|
GetFeaturesByGeometryParameters()
构造函数。
|
public java.lang.String attributeFilter
几何查询属性过滤条件,相当于 SQL 语句中的 WHERE 子句。 其格式为:WHERE 条件表达式,attributeFilter 就是其中的“条件表达式”。该字段的用法为 attributeFilter = "过滤条件"。 例如,要查询字段 fieldValue 小于100的记录,设置 attributeFilter = "fieldValue < 100";要查询字段 name 的值为“酒店”的记录,设置 attributeFilter = "name like '%酒店%'",等等。 用户在设置该字段时,仅需要输入“条件表达式”即可,如:fieldValue < 100。 若不设置该属性则返回与指定几何对象符合某种空间关系的所有要素。
public java.lang.String[] fields
设置结果返回字段。 当指定了返回结果字段后,则 GetFeaturesResult 中的 features 的属性字段只包含所指定的字段。不设置即返回全部字段。
public Geometry geometry
用于几何查询的几何对象,必设参数。
public SpatialQueryMode spatialQueryMode
空间查询模式常量,必设参数。 默认为CONTAIN。