PHP Trait Neos\Neos\Controller\CreateContentContextTrait

Show file Open project: neos/neos-development-collection

Protected Properties

Property Type Description
$_contextFactory Neos\Neos\Domain\Service\ContentContextFactory
$_domainRepository Neos\Neos\Domain\Repository\DomainRepository
$_siteRepository Neos\Neos\Domain\Repository\SiteRepository

Protected Methods

Method Description
createContentContext ( string $workspaceName, array $dimensions = [] ) : ContentContext Create a ContentContext based on the given workspace name
createContextMatchingNodeData ( NodeData $nodeData ) : ContentContext Generates a Context that exactly fits the given NodeData Workspace, Dimensions & Site.

Method Details

createContentContext() protected method

Create a ContentContext based on the given workspace name
protected createContentContext ( string $workspaceName, array $dimensions = [] ) : ContentContext
$workspaceName string Name of the workspace to set for the context
$dimensions array Optional list of dimensions and their values which should be set
return Neos\Neos\Domain\Service\ContentContext

createContextMatchingNodeData() protected method

Generates a Context that exactly fits the given NodeData Workspace, Dimensions & Site.
protected createContextMatchingNodeData ( NodeData $nodeData ) : ContentContext
$nodeData Neos\ContentRepository\Domain\Model\NodeData
return Neos\Neos\Domain\Service\ContentContext

Property Details

$_contextFactory protected property

protected ContentContextFactory,Neos\Neos\Domain\Service $_contextFactory
return Neos\Neos\Domain\Service\ContentContextFactory

$_domainRepository protected property

protected DomainRepository,Neos\Neos\Domain\Repository $_domainRepository
return Neos\Neos\Domain\Repository\DomainRepository

$_siteRepository protected property

protected SiteRepository,Neos\Neos\Domain\Repository $_siteRepository
return Neos\Neos\Domain\Repository\SiteRepository