pub struct UnionArm {
pub name: String,
pub discriminant_value: u16,
pub description: String,
pub dispatch_mac: String,
pub dispatch_mac_present: bool,
pub dispatch_public: String,
pub dispatch_public_present: bool,
pub mutation_semantics: String,
pub mutation_semantics_present: bool,
pub payload: ArmPayload,
}Expand description
A single arm of a tagged union (one member of a capnp union { ... }).
Populated for pure-union structs so Rust codegen can emit a native enum
(one variant per arm) instead of an empty struct. The flat fields list on
StructDef still carries every union member (for the TS/wire-format path);
union_arms is the structured view layered on top.
Fields§
§name: Stringcapnp arm name (camelCase, e.g. atLeastOnce).
discriminant_value: u16Union discriminant ordinal for this arm.
description: StringDescription from $paramDescription/$mcpDescription (may be empty).
dispatch_mac: String$dispatchMac metadata carried by a pure-union arm.
dispatch_mac_present: bool§dispatch_public: String$dispatchPublic metadata carried by a pure-union arm.
dispatch_public_present: bool§mutation_semantics: String$mutationSemantics metadata carried by a pure-union arm.
mutation_semantics_present: bool§payload: ArmPayloadThe payload this arm carries.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for UnionArm
impl<'de> Deserialize<'de> for UnionArm
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for UnionArm
impl RefUnwindSafe for UnionArm
impl Send for UnionArm
impl Sync for UnionArm
impl Unpin for UnionArm
impl UnsafeUnpin for UnionArm
impl UnwindSafe for UnionArm
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
Mutably borrows from an owned value. Read more