Struct miau::source::InMemorySource [−][src]
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
impl RefUnwindSafe for InMemorySource
[src]
impl Send for InMemorySource
[src]
impl Sync for InMemorySource
[src]
impl Unpin for InMemorySource
[src]
impl UnwindSafe for InMemorySource
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,