polars_utils::python_function

Trait TrySerializeToBytes

Source
pub trait TrySerializeToBytes: Sized {
    // Required methods
    fn try_serialize_to_bytes(&self) -> PolarsResult<Vec<u8>>;
    fn try_deserialize_bytes(bytes: &[u8]) -> PolarsResult<Self>;
}
Available on crate features serde and python only.
Expand description

Serializes a Python object without additional system metadata. This is intended to be used together with PySerializeWrap, which attaches e.g. Python version metadata.

Required Methods§

Source

fn try_serialize_to_bytes(&self) -> PolarsResult<Vec<u8>>

Source

fn try_deserialize_bytes(bytes: &[u8]) -> PolarsResult<Self>

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§