DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
dbe::config_object_representation< S > Struct Template Reference

#include <confobject_desc.hpp>

Collaboration diagram for dbe::config_object_representation< S >:
[legend]

Public Types

typedef S t_str
typedef config_object_description< S > t_confobject
typedef std::vector< t_confobject > t_confobjects
typedef std::map< S, QStringList > t_attrmap
typedef std::map< S, t_confobjects > t_relmap

Public Member Functions

t_config_object_preimage toimage ()

Public Attributes

t_attrmap attributes
t_relmap relations
t_confobject ref

Detailed Description

template<typename S = std::string>
struct dbe::config_object_representation< S >

Provides a holder for deep copies of a config object

Definition at line 136 of file confobject_desc.hpp.

Member Typedef Documentation

◆ t_attrmap

template<typename S = std::string>
typedef std::map<S, QStringList> dbe::config_object_representation< S >::t_attrmap

Definition at line 141 of file confobject_desc.hpp.

◆ t_confobject

template<typename S = std::string>
typedef config_object_description<S> dbe::config_object_representation< S >::t_confobject

Definition at line 139 of file confobject_desc.hpp.

◆ t_confobjects

template<typename S = std::string>
typedef std::vector<t_confobject> dbe::config_object_representation< S >::t_confobjects

Definition at line 140 of file confobject_desc.hpp.

◆ t_relmap

template<typename S = std::string>
typedef std::map<S, t_confobjects> dbe::config_object_representation< S >::t_relmap

Definition at line 142 of file confobject_desc.hpp.

◆ t_str

template<typename S = std::string>
typedef S dbe::config_object_representation< S >::t_str

Definition at line 138 of file confobject_desc.hpp.

Member Function Documentation

◆ toimage()

template<typename S = std::string>
t_config_object_preimage dbe::config_object_representation< S >::toimage ( )
inline

Definition at line 149 of file confobject_desc.hpp.

150 {
153
155 std::end(this->attributes),
156 [&lattributes](typename std::pair<S, QStringList> const& e) {
158
159 for (auto const& x : e.second) {
160 v.push_back(x.toStdString());
161 }
162
163 lattributes.insert(std::make_pair(e.first, v));
164 });
165
167 std::begin(this->relations), std::end(this->relations), [&lrelations](typename t_relmap::value_type const& e) {
169
170 for (t_confobject const& x : e.second) {
171 v.push_back({ x.UID(), x.class_name() });
172 }
173
174 lrelations.insert(std::make_pair(e.first, v));
175 });
176
177 return { lattributes, lrelations, { this->ref.UID(), this->ref.class_name() }, this->ref.contained_in() };
178 }
config_object_description< S > t_confobject

Member Data Documentation

◆ attributes

template<typename S = std::string>
t_attrmap dbe::config_object_representation< S >::attributes

Definition at line 144 of file confobject_desc.hpp.

◆ ref

template<typename S = std::string>
t_confobject dbe::config_object_representation< S >::ref

Definition at line 147 of file confobject_desc.hpp.

◆ relations

template<typename S = std::string>
t_relmap dbe::config_object_representation< S >::relations

Definition at line 145 of file confobject_desc.hpp.


The documentation for this struct was generated from the following file: