General Form of MOS Internal File Formats
Ideally all communication would be done via
FITS tables.
Unfortunately FITS tables are not possible to edit with
many text editors, and not everyone has access to
FTOOLS or the STSDAS
tables package.
Instead we define ASCII text files with inspiration drawn from FITS tables.
These are intended to be easy to create and edit. A rough specification
of these files follows.
The first line of a file
The first line of a file must be a ``Magic Number'' in the sense used by
the Unix file program. This is a specific character string
which identifies the file format and version.
Blanks and comments
Blank lines will be ignored.
Unless otherwise specified all lines whose first non-blank character
is `#' (ASCII 043 = 0x23 = 35) will be ignored.
Comments and blank lines for purposes of separation may thus be
inserted anywhere in a file.
Keyword/Value pairs
Keywords will be case insensitive strings with no embedded blanks
followed immediately by a colon. Values will be the remainder of
the line following the colon.
Tables
Files are permitted to contain one table following the keyword/value
pairs. The beginning of the table is marked by another line
containing a magic number.
The design of these tables should consider the probable maximum line
length of each entry. Whenever possible this should be kept within
limits that are comfortable for text editors.
The order of the table columns must match
that expected by the reading software. Column entries may not contain
embedded whitespace. Quoted strings are not permitted. The final
column in the table may be an exception; if interpreted as a string it
may contain arbitrary strings with embedded whitespace.
Back to the MOS home page.
Steve Allen <sla@ucolick.org>