pub trait SettingsLoader:
Sized
+ Serialize
+ Default {
const SETTINGS_FILE: &'static str;
// Required method
fn from_str(s: &str) -> Result<Self, String>;
// Provided methods
fn load() -> Self { ... }
fn is_file_exists() -> bool { ... }
fn save(&self) { ... }
}
Required Associated Constants§
const SETTINGS_FILE: &'static str
Required Methods§
Provided Methods§
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.