18 #include "DD4hep/Detector.h"
58 const std::string& category =
"")
const noexcept(
false);
66 const std::string& category =
"");
72 bool hasValue(
const std::string& tag,
const std::string& category =
"")
const;
78 bool hasType(
const std::string& type,
const std::string& category =
"")
const;
85 void addType(
const std::string& type,
const std::string& category =
"",
86 const std::string& word =
"");
92 const std::string
getType(
const std::string& type,
93 const std::string& category =
"")
const
101 template <
typename T>
102 void addT(std::map<std::string, T>& map,
const T& val,
const std::string& tag,
103 const std::string& category,
const T& catDeco);
106 template <
typename T>
107 const T getT(
const std::map<std::string, T>& map,
const std::string& tag,
108 const std::string& category =
"")
const noexcept(
false);
111 template <
typename T>
112 bool hasT(
const std::map<std::string, T>& map,
const std::string& tag,
113 const std::string& category =
"")
const;
123 template <
typename T>
125 const std::string&
tag,
126 const std::string& category)
const noexcept(
false) {
127 std::string ctag =
"/";
128 if (!category.empty()) {
133 auto search = map.find(ctag);
134 if (search == map.end()) {
135 std::string error_message =
"Acts::ActsExtension does not contain: ";
136 error_message += ctag;
137 error_message +=
'\n';
139 throw std::runtime_error(error_message.c_str());
141 return search->second;
145 template <
typename T>
147 const std::string&
tag,
const std::string& category,
149 std::string ctag =
"/";
150 if (!category.empty()) {
160 template <
typename T>
162 const std::string&
tag,
163 const std::string& category)
const {
164 std::string ctag =
"/";
165 if (!category.empty()) {
170 auto search = map.find(ctag);
171 return (search != map.end());