HostCtx

Trait HostCtx 

Source
pub trait HostCtx {
Show 15 methods // Required methods fn memory(&self) -> SharedMemory; fn module(&self) -> Module; fn interface(&self) -> SimulatorInterface; fn lcd(&self) -> Arc<Mutex<Lcd>>; fn lcd_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, Lcd>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn mutexes(&self) -> Arc<Mutex<MutexPool>>; fn mutexes_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, MutexPool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn tasks(&self) -> Arc<Mutex<TaskPool>>; fn tasks_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, TaskPool>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn start_time(&self) -> Instant; fn current_task<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = TaskHandle> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn controllers(&self) -> Arc<Mutex<Controllers>>; fn controllers_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, Controllers>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait; fn competition_phase(&self) -> Arc<Mutex<CompetitionPhase>>; fn competition_phase_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, CompetitionPhase>> + Send + 'async_trait>> where Self: 'async_trait, 'life0: 'async_trait;
}

Required Methods§

Source

fn memory(&self) -> SharedMemory

Source

fn module(&self) -> Module

Source

fn interface(&self) -> SimulatorInterface

Source

fn lcd(&self) -> Arc<Mutex<Lcd>>

Source

fn lcd_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, Lcd>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn mutexes(&self) -> Arc<Mutex<MutexPool>>

Source

fn mutexes_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, MutexPool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn tasks(&self) -> Arc<Mutex<TaskPool>>

Source

fn tasks_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, TaskPool>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn start_time(&self) -> Instant

Source

fn current_task<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = TaskHandle> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn controllers(&self) -> Arc<Mutex<Controllers>>

Source

fn controllers_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, Controllers>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn competition_phase(&self) -> Arc<Mutex<CompetitionPhase>>

Source

fn competition_phase_lock<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MutexGuard<'_, CompetitionPhase>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Implementors§

Source§

impl HostCtx for Host

Source§

impl<T> HostCtx for T
where T: AsContext<Data = Host> + Sync,