id = $result->getString(0); $this->name = $result->getString(1); $this->country = $result->getString(2); $this->colour = $result->isNull(3) ? Colour::none() : ColourRGB::fromRawRGB($result->getInteger(3)); $this->isSuper = $result->getInteger(4) !== 0; $this->timeZone = new TimeZoneInfo($result->getString(5)); $this->created = DateTime::fromUnixTimeSeconds($result->getInteger(6)); $this->updated = DateTime::fromUnixTimeSeconds($result->getInteger(7)); $this->isDeleted = !$result->isNull(8); $this->deleted = DateTime::fromUnixTimeSeconds($result->isNull(8) ? 0 : $result->getInteger(8)); } public function getId(): string { return $this->id; } public function getName(): string { return $this->name; } public function getCountryCode(): string { return $this->country; } public function getColour(): Colour { return $this->colour; } public function isSuper(): bool { return $this->isSuper; } public function getTimeZone(): TimeZoneInfo { return $this->timeZone; } public function getCreatedTime(): DateTime { return $this->created; } public function getUpdatedTime(): DateTime { return $this->updated; } public function isDeleted(): bool { return $this->isDeleted; } public function getDeletedTime(): DateTime { return $this->deleted; } }