MqttPayloadBuilder class
Utility class to assist with the build in of message topic payloads.
Constructors
- MqttPayloadBuilder()
- Construction
Properties
Methods
-
addBool(
{required bool val}) → void - Add a bool, true is 1, false is 0
-
addBuffer(
Uint8Buffer buffer) → void - Add a buffer
-
addByte(
int val) → void - Add byte, this will overflow on values > 2**8-1
-
addDouble(
double val) → void - Add a 64 bit double
-
addHalf(
int val) → void - Add a halfword, 16 bits, this will overflow on values > 2**16-1
-
addHalfDouble(
double val) → void - Add a 32 bit double
-
addInt(
int val) → void - Add a long word, 64 bits or a Dart int
-
addString(
String val) → void - Add a standard Dart string
-
addUTF16String(
String val) → void - Add a UTF16 string, note Dart natively encodes strings as UTF16
-
addUTF8String(
String val) → void - Add a UTF8 string
-
addWillPayload(
String val) → void - Add a will payload
-
addWord(
int val) → void - Add a word, 32 bits, this will overflow on values > 2**32-1
-
clear(
) → void - Clear the buffer
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited