[][src]Struct manaconf::Section

pub struct Section<'a> { /* fields omitted */ }

A section of configuration

This acts as a pre-applied prefix to a config key when fetching values

Example

let section = config.section("My::Config::Section");
// This is now the same as requesting `My::Config::Section::Value`
let value: String = section.get_value("Value");

Implementations

impl<'a> Section<'a>[src]

pub fn section<K: AsRef<Key>>(&self, key: K) -> Section[src]

Creates a further subsection from this section, similar to a section created by calling Config::section, except in this case the current sections prefix is prepended to the key passed into section

Example

let section = config.section("first");
let subsection = section.section("second");
// Will read value from "first::second::value"
let value: String = subsection.get_value("value");

Trait Implementations

impl<'a> ValueRead for Section<'a>[src]

Auto Trait Implementations

impl<'a> !RefUnwindSafe for Section<'a>

impl<'a> !Send for Section<'a>

impl<'a> !Sync for Section<'a>

impl<'a> Unpin for Section<'a>

impl<'a> !UnwindSafe for Section<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.