Constructs a StreamingUnpacker.
Clears some states for next deserialization.
Executes deserialization.
supports foreach. One loop provides Unpacked object contains execute() result. This is convenient in case that MessagePack values are continuous.
Convenient method for unpacking and clearing states.
Forwards to deserialized object.
... auto unpacker = StreamingUnpacker(serializedData); ... // appends new data to buffer if pre execute() call didn't finish deserialization. unpacker.feed(newSerializedData); while (unpacker.execute()) { foreach (obj; unpacker.purge()) { // do stuff (obj is a Value) } } if (unpacker.size) throw new Exception("Message is too large");
This StreamingUnpacker is a MessagePack streaming deserializer
This implementation enables you to load multiple objects from a stream(like network).