FileLoadStore

Trait FileLoadStore 

Source
pub trait FileLoadStore: Serialize + for<'a> Deserialize<'a> {
    // Required methods
    fn f_load(path: &Path) -> Result<Self, Error>;
    fn f_save(&self, path: &Path) -> Result<(), Error>;
}
Expand description

file load&store trait

Required Methods§

Source

fn f_load(path: &Path) -> Result<Self, Error>

Source

fn f_save(&self, path: &Path) -> Result<(), Error>

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§

Source§

impl<T: Serialize + for<'a> Deserialize<'a>> FileLoadStore for T