ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
LArCalorimeter
LArRawConditions
LArRawConditions
LArCellTimeOffset.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef LARCELLTIMEOFFSET_H
6
#define LARCELLTIMEOFFSET_H
7
8
#include "
AthenaKernel/CLASS_DEF.h
"
9
#include "
Identifier/HWIdentifier.h
"
10
#include <map>
11
12
class
LArCellTimeOffset
{
13
public
:
14
LArCellTimeOffset
();
//Constructor
15
virtual
~LArCellTimeOffset
() {};
//Destructor
16
inline
void
setTimeOffset
(
const
HWIdentifier
fId,
const
float
offset)
//Setter
17
{
m_cellTimeMap
[fId]=offset;}
18
inline
float
TimeOffset
(
const
HWIdentifier
fId)
const
;
//Getter
19
20
inline
unsigned
size
()
const
21
{
return
m_cellTimeMap
.size();}
22
23
inline
void
setDefaultReturnValue
(
const
float
value)
24
{
m_defaultReturnValue
=value; }
25
26
inline
std::map <HWIdentifier,float>::const_iterator
begin
()
const
27
{
return
m_cellTimeMap
.begin();}
28
29
inline
std::map <HWIdentifier,float>::const_iterator
end
()
const
30
{
return
m_cellTimeMap
.end();}
31
32
private
:
33
std::map <HWIdentifier,float>
m_cellTimeMap
;
34
float
m_defaultReturnValue
;
35
};
36
37
inline
float
LArCellTimeOffset::TimeOffset
(
const
HWIdentifier
fId)
const
{
38
const
std::map <HWIdentifier,float>::const_iterator it=
m_cellTimeMap
.find(fId);
39
if
(it==
m_cellTimeMap
.end())
40
return
m_defaultReturnValue
;
41
else
42
return
it->second;
43
}
44
45
CLASS_DEF
(
LArCellTimeOffset
, 141392342, 1)
46
#endif
CLASS_DEF.h
macros to associate a CLID to a type
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:67
HWIdentifier.h
HWIdentifier
Definition
HWIdentifier.h:13
LArCellTimeOffset
Definition
LArCellTimeOffset.h:12
LArCellTimeOffset::LArCellTimeOffset
LArCellTimeOffset()
Definition
LArCellTimeOffset.cxx:7
LArCellTimeOffset::end
std::map< HWIdentifier, float >::const_iterator end() const
Definition
LArCellTimeOffset.h:29
LArCellTimeOffset::setDefaultReturnValue
void setDefaultReturnValue(const float value)
Definition
LArCellTimeOffset.h:23
LArCellTimeOffset::m_cellTimeMap
std::map< HWIdentifier, float > m_cellTimeMap
Definition
LArCellTimeOffset.h:33
LArCellTimeOffset::m_defaultReturnValue
float m_defaultReturnValue
Definition
LArCellTimeOffset.h:34
LArCellTimeOffset::size
unsigned size() const
Definition
LArCellTimeOffset.h:20
LArCellTimeOffset::TimeOffset
float TimeOffset(const HWIdentifier fId) const
Definition
LArCellTimeOffset.h:37
LArCellTimeOffset::setTimeOffset
void setTimeOffset(const HWIdentifier fId, const float offset)
Definition
LArCellTimeOffset.h:16
LArCellTimeOffset::~LArCellTimeOffset
virtual ~LArCellTimeOffset()
Definition
LArCellTimeOffset.h:15
LArCellTimeOffset::begin
std::map< HWIdentifier, float >::const_iterator begin() const
Definition
LArCellTimeOffset.h:26
Generated on
for ATLAS Offline Software by
1.17.0