Struct serde_dynamo::number_set::NumberSet
source · pub struct NumberSet<T>(pub T);
Expand description
Serializes the wrapped value as a number set
This is useful for to_attribute_value
when you want to serialize a sequence as a set of numbers.
§Examples
use serde_dynamo::{number_set::NumberSet, AttributeValue};
let set = vec![
1432,
5342,
];
let val: AttributeValue = serde_dynamo::to_attribute_value(NumberSet(set)).unwrap();
assert_eq!(val, AttributeValue::Ns(vec![
"1432".to_string(),
"5342".to_string(),
]));
Tuple Fields§
§0: T
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for NumberSet<T>where
T: Freeze,
impl<T> RefUnwindSafe for NumberSet<T>where
T: RefUnwindSafe,
impl<T> Send for NumberSet<T>where
T: Send,
impl<T> Sync for NumberSet<T>where
T: Sync,
impl<T> Unpin for NumberSet<T>where
T: Unpin,
impl<T> UnwindSafe for NumberSet<T>where
T: UnwindSafe,
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Creates a shared type from an unshared type.
Creates a shared type from an unshared type.
Creates a shared type from an unshared type.
Creates a shared type from an unshared type.