gisserver.parsers.gml package¶
Additional parsing logic for GML values.
Most GML elements are parsed through GeoDjango by using the GEOSGeometry element.
- class gisserver.parsers.gml.GEOSGMLGeometry(srs: CRS, geos_data: GEOSGeometry)¶
Bases:
GM_ObjectConvert the incoming GML into a Django GEOSGeometry. This tag parses all
<gml:...>geometry elements within the query.- build_rhs(compiler: CompiledQuery)¶
Required function to implement. This allows using the value to be used in a binary operator.
- classmethod from_bbox(bbox_value: str)¶
Parse the bounding box from an input string.
It can either be 4 coordinates, or 4 coordinates with a special reference system.
- classmethod from_xml(element: NSElement)¶
Push the whole <gml:…> element into the GEOS parser. This avoids having to support the whole GEOS logic.
GML is a complex beast with many different forms for the same thing: http://erouault.blogspot.com/2014/04/gml-madness.html
- geos_data: GEOSGeometry¶
- property json¶
- class gisserver.parsers.gml.GM_Envelope¶
Bases:
AstNodeAbstract base classes for the GML envelope, regardless of their version.
- class gisserver.parsers.gml.GM_Object¶
Bases:
AstNodeAbstract base classes for all GML objects, regardless of their version.
- build_rhs(compiler: CompiledQuery)¶
Required function to implement. This allows using the value to be used in a binary operator.
- class gisserver.parsers.gml.TM_Object¶
Bases:
AstNodeAbstract base classes for temporal GML objects, regardless of their version.
See ISO 19108 TM_Object (see D.2.5.2 and ISO 19108:2002, 5.2.2)
- gisserver.parsers.gml.find_gml_nodes(element: NSElement) list[NSElement]¶
Find all
<gml:...>elements in a node. This selects all GML elements, including GML 2.1 tags.
- gisserver.parsers.gml.parse_gml(text: str | bytes) GM_Object | GM_Envelope | TM_Object¶
Parse an XML <gml:…> string.
- gisserver.parsers.gml.parse_gml_node(element: NSElement) GM_Object | GM_Envelope | TM_Object¶
Parse the GML element.