The implementation of waking a task on an executor.
This trait can be used to create a
Waker. An executor can define an
implementation of this trait, and use that to construct a Waker to pass
to the tasks that are executed on that executor.
This trait is a memory-safe and ergonomic alternative to constructing a
RawWaker. It supports the common executor design in which the data used
to wake up a task is stored in an
Arc. Some executors (especially
those for embedded systems) cannot use this API, which is why
exists as an alternative for those systems.
Wake this task.
fn wake_by_ref(self: &Arc<Self>)
Wake this task without consuming the waker.
If an executor supports a cheaper way to wake without consuming the
waker, it should override this method. By default, it clones the
Arc] and calls
wake on the clone.