DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
TPStreamWriterApplication.hpp
Go to the documentation of this file.
1// *** this file is generated by oksdalgen, do not modify it ***
2
3#ifndef _TPStreamWriterApplication_0_dunedaq__appmodel_0_appmodel_H_
4#define _TPStreamWriterApplication_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 // include files for classes used in inheritance hierarchy
17
20
21 // forward declaration for classes used in relationships and algorithms
22
23namespace dunedaq {
24 namespace appmodel {
25 class TPStreamWriterConf;
26 }
27 namespace confmodel {
28 class DaqModule;
29 class Session;
30 }
31}
32
33
34namespace dunedaq {
35 namespace appmodel {
36
38
39 friend class conffwk::Configuration;
40 friend class conffwk::DalObject;
41 friend class conffwk::DalFactory;
42 friend class conffwk::DalRegistry;
43
44 protected:
45
47 virtual ~TPStreamWriterApplication() noexcept;
48 virtual void init(bool init_children);
49
50 public:
51
54 static const std::string& s_class_name;
55
56
66 virtual void print(unsigned int offset, bool print_header, std::ostream& s) const;
67
68
78 virtual std::vector<const dunedaq::conffwk::DalObject *> get(const std::string& name, bool upcast_unregistered = true) const;
79
80
81 protected:
82
83 bool get(const std::string& name, std::vector<const dunedaq::conffwk::DalObject *>& vec, bool upcast_unregistered, bool first_call) const;
84
85
86 private:
87
89
90
91 public:
92
93 // relationship names
94
95 inline static const std::string s_tp_writer = "tp_writer";
96
97 static const std::string& __get_tp_writer_str() noexcept { return s_tp_writer; }
98
99
108 {
109 std::lock_guard scoped_lock(m_mutex);
110 check();
111 check_init();
112 if (!m_tp_writer)
113 {
114 std::ostringstream text;
115 text << "relationship \"" << s_tp_writer << "\" of object " << this << " is not set";
116 throw dunedaq::conffwk::Generic(ERS_HERE, text.str().c_str());
117 }
118 return m_tp_writer;
119 }
120
121
128 void
130
131
132 public:
133
134 // user-defined algorithms
135
140 std::vector<const dunedaq::confmodel::DaqModule*> generate_modules(const confmodel::Session*) const override;
141 };
142
143 // out stream operator
144
145 inline std::ostream& operator<<(std::ostream& s, const TPStreamWriterApplication& obj)
146 {
147 return obj.print_object(s);
148 }
149
150 typedef std::vector<const TPStreamWriterApplication*>::const_iterator TPStreamWriterApplicationIterator;
151
152 }
153}
154
155#endif
#define ERS_HERE
const dunedaq::appmodel::TPStreamWriterConf * get_tp_writer() const
Get "tp_writer" relationship value.
TPStreamWriterApplication(conffwk::DalRegistry &db, const conffwk::ConfigObject &obj) noexcept
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...
static const std::string & __get_tp_writer_str() noexcept
void set_tp_writer(const dunedaq::appmodel::TPStreamWriterConf *value)
Set "tp_writer" relationship value.
std::vector< const dunedaq::confmodel::DaqModule * > generate_modules(const confmodel::Session *) const override
const dunedaq::appmodel::TPStreamWriterConf * m_tp_writer
The base class for any generated DAL object.
Definition DalObject.hpp:45
std::mutex m_mutex
Used to protect changes of DAL 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...
Generic configuration exception.
conffwk entry point
double offset
std::ostream & operator<<(std::ostream &s, const AVXAbsRunSumProcessor &obj)
std::vector< constTPStreamWriterApplication * >::const_iterator TPStreamWriterApplicationIterator
Including Qt Headers.