Struct config::DefaultConfigurationSection
source · [−]pub struct DefaultConfigurationSection { /* private fields */ }Expand description
Represent a configuration section.
Implementations
sourceimpl DefaultConfigurationSection
impl DefaultConfigurationSection
sourcepub fn new(root: Box<dyn ConfigurationRoot>, path: &str) -> Self
pub fn new(root: Box<dyn ConfigurationRoot>, path: &str) -> Self
Initializes a new configuration section.
Arguments
root- A reference to the configuration rootpath- The path of the configuration section
Trait Implementations
sourceimpl Configuration for DefaultConfigurationSection
impl Configuration for DefaultConfigurationSection
sourcefn section(&self, key: &str) -> Box<dyn ConfigurationSection>
fn section(&self, key: &str) -> Box<dyn ConfigurationSection>
Gets a configuration section with the specified key.
sourcefn children(&self) -> Vec<Box<dyn ConfigurationSection>>
fn children(&self) -> Vec<Box<dyn ConfigurationSection>>
Gets the sequence of child configuration sections.
sourcefn reload_token(&self) -> Box<dyn ChangeToken>
fn reload_token(&self) -> Box<dyn ChangeToken>
Returns a change token that can be used to observe when this configuration is reloaded.
sourcefn as_section(&self) -> Option<&dyn ConfigurationSection>
fn as_section(&self) -> Option<&dyn ConfigurationSection>
Attempts to convert the configuration as a configuration section.
sourcefn iter_relative(
&self,
make_paths_relative: bool
) -> Box<dyn Iterator<Item = (String, String)>>
fn iter_relative(
&self,
make_paths_relative: bool
) -> Box<dyn Iterator<Item = (String, String)>>
Gets an iterator of the key/value pairs within the configuration. Read more
sourceimpl Deref for DefaultConfigurationSection
impl Deref for DefaultConfigurationSection
type Target = dyn Configuration + 'static
type Target = dyn Configuration + 'static
The resulting type after dereferencing.
Auto Trait Implementations
impl !RefUnwindSafe for DefaultConfigurationSection
impl !Send for DefaultConfigurationSection
impl !Sync for DefaultConfigurationSection
impl Unpin for DefaultConfigurationSection
impl !UnwindSafe for DefaultConfigurationSection
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more