Iso

Trait Iso 

Source
pub trait Iso<'x>: View
where Self::V: SpecIso<Src = <Self::Src as View>::V, Dst = <Self::Dst as View>::V>, <Self::Src as View>::V: SpecFrom<<Self::Dst as View>::V>, <Self::Dst as View>::V: SpecFrom<<Self::Src as View>::V>, Self::Dst: 'x,
{ type Src: View; type RefSrc: View<V = <Self::Src as View>::V> + From<&'x Self::Dst>; type Dst: View + From<Self::Src>; }
Expand description

All isomorphisms to be used in Mapped combinator must implement this trait.

Required Associated Types§

Source

type Src: View

The source type of the isomorphism.

Source

type RefSrc: View<V = <Self::Src as View>::V> + From<&'x Self::Dst>

The reference of the [Src] type.

Source

type Dst: View + From<Self::Src>

The destination type of the isomorphism.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§