CMS 3D CMS Logo

HcalAssistant.h
Go to the documentation of this file.
1 #ifndef CaloOnlineTools_HcalOnlineDb_HcalAssistant_h
2 #define CaloOnlineTools_HcalOnlineDb_HcalAssistant_h
3 // -*- C++ -*-
4 //
5 // Package: HcalOnlineDb
6 // Class : HcalAssistant
7 //
16 //
17 // Original Author: Gena Kukartsev, kukarzev@fnal.gov
18 // Created: Thu Jul 16 11:39:31 CEST 2009
19 //
20 
21 #include <iostream>
22 #include <string>
23 #include <vector>
24 #include <map>
25 
28 
29 #ifndef DATAFORMATS_HCALDETID_HCALSUBDETECTOR_H
30 #define DATAFORMATS_HCALDETID_HCALSUBDETECTOR_H
32  HcalEmpty = 0,
35  HcalOuter = 3,
39 };
41 #endif
42 
44 public:
45  friend class HcalChannelQualityXml;
46 
47  HcalAssistant();
48  virtual ~HcalAssistant();
49 
50  int addQuotes();
52 
54 
59 
61  int getSubdetector(int _rawid);
62  int getIeta(int _rawid);
63  int getIphi(int _rawid);
64  int getDepth(int _rawid);
65  int getRawId(HcalSubdetector _det, int _ieta, int _iphi, int _depth);
66 
67  int a_to_i(char* inbuf);
68 
69 private:
70  std::vector<std::string> quotes;
71  std::map<int, int> geom_to_rawid; // geom hash is the hey
72  std::map<int, int> rawid_to_geom; // rawId is the key
73  bool listIsRead; // were channels read from OMDS?
74 
75  //
76  //_____ encode HCAL geometry channel in a single integer hash
77  // not relying on HcalDetId
78  int getGeomId(HcalSubdetector _det, int _ieta, int _iphi, int _depth);
79  int getHcalIeta(int _geomId);
80  int getHcalIphi(int _geomId);
81  int getHcalDepth(int _geomId);
83  std::string getSubdetectorString(int _geomId);
84  int getRawId(int _geomId);
85  int getRawIdFromCmssw(int _geomId);
86  int getGeomId(int _rawid);
87 };
88 
89 #endif
HcalAssistant::rawid_to_geom
std::map< int, int > rawid_to_geom
Definition: HcalAssistant.h:72
HcalOther
Definition: HcalAssistant.h:38
HcalAssistant::HcalChannelQualityXml
friend class HcalChannelQualityXml
Definition: HcalAssistant.h:45
HcalAssistant::getHcalDepth
int getHcalDepth(int _geomId)
Definition: HcalAssistant.cc:95
HcalAssistant::getRawId
int getRawId(HcalSubdetector _det, int _ieta, int _iphi, int _depth)
Definition: HcalAssistant.cc:277
HcalAssistant::getListOfChannelsFromDb
int getListOfChannelsFromDb()
Definition: HcalAssistant.cc:200
HcalZDCDetId::Section
Section
Definition: HcalZDCDetId.h:23
HcalAssistant::getUserName
std::string getUserName(void)
Definition: HcalAssistant.cc:71
HcalAssistant::getIphi
int getIphi(int _rawid)
Definition: HcalAssistant.cc:273
HcalAssistant::getZDCSectionString
std::string getZDCSectionString(HcalZDCDetId::Section _section)
Definition: HcalAssistant.cc:172
HcalAssistant::getRawIdFromCmssw
int getRawIdFromCmssw(int _geomId)
Definition: HcalAssistant.cc:254
HcalBarrel
Definition: HcalAssistant.h:33
HcalEmpty
Definition: HcalAssistant.h:32
HcalZDCDetId.h
HcalAssistant::getHcalIphi
int getHcalIphi(int _geomId)
Definition: HcalAssistant.cc:90
HcalOtherEmpty
Definition: HcalAssistant.h:40
HcalAssistant::getDepth
int getDepth(int _rawid)
Definition: HcalAssistant.cc:275
HcalAssistant::addQuotes
int addQuotes()
Definition: HcalAssistant.cc:40
HcalAssistant::getGeomId
int getGeomId(HcalSubdetector _det, int _ieta, int _iphi, int _depth)
Definition: HcalAssistant.cc:77
HcalAssistant::getHcalSubdetector
HcalSubdetector getHcalSubdetector(int _geomId)
Definition: HcalAssistant.cc:100
HcalAssistant::getZDCSection
HcalZDCDetId::Section getZDCSection(std::string _section)
Definition: HcalAssistant.cc:187
HcalOuter
Definition: HcalAssistant.h:35
HcalAssistant::a_to_i
int a_to_i(char *inbuf)
Definition: HcalAssistant.cc:281
HcalAssistant::quotes
std::vector< std::string > quotes
Definition: HcalAssistant.h:70
HcalCalibration
Definition: HcalAssistant.h:40
HcalAssistant
Definition: HcalAssistant.h:43
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
HcalAssistant::getRandomQuote
std::string getRandomQuote(void)
Definition: HcalAssistant.cc:65
HcalAssistant::getIeta
int getIeta(int _rawid)
Definition: HcalAssistant.cc:271
HcalAssistant::geom_to_rawid
std::map< int, int > geom_to_rawid
Definition: HcalAssistant.h:71
HcalOtherSubdetector
HcalOtherSubdetector
Definition: HcalAssistant.h:40
HcalAssistant::~HcalAssistant
virtual ~HcalAssistant()
Definition: HcalAssistant.cc:38
HcalAssistant::getSubdetector
HcalSubdetector getSubdetector(std::string _det)
Definition: HcalAssistant.cc:140
HcalSubdetector.h
HcalAssistant::listIsRead
bool listIsRead
Definition: HcalAssistant.h:73
HcalSubdetector
HcalSubdetector
Definition: HcalAssistant.h:31
HcalAssistant::getSubdetectorString
std::string getSubdetectorString(HcalSubdetector _det)
Definition: HcalAssistant.cc:155
HcalForward
Definition: HcalAssistant.h:36
HcalEndcap
Definition: HcalAssistant.h:34
HcalTriggerTower
Definition: HcalAssistant.h:37
HcalAssistant::HcalAssistant
HcalAssistant()
Definition: HcalAssistant.cc:32
HcalAssistant::getHcalIeta
int getHcalIeta(int _geomId)
Definition: HcalAssistant.cc:85