[][src]Trait core_extensions::option_result_ext::ToOption

pub trait ToOption {
    type Output;
    fn to_option(self) -> Option<Self::Output>;
}

Converts a type containing options into an option containing the type

Associated Types

type Output

The type in which the Options are unwrapped.

Example: Self==(Option,Option) type Output=(i32,i32);

Loading content...

Required methods

fn to_option(self) -> Option<Self::Output>

Performs the conversion

Loading content...

Implementations on Foreign Types

impl<T> ToOption for Option<T>[src]

type Output = T

impl<T> ToOption for (Option<T>, Option<T>)[src]

type Output = (T, T)

impl<T> ToOption for (Option<T>, Option<T>, Option<T>)[src]

type Output = (T, T, T)

impl<T> ToOption for (Option<T>, Option<T>, Option<T>, Option<T>)[src]

type Output = (T, T, T, T)

impl<T> ToOption for (Option<T>, Option<T>, Option<T>, Option<T>, Option<T>)[src]

type Output = (T, T, T, T, T)

Loading content...

Implementors

Loading content...