public void RemoveRental(RentalBase rental) { if (rentalList.Count > 0) { rentalList.Remove(rental); } else { throw new IndexOutOfRangeException(); } }
public void AddRental(RentalBase rental) { if (rentalList.Count < 5) { rentalList.Add(rental); } else { throw new IndexOutOfRangeException(); } }