Expand description
§Callable Once Types
Provides fallible, one-time, zero-argument computations.
A CallableOnce<R, E> is equivalent to FnOnce() -> Result<R, E>, but uses
task-oriented vocabulary. Use it when the operation is a computation or task
whose success value matters. Use RunnableOnce<E> when the operation only
needs to report success or failure.
The trait itself does not require Send; concurrent executors should add
+ Send + 'static at their API boundary.
§Author
Haixing Hu
Structs§
- BoxCallable
Once - Box-based one-time callable.
Traits§
- Callable
Once - A fallible one-time computation.