pub struct PricingContext {
pub quantity: u32,
pub customer_id: Option<Uuid>,
pub timestamp: DateTime<Utc>,
pub demand_level: Option<f64>,
pub inventory_level: Option<f64>,
pub existing_subscriptions: Vec<Uuid>,
}Expand description
Pricing context for complex calculations
Fields§
§quantity: u32§customer_id: Option<Uuid>§timestamp: DateTime<Utc>§demand_level: Option<f64>§inventory_level: Option<f64>§existing_subscriptions: Vec<Uuid>Trait Implementations§
Source§impl Clone for PricingContext
impl Clone for PricingContext
Source§fn clone(&self) -> PricingContext
fn clone(&self) -> PricingContext
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 moreAuto Trait Implementations§
impl Freeze for PricingContext
impl RefUnwindSafe for PricingContext
impl Send for PricingContext
impl Sync for PricingContext
impl Unpin for PricingContext
impl UnwindSafe for PricingContext
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