pub trait AsyncOptionTools<T> {
// Required methods
fn is_some_and_async<F, Fut>(self, f: F) -> impl Future<Output = bool>
where F: FnOnce(T) -> Fut,
Fut: Future<Output = bool>;
fn is_none_or_async<F, Fut>(self, f: F) -> impl Future<Output = bool>
where F: FnOnce(T) -> Fut,
Fut: Future<Output = bool>;
fn map_async<B, F, Fut>(self, f: F) -> impl Future<Output = Option<B>>
where F: FnOnce(T) -> Fut,
Fut: Future<Output = B>;
}Required Methods§
fn is_some_and_async<F, Fut>(self, f: F) -> impl Future<Output = bool>
fn is_none_or_async<F, Fut>(self, f: F) -> impl Future<Output = bool>
fn map_async<B, F, Fut>(self, f: F) -> impl Future<Output = Option<B>>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.