mirror of
https://github.com/django/django.git
synced 2025-10-17 13:58:24 +00:00
Fixed #33136 -- Added GEOSGeometry.make_valid() method.
This commit is contained in:
parent
fb05ca420d
commit
4ffada3609
6 changed files with 45 additions and 5 deletions
|
@ -655,6 +655,16 @@ Other Properties & Methods
|
|||
doesn't impose any constraints on the geometry's SRID if called with a
|
||||
:class:`~django.contrib.gis.gdal.CoordTransform` object.
|
||||
|
||||
.. method:: GEOSGeometry.make_valid()
|
||||
|
||||
.. versionadded:: 4.1
|
||||
|
||||
Returns a valid :class:`GEOSGeometry` equivalent, trying not to lose any of
|
||||
the input vertices. If the geometry is already valid, it is returned
|
||||
untouched. This is similar to the
|
||||
:class:`~django.contrib.gis.db.models.functions.MakeValid` database
|
||||
function. Requires GEOS 3.8.
|
||||
|
||||
.. method:: GEOSGeometry.normalize()
|
||||
|
||||
Converts this geometry to canonical form::
|
||||
|
|
|
@ -53,7 +53,8 @@ Minor features
|
|||
:mod:`django.contrib.gis`
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
* ...
|
||||
* The new :meth:`.GEOSGeometry.make_valid()` method allows converting invalid
|
||||
geometries to valid ones.
|
||||
|
||||
:mod:`django.contrib.messages`
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue