public boolean checkForDoubleBooking(Room room, Date checkInDate, Date checkOutDate) {
        boolean doubleBooking = false;
        int i = 0;
        while (doubleBooking == false && i < bookingList.size()) {
            if ((bookingList.get(i).getRoomNo() == room.getRoomNo())) {
                Date bookingStartDate = bookingList.get(i).getCheckInDate();
                Date bookingEndDate = bookingList.get(i).getCheckOutDate();
                if ((checkInDate.before(bookingStartDate) && checkOutDate.before(bookingStartDate))
                        || (checkInDate.after(bookingEndDate) && checkOutDate.after(bookingEndDate))
                        || checkInDate.equals(bookingEndDate) || checkOutDate.equals(bookingStartDate)) {       // Her checkes alle mulige kombinationer, hvorpå rummet kan være optaget.
                    doubleBooking = false;
                }
                else {
                    doubleBooking = true;
                }
            }
            i++;
        }
        return doubleBooking;
    }