pub struct DialogWatch { /* private fields */ }Expand description
The dialog event package (RFC 4235).
Holds one watcher’s view: the dialogs, and the version counter that view is up to.
Implementations§
Source§impl DialogWatch
impl DialogWatch
Sourcepub fn document(&mut self, dialogs: &[Dialog]) -> String
pub fn document(&mut self, dialogs: &[Dialog]) -> String
The next document for this watcher.
The first is always full and the rest are partial (§4.1). A watcher that joined
mid-call is given the whole picture once and told about changes after that; sending only
changes from the start would leave it inferring a state nobody ever described.
The version is per subscription, not per resource (§4.1): two watchers of the same set of dialogs each count from zero, and sharing a counter would make one of them see gaps.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DialogWatch
impl RefUnwindSafe for DialogWatch
impl Send for DialogWatch
impl Sync for DialogWatch
impl Unpin for DialogWatch
impl UnsafeUnpin for DialogWatch
impl UnwindSafe for DialogWatch
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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