|
NexusForce 1.0.0
A rigorously engineered full-stack C++ backend library.
|
错误条件 更多...
#include <error_condition.hpp>
Public 成员函数 | |
| error_condition () noexcept=default | |
| 默认构造函数 | |
| error_condition (int val, const error_category &cat) noexcept | |
| 构造函数 | |
| error_condition (errc e) noexcept | |
| 从 errc 枚举构造 | |
| void | assign (int val, const error_category &cat) noexcept |
| 赋值错误条件值和类别 | |
| void | clear () noexcept |
| 清空错误条件 | |
| int | value () const noexcept |
| 获取错误条件值 | |
| const error_category & | category () const noexcept |
| 获取错误类别 | |
| string | message () const |
| 获取错误描述信息 | |
| operator bool () const noexcept | |
| 布尔转换 | |
| Public 成员函数 继承自 neforce::icomparable< error_condition > | |
| constexpr bool | operator== (const error_condition &rhs) const noexcept(noexcept(derived().equal_to(rhs))) |
| 相等比较运算符 | |
| constexpr bool | operator!= (const error_condition &rhs) const noexcept(noexcept(!(derived().equal_to(rhs)))) |
| 不等比较运算符 | |
| constexpr bool | operator< (const error_condition &rhs) const noexcept(noexcept(derived().less_than(rhs))) |
| 小于比较运算符 | |
| constexpr bool | operator> (const error_condition &rhs) const noexcept(noexcept(rhs.less_than(derived()))) |
| 大于比较运算符 | |
| constexpr bool | operator<= (const error_condition &rhs) const noexcept(noexcept(!(rhs.less_than(derived())))) |
| 小于等于比较运算符 | |
| constexpr bool | operator>= (const error_condition &rhs) const noexcept(noexcept(!(derived().less_than(rhs)))) |
| 大于等于比较运算符 | |
错误条件
错误条件表示跨类别的可移植错误语义,用于在不依赖具体错误类别的 情况下判断错误类型。默认关联 generic_category()。
在文件 error_condition.hpp 第 28 行定义.
|
defaultnoexcept |
|
inlinenoexcept |
|
inlineexplicitnoexcept |
从 errc 枚举构造
| e | 错误码枚举值 |
等价于 make_error_condition(e),类别为 generic_category()。
在文件 error_condition.hpp 第 56 行定义.
|
inlinenoexcept |
|
inlinenodiscardnoexcept |
|
inlinenoexcept |
|
inlinenodiscard |
|
inlineexplicitnoexcept |
|
inlinenodiscardnoexcept |