Struct tokio::runtime::current_thread::TaskExecutor   [−][src]
pub struct TaskExecutor { /* fields omitted */ }Executes futures on the current thread.
All futures executed using this executor will be executed on the current
thread. As such, run will wait for these futures to complete before
returning.
For more details, see the module level documentation.
Methods
impl TaskExecutor[src] 
impl TaskExecutorpub fn current() -> TaskExecutor[src] 
pub fn current() -> TaskExecutorReturns an executor that executes futures on the current thread.
The user of TaskExecutor must ensure that when a future is submitted,
that it is done within the context of a call to run.
For more details, see the module level documentation.
pub fn spawn_local(
    &mut self, 
    future: Box<Future<Item = (), Error = ()> + 'static>
) -> Result<(), SpawnError>[src] 
pub fn spawn_local(
    &mut self, 
    future: Box<Future<Item = (), Error = ()> + 'static>
) -> Result<(), SpawnError>Spawn a future onto the current CurrentThread instance.
Trait Implementations
impl Clone for TaskExecutor[src] 
impl Clone for TaskExecutorfn clone(&self) -> TaskExecutor[src] 
fn clone(&self) -> TaskExecutorReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src] 
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl Debug for TaskExecutor[src] 
impl Debug for TaskExecutorfn 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 Executor for TaskExecutor[src] 
impl Executor for TaskExecutorfn spawn(
    &mut self, 
    future: Box<Future<Item = (), Error = ()> + 'static + Send>
) -> Result<(), SpawnError>[src] 
fn spawn(
    &mut self, 
    future: Box<Future<Item = (), Error = ()> + 'static + Send>
) -> Result<(), SpawnError>Spawns a future object to run on this executor. Read more
fn status(&self) -> Result<(), SpawnError>[src] 
fn status(&self) -> Result<(), SpawnError>Provides a best effort hint to whether or not spawn will succeed. Read more
impl<F> Executor<F> for TaskExecutor where
    F: Future<Item = (), Error = ()> + 'static, [src] 
impl<F> Executor<F> for TaskExecutor where
    F: Future<Item = (), Error = ()> + 'static, Auto Trait Implementations
impl !Send for TaskExecutor
impl !Send for TaskExecutorimpl !Sync for TaskExecutor
impl !Sync for TaskExecutor