Trait std::option::ToOption

pub trait ToOption<T> {
    fn to_option(&self) -> Option<T>;
}

A generic trait for converting a value to a Option

Required Methods

fn to_option(&self) -> Option<T>

Convert to the option type

Implementors