pub struct Variant {
pub name: String,
pub kind: QuestionKind,
}Expand description
A variant in a OneOf question (enum variant).
Fields§
§name: StringVariant name for display (e.g., “Male”, “Female”, “Other”).
kind: QuestionKindWhat to collect for this variant.
- Unit for unit variants (no data)
- Input for newtype variants with String
- AllOf for struct variants
- OneOf for nested enums
Implementations§
Trait Implementations§
impl StructuralPartialEq for Variant
Auto Trait Implementations§
impl Freeze for Variant
impl RefUnwindSafe for Variant
impl Send for Variant
impl Sync for Variant
impl Unpin for Variant
impl UnwindSafe for Variant
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