casa::PlotMSFlagging Class Reference

#include <PlotMSFlagging.h>

Collaboration diagram for casa::PlotMSFlagging:

Collaboration graph
[legend]
List of all members.

Detailed Description

Specifies flagging parameters (including possibly flag extension) for an MS.

Definition at line 43 of file PlotMSFlagging.h.
 fields
 fieldStrings
 field
 extend
 correlation
correlation __pad0__:all"
correlation correlation:poln-dep"
correlation channel
correlation spw
correlation antenna
correlation time
correlation scans
correlation field
correlation selection:selected"
 PMS_ENUM1 (Field, fields, fieldStrings, field, EXTEND, CORR, CORR_ALL, CORR_POLN_DEP, CHANNEL, SPW, ANTENNA, ANTENNA_ANTENNA, ANTENNA_BASELINES, TIME, SCANS, FIELD, SEL_SELECTED, SEL_ALTERNATE) PMS_ENUM2(Field
 Static //.
 PlotMSFlagging ()
 Non-Static //.
 PlotMSFlagging (MeasurementSet *ms, MeasurementSet *selectedMS, VisSet *visSet)
 Constructor which takes the MS, selected MS, and vis set.
 ~PlotMSFlagging ()
 Destructor.
MeasurementSet * getMS () const
 Gets the MS objects.
MeasurementSet * getSelectedMS () const
VisSetgetVisSet () const
static bool fieldHasSelectionValue (Field f)
 Returns whether the given field has a PlotMSSelection value associated with it or not.
static bool fieldDefault (Field f)
 Returns whether the given field is on or off by default.
static const vector< Field > & fieldMutuallyExclusiveGroup (Field f)
 Returns the list of fields, NOT including the given, with which the given field is mutually exclusive.
static bool fieldIsInMutuallyExclusiveGroup (Field f)
 Returns true if the given field is in a mutually exclusive group, false otherwise.

Public Member Functions

void setMS (MeasurementSet *ms, MeasurementSet *selectedMS, VisSet *visSet)
 Sets the MS objects to the given.
void fromRecord (const RecordInterface &record)
 Converts this object to/from a record.
Record toRecord (bool useStrings=false) const
bool getFlag (Field f) const
 Gets/Sets the on/off flag for the given field.
void getFlag (Field f, bool &flag) const
void setFlag (Field f, bool on)
double getValue (Field f) const
 Gets/Sets the double value for the given field, if applicable.
void getValue (Field f, double &value) const
void setValue (Field f, double value)
String getValueStr (Field f) const
 Gets/Sets the value for the given field as a String.
void getValue (Field f, String &value) const
void setValue (Field f, const String &value)
PlotMSSelection getSelectionValue (Field f) const
 Gets/Sets the selection value for the given field, if applicable.
void getSelectionValue (Field f, PlotMSSelection &value) const
void setSelectionValue (Field f, const PlotMSSelection &value)
bool extend () const
 Convenience methods for returning the standard field values.
bool corr () const
bool corrAll () const
bool corrPolnDep () const
String corrStr () const
bool channel () const
bool spw () const
bool antenna () const
bool antennaAntennaBased () const
double antennaAntennaBasedValue () const
bool antennaBaselinesBased () const
String antennaStr () const
bool time () const
bool scans () const
bool field () const
bool selectionSelected () const
bool selectionAlternate () const
PlotMSSelection selectionAlternateSelection () const
void setExtend (bool flag)
 Convenience methods for setting the standard field values.
void setCorr (bool flag)
void setCorrAll (bool flag)
void setCorrPolnDep (bool flag)
void setCorr (const String &value)
void setChannel (bool flag)
void setSpw (bool flag)
void setAntenna (bool flag)
void setAntennaAntennaBased (bool flag)
void setAntennaAntennaBasedValue (double value)
void setAntennaBaselinesBased (bool flag)
void setAntenna (const String &value)
void setTime (bool flag)
void setScans (bool flag)
void setField (bool flag)
void setSelectionSelected (bool flag)
void setSelectionAlternate (bool flag)
void setSelectionAlternateSelection (const PlotMSSelection &value)
bool operator== (const PlotMSFlagging &other) const
 Equality operators.
bool operator!= (const PlotMSFlagging &other) const

Private Member Functions

void setDefaults ()
 Sets the default values.

Private Attributes

map< Field, bool > itsFlags_
 Flagging field flags.
map< Field, double > itsValues_
 Flagging field double values.
map< Field, PlotMSSelectionitsSelectionValues_
 Flagging field selection values.
MeasurementSet * itsMS_
 Pointers to measurement set objects (do not delete!).
MeasurementSet * itsSelectedMS_
VisSetitsVisSet_

Static Private Attributes

static const String RKEY_VALUE
 String constant for what to append to the enum name in the record to get the key for the value.
static const String RKEY_SELVALUE


Constructor & Destructor Documentation

casa::PlotMSFlagging::PlotMSFlagging (  ) 

Non-Static //.

Default constructor.

casa::PlotMSFlagging::PlotMSFlagging ( MeasurementSet *  ms,
MeasurementSet *  selectedMS,
VisSet visSet 
)

Constructor which takes the MS, selected MS, and vis set.

casa::PlotMSFlagging::~PlotMSFlagging (  ) 

Destructor.


Member Function Documentation

casa::PlotMSFlagging::PMS_ENUM1 ( Field  ,
fields  ,
fieldStrings  ,
field  ,
EXTEND  ,
CORR  ,
CORR_ALL  ,
CORR_POLN_DEP  ,
CHANNEL  ,
SPW  ,
ANTENNA  ,
ANTENNA_ANTENNA  ,
ANTENNA_BASELINES  ,
TIME  ,
SCANS  ,
FIELD  ,
SEL_SELECTED  ,
SEL_ALTERNATE   
)

Static //.

Enum and methods to define the different fields for an MS flagging. All fields have a bool flag for on/off, and some of them also have a double value (see fieldHasValue()) or a PlotMSSelection value (see fieldHasSelectionValue()). Most fields are off by default (see fieldDefault()), with a default double value of 0 or empty/default PlotMSSelection value if applicable. Some fields are in mutually exclusive groups (see fieldMutuallyExclusiveGroup()). If these are changed, also update: convenience methods below, xmlcasa/implement/plotms/plotms*, xmlcasa/tasks/plotms.xml, xmlcasa/scripts/task_plotms.py.**

static bool casa::PlotMSFlagging::fieldHasSelectionValue ( Field  f  )  [static]

Returns whether the given field has a PlotMSSelection value associated with it or not.

static bool casa::PlotMSFlagging::fieldDefault ( Field  f  )  [static]

Returns whether the given field is on or off by default.

This is important for mutually exclusive groups, which need to know which field in that group is on to begin with.

static const vector<Field>& casa::PlotMSFlagging::fieldMutuallyExclusiveGroup ( Field  f  )  [static]

Returns the list of fields, NOT including the given, with which the given field is mutually exclusive.

In a mutually exclusive group, only and exactly one field can be turned on at a given time. NOTE: this is different from mutually exclusive groups in PlotMSAveraging, because here it is NOT allowed to have all fields in a group turned off.

Referenced by fieldIsInMutuallyExclusiveGroup().

static bool casa::PlotMSFlagging::fieldIsInMutuallyExclusiveGroup ( Field  f  )  [inline, static]

Returns true if the given field is in a mutually exclusive group, false otherwise.

See fieldMutuallyExclusiveGroup().

Definition at line 92 of file PlotMSFlagging.h.

References fieldMutuallyExclusiveGroup().

MeasurementSet* casa::PlotMSFlagging::getMS (  )  const

Gets the MS objects.

WARNING: could be NULL if they have not been set through the constructor or setMS().

MeasurementSet* casa::PlotMSFlagging::getSelectedMS (  )  const

VisSet* casa::PlotMSFlagging::getVisSet (  )  const

void casa::PlotMSFlagging::setMS ( MeasurementSet *  ms,
MeasurementSet *  selectedMS,
VisSet visSet 
)

Sets the MS objects to the given.

void casa::PlotMSFlagging::fromRecord ( const RecordInterface &  record  ) 

Converts this object to/from a record.

Each field will have a key that is its enum name, with a bool value for its flag value. Fields that also have double values will have an additional key that is its enum name + "Value" for double values, or its enum name + "SelectionValue" for PlotMSSelection values. PlotMSSelection values are stored in Record form (see PlotMSSelection::fromRecord()). The MS objects (the MS, the selected MS, and the vis set) are NOT included in the record.

Record casa::PlotMSFlagging::toRecord ( bool  useStrings = false  )  const

bool casa::PlotMSFlagging::getFlag ( Field  f  )  const

Gets/Sets the on/off flag for the given field.

Referenced by antenna(), antennaAntennaBased(), antennaBaselinesBased(), channel(), corr(), corrAll(), corrPolnDep(), extend(), field(), getFlag(), scans(), selectionAlternate(), selectionSelected(), spw(), and time().

void casa::PlotMSFlagging::getFlag ( Field  f,
bool &  flag 
) const [inline]

Definition at line 136 of file PlotMSFlagging.h.

References getFlag().

void casa::PlotMSFlagging::setFlag ( Field  f,
bool  on 
)

Referenced by setAntenna(), setAntennaAntennaBased(), setAntennaBaselinesBased(), setChannel(), setCorr(), setCorrAll(), setCorrPolnDep(), setExtend(), setField(), setScans(), setSelectionAlternate(), setSelectionSelected(), setSpw(), and setTime().

double casa::PlotMSFlagging::getValue ( Field  f  )  const

Gets/Sets the double value for the given field, if applicable.

Referenced by antennaAntennaBasedValue(), and getValue().

void casa::PlotMSFlagging::getValue ( Field  f,
double &  value 
) const [inline]

Definition at line 143 of file PlotMSFlagging.h.

References getValue().

void casa::PlotMSFlagging::setValue ( Field  f,
double  value 
)

Referenced by setAntenna(), setAntennaAntennaBasedValue(), and setCorr().

String casa::PlotMSFlagging::getValueStr ( Field  f  )  const

Gets/Sets the value for the given field as a String.

Only applicable for special cases (correlation, antenna). Correlation: "", "all", or "poln-dep". Antenna: "", "all", or antenna-based value.

Referenced by antennaStr(), corrStr(), and getValue().

void casa::PlotMSFlagging::getValue ( Field  f,
String &  value 
) const [inline]

Definition at line 153 of file PlotMSFlagging.h.

References getValueStr().

void casa::PlotMSFlagging::setValue ( Field  f,
const String &  value 
)

PlotMSSelection casa::PlotMSFlagging::getSelectionValue ( Field  f  )  const

Gets/Sets the selection value for the given field, if applicable.

Referenced by getSelectionValue(), and selectionAlternateSelection().

void casa::PlotMSFlagging::getSelectionValue ( Field  f,
PlotMSSelection value 
) const [inline]

Definition at line 160 of file PlotMSFlagging.h.

References getSelectionValue().

void casa::PlotMSFlagging::setSelectionValue ( Field  f,
const PlotMSSelection value 
)

Referenced by setSelectionAlternateSelection().

bool casa::PlotMSFlagging::extend (  )  const [inline]

Convenience methods for returning the standard field values.

Definition at line 168 of file PlotMSFlagging.h.

References getFlag().

Referenced by antenna(), channel(), corr(), selectionAlternate(), selectionSelected(), spw(), and time().

bool casa::PlotMSFlagging::corr (  )  const [inline]

Definition at line 169 of file PlotMSFlagging.h.

References extend(), and getFlag().

Referenced by corrAll(), and corrPolnDep().

bool casa::PlotMSFlagging::corrAll (  )  const [inline]

Definition at line 170 of file PlotMSFlagging.h.

References corr(), and getFlag().

bool casa::PlotMSFlagging::corrPolnDep (  )  const [inline]

Definition at line 171 of file PlotMSFlagging.h.

References corr(), and getFlag().

String casa::PlotMSFlagging::corrStr (  )  const [inline]

Definition at line 172 of file PlotMSFlagging.h.

References getValueStr().

bool casa::PlotMSFlagging::channel (  )  const [inline]

Definition at line 173 of file PlotMSFlagging.h.

References extend(), and getFlag().

bool casa::PlotMSFlagging::spw (  )  const [inline]

Definition at line 174 of file PlotMSFlagging.h.

References extend(), and getFlag().

bool casa::PlotMSFlagging::antenna (  )  const [inline]

Definition at line 175 of file PlotMSFlagging.h.

References extend(), and getFlag().

Referenced by antennaAntennaBased(), and antennaBaselinesBased().

bool casa::PlotMSFlagging::antennaAntennaBased (  )  const [inline]

Definition at line 176 of file PlotMSFlagging.h.

References antenna(), and getFlag().

double casa::PlotMSFlagging::antennaAntennaBasedValue (  )  const [inline]

Definition at line 177 of file PlotMSFlagging.h.

References getValue().

bool casa::PlotMSFlagging::antennaBaselinesBased (  )  const [inline]

Definition at line 178 of file PlotMSFlagging.h.

References antenna(), and getFlag().

String casa::PlotMSFlagging::antennaStr (  )  const [inline]

Definition at line 179 of file PlotMSFlagging.h.

References getValueStr().

bool casa::PlotMSFlagging::time (  )  const [inline]

Definition at line 180 of file PlotMSFlagging.h.

References extend(), and getFlag().

Referenced by field(), and scans().

bool casa::PlotMSFlagging::scans (  )  const [inline]

Definition at line 181 of file PlotMSFlagging.h.

References getFlag(), and time().

bool casa::PlotMSFlagging::field (  )  const [inline]

Definition at line 182 of file PlotMSFlagging.h.

References getFlag(), and time().

bool casa::PlotMSFlagging::selectionSelected (  )  const [inline]

Definition at line 183 of file PlotMSFlagging.h.

References extend(), and getFlag().

bool casa::PlotMSFlagging::selectionAlternate (  )  const [inline]

Definition at line 184 of file PlotMSFlagging.h.

References extend(), and getFlag().

PlotMSSelection casa::PlotMSFlagging::selectionAlternateSelection (  )  const [inline]

Definition at line 185 of file PlotMSFlagging.h.

References getSelectionValue().

void casa::PlotMSFlagging::setExtend ( bool  flag  )  [inline]

Convenience methods for setting the standard field values.

Definition at line 191 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setCorr ( bool  flag  )  [inline]

Definition at line 192 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setCorrAll ( bool  flag  )  [inline]

Definition at line 193 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setCorrPolnDep ( bool  flag  )  [inline]

Definition at line 194 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setCorr ( const String &  value  )  [inline]

Definition at line 195 of file PlotMSFlagging.h.

References setValue().

void casa::PlotMSFlagging::setChannel ( bool  flag  )  [inline]

Definition at line 196 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setSpw ( bool  flag  )  [inline]

Definition at line 197 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setAntenna ( bool  flag  )  [inline]

Definition at line 198 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setAntennaAntennaBased ( bool  flag  )  [inline]

Definition at line 199 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setAntennaAntennaBasedValue ( double  value  )  [inline]

Definition at line 200 of file PlotMSFlagging.h.

References setValue().

void casa::PlotMSFlagging::setAntennaBaselinesBased ( bool  flag  )  [inline]

Definition at line 202 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setAntenna ( const String &  value  )  [inline]

Definition at line 203 of file PlotMSFlagging.h.

References setValue().

void casa::PlotMSFlagging::setTime ( bool  flag  )  [inline]

Definition at line 204 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setScans ( bool  flag  )  [inline]

Definition at line 205 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setField ( bool  flag  )  [inline]

Definition at line 206 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setSelectionSelected ( bool  flag  )  [inline]

Definition at line 207 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setSelectionAlternate ( bool  flag  )  [inline]

Definition at line 208 of file PlotMSFlagging.h.

References setFlag().

void casa::PlotMSFlagging::setSelectionAlternateSelection ( const PlotMSSelection value  )  [inline]

Definition at line 209 of file PlotMSFlagging.h.

References setSelectionValue().

bool casa::PlotMSFlagging::operator== ( const PlotMSFlagging other  )  const

Equality operators.

Referenced by operator!=().

bool casa::PlotMSFlagging::operator!= ( const PlotMSFlagging other  )  const [inline]

Definition at line 217 of file PlotMSFlagging.h.

References operator==().

void casa::PlotMSFlagging::setDefaults (  )  [private]

Sets the default values.


Member Data Documentation

casa::PlotMSFlagging::fields

Definition at line 63 of file PlotMSFlagging.h.

casa::PlotMSFlagging::fieldStrings

Definition at line 63 of file PlotMSFlagging.h.

casa::PlotMSFlagging::field

Definition at line 63 of file PlotMSFlagging.h.

casa::PlotMSFlagging::extend

Definition at line 63 of file PlotMSFlagging.h.

casa::PlotMSFlagging::correlation

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::__pad0__

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::correlation

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::channel

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::spw

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::antenna

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::time

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::scans

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::field

Definition at line 63 of file PlotMSFlagging.h.

correlation casa::PlotMSFlagging::selection

Definition at line 63 of file PlotMSFlagging.h.

MeasurementSet* casa::PlotMSFlagging::itsMS_ [private]

Pointers to measurement set objects (do not delete!).

Definition at line 224 of file PlotMSFlagging.h.

MeasurementSet* casa::PlotMSFlagging::itsSelectedMS_ [private]

Definition at line 225 of file PlotMSFlagging.h.

VisSet* casa::PlotMSFlagging::itsVisSet_ [private]

Definition at line 226 of file PlotMSFlagging.h.

map<Field, bool> casa::PlotMSFlagging::itsFlags_ [private]

Flagging field flags.

Definition at line 230 of file PlotMSFlagging.h.

map<Field, double> casa::PlotMSFlagging::itsValues_ [private]

Flagging field double values.

Definition at line 233 of file PlotMSFlagging.h.

map<Field, PlotMSSelection> casa::PlotMSFlagging::itsSelectionValues_ [private]

Flagging field selection values.

Definition at line 236 of file PlotMSFlagging.h.

const String casa::PlotMSFlagging::RKEY_VALUE [static, private]

String constant for what to append to the enum name in the record to get the key for the value.

Definition at line 246 of file PlotMSFlagging.h.

const String casa::PlotMSFlagging::RKEY_SELVALUE [static, private]

Definition at line 247 of file PlotMSFlagging.h.


The documentation for this class was generated from the following file:
Generated on Thu Aug 27 21:44:18 2009 for NRAOCASA by  doxygen 1.5.1