[−][src]Struct glib::ThreadPool
Implementations
impl ThreadPool
[src]
pub fn new_shared(max_threads: Option<u32>) -> Result<Self, Error>
[src]
pub fn new_exclusive(max_threads: u32) -> Result<Self, Error>
[src]
pub fn push<F: FnOnce() + Send + 'static>(&self, func: F) -> Result<(), Error>
[src]
pub fn push_future<T: Send + 'static, F: FnOnce() -> T + Send + 'static>(
&self,
func: F
) -> Result<impl Future<Output = T>, Error>
[src]
&self,
func: F
) -> Result<impl Future<Output = T>, Error>
pub fn set_max_threads(&self, max_threads: Option<u32>) -> Result<(), Error>
[src]
pub fn get_max_threads(&self) -> Option<u32>
[src]
pub fn get_num_threads(&self) -> u32
[src]
pub fn get_unprocessed(&self) -> u32
[src]
pub fn set_max_unused_threads(max_threads: Option<u32>)
[src]
pub fn get_max_unused_threads() -> Option<u32>
[src]
pub fn get_num_unused_threads() -> u32
[src]
pub fn stop_unused_threads()
[src]
pub fn set_max_idle_time(max_idle_time: u32)
[src]
pub fn get_max_idle_time() -> u32
[src]
Trait Implementations
impl Debug for ThreadPool
[src]
impl Drop for ThreadPool
[src]
impl Send for ThreadPool
[src]
impl Sync for ThreadPool
[src]
Auto Trait Implementations
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,
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.
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>,