Trait recursive_variadic::RecursiveVariadic
[−]
[src]
pub trait RecursiveVariadic { fn get<N: Key>(&self) -> Option<&N::Value>; fn get_mut<N: Key>(&mut self) -> Option<&mut N::Value>; fn and<N: Key>(self, val: N::Value) -> Entry<N, Self>
where
Self: Sized, { ... } fn and_default<N: Key>(self) -> Entry<N, Self>
where
N::Value: Default,
Self: Sized, { ... } }
The building block trait for recursive variadics.
Required Methods
fn get<N: Key>(&self) -> Option<&N::Value>
Try to get the value for N.
fn get_mut<N: Key>(&mut self) -> Option<&mut N::Value>
Try to get the value for N mutably.
Provided Methods
fn and<N: Key>(self, val: N::Value) -> Entry<N, Self> where
Self: Sized,
Self: Sized,
Add a key-value pair to this.
fn and_default<N: Key>(self) -> Entry<N, Self> where
N::Value: Default,
Self: Sized,
N::Value: Default,
Self: Sized,
Add the default value for N
Implementors
impl RecursiveVariadic for Empty
impl<T: Key, R: RecursiveVariadic> RecursiveVariadic for Entry<T, R>