Bring your own encryption key needed and unavailable.
More...
#include <src/api/mip/error.h>
|
void | AddDebugInfo (const std::string &key, const std::string &value, bool sensitive=false) |
| Add debug info entry.
|
|
virtual std::shared_ptr< Error > | Clone () const =0 |
| Clone the error.
|
|
const std::map< std::string, std::string > & | GetDebugInfo () const |
| Get debug info.
|
|
const std::string & | GetErrorName () const |
| Get the error name.
|
|
virtual ErrorType | GetErrorType () const |
| Get the error type.
|
|
const std::string & | GetMessage (bool maskPII=false) const |
| Get the error message.
|
|
void | SetMessage (const std::string &msg) |
| Set the error message.
|
|
char const * | what () const noexcept override |
| Get the error message.
|
|
Bring your own encryption key needed and unavailable.
Definition at line 1196 of file error.h.
◆ AddDebugInfo()
void Error::AddDebugInfo |
( |
const std::string & | key, |
|
|
const std::string & | value, |
|
|
bool | sensitive = false ) |
|
inlineinherited |
◆ Clone()
virtual std::shared_ptr< Error > Error::Clone |
( |
| ) |
const |
|
pure virtualinherited |
◆ GetDebugInfo()
const std::map< std::string, std::string > & Error::GetDebugInfo |
( |
| ) |
const |
|
inlineinherited |
◆ GetErrorName()
const std::string & Error::GetErrorName |
( |
| ) |
const |
|
inlineinherited |
◆ GetErrorType()
virtual ErrorType Error::GetErrorType |
( |
| ) |
const |
|
inlinevirtualinherited |
◆ GetMessage()
const std::string & Error::GetMessage |
( |
bool | maskPII = false | ) |
const |
|
inlineinherited |
Get the error message.
- Returns
- the error message.
Definition at line 151 of file error.h.
151 {
152 return maskPII ? mMaskedMessage : mFormattedMessage;
153 }
◆ SetMessage()
void Error::SetMessage |
( |
const std::string & | msg | ) |
|
|
inlineinherited |
Set the error message.
- Parameters
-
Definition at line 160 of file error.h.
160 {
161 std::string* targetStrings[] = { &mFormattedMessage, &mMaskedMessage };
162 for (auto* targetString : targetStrings) {
163 size_t pos = targetString->find(
mMessage);
164 if (pos != std::string::npos) {
165 targetString->replace(pos,
mMessage.length(), msg);
166 } else {
167 targetString->replace(0, 0, msg);
168 }
169 }
171 }
References Error::mMessage.
◆ what()
char const * Error::what |
( |
| ) |
const |
|
inlineoverridenoexceptinherited |
Get the error message.
- Returns
- the error message
Definition at line 121 of file error.h.
121 {
122 return mFormattedMessage.c_str();
123 }
◆ mDebugInfo
std::map<std::string, std::string> Error::mDebugInfo |
|
inherited |
◆ mMessage
std::string Error::mMessage |
|
inherited |
◆ mName
◆ mType
The documentation for this class was generated from the following file: