Skip to main content

FlattenOptionRefOption

Trait FlattenOptionRefOption 

Source
pub trait FlattenOptionRefOption {
    type Value;

    // Required method
    fn flatten(&self) -> Option<&Self::Value>;
}
Expand description

Helper trait to implement flatten() on Option<&Option<T>>.

Required Associated Types§

Source

type Value

The type of the value contained in the double option.

Required Methods§

Source

fn flatten(&self) -> Option<&Self::Value>

Converts from Option<&Option<T>> to Option<&T>.

Implementations on Foreign Types§

Source§

impl<'a, T> FlattenOptionRefOption for Option<&'a Option<T>>

Implementors§