Refs #28020 -- Removed obsolete GeometryCollection.json.
Unused since 12d0567aa5
.
This commit is contained in:
parent
e19b9d6015
commit
815a0bb80d
|
@ -2,7 +2,6 @@
|
||||||
This module houses the Geometry Collection objects:
|
This module houses the Geometry Collection objects:
|
||||||
GeometryCollection, MultiPoint, MultiLineString, and MultiPolygon
|
GeometryCollection, MultiPoint, MultiLineString, and MultiPolygon
|
||||||
"""
|
"""
|
||||||
import json
|
|
||||||
from ctypes import byref, c_int, c_uint
|
from ctypes import byref, c_int, c_uint
|
||||||
|
|
||||||
from django.contrib.gis.geos import prototypes as capi
|
from django.contrib.gis.geos import prototypes as capi
|
||||||
|
@ -78,19 +77,6 @@ class GeometryCollection(GEOSGeometry):
|
||||||
_set_single = GEOSGeometry._set_single_rebuild
|
_set_single = GEOSGeometry._set_single_rebuild
|
||||||
_assign_extended_slice = GEOSGeometry._assign_extended_slice_rebuild
|
_assign_extended_slice = GEOSGeometry._assign_extended_slice_rebuild
|
||||||
|
|
||||||
@property
|
|
||||||
def json(self):
|
|
||||||
if self.__class__.__name__ == 'GeometryCollection':
|
|
||||||
return json.dumps({
|
|
||||||
'type': self.__class__.__name__,
|
|
||||||
'geometries': [
|
|
||||||
{'type': geom.__class__.__name__, 'coordinates': geom.coords}
|
|
||||||
for geom in self
|
|
||||||
],
|
|
||||||
})
|
|
||||||
return super().json
|
|
||||||
geojson = json
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def kml(self):
|
def kml(self):
|
||||||
"Return the KML for this Geometry Collection."
|
"Return the KML for this Geometry Collection."
|
||||||
|
|
Loading…
Reference in New Issue