Struct flutter_rust_bridge::handler::ThreadPoolExecutor
source · [−]pub struct ThreadPoolExecutor<EH: ErrorHandler> { /* private fields */ }Expand description
The default executor used. It creates an internal thread pool, and each call to a Rust function is handled by a different thread.
Implementations
sourceimpl<EH: ErrorHandler> ThreadPoolExecutor<EH>
impl<EH: ErrorHandler> ThreadPoolExecutor<EH>
Trait Implementations
sourceimpl<EH: ErrorHandler> Executor for ThreadPoolExecutor<EH>
impl<EH: ErrorHandler> Executor for ThreadPoolExecutor<EH>
sourcefn execute<TaskFn, TaskRet>(&self, wrap_info: WrapInfo, task: TaskFn)where
TaskFn: FnOnce(TaskCallback) -> Result<TaskRet> + Send + UnwindSafe + 'static,
TaskRet: IntoDart,
fn execute<TaskFn, TaskRet>(&self, wrap_info: WrapInfo, task: TaskFn)where
TaskFn: FnOnce(TaskCallback) -> Result<TaskRet> + Send + UnwindSafe + 'static,
TaskRet: IntoDart,
sourcefn execute_sync<SyncTaskFn, TaskRet>(
&self,
_wrap_info: WrapInfo,
sync_task: SyncTaskFn
) -> Result<SyncReturn<TaskRet>>where
WireSyncReturnData: From<TaskRet>,
SyncTaskFn: FnOnce() -> Result<SyncReturn<TaskRet>> + UnwindSafe,
fn execute_sync<SyncTaskFn, TaskRet>(
&self,
_wrap_info: WrapInfo,
sync_task: SyncTaskFn
) -> Result<SyncReturn<TaskRet>>where
WireSyncReturnData: From<TaskRet>,
SyncTaskFn: FnOnce() -> Result<SyncReturn<TaskRet>> + UnwindSafe,
Executes a Rust function that returns a SyncReturn.
Auto Trait Implementations
impl<EH> RefUnwindSafe for ThreadPoolExecutor<EH>
impl<EH> Send for ThreadPoolExecutor<EH>
impl<EH> Sync for ThreadPoolExecutor<EH>where
EH: Sync,
impl<EH> Unpin for ThreadPoolExecutor<EH>where
EH: Unpin,
impl<EH> UnwindSafe for ThreadPoolExecutor<EH>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more