42 const int& hdunum = 0);
86 const GFitsHDU*
at(
const std::string& extname)
const;
102 void remove(
const int&
extno);
103 void remove(
const std::string& extname);
106 bool contains(
const int& extno)
const;
107 bool contains(
const std::string& extname)
const;
109 int extno(
const std::string& extname)
const;
111 const bool& create =
false);
112 void save(
const bool& clobber =
false);
114 const bool& clobber =
false);
117 const std::string& name =
"")
const;
118 void publish(
const std::string& extname,
119 const std::string& name =
"")
const;
175 return (
m_hdu[extno]);
191 return (
m_hdu[extno]);
239 return (
int)
m_hdu.size();
253 return (
m_hdu.empty());
284 return (extno >= 0 && extno <
size());
300 return (
extno(extname) != -1);
std::vector< GFitsHDU * > m_hdu
Pointers to HDUs.
GFitsImage * new_image(void)
Allocate new FITS image and return memory pointer.
GFitsHDU * at(const int &extno)
Get pointer to HDU.
Abstract FITS image base class.
GFitsTable * table(const int &extno)
Get pointer to table HDU.
GFits(void)
Void constructor.
bool contains(const int &extno) const
Check if HDU exists in FITS file.
void clear(void)
Clear FITS file.
Abstract FITS extension base class.
const GFilename & filename(void) const
Return FITS filename.
GFilename m_filename
FITS file name.
GFits & operator=(const GFits &fits)
Assignment operator.
Abstract FITS image base class definition.
Abstract FITS extension base class definition.
void saveto(const GFilename &filename, const bool &clobber=false)
Saves to specified FITS file.
GFitsImage * new_primary(void)
Return minimal primary HDU.
void save(const bool &clobber=false)
Saves FITS file.
GFits * clone(void) const
Clone FITS file.
GFitsHDU * operator[](const int &extno)
Get pointer to HDU.
void open(const GFilename &filename, const bool &create=false)
Open or (optionally) create FITS file.
void publish(const int &extno, const std::string &name="") const
Publish FITS HDU on VO Hub.
void free_members(void)
Delete class members.
Abstract interface for FITS table.
GFitsImage * image(const int &extno)
Get pointer to image HDU.
void reserve(const int &num)
Reserves space for HDUs in FITS file.
void init_members(void)
Initialise class members.
bool is_empty(void) const
Signals if there are no HDUs in FITS file.
int size(void) const
Return number of HDUs in FITS file.
GFitsHDU * insert(const int &extno, const GFitsHDU &hdu)
Set HDU for the specified extension number.
virtual ~GFits(void)
Destructor.
bool m_created
FITS file has been created (true/false)
bool m_readwrite
FITS file is readwrite (true/false)
GFitsHDU * append(const GFitsHDU &hdu)
Append HDU to FITS file.
std::string classname(void) const
Return class name.
void copy_members(const GFits &fits)
Copy class members.
Definition of interface for container classes.
int fits_move_to_hdu(const std::string &caller, void *vptr, const int &hdunum=0)
Move to FITS extension.
GFitsHDU * set(const int &extno, const GFitsHDU &hdu)
Set HDU for the specified extension number.
std::string print(const GChatter &chatter=NORMAL) const
Print FITS information.
void close(void)
Close FITS file.
int extno(const std::string &extname) const
Return extension number for specified extension name.
Interface class for container classes.
Filename class interface definition.
void * m_fitsfile
FITS file pointer.
void extend(const GFits &fits)
Append FITS file.
FITS table abstract base class interface definition.