CCfits - HEASARC - NASA
CCfits - HEASARC - NASA
CCfits - HEASARC - NASA
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
24.14 <strong>CCfits</strong>::FITS Class Reference 86<br />
This basic constructor makes a FITS object from the given filename. The file name<br />
is the only required argument. The file name string is passed directly to the cfitsio<br />
library: thus the extended file name syntax described in the cfitsio manual should work<br />
as documented. (Though the extended file name feature which allows the opening of a<br />
particular image located in the row of a table is currently unsupported.)<br />
If the mode is Read [default]: It will read all of the headers in the file, and all of the<br />
data if the readDataFlag is supplied as true. It will also read optional primary keys.<br />
Upon completion, the the last header in the file will become the current extension. (-<br />
However if the file name includes extended syntax selecting a particular extension, that<br />
extension will be the current one.)<br />
If the mode is Write and the file already exists: The file is opened in read-write mode,<br />
all of the headers of the file are read, and all of the data if the readDataFlag is supplied<br />
as true. It will also read optional primary keys. For backwards compatibility with older<br />
versions of <strong>CCfits</strong> (which only read the primary when in Write mode for pre-existing<br />
files), the primary will become the current extension.<br />
If the mode is Write and the file does NOT exist (or is overwritten using ’!’ syntax):<br />
A default primary HDU will be created in the file with BITPIX=8 and NAXIS=0. -<br />
However if you wish to create a new file with image data in the primary, the version<br />
of the FITS constructor that specifies the data type and number of axes should be used<br />
instead.<br />
Parameters<br />
name The name of the FITS file to be read/written<br />
mode The read/write mode: must be Read or Write<br />
readData- boolean: read data on construction if true<br />
Flag<br />
primaryKeys Allows optional reading of primary header keys on construction<br />
Exceptions<br />
NoSuchHDU thrown on HDU seek error either by index or {name,version}<br />
FitsError thrown on non-zero status code from cfitsio when not overriden by<br />
FitsException error to produce more illuminating message.<br />
24.14.2.2 <strong>CCfits</strong>::FITS::FITS ( const String & name, RWmode mode, const string &<br />
hduName, bool readDataFlag = false, const std::vector< String > & hduKeys =<br />
std::vector(), const std::vector< String > & primaryKey =<br />
std::vector(), int version = 1 )<br />
Open a FITS file and read a single specified HDU.<br />
This and similar constructor variants support reading table data.<br />
Optional arguments allow the reading of primary header keys and specified data from<br />
Generated on Tue Dec 6 2011 16:12:51 for <strong>CCfits</strong> by Doxygen