Task cancellation helpers.
Definition in file cancel.hpp.
Go to the source code of this file.
#include <string>#include <boost/smart_ptr/intrusive_ptr.hpp>#include <userver/engine/deadline.hpp>
 Include dependency graph for cancel.hpp:
 This graph shows which files directly or indirectly include this file:Classes | |
| class | engine::TaskCancellationBlocker | 
| class | engine::TaskCancellationToken | 
| Cancellation token to given task object.  More... | |
Namespaces | |
| namespace | engine | 
| Asynchronous engine primitives.  | |
| namespace | engine::current_task | 
| Namespace with functions to work with current task from within it.  | |
Enumerations | |
| enum class | engine::TaskCancellationReason {  engine::kNone , engine::kUserRequest , engine::kDeadline , engine::kOverload , engine::kAbandoned , engine::kShutdown }  | 
| Task cancellation reason.  More... | |
Functions | |
| bool | engine::current_task::IsCancelRequested () noexcept | 
| bool | engine::current_task::ShouldCancel () noexcept | 
| TaskCancellationReason | engine::current_task::CancellationReason () noexcept | 
| void | engine::current_task::CancellationPoint () | 
| Throws an exception if a cancellation request for this task is pending.   | |
| void | engine::current_task::SetDeadline (Deadline deadline) | 
| TaskCancellationToken | engine::current_task::GetCancellationToken () | 
| Return cancellation token for current coroutine.  | |
| std::string_view | engine::ToString (TaskCancellationReason reason) noexcept | 
| Returns a string representation of a cancellation reason.  | |