51 lines
859 B
PHP
51 lines
859 B
PHP
<?php
|
|
|
|
namespace App\Dto\Profils;
|
|
|
|
use App\Entity\Account;
|
|
|
|
class DtoProfils
|
|
{
|
|
private ?string $username;
|
|
private ?string $email;
|
|
|
|
public function __construct(Account $account)
|
|
{
|
|
$this->username = $account->getUsername();
|
|
$this->email = $account->getEmail();
|
|
}
|
|
|
|
/**
|
|
* @return string|null
|
|
*/
|
|
public function getEmail(): ?string
|
|
{
|
|
return $this->email;
|
|
}
|
|
|
|
/**
|
|
* @return string|null
|
|
*/
|
|
public function getUsername(): ?string
|
|
{
|
|
return $this->username;
|
|
}
|
|
|
|
|
|
/**
|
|
* @param string|null $email
|
|
*/
|
|
public function setEmail(?string $email): void
|
|
{
|
|
$this->email = $email;
|
|
}
|
|
|
|
/**
|
|
* @param string|null $username
|
|
*/
|
|
public function setUsername(?string $username): void
|
|
{
|
|
$this->username = $username;
|
|
}
|
|
}
|