00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
#ifndef SourceRow_CLASS
00035
#define SourceRow_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::SourceRowIDL;
00047
#endif
00048
00049
#include <Angle.h>
00050
#include <AngularRate.h>
00051
#include <ArrayTime.h>
00052
#include <ArrayTimeInterval.h>
00053
#include <Complex.h>
00054
#include <Entity.h>
00055
#include <EntityId.h>
00056
#include <EntityRef.h>
00057
#include <Flux.h>
00058
#include <Frequency.h>
00059
#include <Humidity.h>
00060
#include <Interval.h>
00061
#include <Length.h>
00062
#include <Pressure.h>
00063
#include <Speed.h>
00064
#include <Tag.h>
00065
#include <Temperature.h>
00066
#include <ConversionException.h>
00067
#include <NoSuchRow.h>
00068
#include <IllegalAccessException.h>
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
#include "CSourceModel.h"
00106
using namespace SourceModelMod;
00107
00108
00109
00110
00111
00112
00113
00114
00115
using asdm::Angle;
00116
using asdm::AngularRate;
00117
using asdm::ArrayTime;
00118
using asdm::Complex;
00119
using asdm::Entity;
00120
using asdm::EntityId;
00121
using asdm::EntityRef;
00122
using asdm::Flux;
00123
using asdm::Frequency;
00124
using asdm::Humidity;
00125
using asdm::Interval;
00126
using asdm::Length;
00127
using asdm::Pressure;
00128
using asdm::Speed;
00129
using asdm::Tag;
00130
using asdm::Temperature;
00131
using asdm::ConversionException;
00132
using asdm::NoSuchRow;
00133
using asdm::IllegalAccessException;
00134
00135
00136
00137
00138
00139
namespace asdm {
00140
00141
00142
00143
00144
00145
class SpectralWindowRow;
00146
00147
00148
class SourceParameterRow;
00149
00150
00157 class SourceRow {
00158
friend class asdm::SourceTable;
00159
00160
public:
00161
00162
virtual ~
SourceRow();
00163
00167
SourceTable &
getTable()
const;
00168
00169
#ifndef WITHOUT_ACS
00170
00174 SourceRowIDL *
toIDL()
const;
00175
#endif
00176
00177
#ifndef WITHOUT_ACS
00178
00182
void setFromIDL (SourceRowIDL x)
throw(
ConversionException);
00183
#endif
00184
00189 string
toXML()
const;
00190
00196
void setFromXML (string rowDoc)
throw(
ConversionException);
00197
00199
00201
00202
00203
00204
00205
00206
00207
00208
00213
int getSourceId()
const;
00214
00215
00216
00217
00218
00219
00220
00221
00222
00223
00224
00225
00226
00227
00228
00233
ArrayTimeInterval getTimeInterval()
const;
00234
00235
00236
00237
00247
void setTimeInterval (
ArrayTimeInterval timeInterval);
00248
00249
00250
00251
00252
00253
00254
00255
00256
00257
00258
00259
00260
00265
int getNumLines()
const;
00266
00267
00268
00269
00277
void setNumLines (
int numLines);
00278
00279
00280
00281
00282
00283
00284
00285
00286
00287
00288
00289
00290
00295 string
getSourceName()
const;
00296
00297
00298
00299
00307
void setSourceName (string sourceName);
00308
00309
00310
00311
00312
00313
00314
00315
00316
00317
00318
00323
bool isCatalogExists()
const;
00324
00325
00326
00332 string
getCatalog()
const throw(
IllegalAccessException);
00333
00334
00335
00336
00343
void setCatalog (string catalog);
00344
00345
00346
00347
00351
void clearCatalog ();
00352
00353
00354
00355
00356
00357
00358
00359
00364
bool isCalibrationGroupExists()
const;
00365
00366
00367
00373
int getCalibrationGroup()
const throw(
IllegalAccessException);
00374
00375
00376
00377
00384
void setCalibrationGroup (
int calibrationGroup);
00385
00386
00387
00388
00392
void clearCalibrationGroup ();
00393
00394
00395
00396
00397
00398
00399
00400
00401
00402
00407 string
getCode()
const;
00408
00409
00410
00411
00419
void setCode (string code);
00420
00421
00422
00423
00424
00425
00426
00427
00428
00429
00430
00431
00432
00437 vector<Angle >
getDirection()
const;
00438
00439
00440
00441
00449
void setDirection (vector<Angle > direction);
00450
00451
00452
00453
00454
00455
00456
00457
00458
00459
00460
00465
bool isPositionExists()
const;
00466
00467
00468
00474 vector<Length >
getPosition()
const throw(
IllegalAccessException);
00475
00476
00477
00478
00485
void setPosition (vector<Length > position);
00486
00487
00488
00489
00493
void clearPosition ();
00494
00495
00496
00497
00498
00499
00500
00501
00502
00503
00508 vector<AngularRate >
getProperMotion()
const;
00509
00510
00511
00512
00520
void setProperMotion (vector<AngularRate > properMotion);
00521
00522
00523
00524
00525
00526
00527
00528
00529
00530
00531
00536
bool isTransitionExists()
const;
00537
00538
00539
00545 vector<string >
getTransition()
const throw(
IllegalAccessException);
00546
00547
00548
00549
00556
void setTransition (vector<string > transition);
00557
00558
00559
00560
00564
void clearTransition ();
00565
00566
00567
00568
00569
00570
00571
00572
00577
bool isRestFrequencyExists()
const;
00578
00579
00580
00586 vector<Frequency >
getRestFrequency()
const throw(
IllegalAccessException);
00587
00588
00589
00590
00597
void setRestFrequency (vector<Frequency > restFrequency);
00598
00599
00600
00601
00605
void clearRestFrequency ();
00606
00607
00608
00609
00610
00611
00612
00613
00618
bool isSysVelExists()
const;
00619
00620
00621
00627 vector<Speed >
getSysVel()
const throw(
IllegalAccessException);
00628
00629
00630
00631
00638
void setSysVel (vector<Speed > sysVel);
00639
00640
00641
00642
00646
void clearSysVel ();
00647
00648
00649
00650
00651
00652
00653
00654
00659
bool isSourceModelExists()
const;
00660
00661
00662
00668 SourceModelMod::SourceModel
getSourceModel()
const throw(
IllegalAccessException);
00669
00670
00671
00672
00679
void setSourceModel (SourceModelMod::SourceModel sourceModel);
00680
00681
00682
00683
00687
void clearSourceModel ();
00688
00689
00690
00691
00692
00693
00694
00695
00700
bool isDeltaVelExists()
const;
00701
00702
00703
00709
Speed getDeltaVel()
const throw(
IllegalAccessException);
00710
00711
00712
00713
00720
void setDeltaVel (
Speed deltaVel);
00721
00722
00723
00724
00728
void clearDeltaVel ();
00729
00730
00731
00732
00733
00734
00735
00736
00741
bool isRangeVelExists()
const;
00742
00743
00744
00750 vector<Speed >
getRangeVel()
const throw(
IllegalAccessException);
00751
00752
00753
00754
00761
void setRangeVel (vector<Speed > rangeVel);
00762
00763
00764
00765
00769
void clearRangeVel ();
00770
00771
00772
00774
00776
00777
00778
00779
00780
00781
00786
bool isSourceParameterIdExists()
const;
00787
00788
00789
00795
int getSourceParameterId()
const throw(
IllegalAccessException);
00796
00797
00798
00799
00806
void setSourceParameterId (
int sourceParameterId);
00807
00808
00809
00810
00814
void clearSourceParameterId ();
00815
00816
00817
00818
00819
00820
00821
00822
00823
00824
00829
Tag getSpectralWindowId()
const;
00830
00831
00832
00833
00843
void setSpectralWindowId (
Tag spectralWindowId);
00844
00845
00846
00847
00848
00849
00851
00853
00854
00855
00856
00857
00864
SpectralWindowRow*
getSpectralWindowUsingSpectralWindowId();
00865
00866
00867
00868
00869
00870
00871
00872
00873
00874
00880 vector <SourceParameterRow *>
getSourceParameters();
00881
00882
00883
00884
00885
00886
00887
00888
00893
bool compareNoAutoInc(
Tag spectralWindowId,
ArrayTimeInterval timeInterval,
int numLines, string sourceName, string code, vector<Angle > direction, vector<AngularRate > properMotion);
00894
00895
00896
00897
00898
bool compareRequiredValue(
int numLines, string sourceName, string code, vector<Angle > direction, vector<AngularRate > properMotion);
00899
00900
00909
bool equalByRequiredValue(
SourceRow* x) ;
00910
00911
private:
00915
SourceTable &table;
00919
bool hasBeenAdded;
00920
00921
00922
void isAdded();
00923
00924
00933
SourceRow (
SourceTable &table);
00934
00952
SourceRow (
SourceTable &table,
SourceRow &row);
00953
00955
00957
00958
00959
00960
00961
00962
00963
int sourceId;
00964
00965
00966
00967
00977
void setSourceId (
int sourceId);
00978
00979
00980
00981
00982
00983
00984
00985
00986
ArrayTimeInterval timeInterval;
00987
00988
00989
00990
00991
00992
00993
00994
00995
00996
00997
int numLines;
00998
00999
01000
01001
01002
01003
01004
01005
01006
01007
01008 string sourceName;
01009
01010
01011
01012
01013
01014
01015
01016
01017
01018
bool catalogExists;
01019
01020
01021 string catalog;
01022
01023
01024
01025
01026
01027
01028
01029
01030
01031
bool calibrationGroupExists;
01032
01033
01034
int calibrationGroup;
01035
01036
01037
01038
01039
01040
01041
01042
01043
01044
01045 string code;
01046
01047
01048
01049
01050
01051
01052
01053
01054
01055
01056 vector<Angle > direction;
01057
01058
01059
01060
01061
01062
01063
01064
01065
01066
bool positionExists;
01067
01068
01069 vector<Length > position;
01070
01071
01072
01073
01074
01075
01076
01077
01078
01079
01080 vector<AngularRate > properMotion;
01081
01082
01083
01084
01085
01086
01087
01088
01089
01090
bool transitionExists;
01091
01092
01093 vector<string > transition;
01094
01095
01096
01097
01098
01099
01100
01101
01102
01103
bool restFrequencyExists;
01104
01105
01106 vector<Frequency > restFrequency;
01107
01108
01109
01110
01111
01112
01113
01114
01115
01116
bool sysVelExists;
01117
01118
01119 vector<Speed > sysVel;
01120
01121
01122
01123
01124
01125
01126
01127
01128
01129
bool sourceModelExists;
01130
01131
01132 SourceModelMod::SourceModel sourceModel;
01133
01134
01135
01136
01137
01138
01139
01140
01141
01142
bool deltaVelExists;
01143
01144
01145
Speed deltaVel;
01146
01147
01148
01149
01150
01151
01152
01153
01154
01155
bool rangeVelExists;
01156
01157
01158 vector<Speed > rangeVel;
01159
01160
01161
01162
01163
01165
01167
01168
01169
01170
01171
01172
bool sourceParameterIdExists;
01173
01174
01175
int sourceParameterId;
01176
01177
01178
01179
01180
01181
01182
01183
01184
01185
01186
Tag spectralWindowId;
01187
01188
01189
01190
01191
01193
01195
01196
01197
01198
01199
01200
01201
01202
01203
01204
01205
01206
01207
01208
01209
01210 };
01211
01212 }
01213
01214
#endif