DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
SNBBookkeeperConf.hpp
Go to the documentation of this file.
1// *** this file is generated by oksdalgen, do not modify it ***
2
3#ifndef _SNBBookkeeperConf_0_dunedaq__appmodel_0_appmodel_H_
4#define _SNBBookkeeperConf_0_dunedaq__appmodel_0_appmodel_H_
5
6#include <stdint.h> // to define 64 bits types
7#include <iostream>
8#include <sstream>
9#include <string>
10#include <map>
11#include <vector>
12
14#include "conffwk/DalObject.hpp"
15
16
17namespace dunedaq {
18 namespace appmodel {
19
21
22 friend class conffwk::Configuration;
23 friend class conffwk::DalObject;
24 friend class conffwk::DalFactory;
25 friend class conffwk::DalRegistry;
26
27 protected:
28
30 virtual ~SNBBookkeeperConf() noexcept;
31 virtual void init(bool init_children);
32
33 public:
34
37 static const std::string& s_class_name;
38
39
49 virtual void print(unsigned int offset, bool print_header, std::ostream& s) const;
50
51
61 virtual std::vector<const dunedaq::conffwk::DalObject *> get(const std::string& name, bool upcast_unregistered = true) const;
62
63
64 protected:
65
66 bool get(const std::string& name, std::vector<const dunedaq::conffwk::DalObject *>& vec, bool upcast_unregistered, bool first_call) const;
67
68
69 private:
70
71 std::string m_bookkeeper_ip;
74 uint8_t m_refresh_rate;
75 uint16_t m_timeout_send;
76 uint16_t m_timeout_receive;
77
78
79 public:
80
81 // attribute names
82
83 inline static const std::string s_bookkeeper_ip = "bookkeeper_ip";
84 inline static const std::string s_bookkeeper_log_path = "bookkeeper_log_path";
85 inline static const std::string s_connection_prefix = "connection_prefix";
86 inline static const std::string s_refresh_rate = "refresh_rate";
87 inline static const std::string s_timeout_send = "timeout_send";
88 inline static const std::string s_timeout_receive = "timeout_receive";
89
90 static const std::string& __get_bookkeeper_ip_str() noexcept { return s_bookkeeper_ip; }
91 static const std::string& __get_bookkeeper_log_path_str() noexcept { return s_bookkeeper_log_path; }
92 static const std::string& __get_connection_prefix_str() noexcept { return s_connection_prefix; }
93 static const std::string& __get_refresh_rate_str() noexcept { return s_refresh_rate; }
94 static const std::string& __get_timeout_send_str() noexcept { return s_timeout_send; }
95 static const std::string& __get_timeout_receive_str() noexcept { return s_timeout_receive; }
96
97
104 const std::string&
106 {
107 std::lock_guard scoped_lock(m_mutex);
108 check();
109 check_init();
110 return m_bookkeeper_ip;
111 }
112
119 void
120 set_bookkeeper_ip(const std::string& value)
121 {
122 std::lock_guard scoped_lock(m_mutex);
123 check();
124 clear();
126 }
127
128
135 const std::string&
137 {
138 std::lock_guard scoped_lock(m_mutex);
139 check();
140 check_init();
142 }
143
150 void
151 set_bookkeeper_log_path(const std::string& value)
152 {
153 std::lock_guard scoped_lock(m_mutex);
154 check();
155 clear();
157 }
158
159
166 const std::string&
168 {
169 std::lock_guard scoped_lock(m_mutex);
170 check();
171 check_init();
172 return m_connection_prefix;
173 }
174
181 void
182 set_connection_prefix(const std::string& value)
183 {
184 std::lock_guard scoped_lock(m_mutex);
185 check();
186 clear();
188 }
189
190
197 uint8_t
199 {
200 std::lock_guard scoped_lock(m_mutex);
201 check();
202 check_init();
203 return m_refresh_rate;
204 }
205
212 void
213 set_refresh_rate(uint8_t value)
214 {
215 std::lock_guard scoped_lock(m_mutex);
216 check();
217 clear();
219 }
220
221
228 uint16_t
230 {
231 std::lock_guard scoped_lock(m_mutex);
232 check();
233 check_init();
234 return m_timeout_send;
235 }
236
243 void
244 set_timeout_send(uint16_t value)
245 {
246 std::lock_guard scoped_lock(m_mutex);
247 check();
248 clear();
250 }
251
252
259 uint16_t
261 {
262 std::lock_guard scoped_lock(m_mutex);
263 check();
264 check_init();
265 return m_timeout_receive;
266 }
267
274 void
275 set_timeout_receive(uint16_t value)
276 {
277 std::lock_guard scoped_lock(m_mutex);
278 check();
279 clear();
281 }
282
283
284 };
285
286 // out stream operator
287
288 inline std::ostream& operator<<(std::ostream& s, const SNBBookkeeperConf& obj)
289 {
290 return obj.print_object(s);
291 }
292
293 typedef std::vector<const SNBBookkeeperConf*>::const_iterator SNBBookkeeperConfIterator;
294
295 }
296}
297
298#endif
static const std::string s_bookkeeper_log_path
uint16_t get_timeout_send() const
Get "timeout_send" attribute value.
void set_refresh_rate(uint8_t value)
Set "refresh_rate" attribute value.
static const std::string & __get_connection_prefix_str() noexcept
const std::string & get_bookkeeper_ip() const
Get "bookkeeper_ip" attribute value.
static const std::string & s_class_name
static const std::string & __get_timeout_send_str() noexcept
uint8_t get_refresh_rate() const
Get "refresh_rate" attribute value.
static const std::string & __get_refresh_rate_str() noexcept
static const std::string s_connection_prefix
const std::string & get_connection_prefix() const
Get "connection_prefix" attribute value.
static const std::string & __get_bookkeeper_log_path_str() noexcept
static const std::string s_timeout_receive
const std::string & get_bookkeeper_log_path() const
Get "bookkeeper_log_path" attribute value.
virtual std::vector< const dunedaq::conffwk::DalObject * > get(const std::string &name, bool upcast_unregistered=true) const
Get values of relationships and results of some algorithms as a vector of dunedaq::conffwk::DalObject...
uint16_t get_timeout_receive() const
Get "timeout_receive" attribute value.
static const std::string & __get_bookkeeper_ip_str() noexcept
static const std::string & __get_timeout_receive_str() noexcept
void set_connection_prefix(const std::string &value)
Set "connection_prefix" attribute value.
void set_timeout_receive(uint16_t value)
Set "timeout_receive" attribute value.
void set_bookkeeper_ip(const std::string &value)
Set "bookkeeper_ip" attribute value.
virtual void init(bool init_children)
SNBBookkeeperConf(conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
void set_timeout_send(uint16_t value)
Set "timeout_send" attribute value.
void set_bookkeeper_log_path(const std::string &value)
Set "bookkeeper_log_path" attribute value.
void set_by_val(const std::string &name, T value)
Set attribute value.
void set_by_ref(const std::string &name, T &value)
Set attribute value.
The base class for any generated DAL object.
Definition DalObject.hpp:45
std::mutex m_mutex
Used to protect changes of DAL object.
ConfigObject p_obj
Config object used by given template object.
void check_init() const
Check and initialize object if necessary.
DalRegistry: A registry of DalObjects It provides a single interface to create, cache and manage DalO...
conffwk entry point
double offset
std::ostream & operator<<(std::ostream &s, const AVXAbsRunSumProcessor &obj)
std::vector< constSNBBookkeeperConf * >::const_iterator SNBBookkeeperConfIterator
The DUNE-DAQ namespace.
msgpack::object obj