DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
EventPacket.hpp
Go to the documentation of this file.
1
8#ifndef SSPMODULES_SRC_ANLBOARD_EVENTPACKET_HPP_
9#define SSPMODULES_SRC_ANLBOARD_EVENTPACKET_HPP_
10
11#include "SSPTypes.hpp"
12
13#include <sstream>
14#include <utility>
15#include <vector>
16
17namespace dunedaq {
18namespace sspmodules {
19
20// Simple bag of data but with implementation of move methods
21// to allow efficient shifting around of data between containers
23{
24public:
25 // Move constructor
27 {
28 data = std::move(rhs.data);
29 header = rhs.header;
30 }
31
32 // Move assignment operator
34 {
35 data = std::move(rhs.data);
36 header = rhs.header;
37 return *this;
38 }
39
40 // Copy constructor
42 {
43 data = rhs.data;
44 header = rhs.header;
45 }
46
47 // Copy assignment operator
49 {
50 data = rhs.data;
51 header = rhs.header;
52 return *this;
53 }
54
56
57 // Clear data vector and set header word to 0xDEADBEEF
58 void SetEmpty();
59
60 void DumpHeader();
61
62 void DumpEvent();
63
65
66 std::vector<unsigned int> data;
67};
68
69} // namespace sspmodules
70} // namespace dunedaq
71
72#endif // SSPMODULES_SRC_ANLBOARD_EVENTPACKET_HPP_
dunedaq::sspmodules::EventHeader header
EventPacket & operator=(EventPacket &&rhs)
EventPacket(const EventPacket &rhs)
EventPacket & operator=(const EventPacket &rhs)
std::vector< unsigned int > data
The DUNE-DAQ namespace.