pub trait IsOption: Sealed {
type Item;
// Required method
fn into_option(self) -> Option<Self::Item>;
}
Expand description
A helper trait enforcing that the type is Option
.
Required Associated Types§
Required Methods§
Sourcefn into_option(self) -> Option<Self::Item>
fn into_option(self) -> Option<Self::Item>
Consume itself and get the value of Option
.