Google Cloud C++ Client
2.7.0
C++ Client Library for Google Cloud Platform
|
If exceptions are not enabled via GOOGLE_CLOUD_CPP_HAVE_EXCEPTIONS
, calling any function from throw_delegate.h will result in calling the handler installed via this API.
More...
Typedefs | |
using | google::cloud::TerminateHandler = std::function< void(char const *msg)> |
Terminate handler. More... | |
Functions | |
TerminateHandler | google::cloud::SetTerminateHandler (TerminateHandler f) |
Install terminate handler and get the old one atomically. More... | |
TerminateHandler | google::cloud::GetTerminateHandler () |
Get the currently installed handler. More... | |
void | google::cloud::Terminate (char const *msg) |
Invoke the currently installed handler. More... | |
If exceptions are not enabled via GOOGLE_CLOUD_CPP_HAVE_EXCEPTIONS
, calling any function from throw_delegate.h will result in calling the handler installed via this API.
By default, the library calls std::abort()
.
using google::cloud::TerminateHandler = typedef std::function<void(char const* msg)> |
Terminate handler.
It should handle the error, whose description are given in msg and should never return.
Definition at line 40 of file terminate_handler.h.
TerminateHandler google::cloud::GetTerminateHandler | ( | ) |
Get the currently installed handler.
TerminateHandler google::cloud::SetTerminateHandler | ( | TerminateHandler | f | ) |
Install terminate handler and get the old one atomically.
f | the handler. It should never return, behaviour is undefined otherwise. |
void google::cloud::Terminate | ( | char const * | msg | ) |
Invoke the currently installed handler.
msg | Details about the error. |
This function should never return.