[][src]Trait mqtt::encodable::Decodable

pub trait Decodable: Sized {
    type Err: Error;
    type Cond;
    fn decode_with<R: Read>(
        reader: &mut R,
        cond: Option<Self::Cond>
    ) -> Result<Self, Self::Err>; fn decode<R: Read>(reader: &mut R) -> Result<Self, Self::Err> { ... } }

Methods for decoding bytes to an Object according to MQTT specification

Associated Types

type Err: Error

type Cond

Loading content...

Required methods

fn decode_with<R: Read>(
    reader: &mut R,
    cond: Option<Self::Cond>
) -> Result<Self, Self::Err>

Decodes object with additional data (or hints)

Loading content...

Provided methods

fn decode<R: Read>(reader: &mut R) -> Result<Self, Self::Err>

Decodes object from reader

Loading content...

Implementations on Foreign Types

impl Decodable for String[src]

type Err = StringEncodeError

type Cond = ()

impl Decodable for Vec<u8>[src]

type Err = Error

type Cond = u32

impl Decodable for ()[src]

type Err = NoError

type Cond = ()

Loading content...

Implementors

impl Decodable for ConnectReturnCode[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for VariablePacket[src]

type Err = VariablePacketError

type Cond = FixedHeader

impl Decodable for FixedHeader[src]

type Err = FixedHeaderError

type Cond = ()

impl Decodable for ProtocolLevel[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for ConnackFlags[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for ConnectFlags[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for KeepAlive[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for PacketIdentifier[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for ProtocolName[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for TopicNameHeader[src]

type Err = VariableHeaderError

type Cond = ()

impl Decodable for VarBytes[src]

type Err = Error

type Cond = ()

impl Decodable for ConnectPacketPayload[src]

impl Decodable for SubackPacketPayload[src]

impl Decodable for SubscribePacketPayload[src]

impl Decodable for UnsubscribePacketPayload[src]

impl Decodable for TopicFilter[src]

type Err = TopicFilterError

type Cond = ()

impl Decodable for TopicName[src]

type Err = TopicNameError

type Cond = ()

impl<T: Packet + Debug + 'static> Decodable for T[src]

type Err = PacketError<T>

type Cond = FixedHeader

Loading content...