Struct lens_rs::_box[][src]

pub struct _box<Optic>(pub Optic);

build-in optics to create Box, Rc or Arc pointers, implemented Review

assert_eq!(Review::review(optics!(_box), 0), Box::new(0));
assert_eq!(Review::review(optics!(_box), 0), Rc::new(0));
assert_eq!(Review::review(optics!(_box), 0), Arc::new(0));

or to visit the data in Box, implemented Lens

assert_eq!(Box::new(0).view(optic!(_box)), 0);

Trait Implementations

impl<Optic> Clone for _box<Optic> where
    Optic: Clone
[src]

impl<Optic> Copy for _box<Optic> where
    Optic: Copy
[src]

impl<Optic> Debug for _box<Optic> where
    Optic: Debug
[src]

impl<Optic> Eq for _box<Optic> where
    Optic: Eq
[src]

impl<Ls, Image, T> Lens<_box<Ls>, Image> for Box<T> where
    T: Lens<Ls, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Ls> LensMut<_box<Ls>, Image> for Box<T> where
    T: LensMut<Ls, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Ls> LensRef<_box<Ls>, Image> for Box<T> where
    T: LensRef<Ls, Image>, 
[src]

impl<Optic> PartialEq<_box<Optic>> for _box<Optic> where
    Optic: PartialEq<Optic>, 
[src]

impl<Pm, Image, T> Prism<_box<Pm>, Image> for Box<T> where
    T: Prism<Pm, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Pm> PrismMut<_box<Pm>, Image> for Box<T> where
    T: PrismMut<Pm, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Pm> PrismRef<_box<Pm>, Image> for Box<T> where
    T: PrismRef<Pm, Image>, 
[src]

impl<Rv, Image, T> Review<_box<Rv>, Image> for Box<T> where
    T: Review<Rv, Image>, 
[src]

impl<Rv, Image, T> Review<_box<Rv>, Image> for Rc<T> where
    T: Review<Rv, Image>, 
[src]

impl<Rv, Image, T> Review<_box<Rv>, Image> for Arc<T> where
    T: Review<Rv, Image>, 
[src]

impl<Optic> StructuralEq for _box<Optic>[src]

impl<Optic> StructuralPartialEq for _box<Optic>[src]

impl<Tr, Image, T> Traversal<_box<Tr>, Image> for Box<T> where
    T: Traversal<Tr, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Tr> TraversalMut<_box<Tr>, Image> for Box<T> where
    T: TraversalMut<Tr, Image>, 
[src]

impl<T: ?Sized, Image: ?Sized, Tr> TraversalRef<_box<Tr>, Image> for Box<T> where
    T: TraversalRef<Tr, Image>, 
[src]

Auto Trait Implementations

impl<Optic> RefUnwindSafe for _box<Optic> where
    Optic: RefUnwindSafe

impl<Optic> Send for _box<Optic> where
    Optic: Send

impl<Optic> Sync for _box<Optic> where
    Optic: Sync

impl<Optic> Unpin for _box<Optic> where
    Optic: Unpin

impl<Optic> UnwindSafe for _box<Optic> where
    Optic: UnwindSafe

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> Prism<__, T> for T[src]

impl<T> PrismMut<__, T> for T where
    T: ?Sized
[src]

impl<T> PrismRef<__, T> for T where
    T: ?Sized
[src]

impl<Image, T> Review<__, Image> for T where
    T: From<Image>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> Traversal<__, T> for T[src]

impl<T> TraversalMut<__, T> for T where
    T: ?Sized
[src]

impl<T> TraversalRef<__, T> for T where
    T: ?Sized
[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.