Struct eventual::BusySender
[−]
[src]
pub struct BusySender<T: Send + 'static, E: Send + 'static> { /* fields omitted */ }
Trait Implementations
impl<T: Send + 'static, E: Send + 'static> Async for BusySender<T, E>
[src]
type Value = Sender<T, E>
type Error = ()
type Cancel = Receipt<BusySender<T, E>>
fn is_ready(&self) -> bool
Returns true if expect
will succeed.
fn is_err(&self) -> bool
Returns true if the async value is ready and has failed
fn poll(self) -> Result<AsyncResult<Sender<T, E>, ()>, BusySender<T, E>>
Get the underlying value if present
fn ready<F: FnOnce(BusySender<T, E>) + Send + 'static>(
self,
f: F
) -> Receipt<BusySender<T, E>>
self,
f: F
) -> Receipt<BusySender<T, E>>
Invokes the given function when the Async instance is ready to be consumed. Read more
fn expect(self) -> AsyncResult<Self::Value, Self::Error>
Get the underlying value if present, panic otherwise
fn receive<F>(self, f: F) where
F: FnOnce(AsyncResult<Self::Value, Self::Error>) + Send + 'static,
F: FnOnce(AsyncResult<Self::Value, Self::Error>) + Send + 'static,
Invoke the callback with the resolved Async
result.
fn await(self) -> AsyncResult<Self::Value, Self::Error>
Blocks the thread until the async value is complete and returns the result. Read more
fn fire(self)
Trigger the computation without waiting for the result
fn and<U: Async<Error = Self::Error>>(
self,
next: U
) -> Future<U::Value, Self::Error>
self,
next: U
) -> Future<U::Value, Self::Error>
This method returns a future whose completion value depends on the completion value of the original future. Read more
fn and_then<F, U: Async<Error = Self::Error>>(
self,
f: F
) -> Future<U::Value, Self::Error> where
F: FnOnce(Self::Value) -> U + Send + 'static,
U::Value: Send + 'static,
self,
f: F
) -> Future<U::Value, Self::Error> where
F: FnOnce(Self::Value) -> U + Send + 'static,
U::Value: Send + 'static,
This method returns a future whose completion value depends on the completion value of the original future. Read more
fn or<A>(self, alt: A) -> Future<Self::Value, A::Error> where
A: Async<Value = Self::Value>,
A: Async<Value = Self::Value>,
This method returns a future whose completion value depends on the completion value of the original future. Read more
fn or_else<F, A>(self, f: F) -> Future<Self::Value, A::Error> where
F: FnOnce(Self::Error) -> A + Send + 'static,
A: Async<Value = Self::Value>,
F: FnOnce(Self::Error) -> A + Send + 'static,
A: Async<Value = Self::Value>,
This method returns a future whose completion value depends on the completion value of the original future. Read more