pub struct NoSkipLabeledPrice {
pub label: String,
pub amount: i64,
}Expand description
Companion type to LabeledPrice that doesn’t skip fields when serializing. Used for certain deserializers that use arrays to represent struct members
Fields§
§label: StringPortion label
amount: i64Price of the product in the smallest units of the currency (integer, not float/double). For example, for a price of US$ 1.45 pass amount = 145. See the exp parameter in currencies.json, it shows the number of digits past the decimal point for each currency (2 for the majority of currencies).
Implementations§
Source§impl NoSkipLabeledPrice
impl NoSkipLabeledPrice
pub fn skip(self) -> LabeledPrice
Trait Implementations§
Source§impl Clone for NoSkipLabeledPrice
impl Clone for NoSkipLabeledPrice
Source§fn clone(&self) -> NoSkipLabeledPrice
fn clone(&self) -> NoSkipLabeledPrice
Returns a duplicate of the value. Read more
1.0.0 · 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 NoSkipLabeledPrice
impl Debug for NoSkipLabeledPrice
Source§impl Default for NoSkipLabeledPrice
impl Default for NoSkipLabeledPrice
Source§fn default() -> NoSkipLabeledPrice
fn default() -> NoSkipLabeledPrice
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for NoSkipLabeledPrice
impl<'de> Deserialize<'de> for NoSkipLabeledPrice
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
Source§impl From<NoSkipLabeledPrice> for LabeledPrice
impl From<NoSkipLabeledPrice> for LabeledPrice
Source§fn from(t: NoSkipLabeledPrice) -> Self
fn from(t: NoSkipLabeledPrice) -> Self
Converts to this type from the input type.
Source§impl Hash for NoSkipLabeledPrice
impl Hash for NoSkipLabeledPrice
Source§impl Into<NoSkipLabeledPrice> for LabeledPrice
impl Into<NoSkipLabeledPrice> for LabeledPrice
Source§fn into(self) -> NoSkipLabeledPrice
fn into(self) -> NoSkipLabeledPrice
Converts this type into the (usually inferred) input type.
Source§impl Ord for NoSkipLabeledPrice
impl Ord for NoSkipLabeledPrice
Source§fn cmp(&self, other: &NoSkipLabeledPrice) -> Ordering
fn cmp(&self, other: &NoSkipLabeledPrice) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for NoSkipLabeledPrice
impl PartialEq for NoSkipLabeledPrice
Source§impl PartialOrd for NoSkipLabeledPrice
impl PartialOrd for NoSkipLabeledPrice
Source§impl Serialize for NoSkipLabeledPrice
impl Serialize for NoSkipLabeledPrice
impl Eq for NoSkipLabeledPrice
impl StructuralPartialEq for NoSkipLabeledPrice
Auto Trait Implementations§
impl Freeze for NoSkipLabeledPrice
impl RefUnwindSafe for NoSkipLabeledPrice
impl Send for NoSkipLabeledPrice
impl Sync for NoSkipLabeledPrice
impl Unpin for NoSkipLabeledPrice
impl UnsafeUnpin for NoSkipLabeledPrice
impl UnwindSafe for NoSkipLabeledPrice
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.