pub trait DbProject {
// Required methods
fn new<S: AsRef<str>, P: AsRef<Path>>(name: S, project_path: P) -> Self;
fn open<P: AsRef<Path>>(project_path: P) -> Result<Self, Error>
where Self: Sized;
fn data_load<P: AsRef<Path>>(path: P) -> Result<Self, Error>
where Self: Sized;
fn data_load_without_creating<P: AsRef<Path>>(
path: P,
) -> Result<Self, Error>
where Self: Sized;
fn save(&self) -> Result<(), Error>;
}
Required Methods§
fn new<S: AsRef<str>, P: AsRef<Path>>(name: S, project_path: P) -> Self
fn open<P: AsRef<Path>>(project_path: P) -> Result<Self, Error>where
Self: Sized,
fn data_load<P: AsRef<Path>>(path: P) -> Result<Self, Error>where
Self: Sized,
fn data_load_without_creating<P: AsRef<Path>>(path: P) -> Result<Self, Error>where
Self: Sized,
fn save(&self) -> 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.