Struct futures_util::try_future::OrElse [−][src]
#[must_use = "futures do nothing unless polled"]pub struct OrElse<Fut1, Fut2, F> { /* fields omitted */ }
Future for the or_else
combinator, chaining a computation onto the end of
a future which fails with an error.
This is created by the Future::or_else
method.
Trait Implementations
impl<Fut1: Debug, Fut2: Debug, F: Debug> Debug for OrElse<Fut1, Fut2, F>
[src]
impl<Fut1: Debug, Fut2: Debug, F: Debug> Debug for OrElse<Fut1, Fut2, F>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<Fut1, Fut2, F> Future for OrElse<Fut1, Fut2, F> where
Fut1: TryFuture,
Fut2: TryFuture<Ok = Fut1::Ok>,
F: FnOnce(Fut1::Error) -> Fut2,
[src]
impl<Fut1, Fut2, F> Future for OrElse<Fut1, Fut2, F> where
Fut1: TryFuture,
Fut2: TryFuture<Ok = Fut1::Ok>,
F: FnOnce(Fut1::Error) -> Fut2,
type Output = Result<Fut2::Ok, Fut2::Error>
🔬 This is a nightly-only experimental API. (futures_api
)
futures in libcore are unstable
The result of the Future
.
fn poll(self: PinMut<Self>, cx: &mut Context) -> Poll<Self::Output>
[src]
fn poll(self: PinMut<Self>, cx: &mut Context) -> Poll<Self::Output>
🔬 This is a nightly-only experimental API. (futures_api
)
futures in libcore are unstable
Attempt to resolve the future to a final value, registering the current task for wakeup if the value is not yet available. Read more