pub trait ChildOccurrenceShape {
type Empty;
type Member<Occurrence, Child: Behavior, Tail>;
}Expand description
Downstream shape of one direct-child occurrence product.
Behavior owns the closed node algebra: a concrete Behavior leaf,
ChildChoice, or Never. A runtime owns the representation associated
with each leaf. Empty supplies its terminal representation and Member
receives one concrete child, its structural occurrence, and the remaining
child product.
This is a type-level derived construction. It creates no value, allocates
no actor, interprets no effect, and introduces no protocol identity or
runtime key. A shape that builds a heterogeneous product should retain
Tail; the product includes every declared child exactly once.
struct NoChildBindings;
struct ChildBinding<Position, Child, Tail>(core::marker::PhantomData<fn() -> (Position, Child, Tail)>);
struct RuntimeStorage;
impl behavior::ChildOccurrenceShape for RuntimeStorage {
type Empty = NoChildBindings;
type Member<Occurrence, Child: behavior::Behavior, Tail> =
ChildBinding<Occurrence, Child, Tail>;
}
type ChildBindings<Node> = behavior::ChildOccurrences<Node, RuntimeStorage>;Required Associated Types§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.