casa
$Rev:20696$
|
A class to provide easy read-write access to NewCalTable columns. More...
#include <CTColumns.h>
Public Member Functions | |
CTColumns (NewCalTable &caltable) | |
Create a columns object that accesses the data in the specified caltable. | |
~CTColumns () | |
The destructor does nothing special. | |
CTObservationColumns & | observation () |
Read-write access to required subtables. | |
CTAntennaColumns & | antenna () |
CTFieldColumns & | field () |
CTHistoryColumns & | history () |
CTSpWindowColumns & | spectralWindow () |
const ROCTObservationColumns & | observation () const |
Read-write access to optional subtables. | |
const ROCTAntennaColumns & | antenna () const |
const ROCTFieldColumns & | field () const |
const ROCTHistoryColumns & | history () const |
const ROCTSpWindowColumns & | spectralWindow () const |
Private Attributes | |
CTObservationColumns | observation_p |
protected: friend class NewCalTable; | |
CTAntennaColumns | antenna_p |
CTFieldColumns | field_p |
CTHistoryColumns | history_p |
CTSpWindowColumns | spectralWindow_p |
A class to provide easy read-write access to NewCalTable columns.
Public interface
CTColumns stands for NewCalTable columns.
This class provides access to all the subtables and direct access to all the columns in the NewCalTable. It does the declaration of all the Scalar and ArrayColumns with the correct types, so the application programmer doesn't have to worry about getting those right. There is an access function for every predefined column. Access to non-predefined columns will still have to be done with explicit declarations.
// use as follows NewCalTable newcalt("mynewcalt",Table::Update); CTColumns nctc(newcalt); // show time from row 5 cout << nctc.time()(5); // change name of antenna on row 3 in antenna table nctc.antenna().name().put(3,"NewAnt-3");
Having to type long lists of Scalar and Array column declarations gets very tedious. This class attempts to relieve some of that tedium, while at the same time concentrating all the declarations in one place, making Type errors in the column declaration (only caught at run-time) less probable. Type errors in the use of the columns is caught at compile time.
Definition at line 179 of file CTColumns.h.
casa::CTColumns::CTColumns | ( | NewCalTable & | caltable | ) |
Create a columns object that accesses the data in the specified caltable.
The destructor does nothing special.
CTAntennaColumns& casa::CTColumns::antenna | ( | ) | [inline] |
Definition at line 191 of file CTColumns.h.
References antenna_p.
const ROCTAntennaColumns& casa::CTColumns::antenna | ( | ) | const [inline] |
Definition at line 205 of file CTColumns.h.
References antenna_p.
CTFieldColumns& casa::CTColumns::field | ( | ) | [inline] |
Definition at line 192 of file CTColumns.h.
References field_p.
const ROCTFieldColumns& casa::CTColumns::field | ( | ) | const [inline] |
Definition at line 206 of file CTColumns.h.
References field_p.
CTHistoryColumns& casa::CTColumns::history | ( | ) | [inline] |
Definition at line 193 of file CTColumns.h.
References history_p.
const ROCTHistoryColumns& casa::CTColumns::history | ( | ) | const [inline] |
Definition at line 207 of file CTColumns.h.
References history_p.
CTObservationColumns& casa::CTColumns::observation | ( | ) | [inline] |
Read-write access to required subtables.
Definition at line 190 of file CTColumns.h.
References observation_p.
const ROCTObservationColumns& casa::CTColumns::observation | ( | ) | const [inline] |
Read-write access to optional subtables.
Read-only access to required subtables
Definition at line 204 of file CTColumns.h.
References observation_p.
CTSpWindowColumns& casa::CTColumns::spectralWindow | ( | ) | [inline] |
Definition at line 194 of file CTColumns.h.
References spectralWindow_p.
const ROCTSpWindowColumns& casa::CTColumns::spectralWindow | ( | ) | const [inline] |
Definition at line 208 of file CTColumns.h.
References spectralWindow_p.
CTAntennaColumns casa::CTColumns::antenna_p [private] |
Definition at line 217 of file CTColumns.h.
Referenced by antenna().
CTFieldColumns casa::CTColumns::field_p [private] |
Definition at line 218 of file CTColumns.h.
Referenced by field().
CTHistoryColumns casa::CTColumns::history_p [private] |
Definition at line 219 of file CTColumns.h.
Referenced by history().
protected: friend class NewCalTable;
Access to subtables
Definition at line 216 of file CTColumns.h.
Referenced by observation().
Definition at line 220 of file CTColumns.h.
Referenced by spectralWindow().