pub struct Fusion<A, E>(/* private fields */);
Implementations§
Trait Implementations§
source§impl<A, E> Validator<A, E> for Fusion<A, E>
impl<A, E> Validator<A, E> for Fusion<A, E>
fn to_result(self) -> Result<A, ValidationError<E>>
fn is_succeed(&self) -> bool
fn is_fail(&self) -> bool
fn map<A1>(self, f: impl FnOnce(A) -> A1) -> Valid<A1, E>
fn and<A1>(self, other: Valid<A1, E>) -> Valid<A1, E>
fn zip<A1>(self, other: Valid<A1, E>) -> Valid<(A, A1), E>
fn fuse<A1>(self, other: Valid<A1, E>) -> Fusion<(A, A1), E>
fn trace(self, message: &str) -> Valid<A, E>
fn fold<A1>( self, ok: impl FnOnce(A) -> Valid<A1, E>, err: impl FnOnce() -> Valid<A1, E>, ) -> Valid<A1, E>
fn and_then<B>(self, f: impl FnOnce(A) -> Valid<B, E>) -> Valid<B, E>
fn unit(self) -> Valid<(), E>
fn some(self) -> Valid<Option<A>, E>
fn map_to<B>(self, b: B) -> Valid<B, E>
fn when(self, f: impl FnOnce() -> bool) -> Valid<(), E>
Auto Trait Implementations§
impl<A, E> Freeze for Fusion<A, E>where
A: Freeze,
impl<A, E> RefUnwindSafe for Fusion<A, E>where
A: RefUnwindSafe,
E: RefUnwindSafe,
impl<A, E> Send for Fusion<A, E>
impl<A, E> Sync for Fusion<A, E>
impl<A, E> Unpin for Fusion<A, E>
impl<A, E> UnwindSafe for Fusion<A, E>where
A: UnwindSafe,
E: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more