eZ\Publish\Core\Repository\Tests\Service\Integration\ContentTypeBase::createContentTypeGroup PHP Метод

createContentTypeGroup() защищенный Метод

Creates a group with identifier "new-group".
protected createContentTypeGroup ( ) : eZ\Publish\API\Repository\Values\ContentType\ContentTypeGroup
Результат eZ\Publish\API\Repository\Values\ContentType\ContentTypeGroup
    protected function createContentTypeGroup()
    {
        $contentTypeService = $this->repository->getContentTypeService();
        $groupCreate = $contentTypeService->newContentTypeGroupCreateStruct('new-group');
        $groupCreate->creatorId = $this->repository->getCurrentUserReference()->getUserId();
        $groupCreate->creationDate = new \DateTime();
        // @todo uncomment when support for multilingual names and descriptions is added EZP-24776
        //$groupCreate->mainLanguageCode = 'eng-US';
        //$groupCreate->names = array( 'eng-US' => 'Name' );
        //$groupCreate->descriptions = array( 'eng-US' => 'Description' );
        return $contentTypeService->createContentTypeGroup($groupCreate);
    }
ContentTypeBase