示例#1
0
        private ScreeningReservation ScreeningReservationById(ScreeningId screeningId)
        {
            var history = _eventStore.Search(@by: $"ScreeningId = {screeningId}");
            var state   = new ScreeningReservationState(history);

            return(new(state));
        }
 protected bool Equals(ScreeningPlanned other)
 {
     return(ScreeningId.Equals(other.ScreeningId) && Seats.SequenceEqual(other.Seats));
 }
示例#3
0
 protected bool Equals(SeatsReserved other)
 {
     return(ScreeningId.Equals(other.ScreeningId) &&
            CustomerId.Equals(other.CustomerId) &&
            SeatIds.SequenceEqual(other.SeatIds));
 }
示例#4
0
 public ScreeningInfo(ScreeningId screeningId, IReadOnlyList <SeatNumber> allSeats)
 {
     ScreeningId     = screeningId;
     AllSeats        = allSeats.ToList();
     _availableSeats = allSeats.ToList();
 }
 protected bool Equals(SeatsReservationRequestedTooLate other)
 {
     return(ScreeningId.Equals(other.ScreeningId) &&
            CustomerId.Equals(other.CustomerId) &&
            Seats.SequenceEqual(other.Seats));
 }
示例#6
0
 protected bool Equals(Reservation other)
 {
     return(ScreeningId.Equals(other.ScreeningId) && Seats.SequenceEqual(other.Seats));
 }
示例#7
0
 public ClientSeatReservationInfo(ScreeningId screeningId, SeatNumber seatNumber, DateTimeOffset reservedAt)
 {
     ScreeningId = screeningId;
     SeatNumber  = seatNumber;
     ReservedAt  = reservedAt;
 }
示例#8
0
 protected bool Equals(SeatsReservationFailed other)
 {
     return(ScreeningId.Equals(other.ScreeningId) &&
            CustomerId.Equals(other.CustomerId) &&
            AlreadyReservedSeats.SequenceEqual(other.AlreadyReservedSeats));
 }