public function getDuration()
    {
        if ($this->getEndDate()) {
            return $this->getEndDate()->getTimestamp() - $this->getStartDate()->getTimestamp();
        }

        return null;
    }