#include <ErrorHandling.hpp>
|
| enum class | Attribute {
InputFile
, InputLine
, DataPath
, DetectionLoc
,
Signal
} |
| |
|
|
string | m_formattedContext |
| | String containing the target object name followed by the the file and line declaring it.
|
| |
|
map< Attribute, std::string > | m_attributes |
| | The map contains contextual information about the error It could be something like "file" = "/path/to/file.xml" "line" = "24" or something like "dataPath" = "/Functions/co2brine_philipsDensityTable The key is a field of the Attribute enumeration and is converted to a string for writing in the YAML.
|
| |
| integer | m_priority = 0 |
| | Priority level assigned to an error context. More...
|
| |
Store contextual information about the error that occurred and assign it a priority default is 0
Definition at line 36 of file ErrorHandling.hpp.
◆ Attribute
◆ ErrorContext() [1/2]
| geos::ErrorContext::ErrorContext |
( |
string |
formattedContext, |
|
|
map< Attribute, std::string > |
attributes |
|
) |
| |
|
inline |
Construct to initialize ErrorContext.
- Parameters
-
| formattedContext | String containing the target object name followed by the the file and line declaring it. |
| attributes | Map containing contextual information about the error |
Definition at line 77 of file ErrorHandling.hpp.
◆ ErrorContext() [2/2]
Construct to initialize ErrorContext given a string containing the context and his priority.
- Parameters
-
| formattedContext | String containing the target object name followed by the the file and line declaring it. |
| attributes | Map containing contextual information about the error |
| priority | Priority level assigned to an error context. |
Definition at line 87 of file ErrorHandling.hpp.
◆ attributeToString()
| static std::string geos::ErrorContext::attributeToString |
( |
Attribute |
attribute | ) |
|
|
static |
Convert a value from the Attribute enumeration to a string.
- Parameters
-
| attribute | the value of the enumeration to be converted |
- Returns
- a string representation of the enumeration value
◆ setPriority()
Set the priority value of the current error context information. This way the different context information will appear in descending order during the error log output.
- Parameters
-
| priority | the new value to asign |
- Returns
- the reference to the corresponding error
Definition at line 98 of file ErrorHandling.hpp.
◆ m_priority
| integer geos::ErrorContext::m_priority = 0 |
Priority level assigned to an error context.
Used to prioritize contexts (higher values = more relevant). Default is 0.
Definition at line 70 of file ErrorHandling.hpp.
The documentation for this struct was generated from the following file: