[][src]Struct log::key_values::value::Value

pub struct Value<'v>(_);

The value in a key-value pair.

Methods

impl<'v> Value<'v>[src]

pub fn visit(&self, visitor: &mut dyn Visitor) -> Result<(), Error>[src]

Visit a value using a Visitor.

impl<'v> Value<'v>[src]

pub fn from_debug(
    v: &'v impl Debug
) -> Self
[src]

Create a value from a fmt::Debug.

impl<'v> Value<'v>[src]

pub fn from_sval(
    v: &'v impl Value + Debug
) -> Self
[src]

Create a value from a sval::Value.

impl<'v> Value<'v>[src]

pub fn from_serde(
    v: &'v impl Serialize + Debug
) -> Self
[src]

Create a value from a serde::Serialize.

impl<'v> Value<'v>[src]

pub fn from_any<T>(
    v: &'v T,
    from: fn(_: FromAny, _: &T) -> Result<(), Error>
) -> Self
[src]

Create a value from some type.

The value must be provided with a compatible from method, but doesn't need to implement any traits. This method is useful when the type T can't satisfy the requirements for other Value::from methods, but the lifetime 'v prevents local new-types from being used.

Trait Implementations

impl<'v> ToValue for Value<'v>[src]

impl<'v> Debug for Value<'v>[src]

impl<'v> Display for Value<'v>[src]

impl<'v> Serialize for Value<'v>[src]

impl<'v> Value for Value<'v>[src]

Auto Trait Implementations

impl<'v> !Send for Value<'v>

impl<'v> !Sync for Value<'v>

Blanket Implementations

impl<T> From for T[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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

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

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

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

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

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

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

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

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