casacore
Public Member Functions | Private Attributes | List of all members
casacore::MSPrimaryTableHolder Class Reference

More...

#include <MSFitsInput.h>

Public Member Functions

 MSPrimaryTableHolder ()
 This is a helper class to avoid cumbersome switch statements on the template type of the primary array It forwards all the PrimaryTable member function we need in the filler. More...
 
 MSPrimaryTableHolder (FitsInput &infile)
 Construct from an input file containing a FITS primary group hdu. More...
 
 ~MSPrimaryTableHolder ()
 
void attach (FitsInput &infile)
 Attach to the input file, create the appropriate PrimaryArray. More...
 
void detach ()
 Detach from the input file. More...
 
Int dims ()
 Number of dimensions. More...
 
Int dim (Int i)
 Length of i'th axis. More...
 
Charctype (Int i)
 Coordinate type. More...
 
Double crval (Int i)
 Coordinate reference value. More...
 
Double crpix (Int i)
 Coordinate reference pixel. More...
 
Double cdelt (Int i)
 Coordinate delta. More...
 
const FitsKeywordkw (const FITS::ReservedName &n)
 Keyword of given type. More...
 
ConstFitsKeywordListkwlist ()
 All keywords. More...
 
const FitsKeywordnextkw ()
 Advance to next keyword. More...
 
Int read ()
 Read the next group. More...
 

Private Attributes

HeaderDataUnithdu_p
 
PrimaryTable< Short > * ps
 
PrimaryTable< FitsLong > * pl
 
PrimaryTable< Float > * pf
 
PrimaryTable< uChar > * pb
 

Detailed Description

A helper class for MSFitsInput

Intended use:

Internal

Etymology

This class can hold a primary array of several datatypes

Synopsis

This is a helper class to avoid cumbersome switch statements on the template type of the primary array It forwards all the PrimaryArray member functions we need in the filler.

Definition at line 65 of file MSFitsInput.h.

Constructor & Destructor Documentation

◆ MSPrimaryTableHolder() [1/2]

casacore::MSPrimaryTableHolder::MSPrimaryTableHolder ( )

This is a helper class to avoid cumbersome switch statements on the template type of the primary array It forwards all the PrimaryTable member function we need in the filler.

Construct an empty holder, used to attach to later

◆ MSPrimaryTableHolder() [2/2]

casacore::MSPrimaryTableHolder::MSPrimaryTableHolder ( FitsInput infile)

Construct from an input file containing a FITS primary group hdu.

Throws an exception if the datatype is not Short, FitsLong or Float

◆ ~MSPrimaryTableHolder()

casacore::MSPrimaryTableHolder::~MSPrimaryTableHolder ( )

Member Function Documentation

◆ attach()

void casacore::MSPrimaryTableHolder::attach ( FitsInput infile)

Attach to the input file, create the appropriate PrimaryArray.

Throws an exception if the datatype is not Short, FitsLong or Float

◆ cdelt()

Double casacore::MSPrimaryTableHolder::cdelt ( Int  i)
inline

Coordinate delta.

Definition at line 110 of file MSFitsInput.h.

References casacore::PrimaryArray< TYPE >::cdelt(), pf, pl, and ps.

◆ crpix()

Double casacore::MSPrimaryTableHolder::crpix ( Int  i)
inline

Coordinate reference pixel.

Definition at line 106 of file MSFitsInput.h.

References casacore::PrimaryArray< TYPE >::crpix(), pf, pl, and ps.

◆ crval()

Double casacore::MSPrimaryTableHolder::crval ( Int  i)
inline

Coordinate reference value.

Definition at line 102 of file MSFitsInput.h.

References casacore::PrimaryArray< TYPE >::crval(), pf, pl, and ps.

◆ ctype()

Char* casacore::MSPrimaryTableHolder::ctype ( Int  i)
inline

Coordinate type.

Definition at line 98 of file MSFitsInput.h.

References casacore::PrimaryArray< TYPE >::ctype(), pf, pl, and ps.

◆ detach()

void casacore::MSPrimaryTableHolder::detach ( )

Detach from the input file.

◆ dim()

Int casacore::MSPrimaryTableHolder::dim ( Int  i)
inline

Length of i'th axis.

Definition at line 94 of file MSFitsInput.h.

References casacore::HeaderDataUnit::dim(), and hdu_p.

◆ dims()

Int casacore::MSPrimaryTableHolder::dims ( )
inline

Number of dimensions.

Definition at line 90 of file MSFitsInput.h.

References casacore::HeaderDataUnit::dims(), and hdu_p.

◆ kw()

const FitsKeyword* casacore::MSPrimaryTableHolder::kw ( const FITS::ReservedName n)
inline

Keyword of given type.

Definition at line 114 of file MSFitsInput.h.

References hdu_p, and casacore::HeaderDataUnit::kw().

◆ kwlist()

ConstFitsKeywordList& casacore::MSPrimaryTableHolder::kwlist ( )
inline

All keywords.

Definition at line 118 of file MSFitsInput.h.

References hdu_p, and casacore::HeaderDataUnit::kwlist().

◆ nextkw()

const FitsKeyword* casacore::MSPrimaryTableHolder::nextkw ( )
inline

Advance to next keyword.

Definition at line 122 of file MSFitsInput.h.

References hdu_p, and casacore::HeaderDataUnit::nextkw().

◆ read()

Int casacore::MSPrimaryTableHolder::read ( )
inline

Read the next group.

Definition at line 126 of file MSFitsInput.h.

References pb, pf, pl, ps, and casacore::PrimaryTable< TYPE >::read().

Member Data Documentation

◆ hdu_p

HeaderDataUnit* casacore::MSPrimaryTableHolder::hdu_p
private

Definition at line 136 of file MSFitsInput.h.

Referenced by dim(), dims(), kw(), kwlist(), and nextkw().

◆ pb

PrimaryTable<uChar>* casacore::MSPrimaryTableHolder::pb
private

Definition at line 140 of file MSFitsInput.h.

Referenced by read().

◆ pf

PrimaryTable<Float>* casacore::MSPrimaryTableHolder::pf
private

Definition at line 139 of file MSFitsInput.h.

Referenced by cdelt(), crpix(), crval(), ctype(), and read().

◆ pl

PrimaryTable<FitsLong>* casacore::MSPrimaryTableHolder::pl
private

Definition at line 138 of file MSFitsInput.h.

Referenced by cdelt(), crpix(), crval(), ctype(), and read().

◆ ps

PrimaryTable<Short>* casacore::MSPrimaryTableHolder::ps
private

Definition at line 137 of file MSFitsInput.h.

Referenced by cdelt(), crpix(), crval(), ctype(), and read().


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