Neos\ContentRepository\Domain\Service\PublishingService::createContext PHP Метод

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

Creates a new content context based on the given workspace and the NodeData object.
protected createContext ( Workspace $workspace, array $dimensionValues, array $contextProperties = [] ) : Context
$workspace Neos\ContentRepository\Domain\Model\Workspace Workspace for the new context
$dimensionValues array The dimension values for the new context
$contextProperties array Additional pre-defined context properties
Результат Context
    protected function createContext(Workspace $workspace, array $dimensionValues, array $contextProperties = array())
    {
        $presetsMatchingDimensionValues = $this->contentDimensionPresetSource->findPresetsByTargetValues($dimensionValues);
        $dimensions = array_map(function ($preset) {
            return $preset['values'];
        }, $presetsMatchingDimensionValues);
        $contextProperties += array('workspaceName' => $workspace->getName(), 'inaccessibleContentShown' => true, 'invisibleContentShown' => true, 'removedContentShown' => true, 'dimensions' => $dimensions);
        return $this->contextFactory->create($contextProperties);
    }