CalibFormats
HcalObjects
interface
HcalCalibrationsSet.h
Go to the documentation of this file.
1
#ifndef CALIBFORMATS_HCALOBJECTS_HCALCALIBRATIONSSET_H
2
#define CALIBFORMATS_HCALOBJECTS_HCALCALIBRATIONSSET_H 1
3
4
#include "
CalibFormats/HcalObjects/interface/HcalCalibrations.h
"
5
#include "
CondFormats/HcalObjects/interface/HcalDetIdRelationship.h
"
6
#include "
DataFormats/HcalDetId/interface/HcalDetId.h
"
7
#include "
DataFormats/HcalDetId/interface/HcalZDCDetId.h
"
8
#include <vector>
9
#include <unordered_map>
10
#include <cstdint>
11
16
class
HcalCalibrationsSet
{
17
public
:
18
HcalCalibrationsSet
();
19
const
HcalCalibrations
&
getCalibrations
(
const
DetId
id
)
const
;
20
void
setCalibrations
(
const
DetId
id
,
const
HcalCalibrations
& ca);
21
void
clear
();
22
std::vector<DetId>
getAllChannels
()
const
;
23
24
private
:
25
struct
CalibSetObject
{
26
CalibSetObject
(
const
DetId
& aid) {
id
=
hcalTransformedId
(aid); }
27
DetId
id
;
28
HcalCalibrations
calib
;
29
bool
operator<
(
const
CalibSetObject
& cso)
const
{
return
id
< cso.
id
; }
30
bool
operator==
(
const
CalibSetObject
& cso)
const
{
return
id
== cso.
id
; }
31
};
32
typedef
CalibSetObject
Item
;
33
HcalCalibrations
dummy
;
34
std::unordered_map<uint32_t, CalibSetObject>
mItems
;
35
};
36
37
#endif
HcalCalibrationsSet::Item
CalibSetObject Item
Definition:
HcalCalibrationsSet.h:32
HcalCalibrations.h
HcalCalibrationsSet::clear
void clear()
Definition:
HcalCalibrationsSet.cc:29
HcalCalibrationsSet::CalibSetObject::operator==
bool operator==(const CalibSetObject &cso) const
Definition:
HcalCalibrationsSet.h:30
HcalCalibrationsSet
Definition:
HcalCalibrationsSet.h:16
HcalCalibrationsSet::HcalCalibrationsSet
HcalCalibrationsSet()
Definition:
HcalCalibrationsSet.cc:8
HcalCalibrationsSet::dummy
HcalCalibrations dummy
Definition:
HcalCalibrationsSet.h:33
HcalZDCDetId.h
HcalCalibrationsSet::getCalibrations
const HcalCalibrations & getCalibrations(const DetId id) const
Definition:
HcalCalibrationsSet.cc:10
DetId
Definition:
DetId.h:17
HcalCalibrationsSet::getAllChannels
std::vector< DetId > getAllChannels() const
Definition:
HcalCalibrationsSet.cc:31
HcalCalibrationsSet::CalibSetObject::id
DetId id
Definition:
HcalCalibrationsSet.h:27
HcalCalibrationsSet::CalibSetObject::calib
HcalCalibrations calib
Definition:
HcalCalibrationsSet.h:28
hcalTransformedId
DetId hcalTransformedId(const DetId &aid)
Definition:
HcalDetIdRelationship.cc:11
HcalCalibrations
Definition:
HcalCalibrations.h:9
HcalDetId.h
HcalCalibrationsSet::CalibSetObject::operator<
bool operator<(const CalibSetObject &cso) const
Definition:
HcalCalibrationsSet.h:29
HcalDetIdRelationship.h
HcalCalibrationsSet::CalibSetObject
Definition:
HcalCalibrationsSet.h:25
HcalCalibrationsSet::mItems
std::unordered_map< uint32_t, CalibSetObject > mItems
Definition:
HcalCalibrationsSet.h:34
HcalCalibrationsSet::setCalibrations
void setCalibrations(const DetId id, const HcalCalibrations &ca)
Definition:
HcalCalibrationsSet.cc:18
HcalCalibrationsSet::CalibSetObject::CalibSetObject
CalibSetObject(const DetId &aid)
Definition:
HcalCalibrationsSet.h:26
Generated for CMSSW Reference Manual by
1.8.16