Struct futures::executor::JoinHandle [−][src]
#[must_use]pub struct JoinHandle<T> { /* fields omitted */ }
The type of future returned from the ThreadPool::spawn
function, which
proxies the futures running on the thread pool.
This future will resolve in the same way as the underlying future, and it will propagate panics.
Methods
impl<T> JoinHandle<T>
[src]
impl<T> JoinHandle<T>
pub fn forget(self)
[src]
pub fn forget(self)
Drop this handle without canceling the underlying future.
When JoinHandle
is dropped, ThreadPool
will try to abort the associated
task. This function can be used when you want to drop the handle but keep
executing the task.
Trait Implementations
impl<T> Debug for JoinHandle<T> where
T: Debug,
[src]
impl<T> Debug for JoinHandle<T> where
T: Debug,
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
[src]
fn fmt(&self, f: &mut Formatter) -> Result<(), Error>
Formats the value using the given formatter. Read more
impl<T> Future for JoinHandle<T> where
T: 'static + Send,
[src]
impl<T> Future for JoinHandle<T> where
T: 'static + Send,
type Output = T
🔬 This is a nightly-only experimental API. (futures_api
)
futures in libcore are unstable
The result of the Future
.
fn poll(self: PinMut<JoinHandle<T>>, cx: &mut Context) -> Poll<T>
[src]
fn poll(self: PinMut<JoinHandle<T>>, cx: &mut Context) -> Poll<T>
🔬 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
Auto Trait Implementations
impl<T> Send for JoinHandle<T> where
T: Send,
impl<T> Send for JoinHandle<T> where
T: Send,
impl<T> Sync for JoinHandle<T> where
T: Send,
impl<T> Sync for JoinHandle<T> where
T: Send,