pub struct LayeredConfig { /* private fields */ }Expand description
Stack of config layers resolved top-down (last layer wins).
Implementations§
Source§impl LayeredConfig
impl LayeredConfig
pub fn new() -> Self
pub fn push_layer(&mut self, layer: ConfigLayer)
pub fn layer_count(&self) -> usize
pub fn get_or<'a>(&'a self, key: &str, default: &'a str) -> &'a str
pub fn has_key(&self, key: &str) -> bool
pub fn pop_layer(&mut self) -> Option<ConfigLayer>
pub fn clear(&mut self)
Trait Implementations§
Source§impl Clone for LayeredConfig
impl Clone for LayeredConfig
Source§fn clone(&self) -> LayeredConfig
fn clone(&self) -> LayeredConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LayeredConfig
impl Debug for LayeredConfig
Source§impl Default for LayeredConfig
impl Default for LayeredConfig
Source§fn default() -> LayeredConfig
fn default() -> LayeredConfig
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for LayeredConfig
impl RefUnwindSafe for LayeredConfig
impl Send for LayeredConfig
impl Sync for LayeredConfig
impl Unpin for LayeredConfig
impl UnsafeUnpin for LayeredConfig
impl UnwindSafe for LayeredConfig
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