java.lang.Object | |
↳ | com.carto.geometry.GeoJSONGeometryReader |
A GeoJSON parser.
Parser supports Geometry, Feature and FeatureCollection inputs.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
GeoJSONGeometryReader()
Constructs a new GeoJSONGeometryReader object.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
synchronized void | delete() | ||||||||||
Projection |
getTargetProjection()
Returns the current target projection.
| ||||||||||
Feature |
readFeature(String geoJSON)
Reads feature from the specified GeoJSON string.
| ||||||||||
FeatureCollection |
readFeatureCollection(String geoJSON)
Reads feature collection from the specified GeoJSON string.
| ||||||||||
Geometry |
readGeometry(String geoJSON)
Reads geometry from the specified GeoJSON string.
| ||||||||||
void |
setTargetProjection(Projection proj)
Sets the current target projection.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Constructs a new GeoJSONGeometryReader object.
Returns the current target projection. If target projection is set, all geometry
coordinates will be converted from WGS84 to target projection coordinate system.
Reads feature from the specified GeoJSON string.
geoJSON | The GeoJSON string to read. |
---|
Exception | If string could not be parsed. |
---|
Reads feature collection from the specified GeoJSON string.
geoJSON | The GeoJSON string to read. |
---|
Exception | If string could not be parsed. |
---|
Reads geometry from the specified GeoJSON string.
geoJSON | The GeoJSON string to read. |
---|
Exception | If string could not be parsed. |
---|
Sets the current target projection. If target projection is set, all geometry
coordinates will be converted from WGS84 to target projection coordinate system.
proj | The new target projection or null. |
---|