hanyuu/src/Users/UserAuthInfo.php
2023-10-20 22:11:43 +00:00

30 lines
659 B
PHP

<?php
namespace Hanyuu\Users;
use Index\DateTime;
use Index\Data\IDbResult;
class UserAuthInfo {
private string $userId;
private string $type;
private DateTime $enabled;
public function __construct(IDbResult $result) {
$this->userId = $result->getString(0);
$this->type = $result->getString(1);
$this->enabled = DateTime::fromUnixTimeSeconds($result->getInteger(2));
}
public function getUserId(): string {
return $this->userId;
}
public function getType(): string {
return $this->type;
}
public function getEnabledTime(): DateTime {
return $this->enabled;
}
}