[−][src]Crate sage_mqtt
sage_mqtt
is a an encoding/decoding library for MQTT 5.0 protocol.
The library consists in pivot types, such as UTF8String
that can be
written to and read from a stream as well as converted to standard Rust
types.
Structs
Auth | |
Authentication | |
BinaryData | Binary Data is represented by a Two Byte Integer length which indicates the
number of data bytes, followed by that number of bytes. Thus, the length of
Binary Data is limited to the range of 0 to 65,535 Bytes.
This type can be converted from and to |
Bits | Bits in a byte are labelled 7 to 0. Bit number 7 is the most significant
bit.
This type can be converted from and to |
Broker | |
Byte | |
ConnAck | |
Connect | The |
Disconnect | |
FourByteInteger | Four bytes data values are 32-bits unsigned integer represented in
big-endian. That means the most significant byte (MSB) is presented first
on the stream.
This type can be converted from |
PubAck | |
PubComp | |
PubRec | |
PubRel | |
Publish | |
SubAck | |
Subscribe | |
SubscriptionOptions | |
TwoByteInteger | Two bytes data values are 16-bits unsigned integer represented in
big-endian. That means the most significant byte (MSB) is presented first
on the stream.
This type can be converted from |
UTF8String | Text fields in an MQTT paquet are described in UTF-8. Each string in the
stream is prefixed with a two-byte size information with MSB first.
Because of that, a string cannot be longer that 65,535 bytes.
This type can be converted from and to |
UnSubAck | |
UnSubscribe | |
VariableByteInteger | The Variable Byte Integer is encoded using an encoding scheme which uses a single byte for values up to 127. Larger values are handled as follows. The least significant seven bits of each byte encode the data, and the most significant bit is used to indicate whether there are bytes following in the representation. Thus, each byte encodes 128 values and a "continuation bit". The maximum number of bytes in the Variable Byte Integer field is four. |
Enums
ControlPacket | |
Error | |
QoS | |
ReasonCode | |
RetainHandling |
Traits
Decode | The |
Encode | The |
Type Definitions
Result |