CMS 3D CMS Logo

TMem.cc
Go to the documentation of this file.
1 /*
2  * \class TMem
3  *
4  * \author: Julie Malcles - CEA/Saclay
5  */
6 
9 
10 #include <TMath.h>
11 #include <iostream>
12 using namespace std;
13 
14 //ClassImp(TMem)
15 
16 // Default Constructor...
17 TMem::TMem() { init(610); }
18 
19 // Constructor...
21 
22 // Destructor
24 
25 void TMem::init(int fedid) {
26  _fedid = fedid;
27  _memFromDcc = ME::memFromDcc(_fedid);
28 }
29 
31  bool isMemOK = false;
32  for (unsigned int imem = 0; imem < _memFromDcc.size(); imem++) {
33  if (mem == _memFromDcc[imem]) {
34  isMemOK = true;
35  imem = _memFromDcc.size();
36  }
37  }
38  return isMemOK;
39 }
40 
41 int TMem::Mem(int lmr, int n) {
42  std::pair<int, int> mempair = ME::memFromLmr(lmr);
43  if (n == 0)
44  return mempair.first;
45  else
46  return mempair.second;
47 }
init
int init
Definition: HydjetWrapper.h:64
dqmiodumpmetadata.n
n
Definition: dqmiodumpmetadata.py:28
TMem.h
mem
uint16_t mem[nChs][nEvts]
Definition: recycleTccEmu.cc:13
TMem::Mem
int Mem(int, int)
Definition: TMem.cc:41
ME::memFromLmr
static std::pair< ME::DCCid, ME::DCCid > memFromLmr(ME::LMRid ilmr)
Definition: ME.cc:538
TMem::~TMem
~TMem() override
Definition: TMem.cc:23
ME.h
PixelSLinkDataInputSource_cfi.fedid
fedid
Definition: PixelSLinkDataInputSource_cfi.py:6
TMem::isMemRelevant
bool isMemRelevant(int)
Definition: TMem.cc:30
std
Definition: JetResolutionObject.h:76
TMem::TMem
TMem()
Definition: TMem.cc:17
ME::memFromDcc
static std::vector< ME::DCCid > memFromDcc(ME::DCCid idcc)
Definition: ME.cc:561
TMem::init
void init(int)
Definition: TMem.cc:25