for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* This file is part of Platform package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);
namespace Karma\Platform\Io;
* Class AbstractUser
* @package Karma\Platform\Io
abstract class AbstractUser implements UserInterface
{
* @var SystemInterface
protected $system;
* @var string
protected $id;
protected $name;
* @var string|null
protected $avatar;
* User constructor.
* @param SystemInterface $system
* @param string $id
* @param string $name
public function __construct(SystemInterface $system, string $id, string $name)
$this->system = $system;
$this->id = $id;
$this->name = $name;
}
* @return array
public function __debugInfo(): array
return [
'system' => $this->getSystem()->getName(),
'id' => $this->getId(),
'name' => $this->getName(),
'avatar' => $this->getAvatar(),
];
* @return SystemInterface
public function getSystem(): SystemInterface
return $this->system;
* @return string
public function getId(): string
return $this->id;
public function getName(): string
return $this->name;
* @return null|string
public function getAvatar(): ?string
return $this->avatar;