ATLAS Offline Software
CaloCellFactor.h
Go to the documentation of this file.
1 // Dear emacs, this is -*- c++ -*-.
2 
3 /*
4  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
5 */
6 
15 #ifndef CALOREC_CALOCELLSCALE_H
16 #define CALOREC_CALOCELLSCALE_H
17 
18 
19 #include "AthenaKernel/CLASS_DEF.h"
20 #include <vector>
21 
22 namespace CaloRec {
23 
30  {
31  public:
32  typedef std::vector<float> contType;
33  typedef contType::size_type size_type;
34 
35  //** Default Constructor
37 
38  //** Standard constructor, resize vector and set elements on 1.0
39  CaloCellFactor(const size_type& size);
40 
41 
42  //** non-const access
43  inline float& operator[](const size_type& hashID)
44  {return m_cellFactor[hashID];}
45 
46 
47  //** const access
48  inline const float& operator[](const size_type& hashID) const
49  {return m_cellFactor[hashID];}
50 
51  //** resize underlying vector (new elements will be 1.0)
52  void resize(const size_type& size);
53 
54  size_type size() const
55  {return m_cellFactor.size();}
56 
57  private:
59 
60 
61  };//end class
62 }// end namespace
63 
65 
66 #endif
CaloRec::CaloCellFactor::size
size_type size() const
Definition: CaloCellFactor.h:54
CaloRec::CaloCellFactor::resize
void resize(const size_type &size)
Definition: CaloCellFactor.cxx:12
CaloRec::CaloCellFactor::operator[]
float & operator[](const size_type &hashID)
Definition: CaloCellFactor.h:43
CaloRec::CaloCellFactor::operator[]
const float & operator[](const size_type &hashID) const
Definition: CaloCellFactor.h:48
CaloRec::CaloCellFactor::CaloCellFactor
CaloCellFactor()
Definition: CaloCellFactor.h:36
CaloRec::CaloCellFactor
Container for a cell-level rescaling-factors, typically obtained by Z->ee intercalibration.
Definition: CaloCellFactor.h:30
CaloRec::CaloCellFactor::contType
std::vector< float > contType
Definition: CaloCellFactor.h:32
CaloRec::CaloCellFactor::m_cellFactor
contType m_cellFactor
Definition: CaloCellFactor.h:58
CaloRec
Namespace for helper functions.
Definition: CaloCellFactor.h:22
CaloRec::CaloCellFactor::size_type
contType::size_type size_type
Definition: CaloCellFactor.h:33
CLASS_DEF
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
Definition: Control/AthenaKernel/AthenaKernel/CLASS_DEF.h:64
CLASS_DEF.h
macros to associate a CLID to a type