pub struct RuntimeBuilder { /* private fields */ }Expand description
Implementations§
Source§impl RuntimeBuilder
impl RuntimeBuilder
Sourcepub fn worker_threads(self, count: usize) -> Self
pub fn worker_threads(self, count: usize) -> Self
Set the number of worker threads 设置工作线程数量
Sourcepub fn queue_size(self, size: usize) -> Self
pub fn queue_size(self, size: usize) -> Self
Set the queue size for the scheduler 设置调度器的队列大小
Sourcepub fn thread_name(self, name: impl Into<String>) -> Self
pub fn thread_name(self, name: impl Into<String>) -> Self
Set the thread name pattern 设置线程名称模式
Sourcepub fn driver_type(self, driver_type: DriverType) -> Self
pub fn driver_type(self, driver_type: DriverType) -> Self
Set the driver type 设置driver类型
Sourcepub fn io_entries(self, entries: u32) -> Self
pub fn io_entries(self, entries: u32) -> Self
Set the I/O driver queue depth 设置I/O驱动队列深度
Sourcepub fn enable_parking(self, enable: bool) -> Self
pub fn enable_parking(self, enable: bool) -> Self
Enable or disable thread parking 启用或禁用线程休眠
Sourcepub fn park_timeout(self, timeout: Duration) -> Self
pub fn park_timeout(self, timeout: Duration) -> Self
Set the park timeout 设置休眠超时
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RuntimeBuilder
impl RefUnwindSafe for RuntimeBuilder
impl Send for RuntimeBuilder
impl Sync for RuntimeBuilder
impl Unpin for RuntimeBuilder
impl UnsafeUnpin for RuntimeBuilder
impl UnwindSafe for RuntimeBuilder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more