22 #include <boost/format.hpp>
23 #include <boost/exception_ptr.hpp>
25 #include "hazelcast/util/export.h"
27 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)
29 #pragma warning(disable : 4251)
30 #pragma warning(disable : 4275)
60 std::exception_ptr cause,
70 char const* what()
const noexcept
override;
72 const std::string& get_source()
const;
74 const std::string& get_message()
const;
76 const std::string& get_details()
const;
78 int32_t get_error_code()
const;
80 bool is_runtime()
const;
82 bool is_retryable()
const;
84 friend std::ostream HAZELCAST_API& operator<<(std::ostream& os,
92 std::exception_ptr cause_;
93 bool runtime_exception_;
98 std::ostream HAZELCAST_API&
99 operator<<(std::ostream& os,
const iexception& exception);
101 template<
typename EXCEPTIONCLASS>
120 boost::exception_detail::clone_impl<EXCEPTIONCLASS>
build()
122 return boost::enable_current_exception(
123 EXCEPTIONCLASS(source_, msg_.str()));
128 std::ostringstream msg_;
135 #if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64)
boost::exception_detail::clone_impl< EXCEPTIONCLASS > build()
Base class for all exception originated from Hazelcast methods.