changes
This commit is contained in:
@@ -34,7 +34,7 @@ public abstract class Reservation implements IReservation{
|
||||
|
||||
private Float price;
|
||||
|
||||
protected String accountNumber = null;
|
||||
protected String accountNumber = "-99";
|
||||
|
||||
protected Reservation() {
|
||||
numberOfBeds = 1;
|
||||
|
||||
@@ -43,9 +43,6 @@ public final class CabinReservation extends Reservation {
|
||||
if (getPhysical_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, physical_address %s", this.getReservation_number()));
|
||||
}
|
||||
if (getMailing_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, mailing_address: %s", this.getReservation_number()));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -65,9 +65,6 @@ public final class HotelReservation extends Reservation {
|
||||
if (getPhysical_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, physical_address %s", this.getReservation_number()));
|
||||
}
|
||||
if (getMailing_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, mailing_address: %s", this.getReservation_number()));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -53,9 +53,6 @@ public final class HouseReservation extends Reservation {
|
||||
if (getPhysical_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, physical_address %s", this.getReservation_number()));
|
||||
}
|
||||
if (getMailing_address() == null) {
|
||||
throw new IllegalArgumentException(String.format("not valid, mailing_address: %s", this.getReservation_number()));
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user