Warning, file /include/Parsers/Exceptions.h was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013 #ifndef PARSERS_EXCEPTIONS_H
0014 #define PARSERS_EXCEPTIONS_H
0015
0016
0017 #include <Parsers/config.h>
0018
0019
0020 #include <string>
0021 #include <typeinfo>
0022 #include <stdexcept>
0023
0024
0025 namespace dd4hep {
0026
0027
0028
0029
0030
0031
0032
0033 struct unrelated_type_error : public std::runtime_error {
0034 static std::string msg(const std::type_info& typ1, const std::type_info& typ2, const std::string& text);
0035 unrelated_type_error(const std::type_info& typ1, const std::type_info& typ2, const std::string& text = "")
0036 : std::runtime_error(msg(typ1, typ2, text)) {
0037 }
0038 };
0039
0040
0041
0042
0043
0044
0045
0046 struct unrelated_value_error : public std::runtime_error {
0047 static std::string msg(const std::type_info& typ, const std::string& text);
0048 unrelated_value_error(const std::type_info& typ, const std::string& text = "")
0049 : std::runtime_error(msg(typ, text)) {
0050 }
0051 };
0052
0053 }
0054
0055 #endif