diff --git a/src/runtime2/component/component.rs b/src/runtime2/component/component.rs index 506699b8b80d90f0aa92e3164f83e04d1d606777..d50a9ef1a923719d29f2ab9e348e11c9e66117a9 100644 --- a/src/runtime2/component/component.rs +++ b/src/runtime2/component/component.rs @@ -18,6 +18,9 @@ pub enum CompScheduling { /// Generic representation of a component (as viewed by a scheduler). pub(crate) trait Component { + /// Called upon the creation of the component. + fn on_creation(&mut self, sched_ctx: &SchedulerCtx); + /// Called if the component is created by another component and the messages /// are being transferred between the two. fn adopt_message(&mut self, comp_ctx: &mut CompCtx, message: DataMessage);