pub struct UpdateStream { /* private fields */ }Expand description
Asynchronous stream of Updates.
Implementations§
Source§impl UpdateStream
impl UpdateStream
Sourcepub async fn next(&mut self) -> Option<Update>
pub async fn next(&mut self) -> Option<Update>
Wait for the next update. Returns None when the client has disconnected.
Sourcepub async fn next_raw(&mut self) -> Option<RawUpdate>
pub async fn next_raw(&mut self) -> Option<RawUpdate>
Wait for the next raw (unrecognised) update frame, skipping all
typed high-level variants. Useful for handling constructor IDs that
layer-client does not yet wrap — dispatch on constructor_id yourself.
Returns None when the client has disconnected.
Auto Trait Implementations§
impl Freeze for UpdateStream
impl RefUnwindSafe for UpdateStream
impl Send for UpdateStream
impl Sync for UpdateStream
impl Unpin for UpdateStream
impl UnsafeUnpin for UpdateStream
impl UnwindSafe for UpdateStream
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more