Wire Sysio Wire Sysion 1.0.0
|
Defines exception's used by fc.
#include <fc/log/logger.hpp>
#include <exception>
#include <functional>
#include <unordered_map>
#include <boost/core/typeinfo.hpp>
#include <boost/interprocess/exceptions.hpp>
Go to the source code of this file.
Classes | |
class | fc::exception |
Used to generate a useful error report when an exception is thrown. More... | |
class | fc::unhandled_exception |
re-thrown whenever an unhandled exception is caught.Any exceptions thrown by 3rd party libraries that are not caught get wrapped in an unhandled_exception exception. More... | |
class | fc::std_exception_wrapper |
wrapper for std::exception More... | |
class | fc::exception_factory |
struct | fc::exception_factory::base_exception_builder |
struct | fc::exception_factory::exception_builder< T > |
Namespaces | |
namespace | fc |
namespace sysio::chain | |
namespace | fc::detail |
Macros | |
#define | FC_REGISTER_EXCEPTION(r, unused, base) |
#define | FC_REGISTER_EXCEPTIONS(SEQ) |
#define | FC_DECLARE_DERIVED_EXCEPTION(TYPE, BASE, CODE, WHAT) |
#define | FC_DECLARE_EXCEPTION(TYPE, CODE, WHAT) |
#define | LIKELY(x) |
#define | UNLIKELY(x) |
#define | FC_EXPAND_MACRO(x) |
: Workaround for varying preprocessing behavior between MSVC and gcc | |
#define | FC_ASSERT(TEST, ...) |
Checks a condition and throws an assert_exception if the test is FALSE. | |
#define | FC_CAPTURE_AND_THROW(EXCEPTION_TYPE, ...) |
#define | FC_INDIRECT_EXPAND(MACRO, ARGS) |
#define | FC_THROW( ...) |
#define | FC_EXCEPTION(EXCEPTION_TYPE, FORMAT, ...) |
#define | FC_THROW_EXCEPTION(EXCEPTION, FORMAT, ...) |
#define | FC_RETHROW_EXCEPTION(ER, LOG_LEVEL, FORMAT, ...) |
Appends a log_message to the exception ER and rethrows it. | |
#define | FC_LOG_AND_RETHROW() |
#define | FC_CAPTURE_LOG_AND_RETHROW(...) |
#define | FC_CAPTURE_AND_LOG(...) |
#define | FC_LOG_AND_DROP(...) |
#define | FC_RETHROW_EXCEPTIONS(LOG_LEVEL, FORMAT, ...) |
Catchs all exception's, std::exceptions, and ... and rethrows them after appending the provided log message. | |
#define | FC_CAPTURE_AND_RETHROW(...) |
#define | FC_CHECK_DEADLINE(DEADLINE, ...) |
Typedefs | |
typedef std::shared_ptr< exception > | fc::exception_ptr |
typedef std::optional< exception > | fc::oexception |
Enumerations | |
enum | fc::exception_code { fc::unspecified_exception_code = 0 , fc::unhandled_exception_code = 1 , fc::timeout_exception_code = 2 , fc::file_not_found_exception_code = 3 , fc::parse_error_exception_code = 4 , fc::invalid_arg_exception_code = 5 , fc::key_not_found_exception_code = 6 , fc::bad_cast_exception_code = 7 , fc::out_of_range_exception_code = 8 , fc::canceled_exception_code = 9 , fc::assert_exception_code = 10 , fc::eof_exception_code = 11 , fc::std_exception_code = 13 , fc::invalid_operation_exception_code = 14 , fc::unknown_host_exception_code = 15 , fc::null_optional_code = 16 , fc::udt_error_code = 17 , fc::aes_error_code = 18 , fc::overflow_code = 19 , fc::underflow_code = 20 , fc::divide_by_zero_code = 21 } |
Functions | |
void | fc::to_variant (const exception &e, variant &v) |
void | fc::from_variant (const variant &e, exception &ll) |
template<typename T > | |
fc::exception_ptr | fc::copy_exception (T &&e) |
fc::FC_DECLARE_EXCEPTION (timeout_exception, timeout_exception_code, "Timeout") | |
fc::FC_DECLARE_EXCEPTION (file_not_found_exception, file_not_found_exception_code, "File Not Found") | |
fc::FC_DECLARE_EXCEPTION (parse_error_exception, parse_error_exception_code, "Parse Error") | |
report's parse errors | |
fc::FC_DECLARE_EXCEPTION (invalid_arg_exception, invalid_arg_exception_code, "Invalid Argument") | |
fc::FC_DECLARE_EXCEPTION (key_not_found_exception, key_not_found_exception_code, "Key Not Found") | |
reports when a key, guid, or other item is not found. | |
fc::FC_DECLARE_EXCEPTION (bad_cast_exception, bad_cast_exception_code, "Bad Cast") | |
fc::FC_DECLARE_EXCEPTION (out_of_range_exception, out_of_range_exception_code, "Out of Range") | |
fc::FC_DECLARE_EXCEPTION (invalid_operation_exception, invalid_operation_exception_code, "Invalid Operation") | |
if an operation is unsupported or not valid this may be thrown | |
fc::FC_DECLARE_EXCEPTION (unknown_host_exception, unknown_host_exception_code, "Unknown Host") | |
if an host name can not be resolved this may be thrown | |
fc::FC_DECLARE_EXCEPTION (canceled_exception, canceled_exception_code, "Canceled") | |
used to report a canceled Operation | |
fc::FC_DECLARE_EXCEPTION (assert_exception, assert_exception_code, "Assert Exception") | |
used inplace of assert() to report violations of pre conditions. | |
fc::FC_DECLARE_EXCEPTION (eof_exception, eof_exception_code, "End Of File") | |
fc::FC_DECLARE_EXCEPTION (null_optional, null_optional_code, "null optional") | |
fc::FC_DECLARE_EXCEPTION (udt_exception, udt_error_code, "UDT error") | |
fc::FC_DECLARE_EXCEPTION (aes_exception, aes_error_code, "AES error") | |
fc::FC_DECLARE_EXCEPTION (overflow_exception, overflow_code, "Integer Overflow") | |
fc::FC_DECLARE_EXCEPTION (underflow_exception, underflow_code, "Integer Underflow") | |
fc::FC_DECLARE_EXCEPTION (divide_by_zero_exception, divide_by_zero_code, "Integer Divide By Zero") | |
std::string | fc::except_str () |
void | fc::record_assert_trip (const char *filename, uint32_t lineno, const char *expr) |
Variables | |
bool | fc::enable_record_assert_trip = false |
#define FC_ASSERT | ( | TEST, | |
... ) |
Definition at line 362 of file exception.hpp.
#define FC_CAPTURE_AND_LOG | ( | ... | ) |
Definition at line 458 of file exception.hpp.
#define FC_CAPTURE_AND_RETHROW | ( | ... | ) |
Definition at line 523 of file exception.hpp.
#define FC_CAPTURE_AND_THROW | ( | EXCEPTION_TYPE, | |
... ) |
Definition at line 374 of file exception.hpp.
#define FC_CAPTURE_LOG_AND_RETHROW | ( | ... | ) |
Definition at line 433 of file exception.hpp.
#define FC_CHECK_DEADLINE | ( | DEADLINE, | |
... ) |
Definition at line 541 of file exception.hpp.
#define FC_DECLARE_DERIVED_EXCEPTION | ( | TYPE, | |
BASE, | |||
CODE, | |||
WHAT ) |
Definition at line 259 of file exception.hpp.
#define FC_DECLARE_EXCEPTION | ( | TYPE, | |
CODE, | |||
WHAT ) |
Definition at line 294 of file exception.hpp.
#define FC_EXCEPTION | ( | EXCEPTION_TYPE, | |
FORMAT, | |||
... ) |
Definition at line 388 of file exception.hpp.
#define FC_EXPAND_MACRO | ( | x | ) |
Definition at line 358 of file exception.hpp.
#define FC_INDIRECT_EXPAND | ( | MACRO, | |
ARGS ) |
Definition at line 382 of file exception.hpp.
#define FC_LOG_AND_DROP | ( | ... | ) |
Definition at line 480 of file exception.hpp.
FC_LOG_AND_RETHROW | ( | ) |
Definition at line 411 of file exception.hpp.
#define FC_REGISTER_EXCEPTION | ( | r, | |
unused, | |||
base ) |
Definition at line 248 of file exception.hpp.
#define FC_REGISTER_EXCEPTIONS | ( | SEQ | ) |
Definition at line 251 of file exception.hpp.
#define FC_RETHROW_EXCEPTION | ( | ER, | |
LOG_LEVEL, | |||
FORMAT, | |||
... ) |
Definition at line 405 of file exception.hpp.
#define FC_RETHROW_EXCEPTIONS | ( | LOG_LEVEL, | |
FORMAT, | |||
... ) |
Definition at line 505 of file exception.hpp.
#define FC_THROW | ( | ... | ) |
Definition at line 383 of file exception.hpp.
#define FC_THROW_EXCEPTION | ( | EXCEPTION, | |
FORMAT, | |||
... ) |
EXCEPTION | a class in the Phoenix::Athena::API namespace that inherits |
format | - a const char* string with "${keys}" |
Definition at line 395 of file exception.hpp.
#define LIKELY | ( | x | ) |
Definition at line 351 of file exception.hpp.
#define UNLIKELY | ( | x | ) |
Definition at line 352 of file exception.hpp.