1 #include "otsdaq-core/ConfigurationPluginDataFormats/FESlowControlsConfiguration.h"
2 #include "otsdaq-core/Macros/ConfigurationPluginMacros.h"
4 #include "otsdaq-core/ConfigurationInterface/ConfigurationManager.h"
11 FESlowControlsConfiguration::FESlowControlsConfiguration(
void)
42 FESlowControlsConfiguration::~FESlowControlsConfiguration(
void)
50 __MOUT__ <<
"*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*&*" << std::endl;
51 __MOUT__ << configManager->__SELF_NODE__ << std::endl;
56 std::string childType;
57 auto childrenMap = configManager->__SELF_NODE__.getChildren();
58 for(
auto &childPair: childrenMap)
61 __MOUT__ << childPair.first << std::endl;
62 childPair.second.getNode(colNames_.colDataType_).getValue(childType);
63 __MOUT__ <<
"childType=" << childType << std::endl;
65 if(childType[childType.size()-1] ==
'b')
68 sscanf(&childType[0],
"%u",&sz);
71 __SS__ <<
"Data type '" << childType <<
"' for UID=" <<
72 childPair.first <<
" is invalid. " <<
73 " The bit size given was " << sz <<
74 " and it must be between 1 and 64." << std::endl;
75 __MOUT_ERR__ <<
"\n" << ss.str();
76 throw std::runtime_error(ss.str());
79 else if(childType !=
"char" &&
80 childType !=
"short" &&
82 childType !=
"unsigned int" &&
83 childType !=
"long long " &&
84 childType !=
"unsigned long long" &&
85 childType !=
"float" &&
86 childType !=
"double")
88 __SS__ <<
"Data type '" << childType <<
"' for UID=" <<
89 childPair.first <<
" is invalid. " <<
90 "Valid data types (w/size in bytes) are as follows: " <<
92 ", char (" <<
sizeof(char) <<
93 "B), unsigned char (" <<
sizeof(
unsigned char) <<
94 "B), short (" <<
sizeof(short) <<
95 "B), unsigned short (" <<
sizeof(
unsigned short) <<
96 "B), int (" <<
sizeof(int) <<
97 "B), unsigned int (" <<
sizeof(
unsigned int) <<
98 "B), long long (" <<
sizeof(
long long) <<
99 "B), unsigned long long (" <<
sizeof(
unsigned long long) <<
100 "B), float (" <<
sizeof(float) <<
101 "B), double (" <<
sizeof(
double) <<
103 __MOUT_ERR__ <<
"\n" << ss.str();
104 throw std::runtime_error(ss.str());