public void UpdateBuyNowPrice(BuyNowPrice newPrice) { if (newPrice == 0m && BuyNowOnly) { throw new DomainException("Cannot set buy now price to 0 if auction is buyNowOnly"); } if (newPrice.Equals(BuyNowPrice)) { return; } BuyNowPrice = newPrice; AddUpdateEvent(new AuctionBuyNowPriceChanged(AggregateId, newPrice, Owner)); }
public Builder SetBuyNow(BuyNowPrice buyNowPrice) { args.BuyNowPrice = buyNowPrice; return(this); }