Trait config::Source [−][src]
pub trait Source: Debug { fn clone_into_box(&self) -> Box<Source + Send + Sync>; fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>; fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError> { ... } }
Describes a generic source of configuration properties.
Required Methods
ⓘImportant traits for Box<R>
fn clone_into_box(&self) -> Box<Source + Send + Sync>
fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>
Collect all configuration properties available from this source and return a HashMap.
Provided Methods
fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError>
Implementations on Foreign Types
impl Source for Vec<Box<Source + Send + Sync>>
[src]
impl Source for Vec<Box<Source + Send + Sync>>
ⓘImportant traits for Box<R>fn clone_into_box(&self) -> Box<Source + Send + Sync>
[src]
ⓘImportant traits for Box<R>
fn clone_into_box(&self) -> Box<Source + Send + Sync>
fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>
[src]
fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>
fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError>
[src]
fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError>
impl<T> Source for Vec<T> where
T: Source + Sync + Send,
T: Clone,
T: 'static,
[src]
impl<T> Source for Vec<T> where
T: Source + Sync + Send,
T: Clone,
T: 'static,
ⓘImportant traits for Box<R>fn clone_into_box(&self) -> Box<Source + Send + Sync>
[src]
ⓘImportant traits for Box<R>
fn clone_into_box(&self) -> Box<Source + Send + Sync>
fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>
[src]
fn collect(&self) -> Result<HashMap<String, Value>, ConfigError>
fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError>
[src]
fn collect_to(&self, cache: &mut Value) -> Result<(), ConfigError>
Implementors
impl Source for Config
impl Source for Environment
impl<T: FileSource> Source for File<T> where
T: 'static,
T: Sync + Send,