next up previous contents
Next: Examples Up: Free Time Format Specification Previous: Overview   Contents

Subsections

Key Strings

The following provides an exhaustive list of Key Strings used in Free Time Format input. Note that the key strings are in the order in which QIE searches to find them in `TIME_FORMAT_STRING', and NOT necessarily the order in which they actually appear therein.

Date Key Strings

YYYY
4-digit year specification. If found, no attempt is made to locate a 2-digit year.
YY
2-digit year. If no 4-digit year is found, this string is sought. If this format is used the YY_offset parameter must also be set. This format should be avoided where possible as it is intrinsically not year 2000 compliant. An error is returned if this format is used without the YY_offset parameter being set.

Doy
3-digit day of the year. If available, this is used for input, and values obtained are converted into month and day in the given year, with leap years treated correctly. Any other month/day specifiers are ignored. Note the lower case `oy' which avoids conflict with year key strings.
MON
3-character month string. The values expected are: ``JAN", ``FEB", ``MAR", ``APR", ``MAY", ``JUN", ``JUL" or ``JLY", ``AUG", ``SEP", ``OCT", ``NOV", ``DEC", but values in the data file are case-insensitive as they are converted to uppercase prior to conversion to numeric month. If `MON' is present, QIE will not look for the 2-digit month.
MO
2-digit numeric month. Only sought if key string `MON' is not found in `TIME_FORMAT_STRING'.
DD
2-digit numeric day.

Time Key Strings

Time key strings can have any length. The descriptions below show the repeat character with an overbar, e.g., $\overline{\rm H}$ means H, HH, HHH, HHHH, etc. are all allowed. Whole and fractional parts may be specified separately. Fractional parts are assumed to contain no decimal point and are multiplied by $10^{- {\rm field\ width}}$. All values are converted from the input string using the C-library function atof.

$\overline{\tt H}$
n-digit whole or decimal hour (n$\geq$1). Typically `HH' but could be `HHHHH' to read in `17.37' hours.
M $\overline{\tt I}$
n-digit whole or decimal minutes (n$\geq$2, i.e., at least one `I' must be present). `MIII' would read in `28.4' minutes.
$\overline{\tt S}$
n-digit whole or decimal seconds (n$\geq$1).
M $\overline{\tt C}$
n-digit whole or decimal milliseconds (n$\geq$2, i.e., at least one `C' must be present).
$\overline{\tt d}$
n-digit fractional day (n$\geq$1). `ddd' would read in `667' as 0.667 of a day.
$\overline{\tt h}$
n-digit fractional hour (n$\geq$1). `hh' would read in `78' as 0.78 of an hour.
$\overline{\tt m}$
n-digit fractional minute (n$\geq$1). `mmm' would read in `234' as 0.234 of a minute.
$\overline{\tt s}$
n-digit fractional second (n$\geq$1). `sss' would read in `567' as 0.567 of a second.
$\overline{\tt c}$
n-digit fractional millisecond (n$\geq$1). `c' would read in `9' as 0.9 of a millisecond.

Pad Characters

Any character not used in the Date or Time Key Strings can be used in the `TIME_FORMAT_STRING' as a pad character. To ease future enhancements, however, we recommend that such characters be restricted to the letters `X', `T', `Z', $<$space$>$, and punctuation (e.g, ``:''). Note, however, that leading and trailing $<$space$>$ characters are stripped off of the `TIME_FORMAT_STRING' but NOT off of the data value itself, thus a non-$<$space$>$ pad character should be used if required at the leading and trailing ends of the `TIME_FORMAT_STRING'. This is illustrated in the examples below.


next up previous contents
Next: Examples Up: Free Time Format Specification Previous: Overview   Contents
Anthony Allen 2002-04-16