pub struct Surcharge {
pub meta: Bo4eMeta,
pub description: Option<String>,
pub surcharge_type: Option<SurchargeType>,
pub value: Option<f64>,
pub currency: Option<Currency>,
pub target: Option<SurchargeTarget>,
pub tiers: Vec<PriceTier>,
pub details: Option<String>,
pub website: Option<String>,
}Expand description
A surcharge or discount applied to a price.
German: AufAbschlag
§Example
use bo4e_core::com::Surcharge;
let surcharge = Surcharge {
description: Some("Ökosteuer".to_string()),
value: Some(0.02),
..Default::default()
};Fields§
§meta: Bo4eMetaBO4E metadata
description: Option<String>Name/designation of the surcharge (Bezeichnung)
surcharge_type: Option<SurchargeType>Type of surcharge (AufAbschlagstyp)
value: Option<f64>Value of the surcharge (Wert) Positive = surcharge, negative = discount
currency: Option<Currency>Currency unit for absolute surcharges (Waehrungseinheit)
target: Option<SurchargeTarget>Target price/cost category (AufAbschlagsziel)
tiers: Vec<PriceTier>Tiered surcharge values (Staffeln)
details: Option<String>Additional description (Beschreibung)
website: Option<String>Website for published information (Website)
Trait Implementations§
Source§impl Bo4eObject for Surcharge
impl Bo4eObject for Surcharge
Source§fn type_name_german() -> &'static str
fn type_name_german() -> &'static str
Returns the German type name as used in the
_typ field. Read moreSource§fn type_name_english() -> &'static str
fn type_name_english() -> &'static str
Returns the English type name. Read more
Source§impl<'de> Deserialize<'de> for Surcharge
impl<'de> Deserialize<'de> for Surcharge
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
impl StructuralPartialEq for Surcharge
Auto Trait Implementations§
impl Freeze for Surcharge
impl RefUnwindSafe for Surcharge
impl Send for Surcharge
impl Sync for Surcharge
impl Unpin for Surcharge
impl UnwindSafe for Surcharge
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