Module: ol/format/GeoJSON

ol/format/GeoJSON


Classes

GeoJSON

Type Definitions

GeoJSONGeometryCollection{module:geojson~GeoJSON}

Options{Object}

Properties:
Name Type Description
dataProjection ProjectionLike
(defaults to 'EPSG:4326')

默认数据投影。

featureProjection ProjectionLike | undefined

格式读取或写入要素时使用的投影。传递给读取或写入方法的选项将优先。

geometryName string | undefined

创建要素时使用的几何图形名称。

extractGeometryName boolean
(defaults to false)

某些 GeoJSON 提供者在要素 GeoJSON 中包含 geometry_name 字段。如果设置为 true,GeoJSON 读取器将查找该字段来设置几何图形名称。如果此字段设置为 true 且提供了 geometryName,则 geometryName 优先。

featureClass 要素To要素Class<要素Type> | undefined

读取要素时要使用的要素类。默认为 要素。如果主要关注性能,且要素不会被修改或通过格式进行往返转换,请考虑使用 渲染要素