pub struct ChildTask { /* private fields */ }Expand description
A handle to a cFE child task.
This is a wrapper around a CFE-level task ID that will automatically call
CFE_ES_DeleteChildTask when it goes out of scope, preventing resource leaks.
It must not be used for an Application’s Main Task.
Implementations§
Source§impl ChildTask
impl ChildTask
Sourcepub fn new(
name: &str,
entry_point: TaskEntryPoint,
stack_ptr: *mut (),
stack_size: usize,
priority: u16,
flags: TaskFlags,
) -> Result<Self>
pub fn new( name: &str, entry_point: TaskEntryPoint, stack_ptr: *mut (), stack_size: usize, priority: u16, flags: TaskFlags, ) -> Result<Self>
Creates a new cFE child task and starts it running.
The new task is owned by the calling Application. The stack for the task can be provided or allocated from the system memory heap.
§Arguments
name: A unique string to identify the task.entry_point: The function that the new task will execute. This must be a free function withextern "C"linkage.stack_ptr: A pointer to the task’s stack, orcore::ptr::null_mut()to have cFE allocate it.stack_size: The size of the stack to allocate for the new task.priority: The priority of the new task (0=highest, 255=lowest).flags: Task creation flags (e.g.TaskFlags::FP_ENABLED).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ChildTask
impl RefUnwindSafe for ChildTask
impl Send for ChildTask
impl Sync for ChildTask
impl Unpin for ChildTask
impl UnsafeUnpin for ChildTask
impl UnwindSafe for ChildTask
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