Trait microkelvin::First[][src]

pub trait First<'a, A> where
    Self: Compound<A>,
    A: Combine<Self, A>, 
{ fn first(&'a self) -> Result<Option<Branch<'a, Self, A>>, CanonError>;
fn first_mut(
        &'a mut self
    ) -> Result<Option<BranchMut<'a, Self, A>>, CanonError>
    where
        Self: MutableLeaves
; }

Trait that provides a first and first_mut method to any Compound with a Cardinality annotation

Required methods

fn first(&'a self) -> Result<Option<Branch<'a, Self, A>>, CanonError>[src]

Construct a Branch pointing to the first element, if not empty

fn first_mut(&'a mut self) -> Result<Option<BranchMut<'a, Self, A>>, CanonError> where
    Self: MutableLeaves
[src]

Construct a BranchMut pointing to the first element, if not empty

Loading content...

Implementors

impl<'a, C, A> First<'a, A> for C where
    C: Compound<A> + Clone,
    A: Combine<C, A>, 
[src]

Loading content...