decodeMessage method
- @override
override
Decodes the specified message
from binary.
Returns null if the message is null.
Implementation
@override
dynamic decodeMessage(ByteData message) {
if (message == null)
return null;
final ReadBuffer buffer = ReadBuffer(message);
final dynamic result = readValue(buffer);
if (buffer.hasRemaining)
throw const FormatException('Message corrupted');
return result;
}