netstack3_base

Trait SendFrameContext

Source
pub trait SendFrameContext<BC, Meta> {
    // Required method
    fn send_frame<S>(
        &mut self,
        bindings_ctx: &mut BC,
        metadata: Meta,
        frame: S,
    ) -> Result<(), SendFrameError<S>>
       where S: Serializer,
             S::Buffer: BufferMut;
}
Expand description

A context for sending frames.

Required Methods§

Source

fn send_frame<S>( &mut self, bindings_ctx: &mut BC, metadata: Meta, frame: S, ) -> Result<(), SendFrameError<S>>
where S: Serializer, S::Buffer: BufferMut,

Send a frame.

send_frame sends a frame with the given metadata. The frame itself is passed as a Serializer which send_frame is responsible for serializing. If serialization fails for any reason, the original, unmodified Serializer is returned.

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<CC, BC, Meta> SendFrameContext<BC, Meta> for CC
where Meta: SendableFrameMeta<CC, BC>,