Go to the documentation of this file.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 SpectralWindowRow_CLASS
00035 #define SpectralWindowRow_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::SpectralWindowRowIDL;
00047 #endif
00048
00049
00050
00051
00052
00053
00054 #include <Tag.h>
00055 using asdm::Tag;
00056
00057 #include <Frequency.h>
00058 using asdm::Frequency;
00059
00060
00061
00062
00063
00064
00065
00066 #include "CBasebandName.h"
00067 using namespace BasebandNameMod;
00068
00069
00070
00071 #include "CNetSideband.h"
00072 using namespace NetSidebandMod;
00073
00074
00075
00076
00077
00078
00079
00080 #include "CSidebandProcessingMode.h"
00081 using namespace SidebandProcessingModeMod;
00082
00083
00084
00085
00086
00087 #include "CWindowFunction.h"
00088 using namespace WindowFunctionMod;
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102 #include "CCorrelationBit.h"
00103 using namespace CorrelationBitMod;
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117 #include "CFrequencyReferenceCode.h"
00118 using namespace FrequencyReferenceCodeMod;
00119
00120
00121
00122
00123
00124
00125
00126
00127
00128
00129
00130
00131
00132
00133
00134
00135
00136 #include "CSpectralResolutionType.h"
00137 using namespace SpectralResolutionTypeMod;
00138
00139
00140
00141
00142 #include <ConversionException.h>
00143 #include <NoSuchRow.h>
00144 #include <IllegalAccessException.h>
00145
00146
00147
00148
00149
00150
00151 namespace asdm {
00152
00153
00154
00155
00156
00157 class SpectralWindowRow;
00158
00159
00160 class SpectralWindowRow;
00161
00162
00163 class DopplerRow;
00164
00165
00166 class SpectralWindowRow;
00167 typedef void (SpectralWindowRow::*SpectralWindowAttributeFromBin) (EndianISStream& eiss);
00168
00175 class SpectralWindowRow {
00176 friend class asdm::SpectralWindowTable;
00177
00178 public:
00179
00180 virtual ~SpectralWindowRow();
00181
00185 SpectralWindowTable &getTable() const;
00186
00191 bool isAdded() const;
00192
00194
00196
00197
00198
00199
00200
00201
00202
00203
00208 Tag getSpectralWindowId() const;
00209
00210
00211
00212
00213
00214
00215
00216
00217
00218
00219
00220
00221
00222
00223
00228 BasebandNameMod::BasebandName getBasebandName() const;
00229
00230
00231
00232
00240 void setBasebandName (BasebandNameMod::BasebandName basebandName);
00241
00242
00243
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00258 NetSidebandMod::NetSideband getNetSideband() const;
00259
00260
00261
00262
00270 void setNetSideband (NetSidebandMod::NetSideband netSideband);
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283
00288 int getNumChan() const;
00289
00290
00291
00292
00300 void setNumChan (int numChan);
00301
00302
00303
00304
00305
00306
00307
00308
00309
00310
00311
00312
00313
00318 Frequency getRefFreq() const;
00319
00320
00321
00322
00330 void setRefFreq (Frequency refFreq);
00331
00332
00333
00334
00335
00336
00337
00338
00339
00340
00341
00342
00343
00348 SidebandProcessingModeMod::SidebandProcessingMode getSidebandProcessingMode() const;
00349
00350
00351
00352
00360 void setSidebandProcessingMode (SidebandProcessingModeMod::SidebandProcessingMode sidebandProcessingMode);
00361
00362
00363
00364
00365
00366
00367
00368
00369
00370
00371
00372
00373
00378 Frequency getTotBandwidth() const;
00379
00380
00381
00382
00390 void setTotBandwidth (Frequency totBandwidth);
00391
00392
00393
00394
00395
00396
00397
00398
00399
00400
00401
00402
00403
00408 WindowFunctionMod::WindowFunction getWindowFunction() const;
00409
00410
00411
00412
00420 void setWindowFunction (WindowFunctionMod::WindowFunction windowFunction);
00421
00422
00423
00424
00425
00426
00427
00428
00429
00430
00431
00436 bool isChanFreqStartExists() const;
00437
00438
00439
00445 Frequency getChanFreqStart() const;
00446
00447
00448
00449
00456 void setChanFreqStart (Frequency chanFreqStart);
00457
00458
00459
00460
00464 void clearChanFreqStart ();
00465
00466
00467
00468
00469
00470
00471
00472
00477 bool isChanFreqStepExists() const;
00478
00479
00480
00486 Frequency getChanFreqStep() const;
00487
00488
00489
00490
00497 void setChanFreqStep (Frequency chanFreqStep);
00498
00499
00500
00501
00505 void clearChanFreqStep ();
00506
00507
00508
00509
00510
00511
00512
00513
00518 bool isChanFreqArrayExists() const;
00519
00520
00521
00527 vector<Frequency > getChanFreqArray() const;
00528
00529
00530
00531
00538 void setChanFreqArray (vector<Frequency > chanFreqArray);
00539
00540
00541
00542
00546 void clearChanFreqArray ();
00547
00548
00549
00550
00551
00552
00553
00554
00559 bool isChanWidthExists() const;
00560
00561
00562
00568 Frequency getChanWidth() const;
00569
00570
00571
00572
00579 void setChanWidth (Frequency chanWidth);
00580
00581
00582
00583
00587 void clearChanWidth ();
00588
00589
00590
00591
00592
00593
00594
00595
00600 bool isChanWidthArrayExists() const;
00601
00602
00603
00609 vector<Frequency > getChanWidthArray() const;
00610
00611
00612
00613
00620 void setChanWidthArray (vector<Frequency > chanWidthArray);
00621
00622
00623
00624
00628 void clearChanWidthArray ();
00629
00630
00631
00632
00633
00634
00635
00636
00641 bool isCorrelationBitExists() const;
00642
00643
00644
00650 CorrelationBitMod::CorrelationBit getCorrelationBit() const;
00651
00652
00653
00654
00661 void setCorrelationBit (CorrelationBitMod::CorrelationBit correlationBit);
00662
00663
00664
00665
00669 void clearCorrelationBit ();
00670
00671
00672
00673
00674
00675
00676
00677
00682 bool isEffectiveBwExists() const;
00683
00684
00685
00691 Frequency getEffectiveBw() const;
00692
00693
00694
00695
00702 void setEffectiveBw (Frequency effectiveBw);
00703
00704
00705
00706
00710 void clearEffectiveBw ();
00711
00712
00713
00714
00715
00716
00717
00718
00723 bool isEffectiveBwArrayExists() const;
00724
00725
00726
00732 vector<Frequency > getEffectiveBwArray() const;
00733
00734
00735
00736
00743 void setEffectiveBwArray (vector<Frequency > effectiveBwArray);
00744
00745
00746
00747
00751 void clearEffectiveBwArray ();
00752
00753
00754
00755
00756
00757
00758
00759
00764 bool isFreqGroupExists() const;
00765
00766
00767
00773 int getFreqGroup() const;
00774
00775
00776
00777
00784 void setFreqGroup (int freqGroup);
00785
00786
00787
00788
00792 void clearFreqGroup ();
00793
00794
00795
00796
00797
00798
00799
00800
00805 bool isFreqGroupNameExists() const;
00806
00807
00808
00814 string getFreqGroupName() const;
00815
00816
00817
00818
00825 void setFreqGroupName (string freqGroupName);
00826
00827
00828
00829
00833 void clearFreqGroupName ();
00834
00835
00836
00837
00838
00839
00840
00841
00846 bool isLineArrayExists() const;
00847
00848
00849
00855 vector<bool > getLineArray() const;
00856
00857
00858
00859
00866 void setLineArray (vector<bool > lineArray);
00867
00868
00869
00870
00874 void clearLineArray ();
00875
00876
00877
00878
00879
00880
00881
00882
00887 bool isMeasFreqRefExists() const;
00888
00889
00890
00896 FrequencyReferenceCodeMod::FrequencyReferenceCode getMeasFreqRef() const;
00897
00898
00899
00900
00907 void setMeasFreqRef (FrequencyReferenceCodeMod::FrequencyReferenceCode measFreqRef);
00908
00909
00910
00911
00915 void clearMeasFreqRef ();
00916
00917
00918
00919
00920
00921
00922
00923
00928 bool isNameExists() const;
00929
00930
00931
00937 string getName() const;
00938
00939
00940
00941
00948 void setName (string name);
00949
00950
00951
00952
00956 void clearName ();
00957
00958
00959
00960
00961
00962
00963
00964
00969 bool isOversamplingExists() const;
00970
00971
00972
00978 bool getOversampling() const;
00979
00980
00981
00982
00989 void setOversampling (bool oversampling);
00990
00991
00992
00993
00997 void clearOversampling ();
00998
00999
01000
01001
01002
01003
01004
01005
01010 bool isQuantizationExists() const;
01011
01012
01013
01019 bool getQuantization() const;
01020
01021
01022
01023
01030 void setQuantization (bool quantization);
01031
01032
01033
01034
01038 void clearQuantization ();
01039
01040
01041
01042
01043
01044
01045
01046
01051 bool isRefChanExists() const;
01052
01053
01054
01060 double getRefChan() const;
01061
01062
01063
01064
01071 void setRefChan (double refChan);
01072
01073
01074
01075
01079 void clearRefChan ();
01080
01081
01082
01083
01084
01085
01086
01087
01092 bool isResolutionExists() const;
01093
01094
01095
01101 Frequency getResolution() const;
01102
01103
01104
01105
01112 void setResolution (Frequency resolution);
01113
01114
01115
01116
01120 void clearResolution ();
01121
01122
01123
01124
01125
01126
01127
01128
01133 bool isResolutionArrayExists() const;
01134
01135
01136
01142 vector<Frequency > getResolutionArray() const;
01143
01144
01145
01146
01153 void setResolutionArray (vector<Frequency > resolutionArray);
01154
01155
01156
01157
01161 void clearResolutionArray ();
01162
01163
01164
01165
01166
01167
01168
01169
01174 bool isNumAssocValuesExists() const;
01175
01176
01177
01183 int getNumAssocValues() const;
01184
01185
01186
01187
01194 void setNumAssocValues (int numAssocValues);
01195
01196
01197
01198
01202 void clearNumAssocValues ();
01203
01204
01205
01206
01207
01208
01209
01210
01215 bool isAssocNatureExists() const;
01216
01217
01218
01224 vector<SpectralResolutionTypeMod::SpectralResolutionType > getAssocNature() const;
01225
01226
01227
01228
01235 void setAssocNature (vector<SpectralResolutionTypeMod::SpectralResolutionType > assocNature);
01236
01237
01238
01239
01243 void clearAssocNature ();
01244
01245
01246
01248
01250
01251
01252
01253
01254
01255
01260 bool isAssocSpectralWindowIdExists() const;
01261
01262
01263
01269 vector<Tag> getAssocSpectralWindowId() const;
01270
01271
01272
01273
01280 void setAssocSpectralWindowId (vector<Tag> assocSpectralWindowId);
01281
01282
01283
01284
01288 void clearAssocSpectralWindowId ();
01289
01290
01291
01292
01293
01294
01295
01296
01301 bool isDopplerIdExists() const;
01302
01303
01304
01310 int getDopplerId() const;
01311
01312
01313
01314
01321 void setDopplerId (int dopplerId);
01322
01323
01324
01325
01329 void clearDopplerId ();
01330
01331
01332
01333
01334
01335
01336
01337
01342 bool isImageSpectralWindowIdExists() const;
01343
01344
01345
01351 Tag getImageSpectralWindowId() const;
01352
01353
01354
01355
01362 void setImageSpectralWindowId (Tag imageSpectralWindowId);
01363
01364
01365
01366
01370 void clearImageSpectralWindowId ();
01371
01372
01373
01375
01377
01378
01379
01386 void setAssocSpectralWindowId (int i, Tag assocSpectralWindowId) ;
01387
01388
01389
01390
01391
01396 void addAssocSpectralWindowId(Tag id);
01397
01402 void addAssocSpectralWindowId(const vector<Tag> & id);
01403
01404
01410 const Tag getAssocSpectralWindowId(int i);
01411
01419 SpectralWindowRow* getSpectralWindowUsingAssocSpectralWindowId(int i);
01420
01425 vector<SpectralWindowRow *> getSpectralWindowsUsingAssocSpectralWindowId();
01426
01427
01428
01429
01430
01431
01432
01433
01442 SpectralWindowRow* getSpectralWindowUsingImageSpectralWindowId();
01443
01444
01445
01446
01447
01448
01449
01450
01451
01452
01458 vector <DopplerRow *> getDopplers();
01459
01460
01461
01462
01463
01464
01465
01466
01486 bool compareNoAutoInc(BasebandNameMod::BasebandName basebandName, NetSidebandMod::NetSideband netSideband, int numChan, Frequency refFreq, SidebandProcessingModeMod::SidebandProcessingMode sidebandProcessingMode, Frequency totBandwidth, WindowFunctionMod::WindowFunction windowFunction);
01487
01488
01489
01490
01510 bool compareRequiredValue(BasebandNameMod::BasebandName basebandName, NetSidebandMod::NetSideband netSideband, int numChan, Frequency refFreq, SidebandProcessingModeMod::SidebandProcessingMode sidebandProcessingMode, Frequency totBandwidth, WindowFunctionMod::WindowFunction windowFunction);
01511
01512
01521 bool equalByRequiredValue(SpectralWindowRow* x) ;
01522
01523 #ifndef WITHOUT_ACS
01524
01528 SpectralWindowRowIDL *toIDL() const;
01529 #endif
01530
01531 #ifndef WITHOUT_ACS
01532
01537 void setFromIDL (SpectralWindowRowIDL x) ;
01538 #endif
01539
01544 string toXML() const;
01545
01552 void setFromXML (string rowDoc) ;
01553
01554 private:
01558 SpectralWindowTable &table;
01562 bool hasBeenAdded;
01563
01564
01565 void isAdded(bool added);
01566
01567
01576 SpectralWindowRow (SpectralWindowTable &table);
01577
01595 SpectralWindowRow (SpectralWindowTable &table, SpectralWindowRow &row);
01596
01598
01600
01601
01602
01603
01604
01605
01606 Tag spectralWindowId;
01607
01608
01609
01610
01620 void setSpectralWindowId (Tag spectralWindowId);
01621
01622
01623
01624
01625
01626
01627
01628
01629 BasebandNameMod::BasebandName basebandName;
01630
01631
01632
01633
01634
01635
01636
01637
01638
01639
01640 NetSidebandMod::NetSideband netSideband;
01641
01642
01643
01644
01645
01646
01647
01648
01649
01650
01651 int numChan;
01652
01653
01654
01655
01656
01657
01658
01659
01660
01661
01662 Frequency refFreq;
01663
01664
01665
01666
01667
01668
01669
01670
01671
01672
01673 SidebandProcessingModeMod::SidebandProcessingMode sidebandProcessingMode;
01674
01675
01676
01677
01678
01679
01680
01681
01682
01683
01684 Frequency totBandwidth;
01685
01686
01687
01688
01689
01690
01691
01692
01693
01694
01695 WindowFunctionMod::WindowFunction windowFunction;
01696
01697
01698
01699
01700
01701
01702
01703
01704
01705 bool chanFreqStartExists;
01706
01707
01708 Frequency chanFreqStart;
01709
01710
01711
01712
01713
01714
01715
01716
01717
01718 bool chanFreqStepExists;
01719
01720
01721 Frequency chanFreqStep;
01722
01723
01724
01725
01726
01727
01728
01729
01730
01731 bool chanFreqArrayExists;
01732
01733
01734 vector<Frequency > chanFreqArray;
01735
01736
01737
01738
01739
01740
01741
01742
01743
01744 bool chanWidthExists;
01745
01746
01747 Frequency chanWidth;
01748
01749
01750
01751
01752
01753
01754
01755
01756
01757 bool chanWidthArrayExists;
01758
01759
01760 vector<Frequency > chanWidthArray;
01761
01762
01763
01764
01765
01766
01767
01768
01769
01770 bool correlationBitExists;
01771
01772
01773 CorrelationBitMod::CorrelationBit correlationBit;
01774
01775
01776
01777
01778
01779
01780
01781
01782
01783 bool effectiveBwExists;
01784
01785
01786 Frequency effectiveBw;
01787
01788
01789
01790
01791
01792
01793
01794
01795
01796 bool effectiveBwArrayExists;
01797
01798
01799 vector<Frequency > effectiveBwArray;
01800
01801
01802
01803
01804
01805
01806
01807
01808
01809 bool freqGroupExists;
01810
01811
01812 int freqGroup;
01813
01814
01815
01816
01817
01818
01819
01820
01821
01822 bool freqGroupNameExists;
01823
01824
01825 string freqGroupName;
01826
01827
01828
01829
01830
01831
01832
01833
01834
01835 bool lineArrayExists;
01836
01837
01838 vector<bool > lineArray;
01839
01840
01841
01842
01843
01844
01845
01846
01847
01848 bool measFreqRefExists;
01849
01850
01851 FrequencyReferenceCodeMod::FrequencyReferenceCode measFreqRef;
01852
01853
01854
01855
01856
01857
01858
01859
01860
01861 bool nameExists;
01862
01863
01864 string name;
01865
01866
01867
01868
01869
01870
01871
01872
01873
01874 bool oversamplingExists;
01875
01876
01877 bool oversampling;
01878
01879
01880
01881
01882
01883
01884
01885
01886
01887 bool quantizationExists;
01888
01889
01890 bool quantization;
01891
01892
01893
01894
01895
01896
01897
01898
01899
01900 bool refChanExists;
01901
01902
01903 double refChan;
01904
01905
01906
01907
01908
01909
01910
01911
01912
01913 bool resolutionExists;
01914
01915
01916 Frequency resolution;
01917
01918
01919
01920
01921
01922
01923
01924
01925
01926 bool resolutionArrayExists;
01927
01928
01929 vector<Frequency > resolutionArray;
01930
01931
01932
01933
01934
01935
01936
01937
01938
01939 bool numAssocValuesExists;
01940
01941
01942 int numAssocValues;
01943
01944
01945
01946
01947
01948
01949
01950
01951
01952 bool assocNatureExists;
01953
01954
01955 vector<SpectralResolutionTypeMod::SpectralResolutionType > assocNature;
01956
01957
01958
01959
01960
01962
01964
01965
01966
01967
01968
01969 bool assocSpectralWindowIdExists;
01970
01971
01972 vector<Tag> assocSpectralWindowId;
01973
01974
01975
01976
01977
01978
01979
01980
01981
01982 bool dopplerIdExists;
01983
01984
01985 int dopplerId;
01986
01987
01988
01989
01990
01991
01992
01993
01994
01995 bool imageSpectralWindowIdExists;
01996
01997
01998 Tag imageSpectralWindowId;
01999
02000
02001
02002
02003
02005
02007
02008
02009
02010
02011
02012
02013
02014
02015
02016
02017
02018
02019
02020
02021
02022
02023
02024
02025
02026
02027
02029
02031 map<string, SpectralWindowAttributeFromBin> fromBinMethods;
02032 void spectralWindowIdFromBin( EndianISStream& eiss);
02033 void basebandNameFromBin( EndianISStream& eiss);
02034 void netSidebandFromBin( EndianISStream& eiss);
02035 void numChanFromBin( EndianISStream& eiss);
02036 void refFreqFromBin( EndianISStream& eiss);
02037 void sidebandProcessingModeFromBin( EndianISStream& eiss);
02038 void totBandwidthFromBin( EndianISStream& eiss);
02039 void windowFunctionFromBin( EndianISStream& eiss);
02040
02041 void chanFreqStartFromBin( EndianISStream& eiss);
02042 void chanFreqStepFromBin( EndianISStream& eiss);
02043 void chanFreqArrayFromBin( EndianISStream& eiss);
02044 void chanWidthFromBin( EndianISStream& eiss);
02045 void chanWidthArrayFromBin( EndianISStream& eiss);
02046 void correlationBitFromBin( EndianISStream& eiss);
02047 void effectiveBwFromBin( EndianISStream& eiss);
02048 void effectiveBwArrayFromBin( EndianISStream& eiss);
02049 void freqGroupFromBin( EndianISStream& eiss);
02050 void freqGroupNameFromBin( EndianISStream& eiss);
02051 void lineArrayFromBin( EndianISStream& eiss);
02052 void measFreqRefFromBin( EndianISStream& eiss);
02053 void nameFromBin( EndianISStream& eiss);
02054 void oversamplingFromBin( EndianISStream& eiss);
02055 void quantizationFromBin( EndianISStream& eiss);
02056 void refChanFromBin( EndianISStream& eiss);
02057 void resolutionFromBin( EndianISStream& eiss);
02058 void resolutionArrayFromBin( EndianISStream& eiss);
02059 void numAssocValuesFromBin( EndianISStream& eiss);
02060 void assocNatureFromBin( EndianISStream& eiss);
02061 void assocSpectralWindowIdFromBin( EndianISStream& eiss);
02062 void imageSpectralWindowIdFromBin( EndianISStream& eiss);
02063 void dopplerIdFromBin( EndianISStream& eiss);
02064
02065
02070 void toBin(EndianOSStream& eoss);
02071
02079 static SpectralWindowRow* fromBin(EndianISStream& eiss, SpectralWindowTable& table, const vector<string>& attributesSeq);
02080
02081 };
02082
02083 }
02084
02085 #endif