class documentation

class GeometryField(forms.Field):

Known subclasses: django.contrib.gis.forms.fields.GeometryCollectionField, django.contrib.gis.forms.fields.LineStringField, django.contrib.gis.forms.fields.MultiLineStringField, django.contrib.gis.forms.fields.MultiPointField, django.contrib.gis.forms.fields.MultiPolygonField, django.contrib.gis.forms.fields.PointField, django.contrib.gis.forms.fields.PolygonField

View In Hierarchy

This is the basic form field for a Geometry. Any textual input that is accepted by GEOSGeometry is accepted by this form. By default, this includes WKT, HEXEWKB, WKB (in a buffer), and GeoJSON.
Method __init__ Undocumented
Method clean Validate that the input value can be converted to a Geometry object and return it. Raise a ValidationError if the value cannot be instantiated as a Geometry.
Method has​_changed Compare geographic value of data with its initial value.
Method to​_python Transform the value to a Geometry object.
Class Variable default​_error​_messages Undocumented
Instance Variable geom​_type Undocumented
Instance Variable srid Undocumented

Inherited from Field:

Method __deepcopy__ Undocumented
Method bound​_data Return the value that should be shown for this field on render of a bound form, given the submitted POST data for the field and the initial data, if any.
Method get​_bound​_field Return a BoundField instance that will be used when accessing the form field in a template.
Method prepare​_value Undocumented
Method run​_validators Undocumented
Method validate Undocumented
Method widget​_attrs Given a Widget instance (not a Widget class), return a dictionary of any HTML attributes that should be added to the Widget, based on this Field.
Class Variable default​_validators Undocumented
Class Variable empty​_values Undocumented
Instance Variable disabled Undocumented
Instance Variable error​_messages Undocumented
Instance Variable help​_text Undocumented
Instance Variable initial Undocumented
Instance Variable label Undocumented
Instance Variable label​_suffix Undocumented
Instance Variable localize Undocumented
Instance Variable required Undocumented
Instance Variable show​_hidden​_initial Undocumented
Instance Variable validators Undocumented
Instance Variable widget Undocumented
def __init__(self, *, srid=None, geom_type=None, **kwargs):

Undocumented

def clean(self, value):
Validate that the input value can be converted to a Geometry object and return it. Raise a ValidationError if the value cannot be instantiated as a Geometry.
def has_changed(self, initial, data):
Compare geographic value of data with its initial value.
def to_python(self, value):
Transform the value to a Geometry object.
default_error_messages =
srid =

Undocumented