Реализация интерфейсов из библиотеки в таблице

This commit is contained in:
Artem Vasilev 2024-03-04 03:18:57 +03:00
parent 461e851781
commit 53d02b05d5

View File

@ -4,19 +4,20 @@ namespace Webmasterskaya\Component\OauthServer\Administrator\Table;
use Joomla\CMS\Table\Table;
use Joomla\Database\DatabaseDriver;
use League\OAuth2\Server\Entities\ClientEntityInterface;
/**
* @property int $id
* @property string $name
* @property string $identifier
* @property string|null $secret
* @property bool $public
* @property int $public
* @property string|null $redirect_uri
* @property bool $allow_plain_text_pkce
* @property int $allow_plain_text_pkce
*
* @since version
*/
class ClientTable extends Table
class ClientTable extends Table implements ClientEntityInterface
{
/**
* Constructor.
@ -29,4 +30,24 @@ class ClientTable extends Table
{
parent::__construct('#__webmasterskaya_oauthserver_clients', 'id', $db);
}
public function getIdentifier()
{
return $this->identifier;
}
public function getName()
{
return $this->name;
}
public function getRedirectUri()
{
return $this->redirect_uri;
}
public function isConfidential()
{
return !$this->public;
}
}