/** * Find bookings for given room and dates. * * @param Booking $booking * The booking to get data from. * @param boolean $validated * Only check for validated bookings if true. * * @return array * All bookings for given room and dates. */ public function findExisting(Booking $booking, $validated = true) { return $this->findExistingExplicit($booking->getRoom(), $booking->getFromDate(), $booking->getToDate(), $validated, array($booking->getId())); }