ATLAS Offline Software
MuCTPI_RDO.h
Go to the documentation of this file.
1 // Dear emacs, this is -*- c++ -*-
2 
3 /*
4  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 #ifndef TRIGT1RESULT_MUCTPI_RDO_H
8 #define TRIGT1RESULT_MUCTPI_RDO_H
9 
10 // STL include(s):
11 #include <vector>
12 #include <string>
13 #include <cstdint>
14 
15 // Gaudi/Athena include(s):
16 #include "AthenaKernel/CLASS_DEF.h"
17 
41 class MuCTPI_RDO {
42 
43 public:
45  enum SectorLocation { BARREL = 0, ENDCAP = 1, FORWARD = 2 };
46 
47 
49 
57  std::vector< uint32_t >&& dataWord )
58  : m_dataWord( std::move(dataWord) ) {
60  }
61 
63 
70  MuCTPI_RDO( std::vector< uint32_t >&& candidateMultiplicity,
71  std::vector< uint32_t >&& dataWord )
73  m_dataWord( std::move(dataWord) ) {
74  }
75 
77 
80  MuCTPI_RDO () = default;
81 
83 
86  ~MuCTPI_RDO () = default;
87 
89 
97  }
99 
107  if( m_candidateMultiplicity.size() == 0 ) return 0;
108  else return m_candidateMultiplicity[ ( m_candidateMultiplicity.size() - 1 ) / 2 ];
109  }
111 
117  const std::vector< uint32_t >& getAllCandidateMultiplicities() const {
119  }
120 
122 
129  void setDataWord( const uint32_t dataWord ) {
130  m_dataWord.push_back( dataWord );
131  }
133 
141  const std::vector< uint32_t >& dataWord() const {
142  return m_dataWord;
143  }
144 
145 
146 private:
148  std::vector< uint32_t > m_candidateMultiplicity;
150  std::vector< uint32_t > m_dataWord;
151 
152 }; // class MuCTPI_RDO
153 
154 CLASS_DEF( MuCTPI_RDO , 6270 , 0 )
155 
156 #endif // TRIGT1RESULT_MUCTPI_RDO_H
MuCTPI_RDO::SectorLocation
SectorLocation
Enumeration defining the different sources for the muon candidates.
Definition: MuCTPI_RDO.h:45
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
MuCTPI_RDO::BARREL
@ BARREL
Definition: MuCTPI_RDO.h:45
MuCTPI_RDO::FORWARD
@ FORWARD
Definition: MuCTPI_RDO.h:45
MuCTPI_RDO::m_candidateMultiplicity
std::vector< uint32_t > m_candidateMultiplicity
Variable storing the multiplicity word(s) sent to the CTP.
Definition: MuCTPI_RDO.h:148
MuCTPI_RDO::MuCTPI_RDO
MuCTPI_RDO(const uint32_t candidateMultiplicity, std::vector< uint32_t > &&dataWord)
"Intermediate" constructor
Definition: MuCTPI_RDO.h:56
MuCTPI_RDO::getAllCandidateMultiplicities
const std::vector< uint32_t > & getAllCandidateMultiplicities() const
Function returning all candidate multiplicities.
Definition: MuCTPI_RDO.h:117
MuCTPI_RDO::setCandidateMultiplicity
void setCandidateMultiplicity(const uint32_t candidateMultiplicity)
Function adding a multiplicity word to the object.
Definition: MuCTPI_RDO.h:95
MuCTPI_RDO::ENDCAP
@ ENDCAP
Definition: MuCTPI_RDO.h:45
MuCTPI_RDO::candidateMultiplicity
uint32_t candidateMultiplicity() const
Function returning the candidate multiplicity for the triggered bunch crossing.
Definition: MuCTPI_RDO.h:106
MuCTPI_RDO::m_dataWord
std::vector< uint32_t > m_dataWord
Variable storing the muon data words read out.
Definition: MuCTPI_RDO.h:150
MuCTPI_RDO::MuCTPI_RDO
MuCTPI_RDO()=default
Default constructor.
MuCTPI_RDO::setDataWord
void setDataWord(const uint32_t dataWord)
Function adding a data word to the object.
Definition: MuCTPI_RDO.h:129
MuCTPI_RDO::MuCTPI_RDO
MuCTPI_RDO(std::vector< uint32_t > &&candidateMultiplicity, std::vector< uint32_t > &&dataWord)
Full constructor.
Definition: MuCTPI_RDO.h:70
MuCTPI_RDO::~MuCTPI_RDO
~MuCTPI_RDO()=default
Destructor.
MuCTPI_RDO
Class representing the readout data of the MuCTPI hardware and simulation.
Definition: MuCTPI_RDO.h:41
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
MuCTPI_RDO::dataWord
const std::vector< uint32_t > & dataWord() const
Function returning the muon candidate data words.
Definition: MuCTPI_RDO.h:141