Skip to main content

UnboundedSend

Trait UnboundedSend 

Source
pub trait UnboundedSend<T: Send + 'static>:
    Clone
    + Send
    + 'static {
    // Required method
    fn send_now(&self, value: T) -> Result<(), T>;
}
Expand description

The send half of an unbounded MPSC channel.

Unlike MpscSend, sending never blocks — the implementation must buffer arbitrarily many values (or, for embassy-sync, use a large finite capacity that is treated as effectively unbounded).

Required Methods§

Source

fn send_now(&self, value: T) -> Result<(), T>

Send value without blocking.

§Errors

Returns Err(value) if the receiver was dropped.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§