$path */ public function __construct( private int $id, private string $name, private string $kind, private array $path, private DateTimeImmutable $scheduledDate, private int $position, private ?DateTimeImmutable $completedAt, ) {} public function getId(): int { return $this->id; } public function getName(): string { return $this->name; } public function getKind(): string { return $this->kind; } /** * @return list */ public function getPath(): array { return $this->path; } public function getScheduledDate(): DateTimeImmutable { return $this->scheduledDate; } public function getPosition(): int { return $this->position; } public function getCompletedAt(): ?DateTimeImmutable { return $this->completedAt; } public function complete(DateTimeImmutable $completedAt): void { if ($this->completedAt === null) { $this->completedAt = $completedAt; } } public function reopen(): void { $this->completedAt = null; } }