Changeset 1334 in Sophya for trunk/SophyaExt/FitsIOServer/fitsfile.h
- Timestamp:
- Nov 15, 2000, 4:29:11 PM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaExt/FitsIOServer/fitsfile.h
r1300 r1334 55 55 56 56 enum FitsExtensionType { 57 FitsExtensionType_NULL, 57 58 FitsExtensionType_IMAGE, 58 59 FitsExtensionType_ASCII_TBL, 59 FitsExtensionType_BINARY_TBL 60 FitsExtensionType_BINARY_TBL, 61 FitsExtensionType_EOF, 62 FitsExtensionType_ERROR 60 63 }; 61 64 enum FitsDataType { … … 81 84 static void printerror(int&) ; 82 85 static void printerror(int&,char* texte) ; 83 inline void InitNull() {fptr_ = NULL; hdutype_= 0; hdunum_ = 0;86 inline void InitNull() {fptr_ = NULL; hdutype_= FitsExtensionType_NULL; hdunum_ = 0; 84 87 fits_status_ = 0; imageOnPrimary_ = true;} 85 88 fitsfile *fptr_; /**< pointer to the FITS file, defined in fitsio.h */ 86 inthdutype_; /**< image or bintable ? */89 FitsExtensionType hdutype_; /**< image or bintable ? */ 87 90 int hdunum_; /**< index of header to be read/written */ 88 91 int fits_status_; /**< last status returned by fitsio library. updated only by several methods */ … … 102 105 103 106 static int NbBlocks(char flnm[]); 107 int NbBlocks(); 104 108 static void GetBlockType(char flnm[], int hdunum, FitsExtensionType& typeOfExtension, int& naxis, vector<int>& naxisn, FitsDataType& dataType, DVList& dvl ); 105 109 void ReadHeader(int hdunum); … … 126 130 127 131 /*! \return true if the current header corresponds to a FITS image extension */ 128 inline bool IsFitsImage() const { return (hdutype_ == IMAGE_HDU);}132 inline bool IsFitsImage() const { return (hdutype_ == FitsExtensionType_IMAGE);} 129 133 130 134 … … 152 156 153 157 /*! \return true if the current header corresponds to a FITS ASCII or BINTABLE extension */ 154 inline bool IsFitsTable() const {return (hdutype_ == ASCII_TBL || hdutype_ ==BINARY_TBL);}158 inline bool IsFitsTable() const {return (hdutype_ == FitsExtensionType_ASCII_TBL || hdutype_ == FitsExtensionType_BINARY_TBL);} 155 159 156 160 … … 176 180 //////////////////////////////////////////////////////// 177 181 182 /*! \return true if the current header is beyond the maximum */ 183 inline bool IsFitsEOF() const {return (hdutype_ == FitsExtensionType_EOF);} 184 /*! \return true if the current header is incorrect, following a cfitsio, movavs error */ 185 inline bool IsFitsERROR() const {return (hdutype_ == FitsExtensionType_ERROR);} 186 178 187 int NbColsFromFits() const; 179 188 int NentriesFromFits(int nocol) const;
Note:
See TracChangeset
for help on using the changeset viewer.