[][src]Struct value_bag::Slot

pub struct Slot<'s, 'f> { /* fields omitted */ }

A value slot to fill using the Fill trait.

Implementations

impl<'s, 'f> Slot<'s, 'f>[src]

pub fn fill_any<T>(&mut self, value: T) -> Result<(), Error> where
    T: Into<ValueBag<'f>>, 
[src]

Fill the slot with a value.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

impl<'s, 'f> Slot<'s, 'f>[src]

pub fn fill_error<T>(&mut self, value: T) -> Result<(), Error> where
    T: Error
[src]

Fill the slot with an error.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

impl<'s, 'f> Slot<'s, 'f>[src]

pub fn fill_debug<T>(&mut self, value: T) -> Result<(), Error> where
    T: Debug
[src]

Fill the slot with a debuggable value.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

pub fn fill_display<T>(&mut self, value: T) -> Result<(), Error> where
    T: Display
[src]

Fill the slot with a displayable value.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

impl<'s, 'f> Slot<'s, 'f>[src]

pub fn fill_serde<T>(&mut self, value: T) -> Result<(), Error> where
    T: Serialize
[src]

Fill the slot with a structured value.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

impl<'s, 'f> Slot<'s, 'f>[src]

pub fn fill_sval<T>(&mut self, value: T) -> Result<(), Error> where
    T: Value
[src]

Fill the slot with a structured value.

The given value doesn't need to satisfy any particular lifetime constraints.

Panics

Calling more than a single fill method on this slot will panic.

Trait Implementations

impl<'s, 'f> Debug for Slot<'s, 'f>[src]

Auto Trait Implementations

impl<'s, 'f> !RefUnwindSafe for Slot<'s, 'f>

impl<'s, 'f> !Send for Slot<'s, 'f>

impl<'s, 'f> !Sync for Slot<'s, 'f>

impl<'s, 'f> Unpin for Slot<'s, 'f> where
    'f: 's, 

impl<'s, 'f> !UnwindSafe for Slot<'s, 'f>

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.