casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
CalPrimaryBeamRow.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 CalPrimaryBeamRow.h
00032  */
00033  
00034 #ifndef CalPrimaryBeamRow_CLASS
00035 #define CalPrimaryBeamRow_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 <ArrayTime.h>
00052         
00053 
00054          
00055 #include <Angle.h>
00056         
00057 
00058          
00059 #include <Tag.h>
00060         
00061 
00062          
00063 #include <Frequency.h>
00064         
00065 
00066          
00067 #include <EntityRef.h>
00068         
00069 
00070 
00071 
00072 
00073         
00074 
00075         
00076 #include "CReceiverBand.h"
00077         
00078 
00079         
00080 
00081         
00082 
00083         
00084 #include "CAntennaMake.h"
00085         
00086 
00087         
00088 
00089         
00090 
00091         
00092 
00093         
00094 #include "CPolarizationType.h"
00095         
00096 
00097         
00098 
00099         
00100 
00101         
00102 
00103         
00104 
00105         
00106 
00107         
00108 
00109         
00110 #include "CPrimaryBeamDescription.h"
00111         
00112 
00113         
00114 
00115         
00116 
00117 
00118 
00119 #include <ConversionException.h>
00120 #include <NoSuchRow.h>
00121 #include <IllegalAccessException.h>
00122 
00123 #include <RowTransformer.h>
00124 //#include <TableStreamReader.h>
00125 
00126 /*\file CalPrimaryBeam.h
00127     \brief Generated from model's revision "1.64", branch "HEAD"
00128 */
00129 
00130 namespace asdm {
00131 
00132 //class asdm::CalPrimaryBeamTable;
00133 
00134 
00135 // class asdm::CalReductionRow;
00136 class CalReductionRow;
00137 
00138 // class asdm::CalDataRow;
00139 class CalDataRow;
00140         
00141 
00142 class CalPrimaryBeamRow;
00143 typedef void (CalPrimaryBeamRow::*CalPrimaryBeamAttributeFromBin) (EndianIStream& eis);
00144 typedef void (CalPrimaryBeamRow::*CalPrimaryBeamAttributeFromText) (const string& s);
00145 
00152 class CalPrimaryBeamRow {
00153 friend class asdm::CalPrimaryBeamTable;
00154 friend class asdm::RowTransformer<CalPrimaryBeamRow>;
00155 //friend class asdm::TableStreamReader<CalPrimaryBeamTable, CalPrimaryBeamRow>;
00156 
00157 public:
00158 
00159         virtual ~CalPrimaryBeamRow();
00160 
00164         CalPrimaryBeamTable &getTable() const;
00165         
00170         bool isAdded() const;
00171                 
00173         // Intrinsic Table Attributes //
00175         
00176         
00177         // ===> Attribute antennaName
00178         
00179         
00180         
00181 
00182         
00187         string getAntennaName() const;
00188         
00189  
00190         
00191         
00201         void setAntennaName (string antennaName);
00202                 
00203         
00204         
00205         
00206 
00207 
00208         
00209         // ===> Attribute receiverBand
00210         
00211         
00212         
00213 
00214         
00219         ReceiverBandMod::ReceiverBand getReceiverBand() const;
00220         
00221  
00222         
00223         
00233         void setReceiverBand (ReceiverBandMod::ReceiverBand receiverBand);
00234                 
00235         
00236         
00237         
00238 
00239 
00240         
00241         // ===> Attribute startValidTime
00242         
00243         
00244         
00245 
00246         
00251         ArrayTime getStartValidTime() const;
00252         
00253  
00254         
00255         
00263         void setStartValidTime (ArrayTime startValidTime);
00264                 
00265         
00266         
00267         
00268 
00269 
00270         
00271         // ===> Attribute endValidTime
00272         
00273         
00274         
00275 
00276         
00281         ArrayTime getEndValidTime() const;
00282         
00283  
00284         
00285         
00293         void setEndValidTime (ArrayTime endValidTime);
00294                 
00295         
00296         
00297         
00298 
00299 
00300         
00301         // ===> Attribute antennaMake
00302         
00303         
00304         
00305 
00306         
00311         AntennaMakeMod::AntennaMake getAntennaMake() const;
00312         
00313  
00314         
00315         
00323         void setAntennaMake (AntennaMakeMod::AntennaMake antennaMake);
00324                 
00325         
00326         
00327         
00328 
00329 
00330         
00331         // ===> Attribute numSubband
00332         
00333         
00334         
00335 
00336         
00341         int getNumSubband() const;
00342         
00343  
00344         
00345         
00353         void setNumSubband (int numSubband);
00354                 
00355         
00356         
00357         
00358 
00359 
00360         
00361         // ===> Attribute frequencyRange
00362         
00363         
00364         
00365 
00366         
00371         vector<vector<Frequency > > getFrequencyRange() const;
00372         
00373  
00374         
00375         
00383         void setFrequencyRange (vector<vector<Frequency > > frequencyRange);
00384                 
00385         
00386         
00387         
00388 
00389 
00390         
00391         // ===> Attribute numReceptor
00392         
00393         
00394         
00395 
00396         
00401         int getNumReceptor() const;
00402         
00403  
00404         
00405         
00413         void setNumReceptor (int numReceptor);
00414                 
00415         
00416         
00417         
00418 
00419 
00420         
00421         // ===> Attribute polarizationTypes
00422         
00423         
00424         
00425 
00426         
00431         vector<PolarizationTypeMod::PolarizationType > getPolarizationTypes() const;
00432         
00433  
00434         
00435         
00443         void setPolarizationTypes (vector<PolarizationTypeMod::PolarizationType > polarizationTypes);
00444                 
00445         
00446         
00447         
00448 
00449 
00450         
00451         // ===> Attribute mainBeamEfficiency
00452         
00453         
00454         
00455 
00456         
00461         vector<double > getMainBeamEfficiency() const;
00462         
00463  
00464         
00465         
00473         void setMainBeamEfficiency (vector<double > mainBeamEfficiency);
00474                 
00475         
00476         
00477         
00478 
00479 
00480         
00481         // ===> Attribute beamDescriptionUID
00482         
00483         
00484         
00485 
00486         
00491         EntityRef getBeamDescriptionUID() const;
00492         
00493  
00494         
00495         
00503         void setBeamDescriptionUID (EntityRef beamDescriptionUID);
00504                 
00505         
00506         
00507         
00508 
00509 
00510         
00511         // ===> Attribute relativeAmplitudeRms
00512         
00513         
00514         
00515 
00516         
00521         float getRelativeAmplitudeRms() const;
00522         
00523  
00524         
00525         
00533         void setRelativeAmplitudeRms (float relativeAmplitudeRms);
00534                 
00535         
00536         
00537         
00538 
00539 
00540         
00541         // ===> Attribute direction
00542         
00543         
00544         
00545 
00546         
00551         vector<Angle > getDirection() const;
00552         
00553  
00554         
00555         
00563         void setDirection (vector<Angle > direction);
00564                 
00565         
00566         
00567         
00568 
00569 
00570         
00571         // ===> Attribute minValidDirection
00572         
00573         
00574         
00575 
00576         
00581         vector<Angle > getMinValidDirection() const;
00582         
00583  
00584         
00585         
00593         void setMinValidDirection (vector<Angle > minValidDirection);
00594                 
00595         
00596         
00597         
00598 
00599 
00600         
00601         // ===> Attribute maxValidDirection
00602         
00603         
00604         
00605 
00606         
00611         vector<Angle > getMaxValidDirection() const;
00612         
00613  
00614         
00615         
00623         void setMaxValidDirection (vector<Angle > maxValidDirection);
00624                 
00625         
00626         
00627         
00628 
00629 
00630         
00631         // ===> Attribute descriptionType
00632         
00633         
00634         
00635 
00636         
00641         PrimaryBeamDescriptionMod::PrimaryBeamDescription getDescriptionType() const;
00642         
00643  
00644         
00645         
00653         void setDescriptionType (PrimaryBeamDescriptionMod::PrimaryBeamDescription descriptionType);
00654                 
00655         
00656         
00657         
00658 
00659 
00660         
00661         // ===> Attribute imageChannelNumber
00662         
00663         
00664         
00665 
00666         
00671         vector<int > getImageChannelNumber() const;
00672         
00673  
00674         
00675         
00683         void setImageChannelNumber (vector<int > imageChannelNumber);
00684                 
00685         
00686         
00687         
00688 
00689 
00690         
00691         // ===> Attribute imageNominalFrequency
00692         
00693         
00694         
00695 
00696         
00701         vector<Frequency > getImageNominalFrequency() const;
00702         
00703  
00704         
00705         
00713         void setImageNominalFrequency (vector<Frequency > imageNominalFrequency);
00714                 
00715         
00716         
00717         
00718 
00719 
00721         // Extrinsic Table Attributes //
00723         
00724         
00725         // ===> Attribute calDataId
00726         
00727         
00728         
00729 
00730         
00735         Tag getCalDataId() const;
00736         
00737  
00738         
00739         
00749         void setCalDataId (Tag calDataId);
00750                 
00751         
00752         
00753         
00754 
00755 
00756         
00757         // ===> Attribute calReductionId
00758         
00759         
00760         
00761 
00762         
00767         Tag getCalReductionId() const;
00768         
00769  
00770         
00771         
00781         void setCalReductionId (Tag calReductionId);
00782                 
00783         
00784         
00785         
00786 
00787 
00789         // Links //
00791         
00792         
00793 
00794         
00795                 
00802          CalReductionRow* getCalReductionUsingCalReductionId();
00803          
00804 
00805         
00806 
00807         
00808 
00809         
00810                 
00817          CalDataRow* getCalDataUsingCalDataId();
00818          
00819 
00820         
00821 
00822         
00823         
00824         
00870         bool compareNoAutoInc(string antennaName, ReceiverBandMod::ReceiverBand receiverBand, Tag calDataId, Tag calReductionId, ArrayTime startValidTime, ArrayTime endValidTime, AntennaMakeMod::AntennaMake antennaMake, int numSubband, vector<vector<Frequency > > frequencyRange, int numReceptor, vector<PolarizationTypeMod::PolarizationType > polarizationTypes, vector<double > mainBeamEfficiency, EntityRef beamDescriptionUID, float relativeAmplitudeRms, vector<Angle > direction, vector<Angle > minValidDirection, vector<Angle > maxValidDirection, PrimaryBeamDescriptionMod::PrimaryBeamDescription descriptionType, vector<int > imageChannelNumber, vector<Frequency > imageNominalFrequency);
00871         
00872         
00873 
00874         
00912         bool compareRequiredValue(ArrayTime startValidTime, ArrayTime endValidTime, AntennaMakeMod::AntennaMake antennaMake, int numSubband, vector<vector<Frequency > > frequencyRange, int numReceptor, vector<PolarizationTypeMod::PolarizationType > polarizationTypes, vector<double > mainBeamEfficiency, EntityRef beamDescriptionUID, float relativeAmplitudeRms, vector<Angle > direction, vector<Angle > minValidDirection, vector<Angle > maxValidDirection, PrimaryBeamDescriptionMod::PrimaryBeamDescription descriptionType, vector<int > imageChannelNumber, vector<Frequency > imageNominalFrequency); 
00913                  
00914         
00923         bool equalByRequiredValue(CalPrimaryBeamRow* x) ;
00924         
00925 #ifndef WITHOUT_ACS
00926 
00930         asdmIDL::CalPrimaryBeamRowIDL *toIDL() const;
00931         
00939          void toIDL(asdmIDL::CalPrimaryBeamRowIDL& x) const;
00940 #endif
00941         
00942 #ifndef WITHOUT_ACS
00943 
00948         void setFromIDL (asdmIDL::CalPrimaryBeamRowIDL x) ;
00949 #endif
00950         
00955         std::string toXML() const;
00956 
00963         void setFromXML (std::string rowDoc) ;
00964 
00967         // binary-deserialization material from an EndianIStream  //
00969 
00970         std::map<std::string, CalPrimaryBeamAttributeFromBin> fromBinMethods;
00971 void antennaNameFromBin( EndianIStream& eis);
00972 void receiverBandFromBin( EndianIStream& eis);
00973 void calDataIdFromBin( EndianIStream& eis);
00974 void calReductionIdFromBin( EndianIStream& eis);
00975 void startValidTimeFromBin( EndianIStream& eis);
00976 void endValidTimeFromBin( EndianIStream& eis);
00977 void antennaMakeFromBin( EndianIStream& eis);
00978 void numSubbandFromBin( EndianIStream& eis);
00979 void frequencyRangeFromBin( EndianIStream& eis);
00980 void numReceptorFromBin( EndianIStream& eis);
00981 void polarizationTypesFromBin( EndianIStream& eis);
00982 void mainBeamEfficiencyFromBin( EndianIStream& eis);
00983 void beamDescriptionUIDFromBin( EndianIStream& eis);
00984 void relativeAmplitudeRmsFromBin( EndianIStream& eis);
00985 void directionFromBin( EndianIStream& eis);
00986 void minValidDirectionFromBin( EndianIStream& eis);
00987 void maxValidDirectionFromBin( EndianIStream& eis);
00988 void descriptionTypeFromBin( EndianIStream& eis);
00989 void imageChannelNumberFromBin( EndianIStream& eis);
00990 void imageNominalFrequencyFromBin( EndianIStream& eis);
00991 
00992         
00993 
01001          static CalPrimaryBeamRow* fromBin(EndianIStream& eis, CalPrimaryBeamTable& table, const std::vector<std::string>& attributesSeq);       
01002  
01009          void fromText(const std::string& attributeName, const std::string&  t);
01011 
01012 private:
01016         CalPrimaryBeamTable &table;
01020         bool hasBeenAdded;
01021 
01022         // This method is used by the Table class when this row is added to the table.
01023         void isAdded(bool added);
01024 
01025 
01034         CalPrimaryBeamRow (CalPrimaryBeamTable &table);
01035 
01053          CalPrimaryBeamRow (CalPrimaryBeamTable &table, CalPrimaryBeamRow &row);
01054                 
01056         // Intrinsic Table Attributes //
01058         
01059         
01060         // ===> Attribute antennaName
01061         
01062         
01063 
01064         string antennaName;
01065 
01066         
01067         
01068         
01069 
01070         
01071         // ===> Attribute receiverBand
01072         
01073         
01074 
01075         ReceiverBandMod::ReceiverBand receiverBand;
01076 
01077         
01078         
01079         
01080 
01081         
01082         // ===> Attribute startValidTime
01083         
01084         
01085 
01086         ArrayTime startValidTime;
01087 
01088         
01089         
01090         
01091 
01092         
01093         // ===> Attribute endValidTime
01094         
01095         
01096 
01097         ArrayTime endValidTime;
01098 
01099         
01100         
01101         
01102 
01103         
01104         // ===> Attribute antennaMake
01105         
01106         
01107 
01108         AntennaMakeMod::AntennaMake antennaMake;
01109 
01110         
01111         
01112         
01113 
01114         
01115         // ===> Attribute numSubband
01116         
01117         
01118 
01119         int numSubband;
01120 
01121         
01122         
01123         
01124 
01125         
01126         // ===> Attribute frequencyRange
01127         
01128         
01129 
01130         vector<vector<Frequency > > frequencyRange;
01131 
01132         
01133         
01134         
01135 
01136         
01137         // ===> Attribute numReceptor
01138         
01139         
01140 
01141         int numReceptor;
01142 
01143         
01144         
01145         
01146 
01147         
01148         // ===> Attribute polarizationTypes
01149         
01150         
01151 
01152         vector<PolarizationTypeMod::PolarizationType > polarizationTypes;
01153 
01154         
01155         
01156         
01157 
01158         
01159         // ===> Attribute mainBeamEfficiency
01160         
01161         
01162 
01163         vector<double > mainBeamEfficiency;
01164 
01165         
01166         
01167         
01168 
01169         
01170         // ===> Attribute beamDescriptionUID
01171         
01172         
01173 
01174         EntityRef beamDescriptionUID;
01175 
01176         
01177         
01178         
01179 
01180         
01181         // ===> Attribute relativeAmplitudeRms
01182         
01183         
01184 
01185         float relativeAmplitudeRms;
01186 
01187         
01188         
01189         
01190 
01191         
01192         // ===> Attribute direction
01193         
01194         
01195 
01196         vector<Angle > direction;
01197 
01198         
01199         
01200         
01201 
01202         
01203         // ===> Attribute minValidDirection
01204         
01205         
01206 
01207         vector<Angle > minValidDirection;
01208 
01209         
01210         
01211         
01212 
01213         
01214         // ===> Attribute maxValidDirection
01215         
01216         
01217 
01218         vector<Angle > maxValidDirection;
01219 
01220         
01221         
01222         
01223 
01224         
01225         // ===> Attribute descriptionType
01226         
01227         
01228 
01229         PrimaryBeamDescriptionMod::PrimaryBeamDescription descriptionType;
01230 
01231         
01232         
01233         
01234 
01235         
01236         // ===> Attribute imageChannelNumber
01237         
01238         
01239 
01240         vector<int > imageChannelNumber;
01241 
01242         
01243         
01244         
01245 
01246         
01247         // ===> Attribute imageNominalFrequency
01248         
01249         
01250 
01251         vector<Frequency > imageNominalFrequency;
01252 
01253         
01254         
01255         
01256 
01258         // Extrinsic Table Attributes //
01260         
01261         
01262         // ===> Attribute calDataId
01263         
01264         
01265 
01266         Tag calDataId;
01267 
01268         
01269         
01270         
01271 
01272         
01273         // ===> Attribute calReductionId
01274         
01275         
01276 
01277         Tag calReductionId;
01278 
01279         
01280         
01281         
01282 
01284         // Links //
01286         
01287         
01288                 
01289 
01290          
01291 
01292         
01293 
01294         
01295                 
01296 
01297          
01298 
01299         
01300 
01301         
01302 /*
01304         // binary-deserialization material from an EndianIStream  //
01306         std::map<std::string, CalPrimaryBeamAttributeFromBin> fromBinMethods;
01307 void antennaNameFromBin( EndianIStream& eis);
01308 void receiverBandFromBin( EndianIStream& eis);
01309 void calDataIdFromBin( EndianIStream& eis);
01310 void calReductionIdFromBin( EndianIStream& eis);
01311 void startValidTimeFromBin( EndianIStream& eis);
01312 void endValidTimeFromBin( EndianIStream& eis);
01313 void antennaMakeFromBin( EndianIStream& eis);
01314 void numSubbandFromBin( EndianIStream& eis);
01315 void frequencyRangeFromBin( EndianIStream& eis);
01316 void numReceptorFromBin( EndianIStream& eis);
01317 void polarizationTypesFromBin( EndianIStream& eis);
01318 void mainBeamEfficiencyFromBin( EndianIStream& eis);
01319 void beamDescriptionUIDFromBin( EndianIStream& eis);
01320 void relativeAmplitudeRmsFromBin( EndianIStream& eis);
01321 void directionFromBin( EndianIStream& eis);
01322 void minValidDirectionFromBin( EndianIStream& eis);
01323 void maxValidDirectionFromBin( EndianIStream& eis);
01324 void descriptionTypeFromBin( EndianIStream& eis);
01325 void imageChannelNumberFromBin( EndianIStream& eis);
01326 void imageNominalFrequencyFromBin( EndianIStream& eis);
01327 
01328         
01329 */
01330         
01332         // text-deserialization material //
01334         std::map<std::string, CalPrimaryBeamAttributeFromText> fromTextMethods;
01335         
01336 void antennaNameFromText (const string & s);
01337         
01338         
01339 void receiverBandFromText (const string & s);
01340         
01341         
01342 void calDataIdFromText (const string & s);
01343         
01344         
01345 void calReductionIdFromText (const string & s);
01346         
01347         
01348 void startValidTimeFromText (const string & s);
01349         
01350         
01351 void endValidTimeFromText (const string & s);
01352         
01353         
01354 void antennaMakeFromText (const string & s);
01355         
01356         
01357 void numSubbandFromText (const string & s);
01358         
01359         
01360 void frequencyRangeFromText (const string & s);
01361         
01362         
01363 void numReceptorFromText (const string & s);
01364         
01365         
01366 void polarizationTypesFromText (const string & s);
01367         
01368         
01369 void mainBeamEfficiencyFromText (const string & s);
01370         
01371         
01372         
01373 void relativeAmplitudeRmsFromText (const string & s);
01374         
01375         
01376 void directionFromText (const string & s);
01377         
01378         
01379 void minValidDirectionFromText (const string & s);
01380         
01381         
01382 void maxValidDirectionFromText (const string & s);
01383         
01384         
01385 void descriptionTypeFromText (const string & s);
01386         
01387         
01388 void imageChannelNumberFromText (const string & s);
01389         
01390         
01391 void imageNominalFrequencyFromText (const string & s);
01392         
01393 
01394                 
01395         
01400          void toBin(EndianOSStream& eoss);
01401                  
01411 };
01412 
01413 } // End namespace asdm
01414 
01415 #endif /* CalPrimaryBeam_CLASS */