submit

Function submit 

Source
pub fn submit<F: FnOnce() + Send + 'static>(f: F)
Expand description

Submit the closure to the default thread pool.

  • The closure must have 'static lifetime as the thread may outlive the lifetime in which submit is called.
  • The closure must be Send as it will be sent to another thread for execution.