LTL  2.0.x
Public Member Functions | Protected Member Functions | Protected Attributes | Related Functions | List of all members
ltl::FitsIO Class Reference

FitsIO mother class: things FitsIn and FitsOut have in common. More...

Inherited by ltl::FitsIn, and ltl::FitsOut.

Public Member Functions

 FitsIO (unsigned char *inmemptr, size_t inmemlen)
 Set ltl::FitsIO::filename_ and initialize other members. More...
 
 FitsIO (unsigned char **inmemptr, size_t *inmemlen)
 
 FitsIO (const string &path)
 
string getFilename () const
 Return ltl::FitsIO::filename_ . More...
 
unsigned char * streampos () const
 Return ltl::FitsIO::fitsstreamptr_ . More...
 
size_t getRegionLength () const
 Get number of pixels in selected region. More...
 
size_t getRegionLength (const size_t dim) const
 Get length along dimension dim of selected region in pixels. More...
 
int getRegionStart (const size_t dim) const
 Get start pixel coordinate in dimension dim of selected region. More...
 
int getRegionEnd (const size_t dim) const
 Get end pixel coordinate in dimension dim of selected region. More...
 
util::Region getRegion () const
 Return copy of selected region. More...
 

Protected Member Functions

void checkRegion (const size_t dim) const throw (FitsException)
 Test if dimension dim of region is "retrievable". More...
 

Protected Attributes

string filename_
 Filename associated with FitsIn/Out object. More...
 
unsigned char * fitsinmemptr_
 Pointer to in-memory fits file image. More...
 
size_t fitsinmemlength_
 Length of in-memory fits file. More...
 
unsigned char ** ptrfitsinmemptr_
 In-memory fits file image allocation data. More...
 
size_t * ptrfitsinmemlength_
 
unsigned char * fitsdataptr_
 Pointer to data segment map. More...
 
unsigned char * fitsstreamptr_
 Pointer to actual byte in data segment for per pixel I/O. More...
 
size_t fitsmaplength_
 Length of data segment map, multiple of page size. More...
 
util::Regionregionptr_
 Pointer to Region (if set). More...
 
off_t fitsregionoffset_
 Offset to determine first pixel of selected region. More...
 

Related Functions

(Note that these are not member functions.)

template<>
FitsInoperator>> (FitsIn &infile, FitsOut &outfile)
 
FitsOutoperator<< (FitsOut &outfile, FitsIn &infile)
 
FitsOutoperator<< (FitsOut &outfile, FitsExtensionIn &infile)
 
FitsExtensionOutoperator<< (FitsExtensionOut &outfile, const emptyData_ &)
 
FitsExtensionOutoperator<< (FitsExtensionOut &outfile, FitsIn &infile)
 

Detailed Description

FitsIO mother class: things FitsIn and FitsOut have in common.

Constructor & Destructor Documentation

ltl::FitsIO::FitsIO ( unsigned char *  inmemptr,
size_t  inmemlen 
)

Set ltl::FitsIO::filename_ and initialize other members.

ltl::FitsIO::FitsIO ( unsigned char **  inmemptr,
size_t *  inmemlen 
)
ltl::FitsIO::FitsIO ( const string &  path)

Member Function Documentation

void ltl::FitsIO::checkRegion ( const size_t  dim) const
throw (FitsException
)
protected

Test if dimension dim of region is "retrievable".

string ltl::FitsIO::getFilename ( ) const
inline

Return ltl::FitsIO::filename_ .

References filename_.

unsigned char* ltl::FitsIO::streampos ( ) const
inline
size_t ltl::FitsIO::getRegionLength ( ) const

Get number of pixels in selected region.

Referenced by ltl::getFitsMArray(), and ltl::insertFitsMArray().

size_t ltl::FitsIO::getRegionLength ( const size_t  dim) const

Get length along dimension dim of selected region in pixels.

int ltl::FitsIO::getRegionStart ( const size_t  dim) const

Get start pixel coordinate in dimension dim of selected region.

int ltl::FitsIO::getRegionEnd ( const size_t  dim) const

Get end pixel coordinate in dimension dim of selected region.

Referenced by ltl::insertFitsMArray().

util::Region ltl::FitsIO::getRegion ( ) const

Return copy of selected region.

Referenced by ltl::insertFitsMArray().

Member Data Documentation

string ltl::FitsIO::filename_
protected

Filename associated with FitsIn/Out object.

Referenced by getFilename().

unsigned char* ltl::FitsIO::fitsinmemptr_
protected

Pointer to in-memory fits file image.

size_t ltl::FitsIO::fitsinmemlength_
protected

Length of in-memory fits file.

unsigned char** ltl::FitsIO::ptrfitsinmemptr_
protected

In-memory fits file image allocation data.

size_t* ltl::FitsIO::ptrfitsinmemlength_
protected
unsigned char* ltl::FitsIO::fitsdataptr_
protected

Pointer to data segment map.

unsigned char* ltl::FitsIO::fitsstreamptr_
protected

Pointer to actual byte in data segment for per pixel I/O.

Referenced by ltl::FitsIn::getNextPixel(), ltl::FitsOut::setNextPixel(), and streampos().

size_t ltl::FitsIO::fitsmaplength_
protected

Length of data segment map, multiple of page size.

util::Region* ltl::FitsIO::regionptr_
protected
off_t ltl::FitsIO::fitsregionoffset_
protected

Offset to determine first pixel of selected region.