CalDeviceRow.h

Go to the documentation of this file.
00001 
00002 /*
00003  * ALMA - Atacama Large Millimeter Array
00004  * (c) European Southern Observatory, 2002
00005  * (c) Associated Universities Inc., 2002
00006  * Copyright by ESO (in the framework of the ALMA collaboration),
00007  * Copyright by AUI (in the framework of the ALMA collaboration),
00008  * All rights reserved.
00009  * 
00010  * This library is free software; you can redistribute it and/or
00011  * modify it under the terms of the GNU Lesser General Public
00012  * License as published by the Free software Foundation; either
00013  * version 2.1 of the License, or (at your option) any later version.
00014  * 
00015  * This library is distributed in the hope that it will be useful,
00016  * but WITHOUT ANY WARRANTY, without even the implied warranty of
00017  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00018  * Lesser General Public License for more details.
00019  * 
00020  * You should have received a copy of the GNU Lesser General Public
00021  * License along with this library; if not, write to the Free Software
00022  * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
00023  * MA 02111-1307  USA
00024  *
00025  * Warning!
00026  *  -------------------------------------------------------------------- 
00027  * | This is generated code!  Do not modify this file.                  |
00028  * | If you do, all changes will be lost when the file is re-generated. |
00029  *  --------------------------------------------------------------------
00030  *
00031  * File CalDeviceRow.h
00032  */
00033  
00034 #ifndef CalDeviceRow_CLASS
00035 #define CalDeviceRow_CLASS
00036 
00037 #include <vector>
00038 #include <string>
00039 #include <set>
00040 using std::vector;
00041 using std::string;
00042 using std::set;
00043 
00044 #ifndef WITHOUT_ACS
00045 #include <asdmIDLC.h>
00046 using asdmIDL::CalDeviceRowIDL;
00047 #endif
00048 
00049 
00050 
00051 
00052 
00053 
00054 #include <Tag.h>
00055 using  asdm::Tag;
00056 
00057 #include <Temperature.h>
00058 using  asdm::Temperature;
00059 
00060 #include <ArrayTimeInterval.h>
00061 using  asdm::ArrayTimeInterval;
00062 
00063 
00064 
00065 
00066         
00067 
00068         
00069 
00070         
00071 #include "CCalibrationDevice.h"
00072 using namespace CalibrationDeviceMod;
00073         
00074 
00075         
00076 
00077         
00078 
00079         
00080 
00081         
00082 
00083 
00084 
00085 #include <ConversionException.h>
00086 #include <NoSuchRow.h>
00087 #include <IllegalAccessException.h>
00088 
00089 
00090 /*\file CalDevice.h
00091     \brief Generated from model's revision "1.55", branch "HEAD"
00092 */
00093 
00094 namespace asdm {
00095 
00096 //class asdm::CalDeviceTable;
00097 
00098 
00099 // class asdm::AntennaRow;
00100 class AntennaRow;
00101 
00102 // class asdm::SpectralWindowRow;
00103 class SpectralWindowRow;
00104 
00105 // class asdm::FeedRow;
00106 class FeedRow;
00107         
00108 
00109 class CalDeviceRow;
00110 typedef void (CalDeviceRow::*CalDeviceAttributeFromBin) (EndianISStream& eiss);
00111 
00118 class CalDeviceRow {
00119 friend class asdm::CalDeviceTable;
00120 
00121 public:
00122 
00123         virtual ~CalDeviceRow();
00124 
00128         CalDeviceTable &getTable() const;
00129         
00134         bool isAdded() const;
00135                 
00137         // Intrinsic Table Attributes //
00139         
00140         
00141         // ===> Attribute timeInterval
00142         
00143         
00144         
00145 
00146         
00151         ArrayTimeInterval getTimeInterval() const;
00152         
00153  
00154         
00155         
00165         void setTimeInterval (ArrayTimeInterval timeInterval);
00166                 
00167         
00168         
00169         
00170 
00171 
00172         
00173         // ===> Attribute numCalload
00174         
00175         
00176         
00177 
00178         
00183         int getNumCalload() const;
00184         
00185  
00186         
00187         
00195         void setNumCalload (int numCalload);
00196                 
00197         
00198         
00199         
00200 
00201 
00202         
00203         // ===> Attribute calLoadNames
00204         
00205         
00206         
00207 
00208         
00213         vector<CalibrationDeviceMod::CalibrationDevice > getCalLoadNames() const;
00214         
00215  
00216         
00217         
00225         void setCalLoadNames (vector<CalibrationDeviceMod::CalibrationDevice > calLoadNames);
00226                 
00227         
00228         
00229         
00230 
00231 
00232         
00233         // ===> Attribute numReceptor, which is optional
00234         
00235         
00236         
00241         bool isNumReceptorExists() const;
00242         
00243 
00244         
00250         int getNumReceptor() const;
00251         
00252  
00253         
00254         
00261         void setNumReceptor (int numReceptor);
00262                 
00263         
00264         
00265         
00269         void clearNumReceptor ();
00270         
00271 
00272 
00273         
00274         // ===> Attribute calEff, which is optional
00275         
00276         
00277         
00282         bool isCalEffExists() const;
00283         
00284 
00285         
00291         vector<vector<float > > getCalEff() const;
00292         
00293  
00294         
00295         
00302         void setCalEff (vector<vector<float > > calEff);
00303                 
00304         
00305         
00306         
00310         void clearCalEff ();
00311         
00312 
00313 
00314         
00315         // ===> Attribute noiseCal, which is optional
00316         
00317         
00318         
00323         bool isNoiseCalExists() const;
00324         
00325 
00326         
00332         vector<double > getNoiseCal() const;
00333         
00334  
00335         
00336         
00343         void setNoiseCal (vector<double > noiseCal);
00344                 
00345         
00346         
00347         
00351         void clearNoiseCal ();
00352         
00353 
00354 
00355         
00356         // ===> Attribute temperatureLoad, which is optional
00357         
00358         
00359         
00364         bool isTemperatureLoadExists() const;
00365         
00366 
00367         
00373         vector<Temperature > getTemperatureLoad() const;
00374         
00375  
00376         
00377         
00384         void setTemperatureLoad (vector<Temperature > temperatureLoad);
00385                 
00386         
00387         
00388         
00392         void clearTemperatureLoad ();
00393         
00394 
00395 
00397         // Extrinsic Table Attributes //
00399         
00400         
00401         // ===> Attribute antennaId
00402         
00403         
00404         
00405 
00406         
00411         Tag getAntennaId() const;
00412         
00413  
00414         
00415         
00425         void setAntennaId (Tag antennaId);
00426                 
00427         
00428         
00429         
00430 
00431 
00432         
00433         // ===> Attribute feedId
00434         
00435         
00436         
00437 
00438         
00443         int getFeedId() const;
00444         
00445  
00446         
00447         
00457         void setFeedId (int feedId);
00458                 
00459         
00460         
00461         
00462 
00463 
00464         
00465         // ===> Attribute spectralWindowId
00466         
00467         
00468         
00469 
00470         
00475         Tag getSpectralWindowId() const;
00476         
00477  
00478         
00479         
00489         void setSpectralWindowId (Tag spectralWindowId);
00490                 
00491         
00492         
00493         
00494 
00495 
00497         // Links //
00499         
00500         
00501 
00502         
00503                 
00510          AntennaRow* getAntennaUsingAntennaId();
00511          
00512 
00513         
00514 
00515         
00516 
00517         
00518                 
00525          SpectralWindowRow* getSpectralWindowUsingSpectralWindowId();
00526          
00527 
00528         
00529 
00530         
00531 
00532         
00533                 
00534         // ===> Slice link from a row of CalDevice table to a collection of row of Feed table.
00535         
00541         vector <FeedRow *> getFeeds();
00542         
00543         
00544 
00545         
00546 
00547         
00548         
00549         
00567         bool compareNoAutoInc(Tag antennaId, Tag spectralWindowId, ArrayTimeInterval timeInterval, int feedId, int numCalload, vector<CalibrationDeviceMod::CalibrationDevice > calLoadNames);
00568         
00569         
00570 
00571         
00581         bool compareRequiredValue(int numCalload, vector<CalibrationDeviceMod::CalibrationDevice > calLoadNames); 
00582                  
00583         
00592         bool equalByRequiredValue(CalDeviceRow* x) ;
00593         
00594 #ifndef WITHOUT_ACS
00595 
00599         CalDeviceRowIDL *toIDL() const;
00600 #endif
00601         
00602 #ifndef WITHOUT_ACS
00603 
00608         void setFromIDL (CalDeviceRowIDL x) ;
00609 #endif
00610         
00615         string toXML() const;
00616 
00623         void setFromXML (string rowDoc) ;       
00624 
00625 private:
00629         CalDeviceTable &table;
00633         bool hasBeenAdded;
00634 
00635         // This method is used by the Table class when this row is added to the table.
00636         void isAdded(bool added);
00637 
00638 
00647         CalDeviceRow (CalDeviceTable &table);
00648 
00666          CalDeviceRow (CalDeviceTable &table, CalDeviceRow &row);
00667                 
00669         // Intrinsic Table Attributes //
00671         
00672         
00673         // ===> Attribute timeInterval
00674         
00675         
00676 
00677         ArrayTimeInterval timeInterval;
00678 
00679         
00680         
00681         
00682 
00683         
00684         // ===> Attribute numCalload
00685         
00686         
00687 
00688         int numCalload;
00689 
00690         
00691         
00692         
00693 
00694         
00695         // ===> Attribute calLoadNames
00696         
00697         
00698 
00699         vector<CalibrationDeviceMod::CalibrationDevice > calLoadNames;
00700 
00701         
00702         
00703         
00704 
00705         
00706         // ===> Attribute numReceptor, which is optional
00707         
00708         
00709         bool numReceptorExists;
00710         
00711 
00712         int numReceptor;
00713 
00714         
00715         
00716         
00717 
00718         
00719         // ===> Attribute calEff, which is optional
00720         
00721         
00722         bool calEffExists;
00723         
00724 
00725         vector<vector<float > > calEff;
00726 
00727         
00728         
00729         
00730 
00731         
00732         // ===> Attribute noiseCal, which is optional
00733         
00734         
00735         bool noiseCalExists;
00736         
00737 
00738         vector<double > noiseCal;
00739 
00740         
00741         
00742         
00743 
00744         
00745         // ===> Attribute temperatureLoad, which is optional
00746         
00747         
00748         bool temperatureLoadExists;
00749         
00750 
00751         vector<Temperature > temperatureLoad;
00752 
00753         
00754         
00755         
00756 
00758         // Extrinsic Table Attributes //
00760         
00761         
00762         // ===> Attribute antennaId
00763         
00764         
00765 
00766         Tag antennaId;
00767 
00768         
00769         
00770         
00771 
00772         
00773         // ===> Attribute feedId
00774         
00775         
00776 
00777         int feedId;
00778 
00779         
00780         
00781         
00782 
00783         
00784         // ===> Attribute spectralWindowId
00785         
00786         
00787 
00788         Tag spectralWindowId;
00789 
00790         
00791         
00792         
00793 
00795         // Links //
00797         
00798         
00799                 
00800 
00801          
00802 
00803         
00804 
00805         
00806                 
00807 
00808          
00809 
00810         
00811 
00812         
00813                 
00814 
00815 
00816         
00817 
00818         
00820         // binary-deserialization material//
00822         map<string, CalDeviceAttributeFromBin> fromBinMethods;
00823 void antennaIdFromBin( EndianISStream& eiss);
00824 void spectralWindowIdFromBin( EndianISStream& eiss);
00825 void timeIntervalFromBin( EndianISStream& eiss);
00826 void feedIdFromBin( EndianISStream& eiss);
00827 void numCalloadFromBin( EndianISStream& eiss);
00828 void calLoadNamesFromBin( EndianISStream& eiss);
00829 
00830 void numReceptorFromBin( EndianISStream& eiss);
00831 void calEffFromBin( EndianISStream& eiss);
00832 void noiseCalFromBin( EndianISStream& eiss);
00833 void temperatureLoadFromBin( EndianISStream& eiss);
00834         
00835         
00840          void toBin(EndianOSStream& eoss);
00841                  
00849          static CalDeviceRow* fromBin(EndianISStream& eiss, CalDeviceTable& table, const vector<string>& attributesSeq);         
00850 
00851 };
00852 
00853 } // End namespace asdm
00854 
00855 #endif /* CalDevice_CLASS */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines