a container for a set of Miriad (single-) polarization receptor types More...
#include <FillMetadata.h>
Public Member Functions | |
MirPolRecps () | |
virtual | ~MirPolRecps () |
uInt | getPolCount () const |
return the number of distinct single polarization that make up this setup | |
void | addPol (Stokes::StokesTypes pol) |
add a polarization type if it isn't already added. | |
void | addPolsFor (const MirPolCorr &pol) |
add the polarization types involved in the cross-correlation represented by the given correlation type | |
void | addPolsFor (ConstMirPolSetup &pol) |
add the polarization types involved in the cross-correlations represented by the correlation types in the given list | |
Stokes::StokesTypes | getPol (Int i) const |
return the i-th polarization | |
Int | find (Stokes::StokesTypes pol) |
find the position of the given polarization type. | |
Bool | hasPol (Stokes::StokesTypes pol) |
return True if the given polarization is present in this list | |
const List< Stokes::StokesTypes > & | getPols () const |
return the unique list of single polarization types that comprise the correlation types. | |
String | toString (Int i) const |
return a string representing the i-th polarization | |
Static Public Member Functions | |
static String | polToString (Stokes::StokesTypes pol) |
return a string representing the given polarization | |
Private Attributes | |
List< Stokes::StokesTypes > | pols |
ListIter< Stokes::StokesTypes > | iter |
a container for a set of Miriad (single-) polarization receptor types
Internal
the name is short for Miriad Polarization Receptors
This class contains a list of single-polarization types that correspond the types of polarizations a group of receptors are sensitive to.
Single Polarization types are identified using the AIPS' StokesTypes enumeration. For non-true Stokes types, the value for the polarization cross-correlated with itself is used.
Miriad datasets record different polarization measurements in seperate records; thus, there is a notion of a current polarization among several being read. Furthermore, you usually don't know which polarizations are in the dataset until you've read at least one record with each kind of polarization. You do usually know the total number of different polarizations after reading the first record.
Definition at line 553 of file FillMetadata.h.
MirPolRecps::MirPolRecps | ( | ) | [inline] |
Definition at line 559 of file FillMetadata.h.
virtual MirPolRecps::~MirPolRecps | ( | ) | [virtual] |
void MirPolRecps::addPol | ( | Stokes::StokesTypes | pol | ) | [inline] |
add a polarization type if it isn't already added.
Definition at line 567 of file FillMetadata.h.
References hasPol(), and iter.
Referenced by addPolsFor().
void MirPolRecps::addPolsFor | ( | ConstMirPolSetup & | pol | ) | [inline] |
add the polarization types involved in the cross-correlations represented by the correlation types in the given list
Definition at line 583 of file FillMetadata.h.
References addPolsFor(), and ConstMirPolSetup::getCorrs().
void MirPolRecps::addPolsFor | ( | const MirPolCorr & | pol | ) | [inline] |
add the polarization types involved in the cross-correlation represented by the given correlation type
Definition at line 576 of file FillMetadata.h.
References addPol(), MirPolCorr::getFirstPolType(), and MirPolCorr::getSecondPolType().
Referenced by addPolsFor().
Int MirPolRecps::find | ( | Stokes::StokesTypes | pol | ) | [inline] |
find the position of the given polarization type.
-1 is returned if the polarization is not found
Definition at line 597 of file FillMetadata.h.
References iter.
Referenced by hasPol().
Stokes::StokesTypes MirPolRecps::getPol | ( | Int | i | ) | const [inline] |
return the i-th polarization
Definition at line 590 of file FillMetadata.h.
References iter.
Referenced by toString().
uInt MirPolRecps::getPolCount | ( | ) | const [inline] |
return the number of distinct single polarization that make up this setup
Definition at line 564 of file FillMetadata.h.
References pols.
const List<Stokes::StokesTypes>& MirPolRecps::getPols | ( | ) | const [inline] |
return the unique list of single polarization types that comprise the correlation types.
Definition at line 609 of file FillMetadata.h.
References pols.
Bool MirPolRecps::hasPol | ( | Stokes::StokesTypes | pol | ) | [inline] |
return True if the given polarization is present in this list
Definition at line 605 of file FillMetadata.h.
References find().
Referenced by addPol().
static String MirPolRecps::polToString | ( | Stokes::StokesTypes | pol | ) | [inline, static] |
return a string representing the given polarization
Definition at line 615 of file FillMetadata.h.
References casa::name(), and String.
Referenced by toString().
String MirPolRecps::toString | ( | Int | i | ) | const [inline] |
return a string representing the i-th polarization
Definition at line 612 of file FillMetadata.h.
References getPol(), and polToString().
ListIter<Stokes::StokesTypes> MirPolRecps::iter [mutable, private] |
Definition at line 556 of file FillMetadata.h.
List<Stokes::StokesTypes> MirPolRecps::pols [private] |
Definition at line 555 of file FillMetadata.h.
Referenced by getPolCount(), and getPols().