[][src]Struct async_coap::message::StandardMessageParser

pub struct StandardMessageParser<'buf> { /* fields omitted */ }

A class for parsing a stand-alone UDP CoAP message from a given buffer.

Methods

impl<'buf> StandardMessageParser<'buf>[src]

pub const MIN_MESSAGE_BUFFER_LEN: usize[src]

The minimum buffer size that can be passed into new().

pub fn new(buffer: &'buf [u8]) -> Result<StandardMessageParser<'buf>, Error>[src]

Creates a new StandardMessageParser instance with the given buffer.

pub fn as_bytes(&self) -> &'buf [u8][src]

Returns a byte slice containing the encoded message.

Trait Implementations

impl<'buf> MessageRead for StandardMessageParser<'buf>[src]

fn write_msg_to(&self, target: &mut dyn MessageWrite) -> Result<(), Error>[src]

Writes this message to the given target that implements MessageWrite. Read more

fn payload_as_str(&self) -> Option<&str>[src]

Gets the payload as a string slice.

impl<'buf> Display for StandardMessageParser<'buf>[src]

impl<'buf> Debug for StandardMessageParser<'buf>[src]

Auto Trait Implementations

impl<'buf> Unpin for StandardMessageParser<'buf>

impl<'buf> Sync for StandardMessageParser<'buf>

impl<'buf> Send for StandardMessageParser<'buf>

impl<'buf> UnwindSafe for StandardMessageParser<'buf>

impl<'buf> RefUnwindSafe for StandardMessageParser<'buf>

Blanket Implementations

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> From<T> for 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.

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

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

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

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,