[][src]Trait smart_access::traversal::Of

pub trait Of<Index> where
    Index: Clone
{ type View: ?Sized; fn each_of<F>(&mut self, i: Index, f: F) -> bool
    where
        F: FnMut(&mut Self::View) -> bool
; }

An analogue of the At trait.

Associated Types

type View: ?Sized

Loading content...

Required methods

fn each_of<F>(&mut self, i: Index, f: F) -> bool where
    F: FnMut(&mut Self::View) -> bool, 

Traverses the view.

If f returns false, the iteration must stop.

The same goes for each_of: usually you want to return true from it. But there may be exceptions when returning false is more convenient.

Loading content...

Implementors

impl<'a, I, T: 'a> Of<()> for I where
    I: Iterator<Item = &'a mut T>, 
[src]

type View = T

Loading content...