← Back to list

GIS data Formats and the Role of XML and GML

Geographic Information Systems (GIS) employ specialized data formats to store and process spatial information. Among these, the Geography…

Onyeka Onwuama · 2024-12-30 00:58 · 2 claps · 2.1 min read
#xml #gml #gis #technology
Open on Medium ↗

GIS data Formats and the Role of XML and GML

Image source

Image source

Geographic Information Systems (GIS) employ specialized data formats to store and process spatial information. Among these, the Geography Markup Language (GML) is particularly significant as an open standard developed by the Open Geospatial Consortium (OGC). GML’s distinction comes from its basis in XML (Extensible Markup Language), a technology standardized by the World Wide Web Consortium (W3C).

While the early web relied on HTML (Hypertext Markup Language) to format and display content through elements like headings and paragraphs, XML and by extension GML take a more sophisticated approach. Rather than just controlling how information appears visually, these languages capture the underlying structure and semantics of the data itself, making it more meaningful and useful for complex geographic applications.

1. What is XML?

XML stands for Extensible Markup Language and is a text-based markup language. It is widely used for storing and transporting structured data.

To understand XML as a markup language, consider that “markup” refers to the set of symbols or tags embedded within a document to indicate its structure, elements, or formatting. These tags are processed by machines to render, interpret, or manipulate the content, even though they are not visible to the end user.

Example of XML

<book genre="technology" published="2023">
    <title>XML Instructions</title>
    <author>John Doe</author>
</book>

In this example:

  • <book>, <title>, and <author> are the markup elements, also referred to as tags.
  • XML Instructionsand John Doe are the content stored and/or transported.
  • genre and published are attributes of the <book> element.

XML is a versatile format used in many applications, including configuration files, data exchange, and document representation.

2. What is GML?

2.1 Status

GML (Geography Markup Language) is an XML-based encoding standard for geographic information. It is widely used for exchanging spatial information, including maps, locations, and geographical features, in a standardized format.

2.2 Geography, Graphics, and Maps

GML is designed to represent the content of geographic data, encompassing both:

  1. Geometry — Spatial representations such as points, lines, and polygons.
  2. Attributes — Non-spatial properties of geographic features, such as names or descriptions.

The GML specification defines mechanisms and syntax for recording geographic information in XML, enabling the representation of:

  • Complex features (e.g., cities or rivers).
  • Feature collections (e.g., groups of land parcels).
  • Feature associations (e.g., relationships between roads and intersections).

Example of GML

A city encoded in GML might include its geometry and additional attributes:

<gml:featureMember>
    <city>
        <gml:name>Springfield</gml:name>
        <postcode>12345</postcode>
        <gml:Point>
            <gml:coordinates>40.7128,-74.0060</gml:coordinates>
        </gml:Point>
    </city>
</gml:featureMember>

In this example:

  • <gml:featureMember> represents a geographic feature.
  • <city> defines the feature type, with attributes like name and postcode.
  • <gml:Point> specifies the geographic location using coordinates.

Why Use XML and GML in GIS?

  • Interoperability: XML and GML allow seamless data exchange between different systems and software.
  • Standardization: GML ensures geographic data is represented in a uniform way.
  • Flexibility: Both formats are extensible and can be tailored to specific needs.

By leveraging XML and GML, GIS professionals can effectively encode, transport, and share geographic data across platforms, ensuring accuracy and consistency in geospatial applications.


메타데이터
post_id
165cb8ce75ea
slug
gis-data-formats-and-the-role-of-xml-and-gml-165cb8ce75ea
url
https://medium.com/@onyekao/gis-data-formats-and-the-role-of-xml-and-gml-165cb8ce75ea
canonical_url
https://medium.com/@onyekao/gis-data-formats-and-the-role-of-xml-and-gml-165cb8ce75ea
author_url
https://medium.com/@onyekao
status
ok
fetched_at
2026-06-26 21:52:29