id = $id; $this->createdAt = $createdAt; $this->expiresAt = $expiresAt; $this->base64ImageData = $base64ImageData; $this->identity = $identity; } public function getId(): ?string { return $this->id; } public function getCreatedAt(): ?string { return $this->createdAt; } public function getExpiresAt(): ?string { return $this->expiresAt; } public function getBase64ImageData(): ?string { return $this->base64ImageData; } public function getIdentity(): ?Identity { return $this->identity; } public static function fromArray(array $array = []): EnrollmentToken { $id = $array['id'] ?? null; $createdAt = $array['createdAt'] ?? null; $expiresAt = $array['expiresAt'] ?? null; $base64ImageData = $array['base64ImageData'] ?? null; $identity = Identity::fromArray($array['identity']); return new EnrollmentToken($id, $createdAt, $expiresAt, $base64ImageData, $identity); } }