pub enum OneOf4<C1, C2, C3, C4> {
Variant1(C1),
Variant2(C2),
Variant3(C3),
Variant4(C4),
}
Expand description
One of the four variants.
§Examples
use orx_closure::*;
let _ = OneOf4::<i32, bool, String, char>::Variant1(42);
let _ = OneOf4::<i32, bool, String, char>::Variant2(true);
let _ = OneOf4::<i32, bool, String, char>::Variant3("hi".to_string());
let _ = OneOf4::<i32, bool, String, char>::Variant4('x');
Variants§
Variant1(C1)
First variant.
Variant2(C2)
Second variant.
Variant3(C3)
Third variant.
Variant4(C4)
Fourth variant.
Trait Implementations§
Source§impl<C1: PartialEq, C2: PartialEq, C3: PartialEq, C4: PartialEq> PartialEq for OneOf4<C1, C2, C3, C4>
impl<C1: PartialEq, C2: PartialEq, C3: PartialEq, C4: PartialEq> PartialEq for OneOf4<C1, C2, C3, C4>
impl<C1: Eq, C2: Eq, C3: Eq, C4: Eq> Eq for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> StructuralPartialEq for OneOf4<C1, C2, C3, C4>
Auto Trait Implementations§
impl<C1, C2, C3, C4> Freeze for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> RefUnwindSafe for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> Send for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> Sync for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> Unpin for OneOf4<C1, C2, C3, C4>
impl<C1, C2, C3, C4> UnwindSafe for OneOf4<C1, C2, C3, C4>
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