pub struct YamlConfigProvider { /* private fields */ }Expand description
YAML configuration provider implementation
Implementations§
Trait Implementations§
Source§impl ConfigProvider for YamlConfigProvider
impl ConfigProvider for YamlConfigProvider
Source§fn load_config<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Config>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn load_config<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Config>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Load configuration from the provider
Source§fn save_config<'life0, 'life1, 'async_trait>(
&'life0 self,
config: &'life1 Config,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn save_config<'life0, 'life1, 'async_trait>(
&'life0 self,
config: &'life1 Config,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Save configuration to the provider
Source§fn validate_config<'life0, 'life1, 'async_trait>(
&'life0 self,
config: &'life1 Config,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn validate_config<'life0, 'life1, 'async_trait>(
&'life0 self,
config: &'life1 Config,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Validate configuration format and structure
Source§fn config_exists<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn config_exists<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<bool>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Check if configuration exists
Source§fn config_path(&self) -> Option<&Path>
fn config_path(&self) -> Option<&Path>
Get configuration file path (if applicable)
Auto Trait Implementations§
impl Freeze for YamlConfigProvider
impl RefUnwindSafe for YamlConfigProvider
impl Send for YamlConfigProvider
impl Sync for YamlConfigProvider
impl Unpin for YamlConfigProvider
impl UnwindSafe for YamlConfigProvider
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more