Enum TaskWeight
pub enum TaskWeight {
Highest = 10_000,
High = 1_000,
Middle = 100,
Low = 10,
Lowest = 1,
}Expand description
@public 概率调度的档位权重,不表示严格执行顺序。 仅影响排队后的选择;并发档位的有效权重是数量提示乘以本档权重。 快速交接不比较档位,低权重任务也可能先于已排队的高权重任务执行。
Variants§
Highest = 10_000
最高档,单位提示权重为 10000。
High = 1_000
高档,单位提示权重为 1000。
Middle = 100
中档,单位提示权重为 100;串行队列的每个压缩数量档也使用此权重。
Low = 10
低档,单位提示权重为 10。
Lowest = 1
最低档,单位提示权重为 1。
Trait Implementations§
Source§impl Clone for TaskWeight
impl Clone for TaskWeight
Source§fn clone(&self) -> TaskWeight
fn clone(&self) -> TaskWeight
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TaskWeight
Source§impl Debug for TaskWeight
impl Debug for TaskWeight
impl Eq for TaskWeight
Source§impl PartialEq for TaskWeight
impl PartialEq for TaskWeight
impl StructuralPartialEq for TaskWeight
Auto Trait Implementations§
impl Forget for TaskWeight
impl Freeze for TaskWeight
impl Move for TaskWeight
impl RefUnwindSafe for TaskWeight
impl Send for TaskWeight
impl Sync for TaskWeight
impl Unpin for TaskWeight
impl UnsafeUnpin for TaskWeight
impl UnwindSafe for TaskWeight
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