pub struct SourceWaker { /* private fields */ }
Expand description
This is a split waker, meant for being able to wake Reads and Writes separately.
Implementations§
Source§impl SourceWaker
impl SourceWaker
pub fn wake(&self, event: &Event)
pub fn get_read_waker(&self) -> Arc<AtomicWaker>
pub fn get_write_waker(&self) -> Arc<AtomicWaker>
Sourcepub fn register_waker(&self, waker: &Waker)
pub fn register_waker(&self, waker: &Waker)
If you are writing a Future and need to wake on either Read or Write, use this function to
register the Waker. Otherwise, use [get_read_waker
] or [get_write_waker
] respectively.
Trait Implementations§
Source§impl Clone for SourceWaker
impl Clone for SourceWaker
Source§fn clone(&self) -> SourceWaker
fn clone(&self) -> SourceWaker
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Default for SourceWaker
impl Default for SourceWaker
Source§fn default() -> SourceWaker
fn default() -> SourceWaker
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for SourceWaker
impl !RefUnwindSafe for SourceWaker
impl Send for SourceWaker
impl Sync for SourceWaker
impl Unpin for SourceWaker
impl !UnwindSafe for SourceWaker
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more