ATLAS Offline Software
CscPrepData.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // CscPrepData.cxx
7 // Implementation file for class CscPrepData
9 // (c) ATLAS Detector software
11 // Version 1.0 03/29/2005 Ketevi A. Assamagan
13 
14 #include <new>
15 #include <sstream>
17 #include "GaudiKernel/MsgStream.h"
18 
19 namespace Muon
20 {
21 
23  const IdentifierHash& idDE,
24  const Amg::Vector2D& locpos,
25  const std::vector<Identifier>& rdoList,
26  const Amg::MatrixX& locErrMat,
27  const MuonGM::CscReadoutElement* detEl,
28  const int charge,
29  const double time,
31  const CscTimeStatus timeStatus) :
32  MuonCluster(RDOId, idDE, locpos, rdoList, locErrMat), //call base class constructor
33  m_detEl(detEl),
34  m_charge(charge),
35  m_time(time),
36  m_status(status),
37  m_timeStatus(timeStatus)
38  { }
39 
41  const IdentifierHash& idDE,
42  const Amg::Vector2D& locpos,
43  std::vector<Identifier>&& rdoList,
44  Amg::MatrixX&& locErrMat,
45  const MuonGM::CscReadoutElement* detEl,
46  const int charge,
47  const double time,
49  const CscTimeStatus timeStatus) :
50  MuonCluster(RDOId, idDE, locpos, std::move(rdoList), std::move(locErrMat)), //call base class constructor
51  m_detEl(detEl),
52  m_charge(charge),
53  m_time(time),
54  m_status(status),
55  m_timeStatus(timeStatus)
56  { }
57 
58 
59  // Destructor:
61  = default;
62 
63  // Default constructor:
65  MuonCluster(),
66  m_detEl(nullptr),
67  m_charge(0),
68  m_time(0),
69  m_status(CscStatusUndefined),
70  m_timeStatus(CscTimeStatusUndefined)
71  { }
72 
73 
74  MsgStream& CscPrepData::dump( MsgStream& stream) const
75  {
76  stream << MSG::INFO << "CscPrepData {" <<std::endl;
77 
79 
80  std::stringstream s;
81  s << "Charge = "<<this->charge() << ", ";
82  s << std::setiosflags(std::ios::fixed);
83  s << std::setprecision(4);
84  s << "Time = "<<this->time() << ", ";
85  s << "Status = "<<this->status();
86  s << "TimeStatus = "<<this->timeStatus();
87  s << "}" << std::endl;
88  stream << s.str();
89 
90  return stream;
91  }
92 
93  std::ostream& CscPrepData::dump( std::ostream& stream) const
94  {
95  stream << "CscPrepData {"<<std::endl;
96 
98 
99  std::stringstream s;
100  s << "Charge = " << this->charge() << ", ";
101  s << std::setiosflags(std::ios::fixed);
102  s << std::setprecision(4);
103  s << "Time = " << this->time() << ", ";
104  s << "Status = "<<this->status();
105  s << "TimeStatus = "<<this->timeStatus();
106  s << "}" <<std::endl;
107  stream << s.str();
108 
109  return stream;
110  }
111  //end of classdef
112 
113 }//end of ns
Muon::CscPrepData::dump
virtual MsgStream & dump(MsgStream &stream) const override final
Dumps information about the PRD.
Definition: CscPrepData.cxx:74
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
Amg::MatrixX
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixX
Dynamic Matrix - dynamic allocation.
Definition: EventPrimitives.h:27
Muon::CscPrepData::charge
int charge() const
Returns the charge.
Definition: CscPrepData.h:153
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
MuonGM::CscReadoutElement
Definition: CscReadoutElement.h:56
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition: TrackSystemController.h:45
AthenaPoolTestWrite.stream
string stream
Definition: AthenaPoolTestWrite.py:12
Muon::CscPrepData::timeStatus
CscTimeStatus timeStatus() const
Returns the Csc time status flag.
Definition: CscPrepData.h:168
Muon::CscPrepData::~CscPrepData
virtual ~CscPrepData()
Destructor.
CscPrepData.h
Muon::CscPrepData::status
CscClusterStatus status() const
Returns the Csc status (position measurement) flag.
Definition: CscPrepData.h:163
Muon::CscPrepData::time
double time() const
Returns the time.
Definition: CscPrepData.h:158
Muon::CscStatusUndefined
@ CscStatusUndefined
Undefined, should not happen, most likely indicates a problem.
Definition: CscClusterStatus.h:94
charge
double charge(const T &p)
Definition: AtlasPID.h:756
Muon::CscPrepData::CscPrepData
CscPrepData()
Definition: CscPrepData.cxx:64
Muon::CscTimeStatusUndefined
@ CscTimeStatusUndefined
Time is not assessed indicating potential bug.
Definition: CscTimeStatus.h:39
Muon::MuonCluster::dump
virtual MsgStream & dump(MsgStream &stream) const override
Dumps information about the PRD.
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonPrepRawData/src/MuonCluster.cxx:78
Muon::MuonCluster
Class representing clusters in the muon system.
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonPrepRawData/MuonPrepRawData/MuonCluster.h:37
merge.status
status
Definition: merge.py:17
Muon::CscClusterStatus
CscClusterStatus
Enum to represent the cluster status - see the specific enum values for more details.
Definition: CscClusterStatus.h:23
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
Muon::CscTimeStatus
CscTimeStatus
Enum to represent the cluster time measurement status - see the specific enum values for more details...
Definition: CscTimeStatus.h:24
Identifier
Definition: IdentifierFieldParser.cxx:14