#include <userver/utils/scope_guard.hpp>
a helper class to perform actions on scope exit
Usage example:
Definition at line 28 of file scope_guard.hpp.
Public Types | |
using | Callback = std::function<void()> |
Public Member Functions | |
ScopeGuard (Callback callback) | |
ScopeGuard (const ScopeGuard &)=delete | |
ScopeGuard (ScopeGuard &&)=delete | |
ScopeGuard & | operator= (const ScopeGuard &)=delete |
ScopeGuard & | operator= (ScopeGuard &&)=delete |
void | Release () noexcept |
Definition at line 30 of file scope_guard.hpp.
|
inlineexplicit |
Definition at line 32 of file scope_guard.hpp.
|
inline |
Definition at line 41 of file scope_guard.hpp.
|
inlinenoexcept |
Definition at line 58 of file scope_guard.hpp.