CMS 3D CMS Logo

TTUConfigurator.cc
Go to the documentation of this file.
1 // Include files
2 
3 // local
6 
7 //-----------------------------------------------------------------------------
8 // Implementation file for class : TTUConfigurator
9 //
10 // 2009-06-02 : Andres Felipe Osorio Oliveros
11 //-----------------------------------------------------------------------------
12 
13 //=============================================================================
14 // Standard constructor, initializes variables
15 //=============================================================================
16 TTUConfigurator::TTUConfigurator(const std::string& infile) : m_in{}, m_rbcspecs{}, m_ttuspecs{} {
17  m_in.open(infile.c_str());
18 
19  if (!m_in.is_open()) {
20  edm::LogError("TTUConfigurator") << "TTUConfigurator cannot open file";
21  m_hasConfig = false;
22  } else {
23  m_hasConfig = true;
24  }
25 }
26 //=============================================================================
27 // Destructor
28 //=============================================================================
30 
31 //=============================================================================
32 
36 }
37 
39  specs.v_boardspecs.reserve(30);
40  for (int i = 0; i < 30; i++) {
41  auto& board = specs.v_boardspecs.emplace_back();
42  m_in >> board;
43  }
44 }
45 
47  specs.m_boardspecs.reserve(3);
48  for (int i = 0; i < 3; i++) {
49  auto& board = specs.m_boardspecs.emplace_back();
50 
51  m_in >> board;
52  }
53 }
TTUConfigurator::addData
void addData(RBCBoardSpecs &)
Definition: TTUConfigurator.cc:38
mps_fire.i
i
Definition: mps_fire.py:428
MessageLogger.h
TTUConfigurator::m_in
std::ifstream m_in
Definition: TTUConfigurator.h:46
HistogramManager_cfi.specs
specs
Definition: HistogramManager_cfi.py:83
TTUConfigurator::m_ttuspecs
TTUBoardSpecs m_ttuspecs
Definition: TTUConfigurator.h:52
TTUConfigurator::~TTUConfigurator
~TTUConfigurator()
Destructor.
Definition: TTUConfigurator.cc:29
TTUConfigurator::m_rbcspecs
RBCBoardSpecs m_rbcspecs
Definition: TTUConfigurator.h:51
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
RBCBoardSpecs
Definition: RBCBoardSpecs.h:17
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
TTUBoardSpecs
Definition: TTUBoardSpecs.h:18
TTUConfigurator::process
void process()
Definition: TTUConfigurator.cc:33
TTUConfigurator.h
timingPdfMaker.infile
infile
Definition: timingPdfMaker.py:350
TTUConfigurator::TTUConfigurator
TTUConfigurator(const std::string &)
Definition: TTUConfigurator.cc:16