GBTMSFeedFiller.h
Classes
- GBTMSFeedFiller -- GBTMSFeedFiller fills the MSFeed table for GBT fillers (full description)
Interface
- Public Members
- GBTMSFeedFiller()
- GBTMSFeedFiller(MSFeed &msFeed)
- ~GBTMSFeedFiller()
- void attach(MSFeed &msFeed)
- void fill()
- Int fill(const GBTFeed &feed, Int sequence)
- Int srFeedId(Int sequence)
- void setSRFeedId(Int feedId, Int srFeedId)
- Bool checkPrior(const GBTFeed &feed, Int sequence)
- void setTime(Double time, Double interval)
- Int feedId(Int whichFeed) const
- Int srfeedId(Int feedId) const
- String gbtFeedName(Int feedId) const
- Bool hasBeamSwitched() const
- void setHasBeamSwitched(Bool hasBeamSwitched)
- void flush()
- Private Members
- void init(MSFeed &msFeed)
- Int addFeed(Double time, Double interval, const Matrix<Double> &offsets, const Vector<String> &polTypes, const String &feedName, Int srFeedId, const String &trckBeam, const String &rxName, const Vector<String> &rcptrNames)
- GBTMSFeedFiller(const GBTMSFeedFiller &other)
- void operator=(const GBTMSFeedFiller &other)
Review Status
- Date Reviewed:
- yyyy/mm/dd
Prerequisite
- MeasurementSets
- GBT FITS files
Etymology
This class puts GBT data (fills) into the MSFeed table.
Synopsis
This class puts the appropriate values for the GBT in an MSFeed
table (which has been previously created as part of a MeasurementSet).
On each fill() any necessary additions to the MSFeed are made.
The feedIds are available to be used by
other GBTMS*Fillers as other subtables are filled in turn.
Example
Motivation
Writing a filler is a daunting task. There are various dependencies
between the subtables. It helps to encapsulate the knowlege and
task of filling a specific subtable to separate classes.
Member Description
The default ctor. No MSFeed table has been attached yet.
Calling fill on such a filler will throw an exception.
It is present so that this object can be instantiated before
an MSFeed has been created.
A filler attached to an MSFeed table
attach it to an MSFeed
fill - using the given keys from other tables
this implementation always fills just one feed ID (i.e. FEED_ID == 0
here) TIME and INTERVAL are both 0.0 - there is no time dependence and
there is no spectral window dependence. This is only used by the
holography filler since as yet there is no IF information filled for
that backend and hence no feed information is available.
Only one row will ever be filled by this and this should not be
used after the other fill method has been used.
Int fill(const GBTFeed &feed, Int sequence)
Add the feeds found here, reusing the previous sequence number if
sequence is >= 0. sequence is not checked for validity. checkPrior should
be used to verify that things can be reused.
It should be followed by a call to setTime when the mid-point
and interval appropriate for the whole scan are known.
return the feed ID just filled
Int srFeedId(Int sequence)
Get the srfeed ID at the indicated sequency in the current
set of filled feeds
void setSRFeedId(Int feedId, Int srFeedId)
Set the srfeed ID for the indicated FEED_ID
Use this prior to calling fill on all feeds to be filled. This
checks to see if the previous item at sequence can be reused.
If this is false, it also resets the internal feed count
anticipating that the subsequent fill will add new rows.
void setTime(Double time, Double interval)
Set the time of the previously filled rows
Int feedId(Int whichFeed) const
get the feed id corresponding to physical feed id indicated
Int srfeedId(Int feedId) const
get the srfeed id corresponding to feedId - feed id is the
FEED_ID in the most recently filled block of feed information.
Get the value filled in to the GBT_FEED_NAME column for the
indicated FEED_ID value.
Returns True if any of the filled FEED_IDs are beam-switched pairs
Set the hasBeamSwitched flag
flush the underlying MS subtable
initialize the above for the first time
Int addFeed(Double time, Double interval, const Matrix<Double> &offsets, const Vector<String> &polTypes, const String &feedName, Int srFeedId, const String &trckBeam, const String &rxName, const Vector<String> &rcptrNames)
add a row with a new feed id given this information
return the new feed ID just added.
undefined and unavailable
void operator=(const GBTMSFeedFiller &other)