DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
Schema.hpp
Go to the documentation of this file.
1
8#ifndef CONFFWK_SCHEMA_H_
9#define CONFFWK_SCHEMA_H_
10
11#include <string>
12#include <vector>
13#include <iostream>
14
15namespace dunedaq {
16 namespace conffwk {
17
38
39
48
49
52 struct attribute_t {
53
54 std::string p_name;
56 std::string p_range;
60 std::string p_default_value;
61 std::string p_description;
66 const std::string& name,
67 type_t type,
68 const std::string& range,
69 int_format_t int_format,
70 bool is_not_null,
71 bool is_multi_value,
72 const std::string& default_value,
73 const std::string& description
74 );
75
76
80
81
84 void print(
85 std::ostream& out,
86 const std::string& prefix = ""
87 ) const;
88
90 static const char * type2str(type_t type );
91
93 static const char * type(type_t type );
94
96 static const char * format2str(int_format_t format );
97
98 };
99
100
109
110
114
115 std::string p_name;
116 std::string p_type;
119 std::string p_description;
124 const std::string& name,
125 const std::string& type,
126 bool can_be_null,
127 bool is_multi_value,
128 bool is_aggregation,
129 const std::string& description
130 );
131
132
136
137
140 void print(
141 std::ostream& out,
142 const std::string& prefix = ""
143 ) const;
144
145
148 static const char * card2str(cardinality_t cardinality);
149
150 };
151
152
155 struct class_t {
156
157 std::string p_name;
158 std::string p_description;
159 std::string p_schema_path;
161 const std::vector<std::string> p_superclasses;
162 const std::vector<std::string> p_subclasses;
163 const std::vector<attribute_t> p_attributes;
164 const std::vector<relationship_t> p_relationships;
168 class_t(
169 const std::string& name,
170 const std::string& description,
171 const std::string& schema_path,
172 bool is_abstract
173 );
174
175
178 class_t() { ; }
179
180
183 void print(
184 std::ostream& out,
185 const std::string& prefix = ""
186 ) const;
187
188 };
189
190 const char * bool2str(bool value);
191
192 std::ostream& operator<<(std::ostream& out, const attribute_t &);
193 std::ostream& operator<<(std::ostream& out, const relationship_t &);
194 std::ostream& operator<<(std::ostream& out, const class_t &);
195
196 }
197}
198
199#endif // CONFFWK_SCHEMA_H_
const char * bool2str(bool value)
std::ostream & operator<<(std::ostream &, const ConfigurationChange &)
Including Qt Headers.
DAC value out of range
Message.
Definition DACNode.hpp:32
Unknown serialization type
FELIX Initialization std::string initerror FELIX queue timed out
void print(std::ostream &out, const std::string &prefix="") const
static const char * type2str(type_t type)
static const char * format2str(int_format_t format)
const std::vector< attribute_t > p_attributes
Definition Schema.hpp:163
const std::vector< relationship_t > p_relationships
Definition Schema.hpp:164
void print(std::ostream &out, const std::string &prefix="") const
const std::vector< std::string > p_subclasses
Definition Schema.hpp:162
std::string p_description
Definition Schema.hpp:158
std::string p_schema_path
Definition Schema.hpp:159
const std::vector< std::string > p_superclasses
Definition Schema.hpp:161
void print(std::ostream &out, const std::string &prefix="") const
static const char * card2str(cardinality_t cardinality)