casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
GBTMSFillOptions.h
Go to the documentation of this file.
00001 //# GBTMSFillOptions.h: class to hold the filler options
00002 //# Copyright (C) 2002,2003
00003 //# Associated Universities, Inc. Washington DC, USA.
00004 //#
00005 //# This library is free software; you can redistribute it and/or modify it
00006 //# under the terms of the GNU Library General Public License as published by
00007 //# the Free Software Foundation; either version 2 of the License, or (at your
00008 //# option) any later version.
00009 //#
00010 //# This library is distributed in the hope that it will be useful, but WITHOUT
00011 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00012 //# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
00013 //# License for more details.
00014 //#
00015 //# You should have received a copy of the GNU Library General Public License
00016 //# along with this library; if not, write to the Free Software Foundation,
00017 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
00018 //#
00019 //# Correspondence concerning AIPS++ should be addressed as follows:
00020 //#        Internet email: aips2-request@nrao.edu.
00021 //#        Postal address: AIPS++ Project Office
00022 //#                        National Radio Astronomy Observatory
00023 //#                        520 Edgemont Road
00024 //#                        Charlottesville, VA 22903-2475 USA
00025 //#
00026 //#
00027 //# $Id$
00028 
00029 #ifndef NRAO_GBTMSFILLOPTIONS_H
00030 #define NRAO_GBTMSFILLOPTIONS_H
00031 
00032 #include <casa/aips.h>
00033 #include <nrao/FITS/GBTACSTable.h>
00034 
00035 #include <casa/namespace.h>
00036 
00037 //# Forward Declarations
00038 
00039 // <summary>
00040 // This class holds the various fill options set through the filler DO
00041 // </summary>
00042 
00043 // <use visibility=internal>
00044 
00045 // <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos="">
00046 // </reviewed>
00047 
00048 // <prerequisite>
00049 //   <li> <linkto class=gbtmsfiller>gbtmsfiller</linkto> distributed object
00050 // </prerequisite>
00051 //
00052 // <etymology>
00053 // This holds the options for the gbtmsfiller DO.
00054 // </etymology>
00055 //
00056 // <synopsis>
00057 // </synopsis>
00058 //
00059 // <example>
00060 // </example>
00061 //
00062 // <motivation>
00063 // Some options are common to all backends while others only apply to
00064 // one backend.  By putting the options here, an instance of this class
00065 // can be passed to each filler via the fill command so that each 
00066 // backend filler doesn't need to know about options that don't affect
00067 // it and the fill arguments don't need to be changed for each backend
00068 // whenever a particular filler needs a new option.
00069 // </motivation>
00070 //
00071 // <todo asof="yyyy/mm/dd">
00072 //   <li> Everything
00073 // </todo>
00074 
00075 class GBTMSFillOptions
00076 {
00077 public:
00078     // initialized with the default values for each option
00079     GBTMSFillOptions();
00080 
00081     // copy constructor - copy semantics
00082     GBTMSFillOptions(const GBTMSFillOptions &other);
00083 
00084     ~GBTMSFillOptions() {;}
00085 
00086     // Assignment operator, copy semantics
00087     GBTMSFillOptions &operator=(const GBTMSFillOptions &other);
00088 
00089     // The following are used by all backend fillers
00090     // <group>
00091     // Fill the raw pointing values to the appropriate sub-table?
00092     Bool fillRawPointing() const {return itsRawPointing;}
00093     // Set the fillRawPointing option
00094     void setFillRawPointing(Bool fillRawPointing) 
00095     {itsRawPointing = fillRawPointing;}
00096     // Fill the raw focus values to the appropriate sub-table?
00097     Bool fillRawFocus() const {return itsRawFocus;}
00098     // Set the fillRawFocus option
00099     void setFillRawFocus(Bool fillRawFocus) 
00100     {itsRawFocus = fillRawFocus;}
00101     // Which CAL_TEMP to use when filling TCAL, LOW or HIGH?
00102     // Eventually this will be handled through the IF file and these two
00103     // methods will be eliminated. If this returns True, then the HIGH
00104     // cal will be used, otherwise the LOW cal is used.
00105     Bool useHighCal() const {return itsUseHighCal;}
00106     // Set the useHighCal option. This can be used
00107     // to override the default behavior of using LOW_CAL_TEMP.
00108     void setUseHighCal(Bool useHighCal)
00109     {itsUseHighCal = useHighCal;}
00110     // Compress the calibration columns.
00111     Bool compressCalCols() const {return itsCompressCalCols;}
00112     // Set the flag to control whether calibration columns are compressed.
00113     void setCompressCalCols(Bool compressCalCols)
00114     {itsCompressCalCols = compressCalCols;}
00115     // </group>
00116 
00117     // The following options only apply to the ACS
00118     // <group>
00119     // Fill the LAGS in addition to FLOAT_DATA?
00120     Bool fillLags() const {return itsLags;}
00121     // Set the fillLags option
00122     void setFillLags(Bool fillLags) {itsLags = fillLags;}
00123     // The vanVleck correction to use
00124     GBTACSTable::VanVleckCorr vanVleckCorr() const {return itsVVCorr;}
00125     // Set the vanVleck correction to use
00126     void setVanVleckCorr(GBTACSTable::VanVleckCorr vvCorr)
00127     { itsVVCorr = vvCorr;}
00128     // The vanVleck correction to use, as a string
00129     String vanVleckCorrString() const;
00130     // Set the vanVleck correction from a string, returns False if the
00131     // value is unrecognized and sets the vanVleck correction type to the default
00132     Bool setVanVleckCorr(const String &vanVleckCorr);
00133     // The smoothing (windowing) to apply to the corrected data prior to 
00134     // fourier transforming the data to the spectral domain
00135     GBTACSTable::Smoothing smoothing() const {return itsSmooth;}
00136     // Set the smoothing (windowing) function to use
00137     void setSmoothing(GBTACSTable::Smoothing smoothing)
00138     {itsSmooth = smoothing;}
00139     // The smoothing type as a string
00140     String smoothingString() const;
00141     // Set the smoothing correction from a string, returns False if
00142     // The value is unrecognized and set the vanVleck correction type to
00143     // the default
00144     Bool setSmoothing(const String &smoothing);
00145     // Get the vv table size for the schwab correction 
00146     Int vvSize() const 
00147     {return itsVVsize;}
00148     // Set the vv table size for the schwab correction - must be an odd number
00149     Bool setvvSize(const Int vvsize);
00150     // Use a derived bias approximation in the van Vleck correction
00151     // (Schwab correction only)
00152     void setUseBias(Bool usebias) {itsUseBias = usebias;}
00153     // Get the boolean that signals whether or not the bias should be used.
00154     Bool useBias() const {return itsUseBias;}
00155     // Set to fill multi bank ACS data to a single MS
00156     void setOneacsms(Bool oneacsms) {itsOneacsms = oneacsms;}
00157     // Should the filler fill multi bank ACS data to a single MS
00158     Bool oneacsms() const {return itsOneacsms;}
00159     // Set a specific dcbias to use.
00160     Bool setDCBias(Double dcbias) { itsDCBias = dcbias; return True;}
00161     // Returns the specific dcbias to use.  Ignored if usebias is True.
00162     Double dcbias() const {return itsDCBias;}
00163     // Set a minimum bias factor to subtract from the lags.
00164     Bool setMinbiasfactor(Int minbiasfactor) { itsMinbiasfactor = minbiasfactor; return True;}
00165     // The minimum bias factor to subtract (actual may be larger).  If < 0, nothing is subtracted from the lags.
00166     Int minbiasfactor() const {return itsMinbiasfactor;}
00167     // Toggle correcting for offset ACS lags
00168     void setFixbadlags(Bool fixbadlags) {itsFixbadlags = fixbadlags;}
00169     // Should the ACS lags be fixed if possible
00170     Bool fixbadlags() const {return itsFixbadlags;}
00171     // Set the sigma factor used when fixbadlags() is True
00172     void setSigmaFactor(Double sigmafactor) {itsSigmaFactor = sigmafactor;}
00173     // What is the value of the sigma factor used when fixbadlags() is True
00174     Double sigmaFactor() const {return itsSigmaFactor;}
00175     // Set the starting lag for spike fixing, used when fixbadlags() is True
00176     void setSpikeStart(Int spikestart) {itsSpikeStart = spikestart;}
00177     // What is the value of the spike starting location
00178     Int spikeStart() const {return itsSpikeStart;}
00179     // </group>
00180 
00181 private:
00182     Bool itsLags, itsRawFocus, itsRawPointing, itsUseHighCal, 
00183         itsCompressCalCols, itsUseBias, itsOneacsms, itsFixbadlags;
00184     Int itsVVsize, itsMinbiasfactor, itsSpikeStart;
00185     Double itsDCBias, itsSigmaFactor;
00186 
00187     GBTACSTable::VanVleckCorr itsVVCorr;
00188     GBTACSTable::Smoothing itsSmooth;
00189 };
00190 #endif
00191