pub trait ReflectTaskIntrospection {
// Required methods
fn reflect_task(&self, task_id: &str) -> Option<&(dyn Reflect + 'static)>;
fn reflect_task_mut(
&mut self,
task_id: &str,
) -> Option<&mut (dyn Reflect + 'static)>;
// Provided methods
fn register_reflect_types(_registry: &mut TypeRegistry) { ... }
fn debug_state_type_path(_task_id: &str) -> Option<&'static str> { ... }
fn with_debug_state<R>(
&self,
_task_id: &str,
_f: impl FnOnce(&(dyn Reflect + 'static)) -> R,
) -> Option<R> { ... }
}Expand description
Runtime task-reflect contract exposed by generated Copper applications.
Required Methods§
Sourcefn reflect_task(&self, task_id: &str) -> Option<&(dyn Reflect + 'static)>
fn reflect_task(&self, task_id: &str) -> Option<&(dyn Reflect + 'static)>
Returns a reflected immutable task instance for the given task id.
Sourcefn reflect_task_mut(
&mut self,
task_id: &str,
) -> Option<&mut (dyn Reflect + 'static)>
fn reflect_task_mut( &mut self, task_id: &str, ) -> Option<&mut (dyn Reflect + 'static)>
Returns a reflected mutable task instance for the given task id.
Provided Methods§
Sourcefn register_reflect_types(_registry: &mut TypeRegistry)
fn register_reflect_types(_registry: &mut TypeRegistry)
Registers reflected schema types for this mission’s app (tasks, messages, bridges).
Sourcefn debug_state_type_path(_task_id: &str) -> Option<&'static str>
fn debug_state_type_path(_task_id: &str) -> Option<&'static str>
Returns the reflected type path used as the task’s debug-state schema.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".