[][src]Enum germinate::ValueSource

pub enum ValueSource {
    Environment,
    AwsSsm,
}

This type represents the sources where a value can be loaded from

Variants

Environment

This variant represents a value that it loaded from an environment variable

AwsSsm

This variant represents a value that is loaded from AWS System Manager Parameter Store

Implementations

impl ValueSource[src]

pub fn from<T: AsRef<str>>(key: T) -> Result<Self>[src]

Creates a new ValueSource from the given name. The name is the string used in the template to define which loader to use when loading the value

Examples

// template string: "Hello %env:NAME%!"
use germinate::ValueSource;
let source = ValueSource::from("env").unwrap();
assert_eq!(ValueSource::Environment, source);

Trait Implementations

impl Debug for ValueSource[src]

impl PartialEq<ValueSource> for ValueSource[src]

impl StructuralPartialEq for ValueSource[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> Same<T> for T

type Output = T

Should always be Self

impl<T> Sealed<T> for T where
    T: ?Sized

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.