Skip to main content

NetworkWrite

Trait NetworkWrite 

Source
pub trait NetworkWrite {
    type Error: Error;

    // Required method
    fn write(
        &mut self,
        data: &[u8],
    ) -> impl Future<Output = Result<(), Self::Error>>;
}
Expand description

Send direction of the network layer.

Required Associated Types§

Source

type Error: Error

Error type for write operations.

Required Methods§

Source

fn write( &mut self, data: &[u8], ) -> impl Future<Output = Result<(), Self::Error>>

Writes a packet to the network.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<'a, const QUEUE: usize, const MTU: usize> NetworkWrite for LocalAppHandle<'a, QUEUE, MTU>

Source§

impl<L: DatalinkWrite> NetworkWrite for PointToPoint<L>

Source§

impl<N, G, A, C, const MTU: usize, const OUT: usize> NetworkWrite for Router<N, G, A, C, MTU, OUT>
where N: Datalink, G: Datalink, A: RoutingAlgorithm, C: Clock,

Source§

impl<N, const MTU: usize, const OUT: usize> NetworkWrite for Gossip<N, MTU, OUT>
where N: Datalink,