dbms/app/Entities/UserEntity.php
2025-04-30 19:48:46 +09:00

27 lines
554 B
PHP

<?php
namespace App\Entities;
use App\Entities\CommonEntity as Entity;
use App\Models\UserModel as Model;
class UserEntity extends CommonEntity
{
const PK = Model::PK;
const TITLE = Model::TITLE;
public function __toString(): string
{
return "{$this->getPK()}:{$this->getID()}:{$this->getTitle()},{$this->getRole()}}";
}
//공통부분
public function getID(): string
{
return $this->attributes['id'];
}
public function getRole(): string
{
return $this->attributes['role'];
}
}