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 FlagCmdRow_CLASS
00035 #define FlagCmdRow_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::FlagCmdRowIDL;
00047 #endif
00048
00049
00050
00051
00052
00053
00054 #include <ArrayTimeInterval.h>
00055 using asdm::ArrayTimeInterval;
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076 #include <ConversionException.h>
00077 #include <NoSuchRow.h>
00078 #include <IllegalAccessException.h>
00079
00080
00081
00082
00083
00084
00085 namespace asdm {
00086
00087
00088
00089
00090
00091 class FlagCmdRow;
00092 typedef void (FlagCmdRow::*FlagCmdAttributeFromBin) (EndianISStream& eiss);
00093
00100 class FlagCmdRow {
00101 friend class asdm::FlagCmdTable;
00102
00103 public:
00104
00105 virtual ~FlagCmdRow();
00106
00110 FlagCmdTable &getTable() const;
00111
00116 bool isAdded() const;
00117
00119
00121
00122
00123
00124
00125
00126
00127
00128
00133 ArrayTimeInterval getTimeInterval() const;
00134
00135
00136
00137
00147 void setTimeInterval (ArrayTimeInterval timeInterval);
00148
00149
00150
00151
00152
00153
00154
00155
00156
00157
00158
00159
00160
00165 string getType() const;
00166
00167
00168
00169
00177 void setType (string type);
00178
00179
00180
00181
00182
00183
00184
00185
00186
00187
00188
00189
00190
00195 string getReason() const;
00196
00197
00198
00199
00207 void setReason (string reason);
00208
00209
00210
00211
00212
00213
00214
00215
00216
00217
00218
00219
00220
00225 int getLevel() const;
00226
00227
00228
00229
00237 void setLevel (int level);
00238
00239
00240
00241
00242
00243
00244
00245
00246
00247
00248
00249
00250
00255 int getSeverity() const;
00256
00257
00258
00259
00267 void setSeverity (int severity);
00268
00269
00270
00271
00272
00273
00274
00275
00276
00277
00278
00279
00280
00285 bool getApplied() const;
00286
00287
00288
00289
00297 void setApplied (bool applied);
00298
00299
00300
00301
00302
00303
00304
00305
00306
00307
00308
00309
00310
00315 string getCommand() const;
00316
00317
00318
00319
00327 void setCommand (string command);
00328
00329
00330
00331
00332
00333
00335
00337
00339
00341
00342
00343
00344
00364 bool compareNoAutoInc(ArrayTimeInterval timeInterval, string type, string reason, int level, int severity, bool applied, string command);
00365
00366
00367
00368
00386 bool compareRequiredValue(string type, string reason, int level, int severity, bool applied, string command);
00387
00388
00397 bool equalByRequiredValue(FlagCmdRow* x) ;
00398
00399 #ifndef WITHOUT_ACS
00400
00404 FlagCmdRowIDL *toIDL() const;
00405 #endif
00406
00407 #ifndef WITHOUT_ACS
00408
00413 void setFromIDL (FlagCmdRowIDL x) ;
00414 #endif
00415
00420 string toXML() const;
00421
00428 void setFromXML (string rowDoc) ;
00429
00430 private:
00434 FlagCmdTable &table;
00438 bool hasBeenAdded;
00439
00440
00441 void isAdded(bool added);
00442
00443
00452 FlagCmdRow (FlagCmdTable &table);
00453
00471 FlagCmdRow (FlagCmdTable &table, FlagCmdRow &row);
00472
00474
00476
00477
00478
00479
00480
00481
00482 ArrayTimeInterval timeInterval;
00483
00484
00485
00486
00487
00488
00489
00490
00491
00492
00493 string type;
00494
00495
00496
00497
00498
00499
00500
00501
00502
00503
00504 string reason;
00505
00506
00507
00508
00509
00510
00511
00512
00513
00514
00515 int level;
00516
00517
00518
00519
00520
00521
00522
00523
00524
00525
00526 int severity;
00527
00528
00529
00530
00531
00532
00533
00534
00535
00536
00537 bool applied;
00538
00539
00540
00541
00542
00543
00544
00545
00546
00547
00548 string command;
00549
00550
00551
00552
00553
00555
00557
00559
00561
00562
00564
00566 map<string, FlagCmdAttributeFromBin> fromBinMethods;
00567 void timeIntervalFromBin( EndianISStream& eiss);
00568 void typeFromBin( EndianISStream& eiss);
00569 void reasonFromBin( EndianISStream& eiss);
00570 void levelFromBin( EndianISStream& eiss);
00571 void severityFromBin( EndianISStream& eiss);
00572 void appliedFromBin( EndianISStream& eiss);
00573 void commandFromBin( EndianISStream& eiss);
00574
00575
00576
00581 void toBin(EndianOSStream& eoss);
00582
00590 static FlagCmdRow* fromBin(EndianISStream& eiss, FlagCmdTable& table, const vector<string>& attributesSeq);
00591
00592 };
00593
00594 }
00595
00596 #endif