* @copyright Since 2007 PrestaShop SA and Contributors * @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) */ namespace PrestaShop\PrestaShop\Core\Domain\Profile\QueryResult; use PrestaShop\PrestaShop\Core\Domain\Profile\ValueObject\ProfileId; /** * Transfers editable Profile data */ class EditableProfile { /** * @var ProfileId */ private $profileId; /** * @var string[] As langId => name */ private $localizedNames; /** * @var string|null */ private $avatarUrl; /** * @param ProfileId $profileId * @param string[] $localizedNames * @param string|null $avatarUrl */ public function __construct( ProfileId $profileId, array $localizedNames, ?string $avatarUrl = null ) { $this->profileId = $profileId; $this->localizedNames = $localizedNames; $this->avatarUrl = $avatarUrl; } /** * @return ProfileId */ public function getProfileId() { return $this->profileId; } /** * @return array */ public function getLocalizedNames() { return $this->localizedNames; } /** * @deprecated Since PrestaShop 8.1, this method only returns string (and not null values) * * @return string|null */ public function getAvatarUrl(): ?string { return $this->avatarUrl; } }