pub struct Task<System>(_)
where
System: NotSupportedYet;
Expand description
Represents a single task in a system.
This type is ABI-compatible with System::
RawTaskId
.
See TaskRef
for the borrowed counterpart.
See TaskMethods
for the operations provided by this handle
type.
Relation to Other Specifications: Present in almost every real-time operating system.
Task States
A task may be in one of the following states:
-
Dormant — The task is not executing, doesn’t have an associated execution thread, and can be activated.
-
Ready — The task has an associated execution thread, which is ready to be scheduled to the CPU
-
Running — The task has an associated execution thread, which is currently scheduled to the CPU
-
Waiting — The task has an associated execution thread, which is currently blocked by a blocking operation
Trait Implementations§
source§impl<System> PartialEq<Task<System>> for Task<System>where
System: NotSupportedYet,
impl<System> PartialEq<Task<System>> for Task<System>where System: NotSupportedYet,
source§impl<System> PartialEq<Task<System>> for TaskRef<'_, System>where
System: NotSupportedYet,
impl<System> PartialEq<Task<System>> for TaskRef<'_, System>where System: NotSupportedYet,
source§impl<System> PartialEq<TaskRef<'_, System>> for Task<System>where
System: NotSupportedYet,
impl<System> PartialEq<TaskRef<'_, System>> for Task<System>where System: NotSupportedYet,
source§impl<System> TaskHandle for Task<System>where
System: NotSupportedYet,
impl<System> TaskHandle for Task<System>where System: NotSupportedYet,
impl<System> Eq for Task<System>where System: NotSupportedYet,
Auto Trait Implementations§
impl<System> RefUnwindSafe for Task<System>where <System as KernelBase>::RawTaskId: RefUnwindSafe,
impl<System> Send for Task<System>
impl<System> Sync for Task<System>
impl<System> Unpin for Task<System>where <System as KernelBase>::RawTaskId: Unpin,
impl<System> UnwindSafe for Task<System>where <System as KernelBase>::RawTaskId: UnwindSafe,
Blanket Implementations§
source§impl<T> TaskMethods for Twhere
T: TaskHandle,
impl<T> TaskMethods for Twhere T: TaskHandle,
source§fn interrupt(&self) -> Result<(), InterruptTaskError>
fn interrupt(&self) -> Result<(), InterruptTaskError>
Interrupt any ongoing wait operations undertaken by the task. Read more
source§fn unpark(&self) -> Result<(), UnparkError>
fn unpark(&self) -> Result<(), UnparkError>
Make the task’s token available, unblocking
Kernel::park
now or in
the future. Read moresource§fn unpark_exact(&self) -> Result<(), UnparkExactError>
fn unpark_exact(&self) -> Result<(), UnparkExactError>
Make exactly one new token available for the task, unblocking
Kernel::park
now or in the future. Read moresource§fn set_priority(&self, priority: usize) -> Result<(), SetTaskPriorityError>where
Self::System: KernelTaskSetPriority,
fn set_priority(&self, priority: usize) -> Result<(), SetTaskPriorityError>where Self::System: KernelTaskSetPriority,
Set the task’s base priority. Read more
source§fn priority(&self) -> Result<usize, GetTaskPriorityError>
fn priority(&self) -> Result<usize, GetTaskPriorityError>
Get the task’s base priority. Read more
source§fn effective_priority(&self) -> Result<usize, GetTaskPriorityError>
fn effective_priority(&self) -> Result<usize, GetTaskPriorityError>
Get the task’s effective priority. Read more