casa
5.7.0-16
|
A class to provide easy access to MSField columns. More...
#include <MSFieldColumns.h>
Public Member Functions | |
ROMSFieldColumns (const MSField &msField) | |
Construct from the supplied Table. More... | |
~ROMSFieldColumns () | |
The desctructor does nothing special. More... | |
const ROScalarColumn< String > & | code () const |
Read-only access to required columns. More... | |
const ROArrayColumn< Double > & | delayDir () const |
const ROArrayMeasColumn < MDirection > & | delayDirMeasCol () const |
const ROScalarColumn< Bool > & | flagRow () const |
const ROScalarColumn< String > & | name () const |
const ROScalarColumn< Int > & | numPoly () const |
const ROArrayColumn< Double > & | phaseDir () const |
const ROArrayMeasColumn < MDirection > & | phaseDirMeasCol () const |
const ROArrayColumn< Double > & | referenceDir () const |
const ROArrayMeasColumn < MDirection > & | referenceDirMeasCol () const |
const ROScalarColumn< Int > & | sourceId () const |
const ROScalarColumn< Double > & | time () const |
const ROScalarQuantColumn < Double > & | timeQuant () const |
const ROScalarMeasColumn < MEpoch > & | timeMeas () const |
const ROScalarColumn< Int > & | ephemerisId () const |
Read-only access to optional columns. More... | |
MDirection | delayDirMeas (Int row, Double time=0) const |
Access to interpolated directions from polynomials or ephemerides, the default time of zero will return the 0th order element of the polynomial. More... | |
MDirection | phaseDirMeas (Int row, Double time=0) const |
MDirection | referenceDirMeas (Int row, Double time=0) const |
MDirection | ephemerisDirMeas (Int row, Double time=0) const |
MRadialVelocity | radVelMeas (Int row, Double time=0) const |
Quantity | rho (Int row, Double time=0) const |
Bool | needInterTime (Int row) const |
String | ephemPath (Int row) const |
uInt | nrow () const |
Convenience function that returns the number of rows in any of the columns. More... | |
Int | matchDirection (const MDirection &referenceDirection, const MDirection &delayDirection, const MDirection &phaseDirection, const Quantum< Double > &maxSeparation, Int tryRow=-1, Double time=0) |
returns the last row that has a reference direction, phase direction and delay direction that match, to within the specified angular separation, the supplied values. More... | |
void | updateMeasComets () |
Update the MeasComets objects belonging to this FIELD table. More... | |
Protected Member Functions | |
ROMSFieldColumns () | |
void | attach (const MSField &msField) |
Int | measCometIndex (int row) const |
MDirection | extractDirMeas (const MDirection &offsetDir, Int index, Double &interTime, MEpoch originEpoch) const |
Extract the direction Measure from the corresponding ephemeris using the nominal position as an offset. More... | |
void | getMJDs (Double &originMJD, Double &interMJD, const Double interTime, const MEpoch originEpoch) const |
Protected Attributes | |
String | measCometsPath_p |
Vector< MeasComet * > | measCometsV_p |
std::map< Int, Int > | ephIdToMeasComet_p |
Private Member Functions | |
ROMSFieldColumns (const ROMSFieldColumns &) | |
ROMSFieldColumns & | operator= (const ROMSFieldColumns &) |
void | attachOptionalCols (const MSField &msField) |
Bool | matchReferenceDir (uInt row, const MVDirection &dirVal, const Double &sepInRad, MVDirection &mvdir, Double time=0) const |
Bool | matchDelayDir (uInt row, const MVDirection &dirVal, const Double &sepInRad, MVDirection &mvdir, Double time=0) const |
Bool | matchPhaseDir (uInt row, const MVDirection &dirVal, const Double &sepInRad, MVDirection &mvdir, Double time=0) const |
A class to provide easy access to MSField columns.
Public interface
ROMSFieldColumns stands for Read-Only MeasurementSet Field Table columns.
This class provides read-only access to the columns in the MSField Table. 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. See ROMSColumns for an example.
See MSColumns for the motivation.
Definition at line 86 of file MSFieldColumns.h.
casacore::ROMSFieldColumns::ROMSFieldColumns | ( | const MSField & | msField | ) |
Construct from the supplied Table.
casacore::ROMSFieldColumns::~ROMSFieldColumns | ( | ) |
The desctructor does nothing special.
|
protected |
|
private |
|
protected |
|
private |
|
inline |
Read-only access to required columns.
Definition at line 97 of file MSFieldColumns.h.
References code_p.
Referenced by casacore::MSFieldColumns::code().
|
inline |
Definition at line 98 of file MSFieldColumns.h.
References delayDir_p.
Referenced by casacore::MSFieldColumns::delayDir().
MDirection casacore::ROMSFieldColumns::delayDirMeas | ( | Int | row, |
Double | time = 0 |
||
) | const |
Access to interpolated directions from polynomials or ephemerides, the default time of zero will return the 0th order element of the polynomial.
or, if there is an ephemeris, the position at the time origin of the ephemeris.
If there is an ephemeris attached to a field table row, the nominal values of the direction columns are interpreted as an offset to the ephemeris. So if there is an ephemeris attached (EPHEMERIS_ID column contains value > -1), then the direction returned by delayDirMeas, phaseDirMeas, and referenceDirMeas is the ephemeris direction plus the offset taken from the corresponding direction column. This permits the convinient implementation of mosaics where several field table rows share one ephemeris and use different offsets in each row to create the mosaic pattern.
The unaltered ephemeris direction can be queried with the method ephemerisDirMeas(). If there is no ephemeris attached, ephemerisDirMeas() will return the same as referenceDirMeas().
In addtion to the directions, if there is an ephemeris available, also the radial velocity and the distance rho can be accessed.
The method needInterTime returns True if there is a polynomial or ephemeris connected to this field table row, and an interpolation time value should be provided. The method ephemPath returns the absolute path to the ephemeris table connected to the field table row, an empty string if there is none.
|
inline |
Definition at line 99 of file MSFieldColumns.h.
References delayDirMeas_p.
Referenced by casacore::MSFieldColumns::delayDirMeasCol().
MDirection casacore::ROMSFieldColumns::ephemerisDirMeas | ( | Int | row, |
Double | time = 0 |
||
) | const |
|
inline |
Read-only access to optional columns.
Definition at line 118 of file MSFieldColumns.h.
References ephemerisId_p.
Referenced by casacore::MSFieldColumns::ephemerisId().
|
protected |
Extract the direction Measure from the corresponding ephemeris using the nominal position as an offset.
Note that interTime is assumed to use the same time reference frame as originEpoch.
|
inline |
Definition at line 101 of file MSFieldColumns.h.
References flagRow_p.
Referenced by casacore::MSFieldColumns::flagRow().
|
protected |
|
private |
Int casacore::ROMSFieldColumns::matchDirection | ( | const MDirection & | referenceDirection, |
const MDirection & | delayDirection, | ||
const MDirection & | phaseDirection, | ||
const Quantum< Double > & | maxSeparation, | ||
Int | tryRow = -1 , |
||
Double | time = 0 |
||
) |
returns the last row that has a reference direction, phase direction and delay direction that match, to within the specified angular separation, the supplied values.
Only matches on rows where the direction is constant ie., NUM_POLY is 0 and where FLAG_ROW is False. Throws an exception (AipsError) if the reference frames do not match or if the separation does not have angular units (when compiled in debug mode). Returns -1 if no match could be found. If tryRow is positive, then that row is tested to see if it matches before any others are tested. Setting tryRow to a positive value greater than the table length will throw an exception (AipsError), when compiled in debug mode.
|
private |
|
private |
|
protected |
|
inline |
Definition at line 102 of file MSFieldColumns.h.
References name_p.
Referenced by casacore::MSFieldColumns::name().
|
inline |
Convenience function that returns the number of rows in any of the columns.
Definition at line 159 of file MSFieldColumns.h.
References name_p.
Referenced by casa::sdfiller::FieldRecord::fill().
|
inline |
Definition at line 103 of file MSFieldColumns.h.
References numPoly_p.
Referenced by casacore::MSFieldColumns::numPoly().
|
private |
|
inline |
Definition at line 104 of file MSFieldColumns.h.
References phaseDir_p.
Referenced by casacore::MSFieldColumns::phaseDir().
MDirection casacore::ROMSFieldColumns::phaseDirMeas | ( | Int | row, |
Double | time = 0 |
||
) | const |
|
inline |
Definition at line 105 of file MSFieldColumns.h.
References phaseDirMeas_p.
Referenced by casacore::MSFieldColumns::phaseDirMeasCol().
MRadialVelocity casacore::ROMSFieldColumns::radVelMeas | ( | Int | row, |
Double | time = 0 |
||
) | const |
|
inline |
Definition at line 107 of file MSFieldColumns.h.
References referenceDir_p.
Referenced by casacore::MSFieldColumns::referenceDir().
MDirection casacore::ROMSFieldColumns::referenceDirMeas | ( | Int | row, |
Double | time = 0 |
||
) | const |
|
inline |
Definition at line 108 of file MSFieldColumns.h.
References referenceDirMeas_p.
Referenced by casacore::MSFieldColumns::referenceDirMeasCol().
|
inline |
Definition at line 110 of file MSFieldColumns.h.
References sourceId_p.
Referenced by casacore::MSFieldColumns::sourceId().
|
inline |
Definition at line 111 of file MSFieldColumns.h.
References time_p.
Referenced by casacore::MSFieldColumns::time().
|
inline |
Definition at line 113 of file MSFieldColumns.h.
References timeMeas_p.
Referenced by casacore::MSFieldColumns::timeMeas().
|
inline |
Definition at line 112 of file MSFieldColumns.h.
References timeQuant_p.
Referenced by casacore::MSFieldColumns::timeQuant().
void casacore::ROMSFieldColumns::updateMeasComets | ( | ) |
Update the MeasComets objects belonging to this FIELD table.
Needed when the entries in the EPHEMERIS_ID column have changed.
|
private |
Definition at line 235 of file MSFieldColumns.h.
Referenced by code().
|
private |
Definition at line 238 of file MSFieldColumns.h.
Referenced by delayDir().
|
private |
Definition at line 248 of file MSFieldColumns.h.
Referenced by delayDirMeasCol().
|
private |
Definition at line 244 of file MSFieldColumns.h.
Referenced by ephemerisId().
Definition at line 194 of file MSFieldColumns.h.
|
private |
Definition at line 242 of file MSFieldColumns.h.
Referenced by flagRow().
|
protected |
Definition at line 192 of file MSFieldColumns.h.
Definition at line 193 of file MSFieldColumns.h.
|
private |
Definition at line 234 of file MSFieldColumns.h.
|
private |
Definition at line 237 of file MSFieldColumns.h.
Referenced by numPoly().
|
private |
Definition at line 239 of file MSFieldColumns.h.
Referenced by phaseDir().
|
private |
Definition at line 249 of file MSFieldColumns.h.
Referenced by phaseDirMeasCol().
|
private |
Definition at line 240 of file MSFieldColumns.h.
Referenced by referenceDir().
|
private |
Definition at line 250 of file MSFieldColumns.h.
Referenced by referenceDirMeasCol().
|
private |
Definition at line 241 of file MSFieldColumns.h.
Referenced by sourceId().
|
private |
Definition at line 236 of file MSFieldColumns.h.
Referenced by time().
|
private |
Definition at line 247 of file MSFieldColumns.h.
Referenced by timeMeas().
|
private |
Definition at line 253 of file MSFieldColumns.h.
Referenced by timeQuant().