ATLAS Offline Software
Loading...
Searching...
No Matches
ROBData.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef XAOD_ANALYSIS
6
7#ifndef BYTESTREAMDATA_ROBDATA_H
8#define BYTESTREAMDATA_ROBDATA_H
9
27
28#include "eformat/SourceIdentifier.h"
30
43
44
45template <typename ROBFragment, typename PointerType>
46class ROBData_T {
47
48public:
50 class iterator;
51
52
54 explicit ROBData_T(const ROBFragment* rob);
55
57 ROBData_T(const ROBData_T& other);
58
61
63 iterator begin() const;
64
66 iterator end() const;
67
70
72 eformat::SubDetector sub_detector() const;
73
75 uint16_t module_identifier() const;
76
78 uint32_t no_of_elements() const;
79
82
83public:
88 class iterator {
89 private:
97
98 public:
100 iterator(const iterator& other);
101
104
106 uint32_t operator*();
107
116 iterator& operator+=(const unsigned int& pos);
117
120
122 bool operator!=(const iterator& other) const;
123
124 private: //Representation
125 friend class ROBData_T<ROBFragment, PointerType>;
127 };
128
129private: //Representation
132};
133
134template <class ROBFragment, typename PointerType>
136 m_rob->rod_data(m_data);
137}
138
139template <class ROBFragment, typename PointerType>
142
143template <class ROBFragment, typename PointerType>
147
148template <class ROBFragment, typename PointerType>
154
155template <class ROBFragment, typename PointerType>
159
160template <class ROBFragment, typename PointerType>
164
165template <class ROBFragment, typename PointerType>
167 eformat::helper::SourceIdentifier sid(m_rob->rod_source_id());
168 return sid.subdetector_id();
169}
170
171template <class ROBFragment, typename PointerType>
173 // m_data->header()->source_id(); //FIXME: WHY AM I NEEDED?
174 eformat::helper::SourceIdentifier sid(m_rob->rod_source_id());
175 return sid.module_id();
176}
177
178template <class ROBFragment, typename PointerType>
180 return m_rob->rod_ndata();
181}
182
183template <class ROBFragment, typename PointerType>
187
188template <class ROBFragment, typename PointerType>
191
192template <class ROBFragment, typename PointerType>
194 m_it(other.m_it) {
195}
196
197template <class ROBFragment, typename PointerType>
202
203template <class ROBFragment, typename PointerType>
207
208template <class ROBFragment, typename PointerType>
210 m_it += pos;
211 return *this;
212}
213
214template <class ROBFragment, typename PointerType>
219
220template <class ROBFragment, typename PointerType>
224
226
227#endif //BYTESTREAMDATA_ROBDATA_H
228
229#endif
eformat::ROBFragment< PointerType > ROBFragment
Definition RawEvent.h:27
const DataType * PointerType
Definition RawEvent.h:25
ROBData_T< OFFLINE_FRAGMENTS_NAMESPACE::ROBFragment, OFFLINE_FRAGMENTS_NAMESPACE::PointerType > ROBData
Definition ROBData.h:225
This class defines how to iterate over the ROBData_T, in different formats.
Definition ROBData.h:88
uint32_t operator*()
Dereferencing.
Definition ROBData.h:204
iterator & operator++()
Increment.
Definition ROBData.h:215
iterator(const iterator &other)
Copy Constructor.
PointerType m_it
iterator
Definition ROBData.h:126
bool operator!=(const iterator &other) const
Is not equal.
Definition ROBData.h:221
iterator(const PointerType &it)
The sole constructor was made private.
Definition ROBData.h:189
iterator & operator+=(const unsigned int &pos)
winding.
Definition ROBData.h:209
iterator & operator=(const iterator &other)
Assignment Operator.
Definition ROBData.h:198
template data class to wrap ROB fragment for accessing ROD data
Definition ROBData.h:46
eformat::SubDetector sub_detector() const
Return the current subdetector type.
Definition ROBData.h:166
ROBData_T()
Default Constructor.
Definition ROBData.h:140
uint32_t no_of_elements() const
Return the number of 32-bit words inside the ROD.
Definition ROBData.h:179
iterator end() const
Instantiates an iterator over 32-bit integers to the last+1 element.
Definition ROBData.h:161
ROBData_T(const ROBFragment *rob)
Builds a "high-level" ROB Data object.
Definition ROBData.h:135
uint16_t module_identifier() const
Return the current module identifier.
Definition ROBData.h:172
ROBData_T(const ROBData_T &other)
Copy Constructor.
Definition ROBData.h:144
const ROBFragment * getROBFragment() const
Return the ROBFragment.
Definition ROBData.h:184
iterator begin() const
Instantiates an iterator over 32-bit integers to the first element.
Definition ROBData.h:156
ROBData_T & operator=(const ROBData_T &other)
Assignment Operator.
Definition ROBData.h:149