The pickle serializer.
A pass-through serializer.
Values will not be serialized.
Base class for serializers.
Parameter: | encoding – Optional encoding applied after serialization, and before deserialization. |
---|
Example using compression:
>>> s = Pickler(encoding="zlib")
>>> val = s.encode({"foo: "bar"})>>>
s.decode(val)
Serializers must implement the serialize() and deserialize() methods. Both take a single argument, which is the value to serialize/deserialize.