Data Transfer Project

This was an XML (eXtensible Markup Language) self-education exercise. XML is a computer language that uses tags to define elements within a document making it both human-readable and machine-readable.

The aim was to gain an understanding of XML and create a working and valid XML document. It became evident that an XML document needs an XML Schema Definition (XSD) document to fully specify the elements in the XML document. The scope of the project was expanded to include understanding and creating the companion XSD document.

In view of the variety of file formats used by agencies and websites to collect weather data from PWS around the world, it was a simple choice to develop an experimental data exchange format that satisfied all known requirements. It was intended that our PWS software would be programmed to automatically generate the data exchange format at regular intervals.

Project Stages

The stages of the project were as follows:

  1. Match variables with the required station details and weather data,
  2. Create an XML Schema Definition (XSD) document specifying the structure of the new XML Data Transfer Document (or data-xfer-xml), and
  3. Finalise the template file.

Project Variables

The variables used in this project are listed below. Select a variable to view the complete XML element definition, including: the element name and description, the expected data type, the permitted values where explicitly defined, and whether the element is mandatory or optional.

The variables in the template file are replaced with the equivalent output tags from the PWS software. If a variable has no equivalent output tag from the PWS software, the options are to: (1) create a user-defined output tag for the PWS software containing the appropriate value, or (2) replace the variable in the template file with the appropriate value. If an optional variable is permanently unavailable, the template file is edited as per this example - replace <foo>%variable%</foo> with <foo />.

Top of page up arrow

XML Schema Definition

View the XSD diagram for this project.

Template File

Download template (right click on the link and select "Save link as"): data transfer template.

Project Status

See a live example using data-xfer-xml. This document is routinely generated for personal interest only.

This 2014 project is closed.

Top of page up arrow