public compareDuration ( |
||
$period | ||
Résultat | integer |
public function compareDuration(Period $period)
{
$datetime = $this->startDate->add($period->getDateInterval());
if ($this->endDate > $datetime) {
return 1;
}
if ($this->endDate < $datetime) {
return -1;
}
return 0;
}