[][src]Trait drone_cortexm::thr::prelude::ThrToken

pub unsafe trait ThrToken: Clone + Copy + Send + Sync + 'static + Token {
    type Thr: Thread;

    pub const THR_IDX: usize;
    pub fn to_thr(self) -> &'static Self::Thr { ... }
pub fn add_fib<F>(self, fib: F)
    where
        F: FiberRoot
, { ... }
pub fn is_empty(self) -> bool { ... } }

The base trait for a thread token.

Safety

ThrToken::THR_IDX must be a valid index in ThrToken::Thr's array returned by Thread::first method.

Associated Types

type Thr: Thread[src]

The thread type.

Loading content...

Associated Constants

pub const THR_IDX: usize[src]

Position of the thread inside ThrToken::Thr's array returned by Thread::first method.

Loading content...

Provided methods

pub fn to_thr(self) -> &'static Self::Thr[src]

Returns a reference to the thread object.

pub fn add_fib<F>(self, fib: F) where
    F: FiberRoot
[src]

Adds the fiber fib to the fiber chain.

pub fn is_empty(self) -> bool[src]

Returns true if the fiber chain is empty.

Loading content...

Implementors

Loading content...