Trait ConfigManager
pub trait ConfigManager {
// Required methods
fn load_config(&self, path: &str) -> Result<ConfigOpt, ConfyError>;
fn store_config(
&self,
path: &str,
config: &Config,
) -> Result<(), ConfyError>;
}Expand description
Trait for configuration management to enable dependency injection and testing
Required Methods§
fn load_config(&self, path: &str) -> Result<ConfigOpt, ConfyError>
fn load_config(&self, path: &str) -> Result<ConfigOpt, ConfyError>
Load configuration from the specified path
fn store_config(&self, path: &str, config: &Config) -> Result<(), ConfyError>
fn store_config(&self, path: &str, config: &Config) -> Result<(), ConfyError>
Store configuration to the specified path