#[non_exhaustive]pub enum SerializeVariantContent {
Omitted,
Fields(Vec<SerializeFieldShape>),
Shape(ShapeRef),
Custom(OpaqueShape),
}Expand description
The serialized content controlled by an enum variant.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Omitted
The variant is omitted during serialization.
Fields(Vec<SerializeFieldShape>)
Serde derives the variant content from these fields.
Shape(ShapeRef)
A serde_shape hook supplies the content shape inside the enum’s tagging representation.
Custom(OpaqueShape)
A custom serializer controls the variant content.
Trait Implementations§
Source§impl Clone for SerializeVariantContent
impl Clone for SerializeVariantContent
Source§fn clone(&self) -> SerializeVariantContent
fn clone(&self) -> SerializeVariantContent
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SerializeVariantContent
impl Debug for SerializeVariantContent
impl Eq for SerializeVariantContent
Source§impl PartialEq for SerializeVariantContent
impl PartialEq for SerializeVariantContent
impl StructuralPartialEq for SerializeVariantContent
Auto Trait Implementations§
impl Freeze for SerializeVariantContent
impl RefUnwindSafe for SerializeVariantContent
impl Send for SerializeVariantContent
impl Sync for SerializeVariantContent
impl Unpin for SerializeVariantContent
impl UnsafeUnpin for SerializeVariantContent
impl UnwindSafe for SerializeVariantContent
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