#include <userver/concurrent/background_task_storage.hpp>
A version of concurrent::BackgroundTaskStorage for advanced use cases (e.g. driver internals) that can take the ownership of any kind of task.
Definition at line 21 of file background_task_storage.hpp.
◆ CancelAndWait()
void concurrent::BackgroundTaskStorageCore::CancelAndWait |
( |
| ) |
|
|
noexcept |
Explicitly cancel and wait for the tasks. New tasks must not be launched after this call returns. Should be called no more than once.
◆ Detach()
void concurrent::BackgroundTaskStorageCore::Detach |
( |
engine::Task && |
task | ) |
|
Detaches task, allowing it to continue execution out of scope. It will be cancelled and waited for on BTS destruction.
- Note
- After detach, Task becomes invalid
The documentation for this class was generated from the following file: