ATLAS Offline Software
Loading...
Searching...
No Matches
L1TopoRDO.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 L1TOPORDO_L1TOPORDO_H
6#define L1TOPORDO_L1TOPORDO_H
7
8#include <cstdint>
9#include <vector>
10#include <string>
11#include "L1TopoRDO/Error.h"
12
28
29class L1TopoRDO {
30 public:
33 m_error(0),
34 m_sourceID(0){ }
35
37 const std::vector<uint32_t>& getDataWords() const;
39 void setDataWords(std::vector<uint32_t>&&) noexcept;
40
42 const std::vector<uint32_t>& getStatusWords() const;
44 void setStatusWords(std::vector<uint32_t>&&) noexcept;
45
47 // print helpers
48 std::vector<L1Topo::Error> getErrors() const;
50 bool checkError(L1Topo::Error) const;
52 void setError(L1Topo::Error);
53
55 uint32_t getError() const { return m_error; }
56
58 // module ID, of the ROD from which this RDO was filled
59 uint32_t getSourceID() const;
61 void setSourceID(const uint32_t);
62
64 // numbering convention; DAQ modules contain the full output
65 bool isDAQModule() const;
67 // numbering convention; ROI modules contain only the "L1Topo" TOB words and
68 // are intended for the RoIB. They are also unpacked into the RoIBResult
69 bool isROIModule() const;
70
72 const std::string dump() const;
73
74 private:
75 std::vector<uint32_t> m_dataWords;
76 std::vector<uint32_t> m_statusWords;
77 // unsigned int m_versionNumber;
78 uint32_t m_error;
79 uint32_t m_sourceID;
80};
81
83CLASS_DEF(L1TopoRDO, 138978439, 0)
84
85#endif // L1TOPORDO_L1TOPORDO_H
macros to associate a CLID to a type
#define CLASS_DEF(NAME, CID, VERSION)
associate a clid and a version to a type eg
The class that represents the raw data received from an L1Topo board.
Definition L1TopoRDO.h:29
void setError(L1Topo::Error)
set a flag to record an error
Definition L1TopoRDO.cxx:53
bool checkError(L1Topo::Error) const
check if a certain error flag has been set
Definition L1TopoRDO.cxx:49
void setStatusWords(std::vector< uint32_t > &&) noexcept
set the status words
Definition L1TopoRDO.cxx:30
std::vector< L1Topo::Error > getErrors() const
get a vector of Errors found during RAW to RDO conversion; see enum and
Definition L1TopoRDO.cxx:35
bool isDAQModule() const
check the module type, derived from the source ID and the L1Topo module
Definition L1TopoRDO.cxx:67
uint32_t getSourceID() const
get the source identifier, i.e. the word representing the subdet type and
Definition L1TopoRDO.cxx:57
const std::string dump() const
terse printout method used by RoIBResult
Definition L1TopoRDO.cxx:77
void setDataWords(std::vector< uint32_t > &&) noexcept
set the data words
Definition L1TopoRDO.cxx:20
uint32_t m_sourceID
Definition L1TopoRDO.h:79
const std::vector< uint32_t > & getStatusWords() const
get the status words
Definition L1TopoRDO.cxx:25
void setSourceID(const uint32_t)
set the source identifier
Definition L1TopoRDO.cxx:62
std::vector< uint32_t > m_dataWords
Definition L1TopoRDO.h:75
uint32_t m_error
Definition L1TopoRDO.h:78
bool isROIModule() const
check the module type, derived from the source ID and the L1Topo module
Definition L1TopoRDO.cxx:72
const std::vector< uint32_t > & getDataWords() const
get the data words
Definition L1TopoRDO.cxx:15
std::vector< uint32_t > m_statusWords
Definition L1TopoRDO.h:76
uint32_t getError() const
Return error bit vector.
Definition L1TopoRDO.h:55
L1TopoRDO()
Constructor.
Definition L1TopoRDO.h:32
STL namespace.