DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
Queue.hpp
Go to the documentation of this file.
1// *** this file is generated by oksdalgen, do not modify it ***
2
3#ifndef _Queue_0_dunedaq__confmodel_0_confmodel_H_
4#define _Queue_0_dunedaq__confmodel_0_confmodel_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 // include files for classes used in inheritance hierarchy
17
19
20namespace dunedaq {
21 namespace confmodel {
22
24
25 friend class conffwk::Configuration;
26 friend class conffwk::DalObject;
27 friend class conffwk::DalFactory;
28 friend class conffwk::DalRegistry;
29
30 protected:
31
33 virtual ~Queue() noexcept;
34 virtual void init(bool init_children);
35
36 public:
37
40 static const std::string& s_class_name;
41
42
52 virtual void print(unsigned int offset, bool print_header, std::ostream& s) const;
53
54
64 virtual std::vector<const dunedaq::conffwk::DalObject *> get(const std::string& name, bool upcast_unregistered = true) const;
65
66
67 protected:
68
69 bool get(const std::string& name, std::vector<const dunedaq::conffwk::DalObject *>& vec, bool upcast_unregistered, bool first_call) const;
70
71
72 private:
73
74 std::string m_queue_type;
75
76
77 public:
78
79 // attribute names
80
81 inline static const std::string s_queue_type = "queue_type";
82
83 static const std::string& __get_queue_type_str() noexcept { return s_queue_type; }
84
85
90 struct Queue_type {
91 inline static const std::string KUnknown = "kUnknown";
92 inline static const std::string KStdDeQueue = "kStdDeQueue";
93 inline static const std::string KFollySPSCQueue = "kFollySPSCQueue";
94 inline static const std::string KFollyMPMCQueue = "kFollyMPMCQueue";
95 };
96
104 const std::string&
106 {
107 std::lock_guard scoped_lock(m_mutex);
108 check();
109 check_init();
110 return m_queue_type;
111 }
112
120 void
121 set_queue_type(const std::string& value)
122 {
123 std::lock_guard scoped_lock(m_mutex);
124 check();
125 clear();
127 }
128
129
130 };
131
132 // out stream operator
133
134 inline std::ostream& operator<<(std::ostream& s, const Queue& obj)
135 {
136 return obj.print_object(s);
137 }
138
139 typedef std::vector<const Queue*>::const_iterator QueueIterator;
140
141 }
142}
143
144#endif
void set_enum(const std::string &name, const std::string &value)
Set attribute enumeration 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...
void set_queue_type(const std::string &value)
Set "queue_type" attribute value. Type of queue.
Definition Queue.hpp:121
const std::string & get_queue_type() const
Get "queue_type" attribute value. Type of queue.
Definition Queue.hpp:105
Queue(conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
friend class conffwk::DalFactory
Definition Queue.hpp:27
static const std::string & s_class_name
Definition Queue.hpp:40
static const std::string & __get_queue_type_str() noexcept
Definition Queue.hpp:83
virtual void init(bool init_children)
Definition Queue.cpp:61
friend class conffwk::DalObject
Definition Queue.hpp:26
static const std::string s_queue_type
Definition Queue.hpp:81
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...
Definition Queue.cpp:79
virtual ~Queue() noexcept
std::string m_queue_type
Definition Queue.hpp:74
conffwk entry point
double offset
std::vector< constQueue * >::const_iterator QueueIterator
Definition Queue.hpp:139
std::ostream & operator<<(std::ostream &s, const ActionPlan &obj)
The DUNE-DAQ namespace.
Definition DataStore.hpp:57
msgpack::object obj
static const std::string KStdDeQueue
Definition Queue.hpp:92
static const std::string KUnknown
Definition Queue.hpp:91
static const std::string KFollySPSCQueue
Definition Queue.hpp:93
static const std::string KFollyMPMCQueue
Definition Queue.hpp:94