gufe.serialization.msgpack¶
Functions
|
For non-standard datatypes, unpack into the appropriate structures. |
|
For non-standard datatypes, create an ExtType containing packed data. |
|
Serialize an integer larger than 64 bits by string conversion. |
|
Serialize an object with MessagePack serialization. |
|
Deserialize MessagePack encoded bytes. |
Classes
|
Enumeration of custom extension types for MessagePack serialization. |
- class gufe.serialization.msgpack.MPEXT(*values)¶
Enumeration of custom extension types for MessagePack serialization.
- LARGEINT = 0¶
- PATH = 1¶
- UNIT = 2¶
- NDARRAY = 3¶
- NPGENERIC = 4¶
- SETTINGS = 5¶
- UUID = 6¶
- DATETIME = 7¶
- gufe.serialization.msgpack.pack_largeint(large_int: int) bytes¶
Serialize an integer larger than 64 bits by string conversion.
This is a limitation of the MessagePack format.
- gufe.serialization.msgpack.pack_default(obj) msgpack.ExtType¶
For non-standard datatypes, create an ExtType containing packed data.
- gufe.serialization.msgpack.ext_hook_default(code: int, data: bytes)¶
For non-standard datatypes, unpack into the appropriate structures.
- gufe.serialization.msgpack.packb(obj) bytes¶
Serialize an object with MessagePack serialization.
- Parameters:
obj – The object to be serialized.
- Returns:
The serialized object as bytes.
- Return type:
bytes
- gufe.serialization.msgpack.unpackb(data: bytes)¶
Deserialize MessagePack encoded bytes.
- Parameters:
data (bytes) – The bytes to be deserialized.
- Returns:
The deserialized object.
- Return type:
deserialized