casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
casacore::MSFieldColumns Class Reference

A class to provide easy read-write access to MSField columns. More...

#include <MSFieldColumns.h>

Inheritance diagram for casacore::MSFieldColumns:
casacore::ROMSFieldColumns

Public Member Functions

 MSFieldColumns (MSField &msField)
 Construct from the supplied Table. More...
 
 ~MSFieldColumns ()
 The desctructor does nothing special. More...
 
ScalarColumn< String > & code ()
 Read-write access to required columns. More...
 
ArrayColumn< Double > & delayDir ()
 
ArrayMeasColumn< MDirection > & delayDirMeasCol ()
 
ScalarColumn< Bool > & flagRow ()
 
ScalarColumn< String > & name ()
 
ScalarColumn< Int > & numPoly ()
 
ArrayColumn< Double > & phaseDir ()
 
ArrayMeasColumn< MDirection > & phaseDirMeasCol ()
 
ArrayColumn< Double > & referenceDir ()
 
ArrayMeasColumn< MDirection > & referenceDirMeasCol ()
 
ScalarColumn< Int > & sourceId ()
 
ScalarColumn< Double > & time ()
 
ScalarQuantColumn< Double > & timeQuant ()
 
ScalarMeasColumn< MEpoch > & timeMeas ()
 
ScalarColumn< Int > & ephemerisId ()
 Read-write access to optional columns. 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...
 
void setEpochRef (MEpoch::Types ref, Bool tableMustBeEmpty=True)
 set the epoch reference type for the TIME column. More...
 
void setDirectionRef (MDirection::Types ref)
 set the direction reference type for the REFERENCE_DIR, DELAY_DIR & PHASE_DIR columns. More...
 
- Public Member Functions inherited from casacore::ROMSFieldColumns
 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...
 

Static Public Member Functions

static MDirection interpolateDirMeas (const Array< MDirection > &arrDir, Int numPoly, Double interTime, Double timeOrigin)
 Interpolate the direction Measure polynomial. More...
 

Protected Member Functions

 MSFieldColumns ()
 
void attach (MSField &msField)
 
- Protected Member Functions inherited from casacore::ROMSFieldColumns
 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
 

Private Member Functions

 MSFieldColumns (const MSFieldColumns &)
 
MSFieldColumnsoperator= (const MSFieldColumns &)
 
void attachOptionalCols (MSField &msField)
 

Private Attributes

ScalarColumn< Stringname_p
 
ScalarColumn< Stringcode_p
 
ScalarColumn< Doubletime_p
 
ScalarColumn< IntnumPoly_p
 
ArrayColumn< DoubledelayDir_p
 
ArrayColumn< DoublephaseDir_p
 
ArrayColumn< DoublereferenceDir_p
 
ScalarColumn< IntsourceId_p
 
ScalarColumn< BoolflagRow_p
 
ScalarColumn< IntephemerisId_p
 
ScalarMeasColumn< MEpochtimeMeas_p
 
ArrayMeasColumn< MDirectiondelayDirMeas_p
 
ArrayMeasColumn< MDirectionphaseDirMeas_p
 
ArrayMeasColumn< MDirectionreferenceDirMeas_p
 
ScalarQuantColumn< DoubletimeQuant_p
 

Additional Inherited Members

- Protected Attributes inherited from casacore::ROMSFieldColumns
String measCometsPath_p
 
Vector< MeasComet * > measCometsV_p
 
std::map< Int, IntephIdToMeasComet_p
 

Detailed Description

A class to provide easy read-write access to MSField columns.

Intended use:

Public interface

Review Status

Reviewed By:
Bob Garwood
Date Reviewed:
1997/02/01

Prerequisite

Etymology

MSFieldColumns stands for MeasurementSet Field Table columns.

Synopsis

This class provides 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 MSColumns for an example.

Motivation

See MSColumns for the motivation.

Definition at line 289 of file MSFieldColumns.h.

Constructor & Destructor Documentation

casacore::MSFieldColumns::MSFieldColumns ( MSField msField)

Construct from the supplied Table.

casacore::MSFieldColumns::~MSFieldColumns ( )

The desctructor does nothing special.

casacore::MSFieldColumns::MSFieldColumns ( )
protected
casacore::MSFieldColumns::MSFieldColumns ( const MSFieldColumns )
private

Member Function Documentation

void casacore::MSFieldColumns::attach ( MSField msField)
protected
void casacore::MSFieldColumns::attachOptionalCols ( MSField msField)
private
ScalarColumn<String>& casacore::MSFieldColumns::code ( )
inline

Read-write access to required columns.

Note that the direction measures with a stored polynomial have Col() added to their name. They are better accessed via the functions that have the same name, without the Col suffix, that will do the interpolation for you. These functions are in the ROMSFieldColumns class.

Definition at line 305 of file MSFieldColumns.h.

References code_p.

Referenced by casa::sdfiller::FieldRecord::fill().

const ROScalarColumn<String>& casacore::MSFieldColumns::code ( ) const
inline

Read-only access to required columns.

Definition at line 331 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::code().

ArrayColumn<Double>& casacore::MSFieldColumns::delayDir ( )
inline
const ROArrayColumn<Double>& casacore::MSFieldColumns::delayDir ( ) const
inline

Definition at line 333 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::delayDir().

ArrayMeasColumn<MDirection>& casacore::MSFieldColumns::delayDirMeasCol ( )
inline

Definition at line 307 of file MSFieldColumns.h.

References delayDirMeas_p.

const ROArrayMeasColumn<MDirection>& casacore::MSFieldColumns::delayDirMeasCol ( ) const
inline

Definition at line 335 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::delayDirMeasCol().

ScalarColumn<Int>& casacore::MSFieldColumns::ephemerisId ( )
inline

Read-write access to optional columns.

Definition at line 326 of file MSFieldColumns.h.

References ephemerisId_p.

const ROScalarColumn<Int>& casacore::MSFieldColumns::ephemerisId ( ) const
inline

Read-only access to optional columns.

Definition at line 363 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::ephemerisId().

ScalarColumn<Bool>& casacore::MSFieldColumns::flagRow ( )
inline

Definition at line 309 of file MSFieldColumns.h.

References flagRow_p.

const ROScalarColumn<Bool>& casacore::MSFieldColumns::flagRow ( ) const
inline

Definition at line 337 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::flagRow().

static MDirection casacore::MSFieldColumns::interpolateDirMeas ( const Array< MDirection > &  arrDir,
Int  numPoly,
Double  interTime,
Double  timeOrigin 
)
static

Interpolate the direction Measure polynomial.

ScalarColumn<String>& casacore::MSFieldColumns::name ( )
inline

Definition at line 310 of file MSFieldColumns.h.

References name_p.

Referenced by casa::sdfiller::FieldRecord::add(), and casa::sdfiller::FieldRecord::fill().

const ROScalarColumn<String>& casacore::MSFieldColumns::name ( ) const
inline

Definition at line 339 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::name().

ScalarColumn<Int>& casacore::MSFieldColumns::numPoly ( )
inline

Definition at line 311 of file MSFieldColumns.h.

References numPoly_p.

Referenced by casa::sdfiller::FieldRecord::add(), and casa::sdfiller::FieldRecord::fill().

const ROScalarColumn<Int>& casacore::MSFieldColumns::numPoly ( ) const
inline

Definition at line 341 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::numPoly().

MSFieldColumns& casacore::MSFieldColumns::operator= ( const MSFieldColumns )
private
ArrayColumn<Double>& casacore::MSFieldColumns::phaseDir ( )
inline
const ROArrayColumn<Double>& casacore::MSFieldColumns::phaseDir ( ) const
inline

Definition at line 343 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::phaseDir().

ArrayMeasColumn<MDirection>& casacore::MSFieldColumns::phaseDirMeasCol ( )
inline

Definition at line 313 of file MSFieldColumns.h.

References phaseDirMeas_p.

const ROArrayMeasColumn<MDirection>& casacore::MSFieldColumns::phaseDirMeasCol ( ) const
inline

Definition at line 345 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::phaseDirMeasCol().

ArrayColumn<Double>& casacore::MSFieldColumns::referenceDir ( )
inline
const ROArrayColumn<Double>& casacore::MSFieldColumns::referenceDir ( ) const
inline

Definition at line 347 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::referenceDir().

ArrayMeasColumn<MDirection>& casacore::MSFieldColumns::referenceDirMeasCol ( )
inline

Definition at line 316 of file MSFieldColumns.h.

References referenceDirMeas_p.

const ROArrayMeasColumn<MDirection>& casacore::MSFieldColumns::referenceDirMeasCol ( ) const
inline
void casacore::MSFieldColumns::setDirectionRef ( MDirection::Types  ref)

set the direction reference type for the REFERENCE_DIR, DELAY_DIR & PHASE_DIR columns.

This can only be done when the table has no rows. Trying to do so at other times will throw an exception.

void casacore::MSFieldColumns::setEpochRef ( MEpoch::Types  ref,
Bool  tableMustBeEmpty = True 
)

set the epoch reference type for the TIME column.


Tip: In principle this function can only be used if the table is empty, otherwise already written values may thereafter have an incorrect reference, offset, or unit; However, it is possible that part of the table gets written before these values are known; In that case the reference, offset, or units can be set by using a False tableMustBeEmpty argument;

ScalarColumn<Int>& casacore::MSFieldColumns::sourceId ( )
inline

Definition at line 318 of file MSFieldColumns.h.

References sourceId_p.

Referenced by casa::sdfiller::FieldRecord::add(), and casa::sdfiller::FieldRecord::fill().

const ROScalarColumn<Int>& casacore::MSFieldColumns::sourceId ( ) const
inline

Definition at line 351 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::sourceId().

ScalarColumn<Double>& casacore::MSFieldColumns::time ( void  )
inline

Definition at line 319 of file MSFieldColumns.h.

References time_p.

Referenced by casa::sdfiller::FieldRecord::add(), and casa::sdfiller::FieldRecord::fill().

const ROScalarColumn<Double>& casacore::MSFieldColumns::time ( void  ) const
inline

Definition at line 353 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::time().

ScalarMeasColumn<MEpoch>& casacore::MSFieldColumns::timeMeas ( )
inline

Definition at line 321 of file MSFieldColumns.h.

References timeMeas_p.

const ROScalarMeasColumn<MEpoch>& casacore::MSFieldColumns::timeMeas ( ) const
inline

Definition at line 357 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::timeMeas().

ScalarQuantColumn<Double>& casacore::MSFieldColumns::timeQuant ( )
inline

Definition at line 320 of file MSFieldColumns.h.

References timeQuant_p.

const ROScalarQuantColumn<Double>& casacore::MSFieldColumns::timeQuant ( ) const
inline

Definition at line 355 of file MSFieldColumns.h.

References casacore::ROMSFieldColumns::timeQuant().

Member Data Documentation

ScalarColumn<String> casacore::MSFieldColumns::code_p
private

Definition at line 409 of file MSFieldColumns.h.

Referenced by code().

ArrayColumn<Double> casacore::MSFieldColumns::delayDir_p
private

Definition at line 412 of file MSFieldColumns.h.

Referenced by delayDir().

ArrayMeasColumn<MDirection> casacore::MSFieldColumns::delayDirMeas_p
private

Definition at line 422 of file MSFieldColumns.h.

Referenced by delayDirMeasCol().

ScalarColumn<Int> casacore::MSFieldColumns::ephemerisId_p
private

Definition at line 418 of file MSFieldColumns.h.

Referenced by ephemerisId().

ScalarColumn<Bool> casacore::MSFieldColumns::flagRow_p
private

Definition at line 416 of file MSFieldColumns.h.

Referenced by flagRow().

ScalarColumn<String> casacore::MSFieldColumns::name_p
private

Definition at line 408 of file MSFieldColumns.h.

Referenced by name().

ScalarColumn<Int> casacore::MSFieldColumns::numPoly_p
private

Definition at line 411 of file MSFieldColumns.h.

Referenced by numPoly().

ArrayColumn<Double> casacore::MSFieldColumns::phaseDir_p
private

Definition at line 413 of file MSFieldColumns.h.

Referenced by phaseDir().

ArrayMeasColumn<MDirection> casacore::MSFieldColumns::phaseDirMeas_p
private

Definition at line 423 of file MSFieldColumns.h.

Referenced by phaseDirMeasCol().

ArrayColumn<Double> casacore::MSFieldColumns::referenceDir_p
private

Definition at line 414 of file MSFieldColumns.h.

Referenced by referenceDir().

ArrayMeasColumn<MDirection> casacore::MSFieldColumns::referenceDirMeas_p
private

Definition at line 424 of file MSFieldColumns.h.

Referenced by referenceDirMeasCol().

ScalarColumn<Int> casacore::MSFieldColumns::sourceId_p
private

Definition at line 415 of file MSFieldColumns.h.

Referenced by sourceId().

ScalarColumn<Double> casacore::MSFieldColumns::time_p
private

Definition at line 410 of file MSFieldColumns.h.

Referenced by time().

ScalarMeasColumn<MEpoch> casacore::MSFieldColumns::timeMeas_p
private

Definition at line 421 of file MSFieldColumns.h.

Referenced by timeMeas().

ScalarQuantColumn<Double> casacore::MSFieldColumns::timeQuant_p
private

Definition at line 427 of file MSFieldColumns.h.

Referenced by timeQuant().


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