struct VariantAccessImpl<'a> {
value: &'a Value,
}Fields§
§value: &'a ValueTrait Implementations§
Source§impl<'de, 'a> VariantAccess<'de> for VariantAccessImpl<'a>
impl<'de, 'a> VariantAccess<'de> for VariantAccessImpl<'a>
Source§type Error = Error
type Error = Error
The error type that can be returned if some error occurs during
deserialization. Must match the error type of our
EnumAccess.Source§fn unit_variant(self) -> Result<(), Error>
fn unit_variant(self) -> Result<(), Error>
Called when deserializing a variant with no values. Read more
Source§fn newtype_variant_seed<T: DeserializeSeed<'de>>(
self,
seed: T,
) -> Result<T::Value, Error>
fn newtype_variant_seed<T: DeserializeSeed<'de>>( self, seed: T, ) -> Result<T::Value, Error>
Called when deserializing a variant with a single value. Read more
Source§fn tuple_variant<V: Visitor<'de>>(
self,
_len: usize,
visitor: V,
) -> Result<V::Value, Error>
fn tuple_variant<V: Visitor<'de>>( self, _len: usize, visitor: V, ) -> Result<V::Value, Error>
Called when deserializing a tuple-like variant. Read more
Source§fn struct_variant<V: Visitor<'de>>(
self,
_fields: &'static [&'static str],
visitor: V,
) -> Result<V::Value, Error>
fn struct_variant<V: Visitor<'de>>( self, _fields: &'static [&'static str], visitor: V, ) -> Result<V::Value, Error>
Called when deserializing a struct-like variant. Read more
Source§fn newtype_variant<T>(self) -> Result<T, Self::Error>where
T: Deserialize<'de>,
fn newtype_variant<T>(self) -> Result<T, Self::Error>where
T: Deserialize<'de>,
Called when deserializing a variant with a single value. Read more
Auto Trait Implementations§
impl<'a> Freeze for VariantAccessImpl<'a>
impl<'a> RefUnwindSafe for VariantAccessImpl<'a>
impl<'a> Send for VariantAccessImpl<'a>
impl<'a> Sync for VariantAccessImpl<'a>
impl<'a> Unpin for VariantAccessImpl<'a>
impl<'a> UnsafeUnpin for VariantAccessImpl<'a>
impl<'a> UnwindSafe for VariantAccessImpl<'a>
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