Struct any_mpsc::BufferedReceiver[][src]

pub struct BufferedReceiver {
    pub rx: Receiver<Box<dyn Any>>,
    pub buf: Dfb,
}
Expand description

Wraps an mpsc::Receiver to support dynamic typing and buffered results.

Fields

rx: Receiver<Box<dyn Any>>buf: Dfb

Implementations

Wraps mpsc::Receiver::recv. See [BufRecvError] for details on the return value. Will continuously recv until the supplied type is found. Any unmatching types received will be placed in the buffer.

Wraps mpsc::Receiver::recv. See [BufRecvError] for details on the return value. Will attempt to take from the internal buffer before performing an actual channel recv.

Wraps mpsc::Receiver::recv. See [BufRecvError] for details on the return value. Will perform a channel recv regardless of whether or not anything is contained in the buffer.

Wraps mpsc::Receiver::recv_timeout. See [BufRecvError] for details on the return value. Will attempt to take from the internal buffer before performing an actual channel recv_timeout.

Wraps mpsc::Receiver::recv_timeout. See [BufRecvError] for details on the return value. Will perform a channel recv_timeout regardless of whether or not anything is contained in the buffer.

Wraps mpsc::Receiver::try_recv. See [BufRecvError] for details on the return value. Will attempt to take from the internal buffer before performing an actual channel recv_timeout.

Wraps mpsc::Receiver::try_recv. See [BufRecvError] for details on the return value. Will perform a channel recv_timeout regardless of whether or not anything is contained in the buffer.

Wraps mpsc::Receiver::recv. See crate::AnyRecvError for details on the return value. Bypasses the buffer entirely.

Wraps mpsc::Receiver::recv_timeout. See crate::AnyRecvError for details on the return value. Bypasses the buffer entirely.

Wraps mpsc::Receiver::try_recv. See crate::AnyRecvError for details on the return value. Bypasses the buffer entirely.

Will attempt to read a value from the internal buffer. Will not do a channel recv of any kind even if the buffer is empty.

Trait Implementations

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.