CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
OMTFinput.h
Go to the documentation of this file.
1 #ifndef OMTF_OMTFinput_H
2 #define OMTF_OMTFinput_H
3 
4 #include <vector>
5 #include <ostream>
6 #include <bitset>
7 
8 class XMLConfigReader;
10 
11 class OMTFinput {
12 public:
13  typedef std::vector<int> vector1D;
14  typedef std::vector<vector1D> vector2D;
15 
17 
20  bool addLayerHit(unsigned int iLayer, unsigned int iInput, int iPhi, int iEta, bool allowOverwrite = true);
21 
23  void clear();
24 
26  void readData(XMLConfigReader *aReader, unsigned int iEvent = 0, unsigned int iProcessor = 0);
27 
29  void shiftMyPhi(int phiShift);
30 
33  void mergeData(const OMTFinput *aInput);
34 
35  const OMTFinput::vector1D &getLayerData(unsigned int iLayer, bool giveEta = false) const;
36 
37  std::bitset<128> getRefHits(unsigned int iProcessor) const;
38 
39  friend std::ostream &operator<<(std::ostream &out, const OMTFinput &aInput);
40 
41  OMTFinput &operator+=(const OMTFinput &iInput) {
42  mergeData(&iInput);
43  return *this;
44  }
45 
46 private:
51 
56 
59 
61 };
62 
63 #endif
bool addLayerHit(unsigned int iLayer, unsigned int iInput, int iPhi, int iEta, bool allowOverwrite=true)
Definition: OMTFinput.cc:44
void clear()
Reset vectors with data.
Definition: OMTFinput.cc:91
vector2D measurementsEta
Definition: OMTFinput.h:55
void mergeData(const OMTFinput *aInput)
Definition: OMTFinput.cc:76
void shiftMyPhi(int phiShift)
Apply shift to all data.
Definition: OMTFinput.cc:99
friend std::ostream & operator<<(std::ostream &out, const OMTFinput &aInput)
Definition: OMTFinput.cc:121
std::vector< int > vector1D
Definition: OMTFinput.h:13
std::vector< vector1D > vector2D
Definition: OMTFinput.h:14
const OMTFinput::vector1D & getLayerData(unsigned int iLayer, bool giveEta=false) const
Definition: OMTFinput.cc:17
vector1D refHitsEta
RefHitsEta.
Definition: OMTFinput.h:58
int iEvent
Definition: GenABIO.cc:224
OMTFinput(const OMTFConfiguration *)
Definition: OMTFinput.cc:11
std::bitset< 128 > getRefHits(unsigned int iProcessor) const
Definition: OMTFinput.cc:26
const OMTFConfiguration * myOmtfConfig
Definition: OMTFinput.h:60
void readData(XMLConfigReader *aReader, unsigned int iEvent=0, unsigned int iProcessor=0)
Read data from a XML file.
Definition: OMTFinput.cc:70
vector2D measurementsPhi
Definition: OMTFinput.h:50
OMTFinput & operator+=(const OMTFinput &iInput)
Definition: OMTFinput.h:41