casa  $Rev:20696$
FocusModelRow.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 FocusModelRow.h
00032  */
00033  
00034 #ifndef FocusModelRow_CLASS
00035 #define FocusModelRow_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 
00056 
00057         
00058 
00059         
00060 #include "CPolarizationType.h"
00061         
00062 
00063         
00064 #include "CReceiverBand.h"
00065         
00066 
00067         
00068 
00069         
00070 
00071         
00072 
00073         
00074 
00075         
00076 
00077 
00078 
00079 #include <ConversionException.h>
00080 #include <NoSuchRow.h>
00081 #include <IllegalAccessException.h>
00082 
00083 #include <RowTransformer.h>
00084 //#include <TableStreamReader.h>
00085 
00086 /*\file FocusModel.h
00087     \brief Generated from model's revision "1.62", branch "HEAD"
00088 */
00089 
00090 namespace asdm {
00091 
00092 //class asdm::FocusModelTable;
00093 
00094 
00095 // class asdm::AntennaRow;
00096 class AntennaRow;
00097 
00098 // class asdm::FocusModelRow;
00099 class FocusModelRow;
00100         
00101 
00102 class FocusModelRow;
00103 typedef void (FocusModelRow::*FocusModelAttributeFromBin) (EndianIStream& eis);
00104 typedef void (FocusModelRow::*FocusModelAttributeFromText) (const string& s);
00105 
00112 class FocusModelRow {
00113 friend class asdm::FocusModelTable;
00114 friend class asdm::RowTransformer<FocusModelRow>;
00115 //friend class asdm::TableStreamReader<FocusModelTable, FocusModelRow>;
00116 
00117 public:
00118 
00119         virtual ~FocusModelRow();
00120 
00124         FocusModelTable &getTable() const;
00125         
00130         bool isAdded() const;
00131                 
00133         // Intrinsic Table Attributes //
00135         
00136         
00137         // ===> Attribute focusModelId
00138         
00139         
00140         
00141 
00142         
00147         int getFocusModelId() const;
00148         
00149  
00150         
00151         
00152         
00153         
00154 
00155 
00156         
00157         // ===> Attribute polarizationType
00158         
00159         
00160         
00161 
00162         
00167         PolarizationTypeMod::PolarizationType getPolarizationType() const;
00168         
00169  
00170         
00171         
00179         void setPolarizationType (PolarizationTypeMod::PolarizationType polarizationType);
00180                 
00181         
00182         
00183         
00184 
00185 
00186         
00187         // ===> Attribute receiverBand
00188         
00189         
00190         
00191 
00192         
00197         ReceiverBandMod::ReceiverBand getReceiverBand() const;
00198         
00199  
00200         
00201         
00209         void setReceiverBand (ReceiverBandMod::ReceiverBand receiverBand);
00210                 
00211         
00212         
00213         
00214 
00215 
00216         
00217         // ===> Attribute numCoeff
00218         
00219         
00220         
00221 
00222         
00227         int getNumCoeff() const;
00228         
00229  
00230         
00231         
00239         void setNumCoeff (int numCoeff);
00240                 
00241         
00242         
00243         
00244 
00245 
00246         
00247         // ===> Attribute coeffName
00248         
00249         
00250         
00251 
00252         
00257         vector<string > getCoeffName() const;
00258         
00259  
00260         
00261         
00269         void setCoeffName (vector<string > coeffName);
00270                 
00271         
00272         
00273         
00274 
00275 
00276         
00277         // ===> Attribute coeffFormula
00278         
00279         
00280         
00281 
00282         
00287         vector<string > getCoeffFormula() const;
00288         
00289  
00290         
00291         
00299         void setCoeffFormula (vector<string > coeffFormula);
00300                 
00301         
00302         
00303         
00304 
00305 
00306         
00307         // ===> Attribute coeffVal
00308         
00309         
00310         
00311 
00312         
00317         vector<float > getCoeffVal() const;
00318         
00319  
00320         
00321         
00329         void setCoeffVal (vector<float > coeffVal);
00330                 
00331         
00332         
00333         
00334 
00335 
00336         
00337         // ===> Attribute assocNature
00338         
00339         
00340         
00341 
00342         
00347         string getAssocNature() const;
00348         
00349  
00350         
00351         
00359         void setAssocNature (string assocNature);
00360                 
00361         
00362         
00363         
00364 
00365 
00367         // Extrinsic Table Attributes //
00369         
00370         
00371         // ===> Attribute antennaId
00372         
00373         
00374         
00375 
00376         
00381         Tag getAntennaId() const;
00382         
00383  
00384         
00385         
00395         void setAntennaId (Tag antennaId);
00396                 
00397         
00398         
00399         
00400 
00401 
00402         
00403         // ===> Attribute assocFocusModelId
00404         
00405         
00406         
00407 
00408         
00413         int getAssocFocusModelId() const;
00414         
00415  
00416         
00417         
00425         void setAssocFocusModelId (int assocFocusModelId);
00426                 
00427         
00428         
00429         
00430 
00431 
00433         // Links //
00435         
00436         
00437 
00438         
00439                 
00446          AntennaRow* getAntennaUsingAntennaId();
00447          
00448 
00449         
00450 
00451         
00452 
00453         
00454                 
00455         // ===> Slice link from a row of FocusModel table to a collection of row of FocusModel table.
00456         
00462         vector <FocusModelRow *> getFocusModels();
00463         
00464         
00465 
00466         
00467 
00468         
00469         
00470         
00494         bool compareNoAutoInc(Tag antennaId, PolarizationTypeMod::PolarizationType polarizationType, ReceiverBandMod::ReceiverBand receiverBand, int numCoeff, vector<string > coeffName, vector<string > coeffFormula, vector<float > coeffVal, string assocNature, int assocFocusModelId);
00495         
00496         
00497 
00498         
00520         bool compareRequiredValue(PolarizationTypeMod::PolarizationType polarizationType, ReceiverBandMod::ReceiverBand receiverBand, int numCoeff, vector<string > coeffName, vector<string > coeffFormula, vector<float > coeffVal, string assocNature, int assocFocusModelId); 
00521                  
00522         
00531         bool equalByRequiredValue(FocusModelRow* x) ;
00532         
00533 #ifndef WITHOUT_ACS
00534 
00538         asdmIDL::FocusModelRowIDL *toIDL() const;
00539 #endif
00540         
00541 #ifndef WITHOUT_ACS
00542 
00547         void setFromIDL (asdmIDL::FocusModelRowIDL x) ;
00548 #endif
00549         
00554         std::string toXML() const;
00555 
00562         void setFromXML (std::string rowDoc) ;
00563 
00566         // binary-deserialization material from an EndianIStream  //
00568 
00569         std::map<std::string, FocusModelAttributeFromBin> fromBinMethods;
00570 void antennaIdFromBin( EndianIStream& eis);
00571 void focusModelIdFromBin( EndianIStream& eis);
00572 void polarizationTypeFromBin( EndianIStream& eis);
00573 void receiverBandFromBin( EndianIStream& eis);
00574 void numCoeffFromBin( EndianIStream& eis);
00575 void coeffNameFromBin( EndianIStream& eis);
00576 void coeffFormulaFromBin( EndianIStream& eis);
00577 void coeffValFromBin( EndianIStream& eis);
00578 void assocNatureFromBin( EndianIStream& eis);
00579 void assocFocusModelIdFromBin( EndianIStream& eis);
00580 
00581         
00582 
00590          static FocusModelRow* fromBin(EndianIStream& eis, FocusModelTable& table, const std::vector<std::string>& attributesSeq);       
00591  
00598          void fromText(const std::string& attributeName, const std::string&  t);
00600 
00601 private:
00605         FocusModelTable &table;
00609         bool hasBeenAdded;
00610 
00611         // This method is used by the Table class when this row is added to the table.
00612         void isAdded(bool added);
00613 
00614 
00623         FocusModelRow (FocusModelTable &table);
00624 
00642          FocusModelRow (FocusModelTable &table, FocusModelRow &row);
00643                 
00645         // Intrinsic Table Attributes //
00647         
00648         
00649         // ===> Attribute focusModelId
00650         
00651         
00652 
00653         int focusModelId;
00654 
00655         
00656         
00657         
00667         void setFocusModelId (int focusModelId);
00668                 
00669         
00670 
00671         
00672         // ===> Attribute polarizationType
00673         
00674         
00675 
00676         PolarizationTypeMod::PolarizationType polarizationType;
00677 
00678         
00679         
00680         
00681 
00682         
00683         // ===> Attribute receiverBand
00684         
00685         
00686 
00687         ReceiverBandMod::ReceiverBand receiverBand;
00688 
00689         
00690         
00691         
00692 
00693         
00694         // ===> Attribute numCoeff
00695         
00696         
00697 
00698         int numCoeff;
00699 
00700         
00701         
00702         
00703 
00704         
00705         // ===> Attribute coeffName
00706         
00707         
00708 
00709         vector<string > coeffName;
00710 
00711         
00712         
00713         
00714 
00715         
00716         // ===> Attribute coeffFormula
00717         
00718         
00719 
00720         vector<string > coeffFormula;
00721 
00722         
00723         
00724         
00725 
00726         
00727         // ===> Attribute coeffVal
00728         
00729         
00730 
00731         vector<float > coeffVal;
00732 
00733         
00734         
00735         
00736 
00737         
00738         // ===> Attribute assocNature
00739         
00740         
00741 
00742         string assocNature;
00743 
00744         
00745         
00746         
00747 
00749         // Extrinsic Table Attributes //
00751         
00752         
00753         // ===> Attribute antennaId
00754         
00755         
00756 
00757         Tag antennaId;
00758 
00759         
00760         
00761         
00762 
00763         
00764         // ===> Attribute assocFocusModelId
00765         
00766         
00767 
00768         int assocFocusModelId;
00769 
00770         
00771         
00772         
00773 
00775         // Links //
00777         
00778         
00779                 
00780 
00781          
00782 
00783         
00784 
00785         
00786                 
00787 
00788 
00789         
00790 
00791         
00792 /*
00794         // binary-deserialization material from an EndianIStream  //
00796         std::map<std::string, FocusModelAttributeFromBin> fromBinMethods;
00797 void antennaIdFromBin( EndianIStream& eis);
00798 void focusModelIdFromBin( EndianIStream& eis);
00799 void polarizationTypeFromBin( EndianIStream& eis);
00800 void receiverBandFromBin( EndianIStream& eis);
00801 void numCoeffFromBin( EndianIStream& eis);
00802 void coeffNameFromBin( EndianIStream& eis);
00803 void coeffFormulaFromBin( EndianIStream& eis);
00804 void coeffValFromBin( EndianIStream& eis);
00805 void assocNatureFromBin( EndianIStream& eis);
00806 void assocFocusModelIdFromBin( EndianIStream& eis);
00807 
00808         
00809 */
00810         
00812         // text-deserialization material //
00814         std::map<std::string, FocusModelAttributeFromText> fromTextMethods;
00815         
00816 void antennaIdFromText (const string & s);
00817         
00818         
00819 void focusModelIdFromText (const string & s);
00820         
00821         
00822 void polarizationTypeFromText (const string & s);
00823         
00824         
00825 void receiverBandFromText (const string & s);
00826         
00827         
00828 void numCoeffFromText (const string & s);
00829         
00830         
00831 void coeffNameFromText (const string & s);
00832         
00833         
00834 void coeffFormulaFromText (const string & s);
00835         
00836         
00837 void coeffValFromText (const string & s);
00838         
00839         
00840 void assocNatureFromText (const string & s);
00841         
00842         
00843 void assocFocusModelIdFromText (const string & s);
00844         
00845 
00846                 
00847         
00852          void toBin(EndianOSStream& eoss);
00853                  
00863 };
00864 
00865 } // End namespace asdm
00866 
00867 #endif /* FocusModel_CLASS */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines