casa
$Rev:20696$
|
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 FocusRow.h 00032 */ 00033 00034 #ifndef FocusRow_CLASS 00035 #define FocusRow_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 <Angle.h> 00052 00053 00054 00055 #include <Tag.h> 00056 00057 00058 00059 #include <Length.h> 00060 00061 00062 00063 #include <ArrayTimeInterval.h> 00064 00065 00066 00067 00068 00069 00070 00071 00072 00073 00074 00075 00076 00077 00078 00079 00080 00081 00082 00083 #include <ConversionException.h> 00084 #include <NoSuchRow.h> 00085 #include <IllegalAccessException.h> 00086 00087 #include <RowTransformer.h> 00088 //#include <TableStreamReader.h> 00089 00090 /*\file Focus.h 00091 \brief Generated from model's revision "1.64", branch "HEAD" 00092 */ 00093 00094 namespace asdm { 00095 00096 //class asdm::FocusTable; 00097 00098 00099 // class asdm::AntennaRow; 00100 class AntennaRow; 00101 00102 // class asdm::FocusModelRow; 00103 class FocusModelRow; 00104 00105 00106 class FocusRow; 00107 typedef void (FocusRow::*FocusAttributeFromBin) (EndianIStream& eis); 00108 typedef void (FocusRow::*FocusAttributeFromText) (const string& s); 00109 00116 class FocusRow { 00117 friend class asdm::FocusTable; 00118 friend class asdm::RowTransformer<FocusRow>; 00119 //friend class asdm::TableStreamReader<FocusTable, FocusRow>; 00120 00121 public: 00122 00123 virtual ~FocusRow(); 00124 00128 FocusTable &getTable() const; 00129 00134 bool isAdded() const; 00135 00137 // Intrinsic Table Attributes // 00139 00140 00141 // ===> Attribute timeInterval 00142 00143 00144 00145 00146 00151 ArrayTimeInterval getTimeInterval() const; 00152 00153 00154 00155 00165 void setTimeInterval (ArrayTimeInterval timeInterval); 00166 00167 00168 00169 00170 00171 00172 00173 // ===> Attribute focusTracking 00174 00175 00176 00177 00178 00183 bool getFocusTracking() const; 00184 00185 00186 00187 00195 void setFocusTracking (bool focusTracking); 00196 00197 00198 00199 00200 00201 00202 00203 // ===> Attribute focusOffset 00204 00205 00206 00207 00208 00213 vector<Length > getFocusOffset() const; 00214 00215 00216 00217 00225 void setFocusOffset (vector<Length > focusOffset); 00226 00227 00228 00229 00230 00231 00232 00233 // ===> Attribute focusRotationOffset 00234 00235 00236 00237 00238 00243 vector<Angle > getFocusRotationOffset() const; 00244 00245 00246 00247 00255 void setFocusRotationOffset (vector<Angle > focusRotationOffset); 00256 00257 00258 00259 00260 00261 00262 00263 // ===> Attribute measuredFocusPosition, which is optional 00264 00265 00266 00271 bool isMeasuredFocusPositionExists() const; 00272 00273 00274 00280 vector<Length > getMeasuredFocusPosition() const; 00281 00282 00283 00284 00291 void setMeasuredFocusPosition (vector<Length > measuredFocusPosition); 00292 00293 00294 00295 00299 void clearMeasuredFocusPosition (); 00300 00301 00302 00303 00304 // ===> Attribute measuredFocusRotation, which is optional 00305 00306 00307 00312 bool isMeasuredFocusRotationExists() const; 00313 00314 00315 00321 vector<Angle > getMeasuredFocusRotation() const; 00322 00323 00324 00325 00332 void setMeasuredFocusRotation (vector<Angle > measuredFocusRotation); 00333 00334 00335 00336 00340 void clearMeasuredFocusRotation (); 00341 00342 00343 00345 // Extrinsic Table Attributes // 00347 00348 00349 // ===> Attribute antennaId 00350 00351 00352 00353 00354 00359 Tag getAntennaId() const; 00360 00361 00362 00363 00373 void setAntennaId (Tag antennaId); 00374 00375 00376 00377 00378 00379 00380 00381 // ===> Attribute focusModelId 00382 00383 00384 00385 00386 00391 int getFocusModelId() const; 00392 00393 00394 00395 00403 void setFocusModelId (int focusModelId); 00404 00405 00406 00407 00408 00409 00411 // Links // 00413 00414 00415 00416 00417 00424 AntennaRow* getAntennaUsingAntennaId(); 00425 00426 00427 00428 00429 00430 00431 00432 00433 // ===> Slice link from a row of Focus table to a collection of row of FocusModel table. 00434 00440 vector <FocusModelRow *> getFocusModels(); 00441 00442 00443 00444 00445 00446 00447 00448 00466 bool compareNoAutoInc(Tag antennaId, ArrayTimeInterval timeInterval, bool focusTracking, vector<Length > focusOffset, vector<Angle > focusRotationOffset, int focusModelId); 00467 00468 00469 00470 00484 bool compareRequiredValue(bool focusTracking, vector<Length > focusOffset, vector<Angle > focusRotationOffset, int focusModelId); 00485 00486 00495 bool equalByRequiredValue(FocusRow* x) ; 00496 00497 #ifndef WITHOUT_ACS 00498 00502 asdmIDL::FocusRowIDL *toIDL() const; 00503 00511 void toIDL(asdmIDL::FocusRowIDL& x) const; 00512 #endif 00513 00514 #ifndef WITHOUT_ACS 00515 00520 void setFromIDL (asdmIDL::FocusRowIDL x) ; 00521 #endif 00522 00527 std::string toXML() const; 00528 00535 void setFromXML (std::string rowDoc) ; 00536 00539 // binary-deserialization material from an EndianIStream // 00541 00542 std::map<std::string, FocusAttributeFromBin> fromBinMethods; 00543 void antennaIdFromBin( EndianIStream& eis); 00544 void timeIntervalFromBin( EndianIStream& eis); 00545 void focusTrackingFromBin( EndianIStream& eis); 00546 void focusOffsetFromBin( EndianIStream& eis); 00547 void focusRotationOffsetFromBin( EndianIStream& eis); 00548 void focusModelIdFromBin( EndianIStream& eis); 00549 00550 void measuredFocusPositionFromBin( EndianIStream& eis); 00551 void measuredFocusRotationFromBin( EndianIStream& eis); 00552 00553 00561 static FocusRow* fromBin(EndianIStream& eis, FocusTable& table, const std::vector<std::string>& attributesSeq); 00562 00569 void fromText(const std::string& attributeName, const std::string& t); 00571 00572 private: 00576 FocusTable &table; 00580 bool hasBeenAdded; 00581 00582 // This method is used by the Table class when this row is added to the table. 00583 void isAdded(bool added); 00584 00585 00594 FocusRow (FocusTable &table); 00595 00613 FocusRow (FocusTable &table, FocusRow &row); 00614 00616 // Intrinsic Table Attributes // 00618 00619 00620 // ===> Attribute timeInterval 00621 00622 00623 00624 ArrayTimeInterval timeInterval; 00625 00626 00627 00628 00629 00630 00631 // ===> Attribute focusTracking 00632 00633 00634 00635 bool focusTracking; 00636 00637 00638 00639 00640 00641 00642 // ===> Attribute focusOffset 00643 00644 00645 00646 vector<Length > focusOffset; 00647 00648 00649 00650 00651 00652 00653 // ===> Attribute focusRotationOffset 00654 00655 00656 00657 vector<Angle > focusRotationOffset; 00658 00659 00660 00661 00662 00663 00664 // ===> Attribute measuredFocusPosition, which is optional 00665 00666 00667 bool measuredFocusPositionExists; 00668 00669 00670 vector<Length > measuredFocusPosition; 00671 00672 00673 00674 00675 00676 00677 // ===> Attribute measuredFocusRotation, which is optional 00678 00679 00680 bool measuredFocusRotationExists; 00681 00682 00683 vector<Angle > measuredFocusRotation; 00684 00685 00686 00687 00688 00690 // Extrinsic Table Attributes // 00692 00693 00694 // ===> Attribute antennaId 00695 00696 00697 00698 Tag antennaId; 00699 00700 00701 00702 00703 00704 00705 // ===> Attribute focusModelId 00706 00707 00708 00709 int focusModelId; 00710 00711 00712 00713 00714 00716 // Links // 00718 00719 00720 00721 00722 00723 00724 00725 00726 00727 00728 00729 00730 00731 00732 00733 /* 00735 // binary-deserialization material from an EndianIStream // 00737 std::map<std::string, FocusAttributeFromBin> fromBinMethods; 00738 void antennaIdFromBin( EndianIStream& eis); 00739 void timeIntervalFromBin( EndianIStream& eis); 00740 void focusTrackingFromBin( EndianIStream& eis); 00741 void focusOffsetFromBin( EndianIStream& eis); 00742 void focusRotationOffsetFromBin( EndianIStream& eis); 00743 void focusModelIdFromBin( EndianIStream& eis); 00744 00745 void measuredFocusPositionFromBin( EndianIStream& eis); 00746 void measuredFocusRotationFromBin( EndianIStream& eis); 00747 00748 */ 00749 00751 // text-deserialization material // 00753 std::map<std::string, FocusAttributeFromText> fromTextMethods; 00754 00755 void antennaIdFromText (const string & s); 00756 00757 00758 void timeIntervalFromText (const string & s); 00759 00760 00761 void focusTrackingFromText (const string & s); 00762 00763 00764 void focusOffsetFromText (const string & s); 00765 00766 00767 void focusRotationOffsetFromText (const string & s); 00768 00769 00770 void focusModelIdFromText (const string & s); 00771 00772 00773 00774 void measuredFocusPositionFromText (const string & s); 00775 00776 00777 void measuredFocusRotationFromText (const string & s); 00778 00779 00780 00785 void toBin(EndianOSStream& eoss); 00786 00796 }; 00797 00798 } // End namespace asdm 00799 00800 #endif /* Focus_CLASS */