ADTF
Loading...
Searching...
No Matches
result_util.h
Go to the documentation of this file.
1
14
15#ifndef A_UTIL_UTIL_RESULT_RESULT_UTIL_HEADER_INCLUDED
16#define A_UTIL_UTIL_RESULT_RESULT_UTIL_HEADER_INCLUDED
17
18#include <string>
19
20namespace a_util {
21namespace result {
22// forward declarations
23class Result;
24
29 DisableNone = 0x00,
30 DisableCode = 0x01,
31 DisableName = 0x02,
33 DisableFile = 0x08,
34 DisableLine = 0x10,
36}; // enum ResultFormatFlags
37
47std::string toString(const Result& result,
48 ResultFormatFlags formatting_flags = DisableNone,
49 const char* format = nullptr);
50
51} // namespace result
52} // namespace a_util
53
54#endif // A_UTIL_UTIL_RESULT_RESULT_UTIL_HEADER_INCLUDED
Definition result_type_decl.h:34
Serves as component for functionality handling error and return types.
Definition result.h:20
std::string toString(const Result &result, ResultFormatFlags formatting_flags=DisableNone, const char *format=nullptr)
ResultFormatFlags
Definition result_util.h:28
@ DisableName
Do not use the string representation of the error string.
Definition result_util.h:31
@ DisableLine
Do not use the string representation of the line.
Definition result_util.h:34
@ DisableFunction
Do not use the string representation of the function.
Definition result_util.h:35
@ DisableNone
Disable nothing, stringify everything.
Definition result_util.h:29
@ DisableMessage
Do not use the string representation of the error message.
Definition result_util.h:32
@ DisableCode
Do not use the string representation of the error code.
Definition result_util.h:30
@ DisableFile
Do not use the string representation of the file name.
Definition result_util.h:33
Serves as the root component, with common functionality documented in core functionality.
Definition base.h:24