A class that terminates the group when its destructor is called This is called even if a C++ exception is thrown Note: this should be used as a backup, terminate_group should still be called if termination is desired! More...
#include <group.hpp>
Public Member Functions | |
TerminateOnDestruction () | |
Constructor Enabled terminateion on destruction by default. More... | |
~TerminateOnDestruction () | |
Destructor On destruction, terminate the group if enabled. More... | |
void | disable () |
Disable termination of the group on destruction. More... | |
Private Member Functions | |
TerminateOnDestruction (TerminateOnDestruction &&)=delete | |
TerminateOnDestruction (const TerminateOnDestruction &)=delete | |
TerminateOnDestruction & | operator= (const TerminateOnDestruction &)=delete |
Private Attributes | |
bool | enabled |
A class that terminates the group when its destructor is called This is called even if a C++ exception is thrown Note: this should be used as a backup, terminate_group should still be called if termination is desired!
|
privatedelete |
|
privatedelete |
TerminateOnDestruction::TerminateOnDestruction | ( | ) |
Constructor Enabled terminateion on destruction by default.
TerminateOnDestruction::~TerminateOnDestruction | ( | ) |
Destructor On destruction, terminate the group if enabled.
void TerminateOnDestruction::disable | ( | ) |
Disable termination of the group on destruction.
|
privatedelete |
|
private |