ATLAS Offline Software
Public Member Functions | Private Attributes | List of all members
TrigConf::ValidityRange Class Reference

#include <TrigConfCoolWriter.h>

Collaboration diagram for TrigConf::ValidityRange:

Public Member Functions

 ValidityRange (unsigned int run)
 
 ValidityRange (unsigned int run, unsigned int lb)
 
 ValidityRange (cool::ValidityKey since, cool::ValidityKey until)
 
 ValidityRange (const RunRange &rr)
 
cool::ValidityKey & since ()
 
cool::ValidityKey & until ()
 

Private Attributes

std::pair< cool::ValidityKey, cool::ValidityKey > m_range
 

Detailed Description

Definition at line 39 of file TrigConfCoolWriter.h.

Constructor & Destructor Documentation

◆ ValidityRange() [1/4]

TrigConf::ValidityRange::ValidityRange ( unsigned int  run)
inline

Definition at line 41 of file TrigConfCoolWriter.h.

41  {
42  // highest bit==1 indicates infinite run range to be set (would not give valid iov anyway)
43  bool infiniteRange = (run & 0x80000000) != 0;
44  if(infiniteRange) {
45  m_range.first = cool::ValidityKeyMin;
46  m_range.second = cool::ValidityKeyMax;
47  } else {
48  m_range.first = run; m_range.first <<= 32;
49  m_range.second = run+1; m_range.second <<= 32;
50  }
51  }

◆ ValidityRange() [2/4]

TrigConf::ValidityRange::ValidityRange ( unsigned int  run,
unsigned int  lb 
)
inline

Definition at line 54 of file TrigConfCoolWriter.h.

54  {
55  m_range.first = run; m_range.first <<= 32; m_range.first += lb;
56  m_range.second = run+1; m_range.second <<= 32;
57  }

◆ ValidityRange() [3/4]

TrigConf::ValidityRange::ValidityRange ( cool::ValidityKey  since,
cool::ValidityKey  until 
)
inline

Definition at line 59 of file TrigConfCoolWriter.h.

59  {
60  m_range.first = since;
61  m_range.second = until;
62  }

◆ ValidityRange() [4/4]

TrigConf::ValidityRange::ValidityRange ( const RunRange rr)
inline

Definition at line 64 of file TrigConfCoolWriter.h.

64  {
65  int firstRN = rr.first;
66  int lastRN = rr.second;
67  // highest bit==1 indicates infinite run range to be set (would not give valid iov anyway)
68  bool infiniteRange = (firstRN & 0x80000000) != 0;
69  if(infiniteRange) {
70  m_range.first = cool::ValidityKeyMin;
71  m_range.second = cool::ValidityKeyMax;
72  } else {
73  m_range.first = firstRN; m_range.first <<= 32;
74  m_range.second = lastRN+1; m_range.second <<= 32;
75  }
76  }

Member Function Documentation

◆ since()

cool::ValidityKey& TrigConf::ValidityRange::since ( )
inline

Definition at line 77 of file TrigConfCoolWriter.h.

77 { return m_range.first; }

◆ until()

cool::ValidityKey& TrigConf::ValidityRange::until ( )
inline

Definition at line 78 of file TrigConfCoolWriter.h.

78 { return m_range.second; }

Member Data Documentation

◆ m_range

std::pair<cool::ValidityKey,cool::ValidityKey> TrigConf::ValidityRange::m_range
private

Definition at line 80 of file TrigConfCoolWriter.h.


The documentation for this class was generated from the following file:
run
int run(int argc, char *argv[])
Definition: ttree2hdf5.cxx:28
TrigConf::ValidityRange::until
cool::ValidityKey & until()
Definition: TrigConfCoolWriter.h:78
python.BunchSpacingUtils.lb
lb
Definition: BunchSpacingUtils.py:88
run
Definition: run.py:1
TrigConf::ValidityRange::since
cool::ValidityKey & since()
Definition: TrigConfCoolWriter.h:77
TrigConf::ValidityRange::m_range
std::pair< cool::ValidityKey, cool::ValidityKey > m_range
Definition: TrigConfCoolWriter.h:80
rr
const boost::regex rr(r_r)