public void UpdateBy(PricingPolicy policy) { MinimumCharge = policy.MinimumCharge; MaximumCharge = policy.MaximumCharge; FixedCharge = policy.FixedCharge; AdditionalPrice = policy.AdditionalPrice; MaxItemCountInFixedPrice = policy.MaxItemCountInFixedPrice; }
public void SetPricingPolicy(PricingPolicy policy) { CheckRule(new PricingPolicyMustBeValidRule(policy)); if (PricingPolicy == null) { PricingPolicy = policy; } else { PricingPolicy.UpdateBy(policy); } }