SourceXtractorPlusPlus 0.21
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | Private Attributes | List of all members
SourceXtractor::FitsFile Class Reference

represents access to a whole FITS file and handles loading and caching FITS headers More...

#include <FitsFile.h>

Collaboration diagram for SourceXtractor::FitsFile:
Collaboration graph
[legend]

Public Member Functions

 FitsFile (const boost::filesystem::path &path, bool writeable)
 
 FitsFile (FitsFile &&)=default
 
virtual ~FitsFile ()
 
fitsfilegetFitsFilePtr ()
 
const std::vector< int > & getImageHdus () const
 
std::map< std::string, MetadataEntry > & getHDUHeaders (int hdu)
 
std::vector< intgetDimensions (int hdu) const
 
void refresh ()
 

Private Member Functions

void open ()
 
void loadInfo ()
 
void loadFitsHeader ()
 
void loadHeadFile ()
 

Private Attributes

boost::filesystem::path m_path
 
bool m_is_writeable
 
std::unique_ptr< fitsfile, void(*)(fitsfile *)> m_fits_ptr
 
std::vector< intm_image_hdus
 
std::vector< std::map< std::string, MetadataEntry > > m_headers
 

Detailed Description

represents access to a whole FITS file and handles loading and caching FITS headers

Definition at line 43 of file FitsFile.h.

Constructor & Destructor Documentation

◆ FitsFile() [1/2]

SourceXtractor::FitsFile::FitsFile ( const boost::filesystem::path & path,
bool writeable )

Definition at line 98 of file FitsFile.cpp.

References loadInfo(), and open().

Here is the call graph for this function:

◆ FitsFile() [2/2]

SourceXtractor::FitsFile::FitsFile ( FitsFile && )
default

◆ ~FitsFile()

SourceXtractor::FitsFile::~FitsFile ( )
virtual

Definition at line 105 of file FitsFile.cpp.

Member Function Documentation

◆ getDimensions()

std::vector< int > SourceXtractor::FitsFile::getDimensions ( int hdu) const

Definition at line 325 of file FitsFile.cpp.

References std::unique_ptr< T >::get(), m_fits_ptr, and m_path.

Here is the call graph for this function:

◆ getFitsFilePtr()

fitsfile * SourceXtractor::FitsFile::getFitsFilePtr ( )

Definition at line 107 of file FitsFile.cpp.

References std::unique_ptr< T >::get(), and m_fits_ptr.

Here is the call graph for this function:

◆ getHDUHeaders()

std::map< std::string, MetadataEntry > & SourceXtractor::FitsFile::getHDUHeaders ( int hdu)

Definition at line 115 of file FitsFile.cpp.

References m_headers.

◆ getImageHdus()

const std::vector< int > & SourceXtractor::FitsFile::getImageHdus ( ) const

Definition at line 111 of file FitsFile.cpp.

References m_image_hdus.

◆ loadFitsHeader()

void SourceXtractor::FitsFile::loadFitsHeader ( )
private

Definition at line 245 of file FitsFile.cpp.

References std::unique_ptr< T >::get(), SourceXtractor::loadHeadersFromFits(), m_fits_ptr, and m_headers.

Referenced by loadInfo().

Here is the call graph for this function:

◆ loadHeadFile()

void SourceXtractor::FitsFile::loadHeadFile ( )
private

◆ loadInfo()

void SourceXtractor::FitsFile::loadInfo ( )
private

Definition at line 166 of file FitsFile.cpp.

References std::vector< T >::clear(), std::vector< T >::emplace_back(), std::unique_ptr< T >::get(), loadFitsHeader(), loadHeadFile(), m_fits_ptr, m_headers, m_image_hdus, and m_path.

Referenced by FitsFile(), and refresh().

Here is the call graph for this function:

◆ open()

void SourceXtractor::FitsFile::open ( )
private

Definition at line 119 of file FitsFile.cpp.

References m_fits_ptr, m_is_writeable, m_path, and std::unique_ptr< T >::reset().

Referenced by FitsFile().

Here is the call graph for this function:

◆ refresh()

void SourceXtractor::FitsFile::refresh ( )

Definition at line 143 of file FitsFile.cpp.

References loadInfo(), m_fits_ptr, m_is_writeable, m_path, and std::unique_ptr< T >::reset().

Here is the call graph for this function:

Member Data Documentation

◆ m_fits_ptr

std::unique_ptr<fitsfile, void (*)(fitsfile*)> SourceXtractor::FitsFile::m_fits_ptr
private

Definition at line 63 of file FitsFile.h.

Referenced by getDimensions(), getFitsFilePtr(), loadFitsHeader(), loadInfo(), open(), and refresh().

◆ m_headers

std::vector<std::map<std::string, MetadataEntry> > SourceXtractor::FitsFile::m_headers
private

Definition at line 65 of file FitsFile.h.

Referenced by getHDUHeaders(), loadFitsHeader(), loadHeadFile(), and loadInfo().

◆ m_image_hdus

std::vector<int> SourceXtractor::FitsFile::m_image_hdus
private

Definition at line 64 of file FitsFile.h.

Referenced by getImageHdus(), loadHeadFile(), and loadInfo().

◆ m_is_writeable

bool SourceXtractor::FitsFile::m_is_writeable
private

Definition at line 62 of file FitsFile.h.

Referenced by open(), and refresh().

◆ m_path

boost::filesystem::path SourceXtractor::FitsFile::m_path
private

Definition at line 61 of file FitsFile.h.

Referenced by getDimensions(), loadHeadFile(), loadInfo(), open(), and refresh().


The documentation for this class was generated from the following files: