public loadSectionByIdentifier ( string $sectionIdentifier ) : eZ\Publish\API\Repository\Values\Content\Section | ||
$sectionIdentifier | string | |
Résultat | eZ\Publish\API\Repository\Values\Content\Section |
public function loadSectionByIdentifier($sectionIdentifier)
{
if (!is_string($sectionIdentifier) || empty($sectionIdentifier)) {
throw new InvalidArgumentValue('sectionIdentifier', $sectionIdentifier);
}
if ($this->repository->hasAccess('section', 'view') !== true) {
throw new UnauthorizedException('section', 'view');
}
$spiSection = $this->sectionHandler->loadByIdentifier($sectionIdentifier);
return $this->buildDomainSectionObject($spiSection);
}