casa  $Rev:20696$
ReceiverRow.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 ReceiverRow.h
00032  */
00033  
00034 #ifndef ReceiverRow_CLASS
00035 #define ReceiverRow_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 <Frequency.h>
00056         
00057 
00058          
00059 #include <ArrayTimeInterval.h>
00060         
00061 
00062 
00063 
00064 
00065         
00066 
00067         
00068 
00069         
00070 
00071         
00072 
00073         
00074 #include "CReceiverBand.h"
00075         
00076 
00077         
00078 
00079         
00080 #include "CReceiverSideband.h"
00081         
00082 
00083         
00084 #include "CNetSideband.h"
00085         
00086 
00087 
00088 
00089 #include <ConversionException.h>
00090 #include <NoSuchRow.h>
00091 #include <IllegalAccessException.h>
00092 
00093 #include <RowTransformer.h>
00094 //#include <TableStreamReader.h>
00095 
00096 /*\file Receiver.h
00097     \brief Generated from model's revision "1.62", branch "HEAD"
00098 */
00099 
00100 namespace asdm {
00101 
00102 //class asdm::ReceiverTable;
00103 
00104 
00105 // class asdm::SpectralWindowRow;
00106 class SpectralWindowRow;
00107         
00108 
00109 class ReceiverRow;
00110 typedef void (ReceiverRow::*ReceiverAttributeFromBin) (EndianIStream& eis);
00111 typedef void (ReceiverRow::*ReceiverAttributeFromText) (const string& s);
00112 
00119 class ReceiverRow {
00120 friend class asdm::ReceiverTable;
00121 friend class asdm::RowTransformer<ReceiverRow>;
00122 //friend class asdm::TableStreamReader<ReceiverTable, ReceiverRow>;
00123 
00124 public:
00125 
00126         virtual ~ReceiverRow();
00127 
00131         ReceiverTable &getTable() const;
00132         
00137         bool isAdded() const;
00138                 
00140         // Intrinsic Table Attributes //
00142         
00143         
00144         // ===> Attribute receiverId
00145         
00146         
00147         
00148 
00149         
00154         int getReceiverId() const;
00155         
00156  
00157         
00158         
00159         
00160         
00161 
00162 
00163         
00164         // ===> Attribute timeInterval
00165         
00166         
00167         
00168 
00169         
00174         ArrayTimeInterval getTimeInterval() const;
00175         
00176  
00177         
00178         
00188         void setTimeInterval (ArrayTimeInterval timeInterval);
00189                 
00190         
00191         
00192         
00193 
00194 
00195         
00196         // ===> Attribute name
00197         
00198         
00199         
00200 
00201         
00206         string getName() const;
00207         
00208  
00209         
00210         
00218         void setName (string name);
00219                 
00220         
00221         
00222         
00223 
00224 
00225         
00226         // ===> Attribute numLO
00227         
00228         
00229         
00230 
00231         
00236         int getNumLO() const;
00237         
00238  
00239         
00240         
00248         void setNumLO (int numLO);
00249                 
00250         
00251         
00252         
00253 
00254 
00255         
00256         // ===> Attribute frequencyBand
00257         
00258         
00259         
00260 
00261         
00266         ReceiverBandMod::ReceiverBand getFrequencyBand() const;
00267         
00268  
00269         
00270         
00278         void setFrequencyBand (ReceiverBandMod::ReceiverBand frequencyBand);
00279                 
00280         
00281         
00282         
00283 
00284 
00285         
00286         // ===> Attribute freqLO
00287         
00288         
00289         
00290 
00291         
00296         vector<Frequency > getFreqLO() const;
00297         
00298  
00299         
00300         
00308         void setFreqLO (vector<Frequency > freqLO);
00309                 
00310         
00311         
00312         
00313 
00314 
00315         
00316         // ===> Attribute receiverSideband
00317         
00318         
00319         
00320 
00321         
00326         ReceiverSidebandMod::ReceiverSideband getReceiverSideband() const;
00327         
00328  
00329         
00330         
00338         void setReceiverSideband (ReceiverSidebandMod::ReceiverSideband receiverSideband);
00339                 
00340         
00341         
00342         
00343 
00344 
00345         
00346         // ===> Attribute sidebandLO
00347         
00348         
00349         
00350 
00351         
00356         vector<NetSidebandMod::NetSideband > getSidebandLO() const;
00357         
00358  
00359         
00360         
00368         void setSidebandLO (vector<NetSidebandMod::NetSideband > sidebandLO);
00369                 
00370         
00371         
00372         
00373 
00374 
00376         // Extrinsic Table Attributes //
00378         
00379         
00380         // ===> Attribute spectralWindowId
00381         
00382         
00383         
00384 
00385         
00390         Tag getSpectralWindowId() const;
00391         
00392  
00393         
00394         
00404         void setSpectralWindowId (Tag spectralWindowId);
00405                 
00406         
00407         
00408         
00409 
00410 
00412         // Links //
00414         
00415         
00416 
00417         
00418                 
00425          SpectralWindowRow* getSpectralWindowUsingSpectralWindowId();
00426          
00427 
00428         
00429 
00430         
00431         
00432         
00454         bool compareNoAutoInc(Tag spectralWindowId, ArrayTimeInterval timeInterval, string name, int numLO, ReceiverBandMod::ReceiverBand frequencyBand, vector<Frequency > freqLO, ReceiverSidebandMod::ReceiverSideband receiverSideband, vector<NetSidebandMod::NetSideband > sidebandLO);
00455         
00456         
00457 
00458         
00476         bool compareRequiredValue(string name, int numLO, ReceiverBandMod::ReceiverBand frequencyBand, vector<Frequency > freqLO, ReceiverSidebandMod::ReceiverSideband receiverSideband, vector<NetSidebandMod::NetSideband > sidebandLO); 
00477                  
00478         
00487         bool equalByRequiredValue(ReceiverRow* x) ;
00488         
00489 #ifndef WITHOUT_ACS
00490 
00494         asdmIDL::ReceiverRowIDL *toIDL() const;
00495 #endif
00496         
00497 #ifndef WITHOUT_ACS
00498 
00503         void setFromIDL (asdmIDL::ReceiverRowIDL x) ;
00504 #endif
00505         
00510         std::string toXML() const;
00511 
00518         void setFromXML (std::string rowDoc) ;
00519 
00522         // binary-deserialization material from an EndianIStream  //
00524 
00525         std::map<std::string, ReceiverAttributeFromBin> fromBinMethods;
00526 void receiverIdFromBin( EndianIStream& eis);
00527 void spectralWindowIdFromBin( EndianIStream& eis);
00528 void timeIntervalFromBin( EndianIStream& eis);
00529 void nameFromBin( EndianIStream& eis);
00530 void numLOFromBin( EndianIStream& eis);
00531 void frequencyBandFromBin( EndianIStream& eis);
00532 void freqLOFromBin( EndianIStream& eis);
00533 void receiverSidebandFromBin( EndianIStream& eis);
00534 void sidebandLOFromBin( EndianIStream& eis);
00535 
00536         
00537 
00545          static ReceiverRow* fromBin(EndianIStream& eis, ReceiverTable& table, const std::vector<std::string>& attributesSeq);   
00546  
00553          void fromText(const std::string& attributeName, const std::string&  t);
00555 
00556 private:
00560         ReceiverTable &table;
00564         bool hasBeenAdded;
00565 
00566         // This method is used by the Table class when this row is added to the table.
00567         void isAdded(bool added);
00568 
00569 
00578         ReceiverRow (ReceiverTable &table);
00579 
00597          ReceiverRow (ReceiverTable &table, ReceiverRow &row);
00598                 
00600         // Intrinsic Table Attributes //
00602         
00603         
00604         // ===> Attribute receiverId
00605         
00606         
00607 
00608         int receiverId;
00609 
00610         
00611         
00612         
00622         void setReceiverId (int receiverId);
00623                 
00624         
00625 
00626         
00627         // ===> Attribute timeInterval
00628         
00629         
00630 
00631         ArrayTimeInterval timeInterval;
00632 
00633         
00634         
00635         
00636 
00637         
00638         // ===> Attribute name
00639         
00640         
00641 
00642         string name;
00643 
00644         
00645         
00646         
00647 
00648         
00649         // ===> Attribute numLO
00650         
00651         
00652 
00653         int numLO;
00654 
00655         
00656         
00657         
00658 
00659         
00660         // ===> Attribute frequencyBand
00661         
00662         
00663 
00664         ReceiverBandMod::ReceiverBand frequencyBand;
00665 
00666         
00667         
00668         
00669 
00670         
00671         // ===> Attribute freqLO
00672         
00673         
00674 
00675         vector<Frequency > freqLO;
00676 
00677         
00678         
00679         
00680 
00681         
00682         // ===> Attribute receiverSideband
00683         
00684         
00685 
00686         ReceiverSidebandMod::ReceiverSideband receiverSideband;
00687 
00688         
00689         
00690         
00691 
00692         
00693         // ===> Attribute sidebandLO
00694         
00695         
00696 
00697         vector<NetSidebandMod::NetSideband > sidebandLO;
00698 
00699         
00700         
00701         
00702 
00704         // Extrinsic Table Attributes //
00706         
00707         
00708         // ===> Attribute spectralWindowId
00709         
00710         
00711 
00712         Tag spectralWindowId;
00713 
00714         
00715         
00716         
00717 
00719         // Links //
00721         
00722         
00723                 
00724 
00725          
00726 
00727         
00728 
00729         
00730 /*
00732         // binary-deserialization material from an EndianIStream  //
00734         std::map<std::string, ReceiverAttributeFromBin> fromBinMethods;
00735 void receiverIdFromBin( EndianIStream& eis);
00736 void spectralWindowIdFromBin( EndianIStream& eis);
00737 void timeIntervalFromBin( EndianIStream& eis);
00738 void nameFromBin( EndianIStream& eis);
00739 void numLOFromBin( EndianIStream& eis);
00740 void frequencyBandFromBin( EndianIStream& eis);
00741 void freqLOFromBin( EndianIStream& eis);
00742 void receiverSidebandFromBin( EndianIStream& eis);
00743 void sidebandLOFromBin( EndianIStream& eis);
00744 
00745         
00746 */
00747         
00749         // text-deserialization material //
00751         std::map<std::string, ReceiverAttributeFromText> fromTextMethods;
00752         
00753 void receiverIdFromText (const string & s);
00754         
00755         
00756 void spectralWindowIdFromText (const string & s);
00757         
00758         
00759 void timeIntervalFromText (const string & s);
00760         
00761         
00762 void nameFromText (const string & s);
00763         
00764         
00765 void numLOFromText (const string & s);
00766         
00767         
00768 void frequencyBandFromText (const string & s);
00769         
00770         
00771 void freqLOFromText (const string & s);
00772         
00773         
00774 void receiverSidebandFromText (const string & s);
00775         
00776         
00777 void sidebandLOFromText (const string & s);
00778         
00779 
00780                 
00781         
00786          void toBin(EndianOSStream& eoss);
00787                  
00797 };
00798 
00799 } // End namespace asdm
00800 
00801 #endif /* Receiver_CLASS */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines