Main Page
Namespaces
Classes
Package Documentation
CondFormats
SiPixelObjects
src
SiPixelLorentzAngle.cc
Go to the documentation of this file.
1
#include "
CondFormats/SiPixelObjects/interface/SiPixelLorentzAngle.h
"
2
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
3
4
bool
SiPixelLorentzAngle::putLorentzAngle
(
const
uint32_t& detid,
float
&
value
){
5
std::map<unsigned int,float>::const_iterator
id
=
m_LA
.find(detid);
6
if
(
id
!=
m_LA
.end()){
7
edm::LogError
(
"SiPixelLorentzAngle"
) <<
"SiPixelLorentzAngle for DetID "
<< detid <<
" is already stored. Skippig this put"
<< std::endl;
8
return
false
;
9
}
10
else
m_LA
[detid]=
value
;
11
return
true
;
12
}
13
float
SiPixelLorentzAngle::getLorentzAngle
(
const
uint32_t& detid)
const
{
14
std::map<unsigned int,float>::const_iterator
id
=
m_LA
.find(detid);
15
if
(
id
!=
m_LA
.end())
return
id->second;
16
else
{
17
edm::LogError
(
"SiPixelLorentzAngle"
) <<
"SiPixelLorentzAngle for DetID "
<< detid <<
" is not stored"
<< std::endl;
18
}
19
return
0;
20
}
MessageLogger.h
SiPixelLorentzAngle::m_LA
std::map< unsigned int, float > m_LA
Definition:
SiPixelLorentzAngle.h:27
edm::LogError
Definition:
MessageLogger.h:183
value
Definition:
value.py:1
SiPixelLorentzAngle::putLorentzAngle
bool putLorentzAngle(const uint32_t &, float &)
Definition:
SiPixelLorentzAngle.cc:4
relativeConstraints.value
value
Definition:
relativeConstraints.py:53
SiPixelLorentzAngle::getLorentzAngle
float getLorentzAngle(const uint32_t &) const
Definition:
SiPixelLorentzAngle.cc:13
SiPixelLorentzAngle.h
Generated for CMSSW Reference Manual by
1.8.11