deserializePPT method
Converts a uint8 JSON message into a PPT Payload Object
Implementation
@override
PPTPayload? deserializePPT(Uint8List binPayload) {
var messageStr = Utf8Decoder().convert(binPayload);
Object? decodedObject = json.decode(messageStr);
if (decodedObject is Map) {
return PPTPayload(
arguments: decodedObject['args'],
argumentsKeywords: decodedObject['kwargs']);
}
_logger.shout('Could not deserialize the message: $messageStr');
// TODO respond with an error
return null;
}