[][src]Function desync::scheduler::future

pub fn future<TFn, Item: 'static + Send>(
    queue: &Arc<JobQueue>,
    job: TFn
) -> impl Future<Item = Item, Error = Canceled> + Send where
    TFn: 'static + Send + FnOnce() -> Item, 

Schedules a job to run and returns a future for retrieving the result