Changeset 2008 for trunk/doc/pslib/psLibSDRS.tex
- Timestamp:
- Oct 7, 2004, 10:21:29 AM (22 years ago)
- File:
-
- 1 edited
-
trunk/doc/pslib/psLibSDRS.tex (modified) (10 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/doc/pslib/psLibSDRS.tex
r2007 r2008 1 %%% $Id: psLibSDRS.tex,v 1.1 29 2004-10-07 19:55:20eugene Exp $1 %%% $Id: psLibSDRS.tex,v 1.130 2004-10-07 20:21:29 eugene Exp $ 2 2 \documentclass[panstarrs,spec]{panstarrs} 3 3 … … 1232 1232 PS_TYPE_C32, ///< Complex numbers consisting of floats 1233 1233 PS_TYPE_C64, ///< Complex numbers consisting of doubles 1234 PS_TYPE_STR, ///< String1235 PS_TYPE_BOOL, ///< Boolean1236 PS_TYPE_OTHER ///< Not supported for arithmetic1237 1234 } psElemType; 1238 1235 \end{verbatim} … … 1259 1256 psC64 C64; ///< double complex value entry 1260 1257 } data; 1261 } p _psScalar;1258 } psScalar; 1262 1259 \end{verbatim} 1263 1260 … … 3617 3614 psF32 F32; ///< floating value 3618 3615 psF64 F64; ///< double value 3619 void * void; ///< other type3616 void *data; ///< other type 3620 3617 } data; ///< value of metadata 3621 3618 char *comment; ///< optional comment ("", not NULL) … … 3640 3637 PS_META_F32, ///< float (.F32) 3641 3638 PS_META_F64, ///< double (.F64) 3642 PS_META_STR, ///< string (. void)3643 PS_META_ IMG, ///< image (.void)3644 PS_META_JPEG, ///< JPEG (. void)3645 PS_META_PNG, ///< PNG (. void)3646 PS_META_ASTROM, ///< astrometric coefficients (. void)3647 PS_META_UNKNOWN, ///< other (. void)3639 PS_META_STR, ///< string (.data) 3640 PS_META_MATH, ///< psScalar, psVector, psImage (.data) 3641 PS_META_JPEG, ///< JPEG (.data) 3642 PS_META_PNG, ///< PNG (.data) 3643 PS_META_ASTROM, ///< astrometric coefficients (.data) 3644 PS_META_UNKNOWN, ///< other (.data) 3648 3645 PS_META_NTYPE ///< Number of types; must be last 3649 3646 } psMetadataType; … … 3826 3823 3827 3824 \begin{verbatim} 3828 int psMetadataParseConfig(psMetadata *md, const char *filename, bool overwrite);3825 psMetadata *psMetadataParseConfig(psMetadata *md, int *nFail, const char *filename, bool overwrite); 3829 3826 \end{verbatim} 3830 3827 … … 3832 3829 file, \code{filename}, \code{psMetadataParseConfig} shall parse the 3833 3830 configuration file, placing the contained key/type/value/comment quads 3834 into the metadata, and returning the number of lines that failed to 3835 parse. Multiple specifications of a key that haven't been declared 3836 (see below) are overwritten if and only if \code{overwrite} is 3837 \code{true}. 3838 3839 If the metadata container is \code{NULL}, it shall be allocated. If 3840 the file specified by \code{filename} is not readable, then the 3841 function shall generate an error and return \code{-1}. 3831 into the metadata, and returning a pointer to the metadata structure. 3832 The number of lines that failed to parse is returned in \code{nFail}. 3833 Multiple specifications of a key that haven't been declared (see 3834 below) are overwritten if and only if \code{overwrite} is \code{true}. 3835 If the metadata container is \code{NULL}, it shall be allocated. 3836 3837 On error, the function shall return \code{NULL}. 3842 3838 3843 3839 The configuration file shall consist of plain text with … … 3893 3889 by specifying the key at the start of the line (possibly preceded by 3894 3890 whitespace) and specifying the type as a ``multiple symbol'', which we 3895 choose to be an asterisk, \code{*}. Everything else on the line shall 3896 be ignored. A warning shall be produced when a key which has not been 3891 choose to be an asterisk, \code{*}. No other data may be provided on 3892 this line, though a comment, preceeded by the comment marker, is 3893 valid. A warning shall be produced when a key which has not been 3897 3894 specified to be non-unique is repeated; in this case, the former value 3898 3895 shall be overwritten if \code{overwrite} is \code{true}, otherwise the … … 3904 3901 (including those that were ignored because \code{overwrite} is 3905 3902 \code{false}, and any other parsing problems, but not including blank 3906 lines and comment lines) shall be returned by the function. 3903 lines and comment lines) shall be returned by the function in the 3904 argument \code{nFail}. 3907 3905 3908 3906 Here are some examples of lines of a valid configuration file: … … 3917 3915 @primes U8 2,3 5 7,11,13 17 # These are prime numbers 3918 3916 3919 comment * The rest of this line is ignored, but `comment' is set to be non-unique3917 comment * # This is a comment in the ITEM_SET item 3920 3918 comment STR This 3921 3919 comment STR is
Note:
See TracChangeset
for help on using the changeset viewer.
