Trait Body

Source
pub trait Body: Sized {
    // Required methods
    fn decode_from_reader(r: &mut Reader<'_>) -> Result<Self>;
    fn encode_onto<W: Writer + ?Sized>(self, w: &mut W) -> EncodeResult<()>;
}
Expand description

Internal: traits in common different cell bodies.

Required Methods§

Source

fn decode_from_reader(r: &mut Reader<'_>) -> Result<Self>

Decode a relay cell body from a provided reader.

Source

fn encode_onto<W: Writer + ?Sized>(self, w: &mut W) -> EncodeResult<()>

Encode the body of this cell into the end of a writer.

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 Body for ConfluxLinked

Available on crate feature conflux only.
Source§

impl Body for ConfluxLinkedAck

Available on crate feature conflux only.
Source§

impl Body for ConfluxSwitch

Available on crate feature conflux only.
Source§

impl Body for V1LinkPayload

Available on crate feature conflux only.
Source§

impl Body for EstablishIntro

Available on crate feature hs only.
Source§

impl Body for EstablishRendezvous

Available on crate feature hs only.
Source§

impl Body for IntroEstablished

Available on crate feature hs only.
Source§

impl Body for Introduce1

Available on crate feature hs only.
Source§

impl Body for Introduce2

Available on crate feature hs only.
Source§

impl Body for IntroduceAck

Available on crate feature hs only.
Source§

impl Body for Rendezvous1

Available on crate feature hs only.
Source§

impl Body for Rendezvous2

Available on crate feature hs only.
Source§

impl Body for RendezvousEstablished

Available on crate feature hs only.
Source§

impl Body for ConnectUdp

Available on crate feature experimental-udp only.
Source§

impl Body for ConnectedUdp

Available on crate feature experimental-udp only.
Source§

impl Body for Datagram

Available on crate feature experimental-udp only.
Source§

impl Body for Begin

Source§

impl Body for BeginDir

Source§

impl Body for Connected

Source§

impl Body for Data

Source§

impl Body for Drop

Source§

impl Body for End

Source§

impl Body for Extend2

Source§

impl Body for Extend

Source§

impl Body for Extended2

Source§

impl Body for Extended

Source§

impl Body for Resolve

Source§

impl Body for Resolved

Source§

impl Body for Sendme

Source§

impl Body for Truncate

Source§

impl Body for Truncated

Source§

impl Body for Unrecognized