Struct async_global_executor::GlobalExecutorConfig [−][src]
Configuration to init the thread pool for the multi-threaded global executor.
Fields
env_var: Option<&'static str>
The environment variable from which we’ll try to parse the number of threads to spawn.
default_threads: Option<usize>
The default number of threads to spawn.
thread_name: Option<String>
The name to us fo the threads.
thread_name_prefix: Option<&'static str>
The prefix used to name the threads.
Implementations
impl GlobalExecutorConfig
[src]
pub fn with_env_var(self, env_var: &'static str) -> Self
[src]
Use the specified environment variable to find the number of threads to spawn.
pub fn with_default_threads(self, default_threads: usize) -> Self
[src]
Use the specified value as the default number of threads.
pub fn with_thread_name(self, thread_name: String) -> Self
[src]
Use the specified prefix to name the threads.
pub fn with_thread_name_prefix(self, thread_name_prefix: &'static str) -> Self
[src]
Use the specified prefix to name the threads.
Trait Implementations
impl Debug for GlobalExecutorConfig
[src]
impl Default for GlobalExecutorConfig
[src]
fn default() -> GlobalExecutorConfig
[src]
Auto Trait Implementations
impl RefUnwindSafe for GlobalExecutorConfig
impl Send for GlobalExecutorConfig
impl Sync for GlobalExecutorConfig
impl Unpin for GlobalExecutorConfig
impl UnwindSafe for GlobalExecutorConfig
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,