struct Folding<'a> {
held: &'a Held,
window: Option<Window>,
live: bool,
}Expand description
The messages a fold has taken out, and the promise that they go back.
This is a guard rather than a straight-line take-and-restore because
the render between them is a place a panic can land, and a panic there
with no guard is out of all proportion to its trigger: the messages are
dropped, folding stays set, and notify_all is never reached - so every
reader of the seat parks in Held::lock on a notification that never
comes, and the seat is wedged for the process’s life. Through
Conversations::apply the same lock is the socket’s single stream
folder, so it is every client on every seat that stops being delivered to
rather than one page.
With the guard, a panic costs one bad fold: the messages go back, the boundaries are left for the next fold to rebuild, and the readers wake.
Fields§
§held: &'a Held§window: Option<Window>§live: boolImplementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Folding<'a>
impl<'a> RefUnwindSafe for Folding<'a>
impl<'a> Send for Folding<'a>
impl<'a> Sync for Folding<'a>
impl<'a> Unpin for Folding<'a>
impl<'a> UnsafeUnpin for Folding<'a>
impl<'a> UnwindSafe for Folding<'a>
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<S, T> Duplex<S> for Twhere
T: FromSample<S> + ToSample<S>,
§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> 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> ⓘ
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> ⓘ
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