Chromium Embedded Framework (CEF)
128.4.2+g5c235a2+chromium-128.0.6613.18
|
ScopedClosureRunner is akin to std::unique_ptr<> for Closures. More...
#include "include/base/cef_callback_helpers.h"
Public Member Functions | |
ScopedClosureRunner () | |
ScopedClosureRunner (OnceClosure closure) | |
ScopedClosureRunner (ScopedClosureRunner &&other) | |
ScopedClosureRunner & | operator= (ScopedClosureRunner &&other) |
~ScopedClosureRunner () | |
operator bool () const | |
void | RunAndReset () |
void | ReplaceClosure (OnceClosure closure) |
OnceClosure | Release () |
ScopedClosureRunner is akin to std::unique_ptr<> for Closures.
It ensures that the Closure is executed no matter how the current scope exits. If you are looking for "ScopedCallback", "CallbackRunner", or "CallbackScoper" this is the class you want.
base::ScopedClosureRunner::ScopedClosureRunner | ( | ) |
|
explicit |
base::ScopedClosureRunner::ScopedClosureRunner | ( | ScopedClosureRunner && | other | ) |
base::ScopedClosureRunner::~ScopedClosureRunner | ( | ) |
|
inlineexplicit |
ScopedClosureRunner& base::ScopedClosureRunner::operator= | ( | ScopedClosureRunner && | other | ) |
OnceClosure base::ScopedClosureRunner::Release | ( | ) |
void base::ScopedClosureRunner::ReplaceClosure | ( | OnceClosure | closure | ) |
void base::ScopedClosureRunner::RunAndReset | ( | ) |