Struct miau::source::InMemorySource[][src]

pub struct InMemorySource { /* fields omitted */ }

Represents in memory configuration source.

Implementations

impl InMemorySource[src]

pub fn empty() -> Self[src]

Creates new empty InMemorySource

pub fn from_string_slice(string: &str) -> Self[src]

Creates new InMemorySource from &str.

Example

use miau::builder::ConfigurationBuilder;
use miau::source::InMemorySource;
use miau::format::Json;

let mut builder = ConfigurationBuilder::default();

let c1 = r#"{"value" : 1}"#;

builder.add(InMemorySource::from_string_slice(&c1), Json::new());
let configuration = builder.build().unwrap(); // do not do it in you app

pub fn from_bytes(input: Vec<u8>) -> Self[src]

Creates new InMemorySource from Vec<u8>.

Trait Implementations

impl Default for InMemorySource[src]

impl Source for InMemorySource[src]

Auto Trait Implementations

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.