Enum HostFrame
pub enum HostFrame {
Event(Event),
Command(Command),
}Expand description
Phase CPD-1 (cross-process dispatch) — envelope enum for frames
sent over the launcher → host pipe direction. Today the host’s
read loop only expects Event JSON; CPD-2 extends the read loop
to recognize this tagged union and dispatch by kind:
event→ existing event-handling code (state sync from launcher reducer broadcasts).command→ new command-handling code (saga-issued actions).
Newline-delimited JSON, one frame per line. #[serde(tag = "kind", rename_all = "snake_case")] so the wire shape is e.g.
{"kind":"event","event":"pool_window_added",...} or
{"kind":"command","cmd":"spawn_pool_window","saga_id":42}.
Schema-only in CPD-1: introduced now so the launcher’s host-pipe writer (CPD-2) and the host’s read loop (CPD-2/CPD-3) can be built against a stable wire envelope without further schema churn.
Variants§
Event(Event)
Wraps a launcher-emitted Event being pushed down to the host (existing fanout path; CPD-2 refactors the writer to go through this envelope).
Command(Command)
Wraps a saga-issued Command being dispatched from the launcher
to the host. Carries saga_id inside the Command payload.
Trait Implementations§
§impl<'de> Deserialize<'de> for HostFrame
impl<'de> Deserialize<'de> for HostFrame
§fn deserialize<__D>(
__deserializer: __D,
) -> Result<HostFrame, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<HostFrame, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
§impl Serialize for HostFrame
impl Serialize for HostFrame
§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for HostFrame
impl RefUnwindSafe for HostFrame
impl Send for HostFrame
impl Sync for HostFrame
impl Unpin for HostFrame
impl UnsafeUnpin for HostFrame
impl UnwindSafe for HostFrame
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.