ATLAS Offline Software
RpcCoinData.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // TgcCoinData.cxx
7 // Implementation file for class TgcCoinData
9 // (c) ATLAS Detector software
11 
12 #include <new>
14 #include "GaudiKernel/MsgStream.h"
15 
16 namespace Muon
17 {
18  // Constructor
20  const IdentifierHash &idDE,
21  const Amg::Vector2D& locpos,
22  const std::vector<Identifier>& stripList,
23  const Amg::MatrixX& locErrMat,
24  const MuonGM::RpcReadoutElement* detEl,
25  const float time,
26  const unsigned short ambiguityFlag,
27  const unsigned short ijk,
28  const unsigned short threshold,
29  const unsigned short overlap,
30  const unsigned short parent_cmId,
31  const unsigned short parent_padId,
32  const unsigned short parent_sectorId,
33  bool lowPtCm):
34  RpcPrepData(stripId, idDE, locpos, stripList, locErrMat, detEl, time, ambiguityFlag),
35  m_ijk(ijk),
36  m_threshold(threshold),
37  m_overlap(overlap),
38  m_parentCmId(parent_cmId),
39  m_parentPadId(parent_padId),
40  m_parentSectorId(parent_sectorId),
41  m_lowPtCm(lowPtCm)
42 { }
43 
44 // Destructor:
46 = default;
47 
48 // Default constructor:
50  RpcPrepData( ),
51  m_ijk(0),
52  m_threshold(99),
53  m_overlap(99),
54  m_parentCmId(0),
55  m_parentPadId(0),
56  m_parentSectorId(0),
57  m_lowPtCm(false)
58 { }
59 
60 //copy constructor:
62 
63 = default;
64 
65 //move constructor:
67  RpcPrepData(std::move(RIO)),
68  m_ijk( RIO.m_ijk ),
69  m_threshold( RIO.m_threshold ),
70  m_overlap( RIO.m_overlap ),
71  m_parentCmId( RIO.m_parentCmId ),
72  m_parentPadId( RIO.m_parentPadId ),
73  m_parentSectorId( RIO.m_parentSectorId ),
74  m_lowPtCm( RIO.m_lowPtCm )
75 { }
76 
77 //assignment operator
79 {
80  if(&RIO !=this)
81  {
83  m_ijk = RIO.m_ijk;
85  m_overlap = RIO.m_overlap;
89  m_lowPtCm = RIO.m_lowPtCm;
90  }
91  return *this;
92 }
93 
94 //move operator
96  noexcept {
97  if(&RIO !=this)
98  {
99  m_ijk = RIO.m_ijk;
100  m_threshold = RIO.m_threshold;
101  m_overlap = RIO.m_overlap;
102  m_parentCmId = RIO.m_parentCmId;
103  m_parentPadId = RIO.m_parentPadId;
104  m_parentSectorId = RIO.m_parentSectorId;
105  m_lowPtCm = RIO.m_lowPtCm;
106  RpcPrepData::operator=(std::move(RIO));
107  }
108  return *this;
109 }
110 
111 // << operator
112 
113 MsgStream& RpcCoinData::dump( MsgStream& stream) const
114 {
115  stream << MSG::INFO<<"RpcCoinData {"<<std::endl;
116 
118 
119  stream<<"ijk = "<<this->ijk()<<", ";
120  stream<<"threshold = "<<this->threshold()<<", ";
121  stream<<"overlap = "<<this->overlap()<<", ";
122  stream<<"parentCmId = "<<this->parentCmId()<<", ";
123  stream<<"parentPadId = "<<this->parentPadId()<<", ";
124  stream<<"parentSectorId = "<<this->parentSectorId()<<", ";
125  stream<<"lowPtCm = "<<this->isLowPtCoin()<<", ";
126  stream<<"lowPtInputToHighPtCm = "<<this->isLowPtInputToHighPtCm()<<", ";
127  stream<<"}"<<endmsg;
128 
129  return stream;
130 }
131 
132 std::ostream& RpcCoinData::dump( std::ostream& stream) const
133 {
134  stream <<"RpcCoinData {"<<std::endl;
135 
137 
138  stream<<"ijk = "<<this->ijk()<<", ";
139  stream<<"threshold = "<<this->threshold()<<", ";
140  stream<<"overlap = "<<this->overlap()<<", ";
141  stream<<"parentCmId = "<<this->parentCmId()<<", ";
142  stream<<"parentPadId = "<<this->parentPadId()<<", ";
143  stream<<"parentSectorId = "<<this->parentSectorId()<<", ";
144  stream<<"lowPtCm = "<<this->isLowPtCoin()<<", ";
145  stream<<"lowPtInputToHighPtCm = "<<this->isLowPtInputToHighPtCm()<<", ";
146  stream<<"}"<<std::endl;
147 
148  return stream;
149 }
151 {
152  return m_lowPtCm && m_ijk == 6;
153 }
155 {
156  return (!m_lowPtCm) && m_ijk == 6;
157 }
159 {
160  return m_ijk == 0;
161 }
162 
163 
164 }//end of namespace
165 
Muon::RpcCoinData::overlap
unsigned short overlap() const
return the overlap flag
Definition: RpcCoinData.h:111
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:29
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
Muon::RpcCoinData::RpcCoinData
RpcCoinData()
Public, Copy, operator=, constructor.
Definition: RpcCoinData.cxx:49
Muon::RpcCoinData::operator=
RpcCoinData & operator=(const RpcCoinData &)
Definition: RpcCoinData.cxx:78
Muon::RpcCoinData::parentCmId
unsigned short parentCmId() const
parent ID (online-style) of CM, PAD and Sector
Definition: RpcCoinData.h:114
Muon::RpcCoinData::m_threshold
unsigned short m_threshold
Definition: RpcCoinData.h:92
MuonGM::RpcReadoutElement
An RpcReadoutElement corresponds to a single RPC module; therefore typicaly a barrel muon station con...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/RpcReadoutElement.h:54
Muon::RpcCoinData::~RpcCoinData
virtual ~RpcCoinData()
Destructor:
Muon
This class provides conversion from CSC RDO data to CSC Digits.
Definition: TrackSystemController.h:49
RpcCoinData.h
AthenaPoolTestWrite.stream
string stream
Definition: AthenaPoolTestWrite.py:12
Muon::RpcCoinData::isHighPtCoin
bool isHighPtCoin() const
Definition: RpcCoinData.cxx:154
Muon::RpcCoinData
Definition: RpcCoinData.h:25
Muon::RpcCoinData::ijk
unsigned short ijk() const
return ijk of the trigger hit (can be 6, 7 or 0)
Definition: RpcCoinData.h:105
Muon::RpcCoinData::m_overlap
unsigned short m_overlap
Definition: RpcCoinData.h:93
Muon::RpcCoinData::parentSectorId
unsigned short parentSectorId() const
Definition: RpcCoinData.h:116
Muon::RpcPrepData
Class to represent RPC measurements.
Definition: RpcPrepData.h:35
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
Muon::RpcCoinData::m_parentPadId
unsigned short m_parentPadId
Definition: RpcCoinData.h:95
Muon::RpcPrepData::dump
virtual MsgStream & dump(MsgStream &stream) const override
Dumps information about the PRD.
Definition: RpcPrepData.cxx:119
Muon::RpcCoinData::m_ijk
unsigned short m_ijk
Definition: RpcCoinData.h:91
Muon::RpcCoinData::isLowPtInputToHighPtCm
bool isLowPtInputToHighPtCm() const
Definition: RpcCoinData.cxx:158
Muon::RpcCoinData::parentPadId
unsigned short parentPadId() const
Definition: RpcCoinData.h:115
threshold
Definition: chainparser.cxx:74
Muon::RpcCoinData::m_parentCmId
unsigned short m_parentCmId
Definition: RpcCoinData.h:94
Muon::RpcPrepData::operator=
RpcPrepData & operator=(const RpcPrepData &)=default
Muon::RpcCoinData::threshold
unsigned short threshold() const
return highest threshold for the trigger pattern this hit is contributing
Definition: RpcCoinData.h:108
Muon::RpcCoinData::m_parentSectorId
unsigned short m_parentSectorId
Definition: RpcCoinData.h:96
CaloSwCorrections.time
def time(flags, cells_name, *args, **kw)
Definition: CaloSwCorrections.py:242
Muon::RpcCoinData::isLowPtCoin
bool isLowPtCoin() const
Low Pt, High Pt or Low Pt input to High Pt CM.
Definition: RpcCoinData.cxx:150
Muon::RpcCoinData::dump
virtual MsgStream & dump(MsgStream &stream) const
Dumps information about the RpcCoinData.
Definition: RpcCoinData.cxx:113
IdentifierHash
Definition: IdentifierHash.h:38
Muon::RpcCoinData::m_lowPtCm
bool m_lowPtCm
Definition: RpcCoinData.h:97