CMS 3D CMS Logo

LMFRunIOV.h
Go to the documentation of this file.
1 #ifndef LMFRUNIOV_H
2 #define LMFRUNIOV_H
3 
11 
12 #include <string>
13 
14 /*
15  Last updated by Giovanni.Organtini@roma1.infn.it 2010
16 */
17 
18 class LMFRunIOV : public LMFUnique {
19 public:
20  friend class EcalCondDBInterface;
21 
22  LMFRunIOV();
23  LMFRunIOV(oracle::occi::Environment *env, oracle::occi::Connection *conn);
25  LMFRunIOV(const LMFRunIOV &r);
26  ~LMFRunIOV() override;
27 
28  // Methods for user data
30  LMFRunIOV &setLMFRunTag(int tag_id);
34  LMFRunIOV &setTriggerType(int trigType_id);
35  LMFRunIOV &setTriggerType(std::string trigShortName);
36  LMFRunIOV &setLmr(int n);
37  LMFRunIOV &setColor(const LMFColor &c);
39  LMFRunIOV &setColor(int color_id);
40  LMFRunIOV &setColorIndex(int color_index);
42  LMFRunIOV &setSubRunEnd(const Tm &end);
44 
45  LMFRunTag getLMFRunTag() const;
46  LMFSeqDat getSequence() const;
48 
49  int getLmr() const;
50  std::string getSubRunType() const;
53  LMFColor getLMFColor() const;
54  LMFColor getColor() const { return getLMFColor(); }
55  Tm getSubRunStart() const;
56  Tm getSubRunEnd() const;
57  Tm getDBInsertionTime() const;
58  bool isValid() override;
59 
60  void dump() const override;
61  virtual LMFRunIOV &operator=(const LMFRunIOV &r);
62  std::list<LMFRunIOV> fetchBySequence(const LMFSeqDat &s);
63  std::list<LMFRunIOV> fetchBySequence(const LMFSeqDat &s, int lmr);
64  std::list<LMFRunIOV> fetchBySequence(const LMFSeqDat &s, int lmr, int type, int color);
65  std::list<LMFRunIOV> fetchLastBeforeSequence(const LMFSeqDat &s, int lmr, int type, int color);
66 
67  // Operators
68  bool operator==(const LMFRunIOV &m) const {
69  return (getLMFRunTag() == m.getLMFRunTag() && getSequence() == m.getSequence() && getLmr() == m.getLmr() &&
70  getLMFColor() == m.getLMFColor() && getTriggerType() == m.getTriggerType() &&
71  getSubRunType() == m.getSubRunType() && getSubRunStart() == m.getSubRunStart() &&
72  getSubRunEnd() == m.getSubRunEnd());
73  }
74 
75  bool operator!=(const LMFRunIOV &m) const { return !(*this == m); }
76 
78  std::string setByIDSql(Statement *stmt, int id) override;
80  void getParameters(ResultSet *rset) override;
81 
82 private:
83  void checkFabric();
84  void initialize();
85  std::list<LMFRunIOV> fetchBySequence(const std::vector<int> &par,
86  const std::string &sql,
87  const std::string &method) noexcept(false);
88 
90 };
91 
92 #endif
EcalCondDBInterface
Definition: EcalCondDBInterface.h:37
LMFTrigType
Definition: LMFTrigType.h:10
LMFRunIOV::initialize
void initialize()
Definition: LMFRunIOV.cc:10
start
Definition: start.py:1
LMFTrigType.h
LMFRunIOV::checkFabric
void checkFabric()
Definition: LMFRunIOV.cc:73
dqmiodumpmetadata.n
n
Definition: dqmiodumpmetadata.py:28
cmsswSequenceInfo.seq
seq
Definition: cmsswSequenceInfo.py:539
groupFilesInBlocks.tt
int tt
Definition: groupFilesInBlocks.py:144
LMFRunTag
Definition: LMFRunTag.h:16
AlcaSiPixelAliHarvester0T_cff.method
method
Definition: AlcaSiPixelAliHarvester0T_cff.py:41
SiStripCommissioningClient_cfg.conn
conn
Definition: SiStripCommissioningClient_cfg.py:5
LMFColor
Definition: LMFColor.h:12
LMFRunIOV::getParameters
void getParameters(ResultSet *rset) override
Definition: LMFRunIOV.cc:225
LMFRunIOV::setSubRunEnd
LMFRunIOV & setSubRunEnd(const Tm &end)
Definition: LMFRunIOV.cc:147
DDAxes::x
LMFRunIOV::getColorShortName
std::string getColorShortName() const
Definition: LMFRunIOV.cc:97
LMFRunIOV::operator==
bool operator==(const LMFRunIOV &m) const
Definition: LMFRunIOV.h:68
EcalDBConnection::stmt
oracle::occi::Statement * stmt
Definition: EcalDBConnection.h:73
alignCSCRings.s
s
Definition: alignCSCRings.py:92
LMFRunIOV::setSubRunStart
LMFRunIOV & setSubRunStart(const Tm &start)
Definition: LMFRunIOV.cc:136
LMFSeqDat.h
LMFRunIOV::_fabric
LMFDefFabric * _fabric
Definition: LMFRunIOV.h:89
LMFRunIOV::fetchLastBeforeSequence
std::list< LMFRunIOV > fetchLastBeforeSequence(const LMFSeqDat &s, int lmr, int type, int color)
Definition: LMFRunIOV.cc:391
LMFRunIOV::getLMFColor
LMFColor getLMFColor() const
Definition: LMFRunIOV.cc:91
LMFRunIOV
Definition: LMFRunIOV.h:18
LMFRunIOV::getSequence
LMFSeqDat getSequence() const
Definition: LMFRunIOV.cc:180
GlobalPosition_Frontier_DevDB_cff.tag
tag
Definition: GlobalPosition_Frontier_DevDB_cff.py:11
LMFRunIOV::LMFRunIOV
LMFRunIOV()
Definition: LMFRunIOV.cc:28
LMFRunIOV::getLmr
int getLmr() const
Definition: LMFRunIOV.cc:134
visualization-live-secondInstance_cfg.m
m
Definition: visualization-live-secondInstance_cfg.py:72
mps_fire.end
end
Definition: mps_fire.py:242
LMFUnique.h
LMFRunIOV::getColor
LMFColor getColor() const
Definition: LMFRunIOV.h:54
Tm
Definition: Tm.h:13
LMFRunIOV::isValid
bool isValid() override
Definition: LMFRunIOV.cc:281
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
web.browse_db.env
env
Definition: browse_db.py:18
LMFRunIOV::setTriggerType
LMFRunIOV & setTriggerType(LMFTrigType &tt)
Definition: LMFRunIOV.cc:107
LMFRunTag.h
LMFRunIOV::dump
void dump() const override
Definition: LMFRunIOV.cc:186
LMFRunIOV::getLMFRunTag
LMFRunTag getLMFRunTag() const
Definition: LMFRunIOV.cc:57
LMFDefFabric
Definition: LMFDefFabric.h:25
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
LMFRunIOV::getSubRunType
std::string getSubRunType() const
Definition: LMFRunIOV.cc:170
Tm.h
LMFRunIOV::fetchBySequence
std::list< LMFRunIOV > fetchBySequence(const LMFSeqDat &s)
Definition: LMFRunIOV.cc:353
LMFRunIOV::setByIDSql
std::string setByIDSql(Statement *stmt, int id) override
Definition: LMFRunIOV.cc:213
LMFSeqDat
Definition: LMFSeqDat.h:14
LMFRunIOV::getColorLongName
std::string getColorLongName() const
Definition: LMFRunIOV.cc:102
LMFRunIOV::setLmr
LMFRunIOV & setLmr(int n)
Definition: LMFRunIOV.cc:129
LMFColor.h
LMFRunIOV::~LMFRunIOV
~LMFRunIOV() override
Definition: LMFRunIOV.cc:41
alignCSCRings.r
r
Definition: alignCSCRings.py:93
LMFRunIOV::getTriggerType
LMFTrigType getTriggerType() const
Definition: LMFRunIOV.cc:123
LMFRunIOV::operator=
virtual LMFRunIOV & operator=(const LMFRunIOV &r)
Definition: LMFRunIOV.cc:408
LMFDefFabric.h
LMFRunIOV::setColorIndex
LMFRunIOV & setColorIndex(int color_index)
Definition: LMFRunIOV.cc:79
LMFRunIOV::operator!=
bool operator!=(const LMFRunIOV &m) const
Definition: LMFRunIOV.h:75
LMFUnique::Statement
oracle::occi::Statement Statement
Definition: LMFUnique.h:24
LMFRunIOV::getSubRunStart
Tm getSubRunStart() const
Definition: LMFRunIOV.cc:141
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
LMFRunIOV::setSequence
LMFRunIOV & setSequence(LMFSeqDat &seq)
Definition: LMFRunIOV.cc:172
LMFRunIOV::setLMFRunTag
LMFRunIOV & setLMFRunTag(const LMFRunTag &tag)
Definition: LMFRunIOV.cc:47
c
auto & c
Definition: CAHitNtupletGeneratorKernelsImpl.h:46
LMFRunIOV::getDBInsertionTime
Tm getDBInsertionTime() const
Definition: LMFRunIOV.cc:159
LMFUnique
Definition: LMFUnique.h:21
LMFRunIOV::getSubRunEnd
Tm getSubRunEnd() const
Definition: LMFRunIOV.cc:152
LMFRunIOV::setColor
LMFRunIOV & setColor(const LMFColor &c)
Definition: LMFRunIOV.cc:63
LMFRunIOV::writeDBSql
std::string writeDBSql(Statement *stmt) override
Definition: LMFRunIOV.cc:302
EcalDBConnection
Definition: EcalDBConnection.h:15
LMFRunIOV::setSubRunType
LMFRunIOV & setSubRunType(const std::string &x)
Definition: LMFRunIOV.cc:165
LMFRunIOV::fetchIdSql
std::string fetchIdSql(Statement *stmt) override
Definition: LMFRunIOV.cc:194
LMFUnique::ResultSet
oracle::occi::ResultSet ResultSet
Definition: LMFUnique.h:23