pub trait File {
// Required methods
fn load(path: &Path) -> Result<Self>
where Self: Sized;
fn write(&self, path: &Path) -> Result<()>;
}Expand description
Generic trait
pub trait File {
// Required methods
fn load(path: &Path) -> Result<Self>
where Self: Sized;
fn write(&self, path: &Path) -> Result<()>;
}Generic trait