diff options
Diffstat (limited to 'docs')
| -rw-r--r-- | docs/ref/contrib/gis/geos.txt | 10 | ||||
| -rw-r--r-- | docs/releases/4.1.txt | 3 |
2 files changed, 12 insertions, 1 deletions
diff --git a/docs/ref/contrib/gis/geos.txt b/docs/ref/contrib/gis/geos.txt index 84de1094fc..e8a88014cc 100644 --- a/docs/ref/contrib/gis/geos.txt +++ b/docs/ref/contrib/gis/geos.txt @@ -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:: diff --git a/docs/releases/4.1.txt b/docs/releases/4.1.txt index 28dd574af5..8401103767 100644 --- a/docs/releases/4.1.txt +++ b/docs/releases/4.1.txt @@ -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` ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
