Example #1
0
        public void InsertBid(Bid Bid)
        {
            if (Bid == null)
                throw new ArgumentNullException("Bid");

            var auction = _auctionService.GetAuctionById(Bid.AuctionId);
            if (Bid.Amount > _auctionService.GetHighestBidForAuction(auction).Amount)
            {
                _bidService.InsertBid(Bid);
            }
            else
            {
                throw new Exception("Bid amount too low.");
            }

            _eventPublisher.EntityInserted(Bid);
        }
Example #2
0
 public void UpdateBid(Bid Bid)
 {
     throw new NotImplementedException();
 }