casa  $Rev:20696$
GainTrackingRow.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 GainTrackingRow.h
00032  */
00033  
00034 #ifndef GainTrackingRow_CLASS
00035 #define GainTrackingRow_CLASS
00036 
00037 #include <vector>
00038 #include <string>
00039 #include <set>
00040 
00041 #ifndef WITHOUT_ACS
00042 #include <asdmIDLC.h>
00043 #endif
00044 
00045 
00046 
00047 
00048 
00049 
00050          
00051 #include <Tag.h>
00052         
00053 
00054          
00055 #include <ArrayTimeInterval.h>
00056         
00057 
00058         
00059 #include <ComplexWrapper.h>
00060         
00061 
00062 
00063 
00064 
00065         
00066 
00067         
00068 
00069         
00070 
00071         
00072 #include "CPolarizationType.h"
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 #include <RowTransformer.h>
00090 //#include <TableStreamReader.h>
00091 
00092 /*\file GainTracking.h
00093     \brief Generated from model's revision "1.62", branch "HEAD"
00094 */
00095 
00096 namespace asdm {
00097 
00098 //class asdm::GainTrackingTable;
00099 
00100 
00101 // class asdm::AntennaRow;
00102 class AntennaRow;
00103 
00104 // class asdm::SpectralWindowRow;
00105 class SpectralWindowRow;
00106 
00107 // class asdm::FeedRow;
00108 class FeedRow;
00109         
00110 
00111 class GainTrackingRow;
00112 typedef void (GainTrackingRow::*GainTrackingAttributeFromBin) (EndianIStream& eis);
00113 typedef void (GainTrackingRow::*GainTrackingAttributeFromText) (const string& s);
00114 
00121 class GainTrackingRow {
00122 friend class asdm::GainTrackingTable;
00123 friend class asdm::RowTransformer<GainTrackingRow>;
00124 //friend class asdm::TableStreamReader<GainTrackingTable, GainTrackingRow>;
00125 
00126 public:
00127 
00128         virtual ~GainTrackingRow();
00129 
00133         GainTrackingTable &getTable() const;
00134         
00139         bool isAdded() const;
00140                 
00142         // Intrinsic Table Attributes //
00144         
00145         
00146         // ===> Attribute timeInterval
00147         
00148         
00149         
00150 
00151         
00156         ArrayTimeInterval getTimeInterval() const;
00157         
00158  
00159         
00160         
00170         void setTimeInterval (ArrayTimeInterval timeInterval);
00171                 
00172         
00173         
00174         
00175 
00176 
00177         
00178         // ===> Attribute numReceptor
00179         
00180         
00181         
00182 
00183         
00188         int getNumReceptor() const;
00189         
00190  
00191         
00192         
00200         void setNumReceptor (int numReceptor);
00201                 
00202         
00203         
00204         
00205 
00206 
00207         
00208         // ===> Attribute attenuator
00209         
00210         
00211         
00212 
00213         
00218         vector<float > getAttenuator() const;
00219         
00220  
00221         
00222         
00230         void setAttenuator (vector<float > attenuator);
00231                 
00232         
00233         
00234         
00235 
00236 
00237         
00238         // ===> Attribute polarizationType
00239         
00240         
00241         
00242 
00243         
00248         vector<PolarizationTypeMod::PolarizationType > getPolarizationType() const;
00249         
00250  
00251         
00252         
00260         void setPolarizationType (vector<PolarizationTypeMod::PolarizationType > polarizationType);
00261                 
00262         
00263         
00264         
00265 
00266 
00267         
00268         // ===> Attribute samplingLevel, which is optional
00269         
00270         
00271         
00276         bool isSamplingLevelExists() const;
00277         
00278 
00279         
00285         float getSamplingLevel() const;
00286         
00287  
00288         
00289         
00296         void setSamplingLevel (float samplingLevel);
00297                 
00298         
00299         
00300         
00304         void clearSamplingLevel ();
00305         
00306 
00307 
00308         
00309         // ===> Attribute numAttFreq, which is optional
00310         
00311         
00312         
00317         bool isNumAttFreqExists() const;
00318         
00319 
00320         
00326         int getNumAttFreq() const;
00327         
00328  
00329         
00330         
00337         void setNumAttFreq (int numAttFreq);
00338                 
00339         
00340         
00341         
00345         void clearNumAttFreq ();
00346         
00347 
00348 
00349         
00350         // ===> Attribute attFreq, which is optional
00351         
00352         
00353         
00358         bool isAttFreqExists() const;
00359         
00360 
00361         
00367         vector<double > getAttFreq() const;
00368         
00369  
00370         
00371         
00378         void setAttFreq (vector<double > attFreq);
00379                 
00380         
00381         
00382         
00386         void clearAttFreq ();
00387         
00388 
00389 
00390         
00391         // ===> Attribute attSpectrum, which is optional
00392         
00393         
00394         
00399         bool isAttSpectrumExists() const;
00400         
00401 
00402         
00408         vector<Complex > getAttSpectrum() const;
00409         
00410  
00411         
00412         
00419         void setAttSpectrum (vector<Complex > attSpectrum);
00420                 
00421         
00422         
00423         
00427         void clearAttSpectrum ();
00428         
00429 
00430 
00432         // Extrinsic Table Attributes //
00434         
00435         
00436         // ===> Attribute antennaId
00437         
00438         
00439         
00440 
00441         
00446         Tag getAntennaId() const;
00447         
00448  
00449         
00450         
00460         void setAntennaId (Tag antennaId);
00461                 
00462         
00463         
00464         
00465 
00466 
00467         
00468         // ===> Attribute feedId
00469         
00470         
00471         
00472 
00473         
00478         int getFeedId() const;
00479         
00480  
00481         
00482         
00492         void setFeedId (int feedId);
00493                 
00494         
00495         
00496         
00497 
00498 
00499         
00500         // ===> Attribute spectralWindowId
00501         
00502         
00503         
00504 
00505         
00510         Tag getSpectralWindowId() const;
00511         
00512  
00513         
00514         
00524         void setSpectralWindowId (Tag spectralWindowId);
00525                 
00526         
00527         
00528         
00529 
00530 
00532         // Links //
00534         
00535         
00536 
00537         
00538                 
00545          AntennaRow* getAntennaUsingAntennaId();
00546          
00547 
00548         
00549 
00550         
00551 
00552         
00553                 
00560          SpectralWindowRow* getSpectralWindowUsingSpectralWindowId();
00561          
00562 
00563         
00564 
00565         
00566 
00567         
00568                 
00569         // ===> Slice link from a row of GainTracking table to a collection of row of Feed table.
00570         
00576         vector <FeedRow *> getFeeds();
00577         
00578         
00579 
00580         
00581 
00582         
00583         
00584         
00604         bool compareNoAutoInc(Tag antennaId, Tag spectralWindowId, ArrayTimeInterval timeInterval, int feedId, int numReceptor, vector<float > attenuator, vector<PolarizationTypeMod::PolarizationType > polarizationType);
00605         
00606         
00607 
00608         
00620         bool compareRequiredValue(int numReceptor, vector<float > attenuator, vector<PolarizationTypeMod::PolarizationType > polarizationType); 
00621                  
00622         
00631         bool equalByRequiredValue(GainTrackingRow* x) ;
00632         
00633 #ifndef WITHOUT_ACS
00634 
00638         asdmIDL::GainTrackingRowIDL *toIDL() const;
00639 #endif
00640         
00641 #ifndef WITHOUT_ACS
00642 
00647         void setFromIDL (asdmIDL::GainTrackingRowIDL x) ;
00648 #endif
00649         
00654         std::string toXML() const;
00655 
00662         void setFromXML (std::string rowDoc) ;
00663 
00666         // binary-deserialization material from an EndianIStream  //
00668 
00669         std::map<std::string, GainTrackingAttributeFromBin> fromBinMethods;
00670 void antennaIdFromBin( EndianIStream& eis);
00671 void spectralWindowIdFromBin( EndianIStream& eis);
00672 void timeIntervalFromBin( EndianIStream& eis);
00673 void feedIdFromBin( EndianIStream& eis);
00674 void numReceptorFromBin( EndianIStream& eis);
00675 void attenuatorFromBin( EndianIStream& eis);
00676 void polarizationTypeFromBin( EndianIStream& eis);
00677 
00678 void samplingLevelFromBin( EndianIStream& eis);
00679 void numAttFreqFromBin( EndianIStream& eis);
00680 void attFreqFromBin( EndianIStream& eis);
00681 void attSpectrumFromBin( EndianIStream& eis);
00682 
00683 
00691          static GainTrackingRow* fromBin(EndianIStream& eis, GainTrackingTable& table, const std::vector<std::string>& attributesSeq);   
00692  
00699          void fromText(const std::string& attributeName, const std::string&  t);
00701 
00702 private:
00706         GainTrackingTable &table;
00710         bool hasBeenAdded;
00711 
00712         // This method is used by the Table class when this row is added to the table.
00713         void isAdded(bool added);
00714 
00715 
00724         GainTrackingRow (GainTrackingTable &table);
00725 
00743          GainTrackingRow (GainTrackingTable &table, GainTrackingRow &row);
00744                 
00746         // Intrinsic Table Attributes //
00748         
00749         
00750         // ===> Attribute timeInterval
00751         
00752         
00753 
00754         ArrayTimeInterval timeInterval;
00755 
00756         
00757         
00758         
00759 
00760         
00761         // ===> Attribute numReceptor
00762         
00763         
00764 
00765         int numReceptor;
00766 
00767         
00768         
00769         
00770 
00771         
00772         // ===> Attribute attenuator
00773         
00774         
00775 
00776         vector<float > attenuator;
00777 
00778         
00779         
00780         
00781 
00782         
00783         // ===> Attribute polarizationType
00784         
00785         
00786 
00787         vector<PolarizationTypeMod::PolarizationType > polarizationType;
00788 
00789         
00790         
00791         
00792 
00793         
00794         // ===> Attribute samplingLevel, which is optional
00795         
00796         
00797         bool samplingLevelExists;
00798         
00799 
00800         float samplingLevel;
00801 
00802         
00803         
00804         
00805 
00806         
00807         // ===> Attribute numAttFreq, which is optional
00808         
00809         
00810         bool numAttFreqExists;
00811         
00812 
00813         int numAttFreq;
00814 
00815         
00816         
00817         
00818 
00819         
00820         // ===> Attribute attFreq, which is optional
00821         
00822         
00823         bool attFreqExists;
00824         
00825 
00826         vector<double > attFreq;
00827 
00828         
00829         
00830         
00831 
00832         
00833         // ===> Attribute attSpectrum, which is optional
00834         
00835         
00836         bool attSpectrumExists;
00837         
00838 
00839         vector<Complex > attSpectrum;
00840 
00841         
00842         
00843         
00844 
00846         // Extrinsic Table Attributes //
00848         
00849         
00850         // ===> Attribute antennaId
00851         
00852         
00853 
00854         Tag antennaId;
00855 
00856         
00857         
00858         
00859 
00860         
00861         // ===> Attribute feedId
00862         
00863         
00864 
00865         int feedId;
00866 
00867         
00868         
00869         
00870 
00871         
00872         // ===> Attribute spectralWindowId
00873         
00874         
00875 
00876         Tag spectralWindowId;
00877 
00878         
00879         
00880         
00881 
00883         // Links //
00885         
00886         
00887                 
00888 
00889          
00890 
00891         
00892 
00893         
00894                 
00895 
00896          
00897 
00898         
00899 
00900         
00901                 
00902 
00903 
00904         
00905 
00906         
00907 /*
00909         // binary-deserialization material from an EndianIStream  //
00911         std::map<std::string, GainTrackingAttributeFromBin> fromBinMethods;
00912 void antennaIdFromBin( EndianIStream& eis);
00913 void spectralWindowIdFromBin( EndianIStream& eis);
00914 void timeIntervalFromBin( EndianIStream& eis);
00915 void feedIdFromBin( EndianIStream& eis);
00916 void numReceptorFromBin( EndianIStream& eis);
00917 void attenuatorFromBin( EndianIStream& eis);
00918 void polarizationTypeFromBin( EndianIStream& eis);
00919 
00920 void samplingLevelFromBin( EndianIStream& eis);
00921 void numAttFreqFromBin( EndianIStream& eis);
00922 void attFreqFromBin( EndianIStream& eis);
00923 void attSpectrumFromBin( EndianIStream& eis);
00924 
00925 */
00926         
00928         // text-deserialization material //
00930         std::map<std::string, GainTrackingAttributeFromText> fromTextMethods;
00931         
00932 void antennaIdFromText (const string & s);
00933         
00934         
00935 void spectralWindowIdFromText (const string & s);
00936         
00937         
00938 void timeIntervalFromText (const string & s);
00939         
00940         
00941 void feedIdFromText (const string & s);
00942         
00943         
00944 void numReceptorFromText (const string & s);
00945         
00946         
00947 void attenuatorFromText (const string & s);
00948         
00949         
00950 void polarizationTypeFromText (const string & s);
00951         
00952 
00953         
00954 void samplingLevelFromText (const string & s);
00955         
00956         
00957 void numAttFreqFromText (const string & s);
00958         
00959         
00960 void attFreqFromText (const string & s);
00961         
00962         
00963 void attSpectrumFromText (const string & s);
00964         
00965         
00966         
00971          void toBin(EndianOSStream& eoss);
00972                  
00982 };
00983 
00984 } // End namespace asdm
00985 
00986 #endif /* GainTracking_CLASS */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines