ScanRow.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 ScanRow.h
00032  */
00033  
00034 #ifndef ScanRow_CLASS
00035 #define ScanRow_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::ScanRowIDL;
00047 #endif
00048 
00049 
00050 
00051 
00052 
00053 
00054 #include <ArrayTime.h>
00055 using  asdm::ArrayTime;
00056 
00057 #include <Tag.h>
00058 using  asdm::Tag;
00059 
00060 
00061 
00062 
00063         
00064 
00065         
00066 
00067         
00068 
00069         
00070 
00071         
00072 
00073         
00074 #include "CScanIntent.h"
00075 using namespace ScanIntentMod;
00076         
00077 
00078         
00079 #include "CCalDataOrigin.h"
00080 using namespace CalDataOriginMod;
00081         
00082 
00083         
00084 
00085         
00086 #include "CCalibrationFunction.h"
00087 using namespace CalibrationFunctionMod;
00088         
00089 
00090         
00091 #include "CCalibrationSet.h"
00092 using namespace CalibrationSetMod;
00093         
00094 
00095         
00096 #include "CAntennaMotionPattern.h"
00097 using namespace AntennaMotionPatternMod;
00098         
00099 
00100         
00101 
00102         
00103 
00104         
00105 
00106         
00107 
00108 
00109 
00110 #include <ConversionException.h>
00111 #include <NoSuchRow.h>
00112 #include <IllegalAccessException.h>
00113 
00114 
00115 /*\file Scan.h
00116     \brief Generated from model's revision "1.55", branch "HEAD"
00117 */
00118 
00119 namespace asdm {
00120 
00121 //class asdm::ScanTable;
00122 
00123 
00124 // class asdm::ExecBlockRow;
00125 class ExecBlockRow;
00126         
00127 
00128 class ScanRow;
00129 typedef void (ScanRow::*ScanAttributeFromBin) (EndianISStream& eiss);
00130 
00137 class ScanRow {
00138 friend class asdm::ScanTable;
00139 
00140 public:
00141 
00142         virtual ~ScanRow();
00143 
00147         ScanTable &getTable() const;
00148         
00153         bool isAdded() const;
00154                 
00156         // Intrinsic Table Attributes //
00158         
00159         
00160         // ===> Attribute scanNumber
00161         
00162         
00163         
00164 
00165         
00170         int getScanNumber() const;
00171         
00172  
00173         
00174         
00184         void setScanNumber (int scanNumber);
00185                 
00186         
00187         
00188         
00189 
00190 
00191         
00192         // ===> Attribute startTime
00193         
00194         
00195         
00196 
00197         
00202         ArrayTime getStartTime() const;
00203         
00204  
00205         
00206         
00214         void setStartTime (ArrayTime startTime);
00215                 
00216         
00217         
00218         
00219 
00220 
00221         
00222         // ===> Attribute endTime
00223         
00224         
00225         
00226 
00227         
00232         ArrayTime getEndTime() const;
00233         
00234  
00235         
00236         
00244         void setEndTime (ArrayTime endTime);
00245                 
00246         
00247         
00248         
00249 
00250 
00251         
00252         // ===> Attribute numIntent
00253         
00254         
00255         
00256 
00257         
00262         int getNumIntent() const;
00263         
00264  
00265         
00266         
00274         void setNumIntent (int numIntent);
00275                 
00276         
00277         
00278         
00279 
00280 
00281         
00282         // ===> Attribute numSubScan
00283         
00284         
00285         
00286 
00287         
00292         int getNumSubScan() const;
00293         
00294  
00295         
00296         
00304         void setNumSubScan (int numSubScan);
00305                 
00306         
00307         
00308         
00309 
00310 
00311         
00312         // ===> Attribute scanIntent
00313         
00314         
00315         
00316 
00317         
00322         vector<ScanIntentMod::ScanIntent > getScanIntent() const;
00323         
00324  
00325         
00326         
00334         void setScanIntent (vector<ScanIntentMod::ScanIntent > scanIntent);
00335                 
00336         
00337         
00338         
00339 
00340 
00341         
00342         // ===> Attribute calDataType
00343         
00344         
00345         
00346 
00347         
00352         vector<CalDataOriginMod::CalDataOrigin > getCalDataType() const;
00353         
00354  
00355         
00356         
00364         void setCalDataType (vector<CalDataOriginMod::CalDataOrigin > calDataType);
00365                 
00366         
00367         
00368         
00369 
00370 
00371         
00372         // ===> Attribute calibrationOnLine
00373         
00374         
00375         
00376 
00377         
00382         vector<bool > getCalibrationOnLine() const;
00383         
00384  
00385         
00386         
00394         void setCalibrationOnLine (vector<bool > calibrationOnLine);
00395                 
00396         
00397         
00398         
00399 
00400 
00401         
00402         // ===> Attribute calibrationFunction, which is optional
00403         
00404         
00405         
00410         bool isCalibrationFunctionExists() const;
00411         
00412 
00413         
00419         vector<CalibrationFunctionMod::CalibrationFunction > getCalibrationFunction() const;
00420         
00421  
00422         
00423         
00430         void setCalibrationFunction (vector<CalibrationFunctionMod::CalibrationFunction > calibrationFunction);
00431                 
00432         
00433         
00434         
00438         void clearCalibrationFunction ();
00439         
00440 
00441 
00442         
00443         // ===> Attribute calibrationSet, which is optional
00444         
00445         
00446         
00451         bool isCalibrationSetExists() const;
00452         
00453 
00454         
00460         vector<CalibrationSetMod::CalibrationSet > getCalibrationSet() const;
00461         
00462  
00463         
00464         
00471         void setCalibrationSet (vector<CalibrationSetMod::CalibrationSet > calibrationSet);
00472                 
00473         
00474         
00475         
00479         void clearCalibrationSet ();
00480         
00481 
00482 
00483         
00484         // ===> Attribute calPattern, which is optional
00485         
00486         
00487         
00492         bool isCalPatternExists() const;
00493         
00494 
00495         
00501         vector<AntennaMotionPatternMod::AntennaMotionPattern > getCalPattern() const;
00502         
00503  
00504         
00505         
00512         void setCalPattern (vector<AntennaMotionPatternMod::AntennaMotionPattern > calPattern);
00513                 
00514         
00515         
00516         
00520         void clearCalPattern ();
00521         
00522 
00523 
00524         
00525         // ===> Attribute numField, which is optional
00526         
00527         
00528         
00533         bool isNumFieldExists() const;
00534         
00535 
00536         
00542         int getNumField() const;
00543         
00544  
00545         
00546         
00553         void setNumField (int numField);
00554                 
00555         
00556         
00557         
00561         void clearNumField ();
00562         
00563 
00564 
00565         
00566         // ===> Attribute fieldName, which is optional
00567         
00568         
00569         
00574         bool isFieldNameExists() const;
00575         
00576 
00577         
00583         vector<string > getFieldName() const;
00584         
00585  
00586         
00587         
00594         void setFieldName (vector<string > fieldName);
00595                 
00596         
00597         
00598         
00602         void clearFieldName ();
00603         
00604 
00605 
00606         
00607         // ===> Attribute sourceName, which is optional
00608         
00609         
00610         
00615         bool isSourceNameExists() const;
00616         
00617 
00618         
00624         string getSourceName() const;
00625         
00626  
00627         
00628         
00635         void setSourceName (string sourceName);
00636                 
00637         
00638         
00639         
00643         void clearSourceName ();
00644         
00645 
00646 
00647         
00648         // ===> Attribute flagRow
00649         
00650         
00651         
00652 
00653         
00658         bool getFlagRow() const;
00659         
00660  
00661         
00662         
00670         void setFlagRow (bool flagRow);
00671                 
00672         
00673         
00674         
00675 
00676 
00678         // Extrinsic Table Attributes //
00680         
00681         
00682         // ===> Attribute execBlockId
00683         
00684         
00685         
00686 
00687         
00692         Tag getExecBlockId() const;
00693         
00694  
00695         
00696         
00706         void setExecBlockId (Tag execBlockId);
00707                 
00708         
00709         
00710         
00711 
00712 
00714         // Links //
00716         
00717         
00718 
00719         
00720                 
00727          ExecBlockRow* getExecBlockUsingExecBlockId();
00728          
00729 
00730         
00731 
00732         
00733         
00734         
00760         bool compareNoAutoInc(Tag execBlockId, int scanNumber, ArrayTime startTime, ArrayTime endTime, int numIntent, int numSubScan, vector<ScanIntentMod::ScanIntent > scanIntent, vector<CalDataOriginMod::CalDataOrigin > calDataType, vector<bool > calibrationOnLine, bool flagRow);
00761         
00762         
00763 
00764         
00786         bool compareRequiredValue(ArrayTime startTime, ArrayTime endTime, int numIntent, int numSubScan, vector<ScanIntentMod::ScanIntent > scanIntent, vector<CalDataOriginMod::CalDataOrigin > calDataType, vector<bool > calibrationOnLine, bool flagRow); 
00787                  
00788         
00797         bool equalByRequiredValue(ScanRow* x) ;
00798         
00799 #ifndef WITHOUT_ACS
00800 
00804         ScanRowIDL *toIDL() const;
00805 #endif
00806         
00807 #ifndef WITHOUT_ACS
00808 
00813         void setFromIDL (ScanRowIDL x) ;
00814 #endif
00815         
00820         string toXML() const;
00821 
00828         void setFromXML (string rowDoc) ;       
00829 
00830 private:
00834         ScanTable &table;
00838         bool hasBeenAdded;
00839 
00840         // This method is used by the Table class when this row is added to the table.
00841         void isAdded(bool added);
00842 
00843 
00852         ScanRow (ScanTable &table);
00853 
00871          ScanRow (ScanTable &table, ScanRow &row);
00872                 
00874         // Intrinsic Table Attributes //
00876         
00877         
00878         // ===> Attribute scanNumber
00879         
00880         
00881 
00882         int scanNumber;
00883 
00884         
00885         
00886         
00887 
00888         
00889         // ===> Attribute startTime
00890         
00891         
00892 
00893         ArrayTime startTime;
00894 
00895         
00896         
00897         
00898 
00899         
00900         // ===> Attribute endTime
00901         
00902         
00903 
00904         ArrayTime endTime;
00905 
00906         
00907         
00908         
00909 
00910         
00911         // ===> Attribute numIntent
00912         
00913         
00914 
00915         int numIntent;
00916 
00917         
00918         
00919         
00920 
00921         
00922         // ===> Attribute numSubScan
00923         
00924         
00925 
00926         int numSubScan;
00927 
00928         
00929         
00930         
00931 
00932         
00933         // ===> Attribute scanIntent
00934         
00935         
00936 
00937         vector<ScanIntentMod::ScanIntent > scanIntent;
00938 
00939         
00940         
00941         
00942 
00943         
00944         // ===> Attribute calDataType
00945         
00946         
00947 
00948         vector<CalDataOriginMod::CalDataOrigin > calDataType;
00949 
00950         
00951         
00952         
00953 
00954         
00955         // ===> Attribute calibrationOnLine
00956         
00957         
00958 
00959         vector<bool > calibrationOnLine;
00960 
00961         
00962         
00963         
00964 
00965         
00966         // ===> Attribute calibrationFunction, which is optional
00967         
00968         
00969         bool calibrationFunctionExists;
00970         
00971 
00972         vector<CalibrationFunctionMod::CalibrationFunction > calibrationFunction;
00973 
00974         
00975         
00976         
00977 
00978         
00979         // ===> Attribute calibrationSet, which is optional
00980         
00981         
00982         bool calibrationSetExists;
00983         
00984 
00985         vector<CalibrationSetMod::CalibrationSet > calibrationSet;
00986 
00987         
00988         
00989         
00990 
00991         
00992         // ===> Attribute calPattern, which is optional
00993         
00994         
00995         bool calPatternExists;
00996         
00997 
00998         vector<AntennaMotionPatternMod::AntennaMotionPattern > calPattern;
00999 
01000         
01001         
01002         
01003 
01004         
01005         // ===> Attribute numField, which is optional
01006         
01007         
01008         bool numFieldExists;
01009         
01010 
01011         int numField;
01012 
01013         
01014         
01015         
01016 
01017         
01018         // ===> Attribute fieldName, which is optional
01019         
01020         
01021         bool fieldNameExists;
01022         
01023 
01024         vector<string > fieldName;
01025 
01026         
01027         
01028         
01029 
01030         
01031         // ===> Attribute sourceName, which is optional
01032         
01033         
01034         bool sourceNameExists;
01035         
01036 
01037         string sourceName;
01038 
01039         
01040         
01041         
01042 
01043         
01044         // ===> Attribute flagRow
01045         
01046         
01047 
01048         bool flagRow;
01049 
01050         
01051         
01052         
01053 
01055         // Extrinsic Table Attributes //
01057         
01058         
01059         // ===> Attribute execBlockId
01060         
01061         
01062 
01063         Tag execBlockId;
01064 
01065         
01066         
01067         
01068 
01070         // Links //
01072         
01073         
01074                 
01075 
01076          
01077 
01078         
01079 
01080         
01082         // binary-deserialization material//
01084         map<string, ScanAttributeFromBin> fromBinMethods;
01085 void execBlockIdFromBin( EndianISStream& eiss);
01086 void scanNumberFromBin( EndianISStream& eiss);
01087 void startTimeFromBin( EndianISStream& eiss);
01088 void endTimeFromBin( EndianISStream& eiss);
01089 void numIntentFromBin( EndianISStream& eiss);
01090 void numSubScanFromBin( EndianISStream& eiss);
01091 void scanIntentFromBin( EndianISStream& eiss);
01092 void calDataTypeFromBin( EndianISStream& eiss);
01093 void calibrationOnLineFromBin( EndianISStream& eiss);
01094 void flagRowFromBin( EndianISStream& eiss);
01095 
01096 void calibrationFunctionFromBin( EndianISStream& eiss);
01097 void calibrationSetFromBin( EndianISStream& eiss);
01098 void calPatternFromBin( EndianISStream& eiss);
01099 void numFieldFromBin( EndianISStream& eiss);
01100 void fieldNameFromBin( EndianISStream& eiss);
01101 void sourceNameFromBin( EndianISStream& eiss);
01102         
01103         
01108          void toBin(EndianOSStream& eoss);
01109                  
01117          static ScanRow* fromBin(EndianISStream& eiss, ScanTable& table, const vector<string>& attributesSeq);   
01118 
01119 };
01120 
01121 } // End namespace asdm
01122 
01123 #endif /* Scan_CLASS */
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines