public function Period::__construct in Recurring Time Period 8
Constructs a new Period object.
Parameters
\DateTimeImmutable $start_date: The start date/time.
\DateTimeImmutable $end_date: The end date/time.
string|null $label: (optional) The label.
File
- src/
DateTime/ Period.php, line 51
Class
- Period
- Represents a period of time with specific start and end dates.
Namespace
Drupal\recurring_period\DatetimeCode
public function __construct(\DateTimeImmutable $start_date, \DateTimeImmutable $end_date, $label = '') {
$this->startDate = $start_date;
$this->endDate = $end_date;
$this->label = $label;
}