pub struct _Some;
Expand description
Prism for Option::Some
.
Trait Implementations§
source§impl<T> AffineFold<Option<T>> for _Some
impl<T> AffineFold<Option<T>> for _Some
source§impl<'a, T> AffineFoldMut<'a, Option<T>> for _Somewhere
T: 'a,
impl<'a, T> AffineFoldMut<'a, Option<T>> for _Somewhere
T: 'a,
source§impl<'a, T> AffineFoldRef<'a, Option<T>> for _Somewhere
T: 'a,
impl<'a, T> AffineFoldRef<'a, Option<T>> for _Somewhere
T: 'a,
source§impl<T> AffineTraversal<Option<T>> for _Some
impl<T> AffineTraversal<Option<T>> for _Some
source§impl OpticsFallible for _Some
impl OpticsFallible for _Some
source§fn success_witness(&self) -> _Some
fn success_witness(&self) -> _Some
Get a lightweight witness for success.
source§fn map_fallible<S, F, E, G>(self, f: F, g: G) -> MapFallible<Self, F, G>
fn map_fallible<S, F, E, G>(self, f: F, g: G) -> MapFallible<Self, F, G>
Map the
Success
and Error
type for this fallible optics.source§fn map_success<S, F>(self, f: F) -> MapSuccess<Self, F>
fn map_success<S, F>(self, f: F) -> MapSuccess<Self, F>
Map the
Success
type for this fallible optics.source§fn map_error<E, G>(self, g: G) -> MapError<Self, G>
fn map_error<E, G>(self, g: G) -> MapError<Self, G>
Map the
Error
type for this fallible optics.source§fn assert_infallible(self) -> MapFallibleTo<Self, Self::Success, Infallible>
fn assert_infallible(self) -> MapFallibleTo<Self, Self::Success, Infallible>
Assert that this optics should never fail (in practice).
The resulting optics panics on error.
source§fn to_str_err(self) -> MapFallibleTo<Self, Self::Success, String>
fn to_str_err(self) -> MapFallibleTo<Self, Self::Success, String>
Map the
Error
type to Box<str>
.source§impl Ord for _Some
impl Ord for _Some
source§impl PartialEq for _Some
impl PartialEq for _Some
source§impl PartialOrd for _Some
impl PartialOrd for _Some
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl<T> Traversal<Option<T>> for _Some
impl<T> Traversal<Option<T>> for _Some
impl Copy for _Some
impl Eq for _Some
impl<T> Prism<Option<T>> for _Some
impl StructuralPartialEq for _Some
Auto Trait Implementations§
impl Freeze for _Some
impl RefUnwindSafe for _Some
impl Send for _Some
impl Sync for _Some
impl Unpin for _Some
impl UnwindSafe for _Some
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