Errors.h
Go to the documentation of this file.
1#pragma once
2
3#include <stdexcept>
4#include <string>
5
7{
8 /**
9 * @brief The ConfigInsertError class represents an error that is thrown if an attempt
10 * is mode to set a config value but the value is already defined with the same tag.
11 */
12 class ConfigInsertError : public std::runtime_error
13 {
14 public:
15 ConfigInsertError(const std::string& message) : std::runtime_error(message)
16 {
17 }
18 };
19
20 /**
21 * @brief The ConfigElementNotFoundError class represents an error that is thrown when
22 * trying to get a config value that is not defined in the config.
23 */
24 class ConfigElementNotFoundError : public std::runtime_error
25 {
26 public:
27 ConfigElementNotFoundError(const std::string& message) : std::runtime_error(message)
28 {
29 }
30 };
31
32 /**
33 * @brief The ParserError class represents a generic error that occurs during parsing
34 */
35 class ParserError : public std::runtime_error
36 {
37 public:
38 ParserError(const std::string& message) : std::runtime_error(message)
39 {
40 }
41 };
42} // namespace armarx::control::hardware_config
ConfigInsertError(const std::string &message)
Definition Errors.h:15
ParserError(const std::string &message)
Definition Errors.h:38