[][src]Enum onc_rpc::MessageType

pub enum MessageType<T, P> where
    T: AsRef<[u8]>,
    P: AsRef<[u8]>, 
{ Call(CallBody<T, P>), Reply(ReplyBody<T, P>), }

The type of RPC message.

Variants

Call(CallBody<T, P>)

This message is invoking an RPC.

Reply(ReplyBody<T, P>)

This message is a response to an RPC request.

Implementations

impl<T, P> MessageType<T, P> where
    T: AsRef<[u8]>,
    P: AsRef<[u8]>, 
[src]

pub fn serialise_into(&self, buf: &mut Cursor<Vec<u8>>) -> Result<(), Error>[src]

Serialises this MessageType into buf, advancing the cursor position by serialised_len bytes.

pub fn serialised_len(&self) -> u32[src]

Returns the on-wire length of this message once serialised, including the message header.

Trait Implementations

impl<T: Debug, P: Debug> Debug for MessageType<T, P> where
    T: AsRef<[u8]>,
    P: AsRef<[u8]>, 
[src]

impl<T: PartialEq, P: PartialEq> PartialEq<MessageType<T, P>> for MessageType<T, P> where
    T: AsRef<[u8]>,
    P: AsRef<[u8]>, 
[src]

impl<T, P> StructuralPartialEq for MessageType<T, P> where
    T: AsRef<[u8]>,
    P: AsRef<[u8]>, 
[src]

impl TryFrom<Bytes> for MessageType<Bytes, Bytes>[src]

type Error = Error

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<T, P> RefUnwindSafe for MessageType<T, P> where
    P: RefUnwindSafe,
    T: RefUnwindSafe
[src]

impl<T, P> Send for MessageType<T, P> where
    P: Send,
    T: Send
[src]

impl<T, P> Sync for MessageType<T, P> where
    P: Sync,
    T: Sync
[src]

impl<T, P> Unpin for MessageType<T, P> where
    P: Unpin,
    T: Unpin
[src]

impl<T, P> UnwindSafe for MessageType<T, P> where
    P: UnwindSafe,
    T: UnwindSafe
[src]

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.