ATLAS Offline Software
Loading...
Searching...
No Matches
CscDigit.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
6
8#include <algorithm>
9#include <utility>
10
12
14
17
20
21CscDigit::CscDigit(const Identifier& id, std::vector<float> sampleCharges)
23
24 std::vector<float, std::allocator<float> >::iterator pkit
25 = std::max_element( m_sampleCharges.begin(), m_sampleCharges.end() );
26
27 m_charge = *pkit;
28 m_time = 0.0; // obsolete
29
30}
31
33bool CscDigit::is_valid(const CscIdHelper * cscHelper) const {
34 return (m_charge > 0 && cscHelper->valid(m_muonId));
35}
36
std::vector< float > m_sampleCharges
Definition CscDigit.h:23
CscDigit()=default
Default constructor.
bool is_valid(const CscIdHelper *cscHelper) const
Is this a valid digit.
Definition CscDigit.cxx:33
int charge() const
Return the charge.
Definition CscDigit.h:42
int m_charge
Definition CscDigit.h:21
float m_time
Definition CscDigit.h:22
const std::vector< float > & sampleCharges() const
Definition CscDigit.h:48
float time() const
return the time
Definition CscDigit.h:46
bool valid(const Identifier &id) const
Public validation of levels.
Identifier m_muonId
Definition MuonDigit.h:21
MuonDigit()=default
STL namespace.