private function between(\DateTime $time, DateTimeFormatInterface $start, DateTimeFormatInterface $end)
    {
        return $this->after($time, $start) && $this->before($time, $end);
    }
private function between(\DateTime $time, DateTimeFormatInterface $start, DateTimeFormatInterface $end)
    {
        return $this->after($time, $start) && $this->before($time, $end);
    }
private function between ( \ DateTime $ time , DateTimeFormatInterface $ start , DateTimeFormatInterface $ end ) { return $ this -> after ( $ time , $ start ) && $ this -> before ( $ time , $ end ) ; }
Return if a time is between a start and end time.

@param \DateTime               $time
@param DateTimeFormatInterface $start
@param DateTimeFormatInterface $end

@return bool
Return if a time is between a start and end time .