XmlFormat

System for formatting Objects as XML

Description:

This attribute specifies the formatting system to use when AST Objects are written out as XML through an XmlChan. It affects the behaviour of the AST_WRITE routine when they are used to transfer any AST Object to or from an external XML representation.

The XmlChan class allows AST objects to be represented in the form of XML in several ways (conventions) and the XmlFormat attribute is used to specify which of these should be used. The formatting options available are outlined in the " Formats Available" section below.

By default, an XmlChan will attempt to determine which format system is already in use, and will set the default XmlFormat value accordingly (so that subsequent I/O operations adopt the same conventions). It does this by looking for certain critical items which only occur in particular formats. For details of how this works, see the " Choice of Default Format" section below. If you wish to ensure that a particular format system is used, independently of any XML already read, you should set an explicit XmlFormat value yourself.

Type:
String.

Applicability

XmlChan
All XmlChans have this attribute.

Formats Available

The XmlFormat attribute can take any of the following (case insensitive) string values to select the corresponding formatting system:

Choice of Default Format;

If the XmlFormat attribute of an XmlChan is not set, the default value it takes is determined by the presence of certain critical items within the document most recently read using AST_READ. The sequence of decision used to arrive at the default value is as follows:

Setting an explicit value for the XmlFormat attribute always over-rides this default behaviour.

The IVOA Format

The IVOA support caters only for certain parts of V1.20 of the draft Space-Time Coordinate (STC) schema (see http://www.ivoa.net/Documents/WD/STC/STC-20050225.html). Note, this draft has now been superceded by an officially adopted version that differs in several significant respects from V1.20. Consequently, the " IVOA" XmlChan format is of historical interest only.

The following points should be noted when using an XmlChan to read or write STC information (note, this list is currently incomplete):