1 #ifndef artdaq_core_Data_detail_RawFragmentHeaderV0_hh
2 #define artdaq_core_Data_detail_RawFragmentHeaderV0_hh
9 #include "artdaq-core/Data/dictionarycontrol.hh"
10 #include "cetlib_except/exception.h"
12 #include "artdaq-core/Data/detail/RawFragmentHeader.hh"
13 #include "artdaq-core/Utilities/TimeUtils.hh"
24 struct RawFragmentHeaderV0;
73 return std::map<type_t, std::string>{
86 return std::map<type_t, std::string>{
91 { 229,
"EndOfSubrun" },
124 constexpr
static std::size_t
num_words();
169 "sizeof(RawFragmentHeader) is not an integer "
170 "multiple of sizeof(RawDataType)!");
176 if (utype < FIRST_USER_TYPE || utype > LAST_USER_TYPE)
178 throw cet::exception(
"InvalidValue")
179 <<
"RawFragmentHeader user types must be in the range of "
180 << ((int)FIRST_USER_TYPE) <<
" to " << ((int)LAST_USER_TYPE)
181 <<
" (bad type is " << ((int)utype) <<
").";
190 if (stype < FIRST_SYSTEM_TYPE /*|| stype > LAST_SYSTEM_TYPE*/)
192 throw cet::exception(
"InvalidValue")
193 <<
"RawFragmentHeader system types must be in the range of "
194 << ((int)FIRST_SYSTEM_TYPE) <<
" to " << ((int)LAST_SYSTEM_TYPE);
struct timespec get_realtime_clock()
Get the current time of day as a pair of seconds and nanoseconds (from clock_gettime(CLOCK_REALTIME, ...) system call)