pub struct AmountWithBreakdown {
pub currency_code: String,
pub value: String,
pub breakdown: Option<AmountBreakdown>,
}
Fields§
§currency_code: String
The three-character ISO-4217 currency code that identifies the currency.
value: String
The value, which might be: An integer for currencies like JPY that are not typically fractional. A decimal fraction for currencies like TND that are subdivided into thousandths.
breakdown: Option<AmountBreakdown>
The breakdown of the amount. Breakdown provides details such as total item amount, total tax amount, shipping, handling, insurance, and discounts, if any.
Implementations§
source§impl AmountWithBreakdown
impl AmountWithBreakdown
pub fn new(currency_code: CurrencyCode, value: String) -> AmountWithBreakdown
pub fn breakdown(self, breakdown: AmountBreakdown) -> Self
Trait Implementations§
source§impl Clone for AmountWithBreakdown
impl Clone for AmountWithBreakdown
source§fn clone(&self) -> AmountWithBreakdown
fn clone(&self) -> AmountWithBreakdown
Returns a copy 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 AmountWithBreakdown
impl Debug for AmountWithBreakdown
source§impl Default for AmountWithBreakdown
impl Default for AmountWithBreakdown
source§fn default() -> AmountWithBreakdown
fn default() -> AmountWithBreakdown
Returns the “default value” for a type. Read more
source§impl<'de> Deserialize<'de> for AmountWithBreakdown
impl<'de> Deserialize<'de> for AmountWithBreakdown
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