PHP 클래스 Neos\ContentRepository\TypeConverter\NodeConverter

상속: extends Neos\Flow\Property\TypeConverter\AbstractTypeConverter
파일 보기 프로젝트 열기: neos/neos-development-collection 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$contextFactory Neos\ContentRepository\Domain\Service\ContextFactoryInterface
$nodeFactory Neos\ContentRepository\Domain\Factory\NodeFactory
$nodeService Neos\ContentRepository\Domain\Service\NodeServiceInterface
$nodeTypeManager Neos\ContentRepository\Domain\Service\NodeTypeManager
$objectManager Neos\Flow\ObjectManagement\ObjectManagerInterface
$priority integer
$propertyMapper Neos\Flow\Property\PropertyMapper
$securityContext Neos\Flow\Security\Context
$sourceTypes array
$targetType string

공개 메소드들

메소드 설명
convertFrom ( string | array $source, string $targetType = null, array $subProperties = [], Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null ) : mixed Converts the specified $source into a Node.

보호된 메소드들

메소드 설명
prepareContextProperties ( string $workspaceName, Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null, array $dimensions = null ) : array Prepares the context properties for the nodes based on the given workspace and dimensions
setNodeProperties ( object $nodeLike, NodeType $nodeType, array $properties, Context $context, Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null ) : void Iterates through the given $properties setting them on the specified $node using the appropriate TypeConverters.

메소드 상세

convertFrom() 공개 메소드

If $source is a UUID it is expected to refer to the identifier of a NodeData record of the "live" workspace Otherwise $source has to be a valid node path: The node path must be an absolute context node path and can be specified as a string or as an array item with the key "__contextNodePath". The latter case is for updating existing nodes. This conversion method does not support / allow creation of new nodes because new nodes should be created through the createNode() method of an existing reference node. Also note that the context's "current node" is not affected by this object converter, you will need to set it to whatever node your "current" node is, if any. All elements in the source array which start with two underscores (like __contextNodePath) are specially treated by this converter. All elements in the source array which start with a *single underscore (like _hidden) are *directly* set on the Node object. All other elements, not being prefixed with underscore, are properties of the node.
public convertFrom ( string | array $source, string $targetType = null, array $subProperties = [], Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null ) : mixed
$source string | array Either a string or array containing the absolute context node path which identifies the node. For example "/sites/mysitecom/homepage/about@user-admin"
$targetType string not used
$subProperties array not used
$configuration Neos\Flow\Property\PropertyMappingConfigurationInterface
리턴 mixed An object or \Neos\Error\Messages\Error if the input format is not supported or could not be converted for other reasons

prepareContextProperties() 보호된 메소드

Prepares the context properties for the nodes based on the given workspace and dimensions
protected prepareContextProperties ( string $workspaceName, Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null, array $dimensions = null ) : array
$workspaceName string
$configuration Neos\Flow\Property\PropertyMappingConfigurationInterface
$dimensions array
리턴 array

setNodeProperties() 보호된 메소드

Iterates through the given $properties setting them on the specified $node using the appropriate TypeConverters.
protected setNodeProperties ( object $nodeLike, NodeType $nodeType, array $properties, Context $context, Neos\Flow\Property\PropertyMappingConfigurationInterface $configuration = null ) : void
$nodeLike object
$nodeType Neos\ContentRepository\Domain\Model\NodeType
$properties array
$context Neos\ContentRepository\Domain\Service\Context
$configuration Neos\Flow\Property\PropertyMappingConfigurationInterface
리턴 void

프로퍼티 상세

$contextFactory 보호되어 있는 프로퍼티

protected ContextFactoryInterface,Neos\ContentRepository\Domain\Service $contextFactory
리턴 Neos\ContentRepository\Domain\Service\ContextFactoryInterface

$nodeFactory 보호되어 있는 프로퍼티

protected NodeFactory,Neos\ContentRepository\Domain\Factory $nodeFactory
리턴 Neos\ContentRepository\Domain\Factory\NodeFactory

$nodeService 보호되어 있는 프로퍼티

protected NodeServiceInterface,Neos\ContentRepository\Domain\Service $nodeService
리턴 Neos\ContentRepository\Domain\Service\NodeServiceInterface

$nodeTypeManager 보호되어 있는 프로퍼티

protected NodeTypeManager,Neos\ContentRepository\Domain\Service $nodeTypeManager
리턴 Neos\ContentRepository\Domain\Service\NodeTypeManager

$objectManager 보호되어 있는 프로퍼티

protected ObjectManagerInterface,Neos\Flow\ObjectManagement $objectManager
리턴 Neos\Flow\ObjectManagement\ObjectManagerInterface

$priority 보호되어 있는 프로퍼티

protected int $priority
리턴 integer

$propertyMapper 보호되어 있는 프로퍼티

protected PropertyMapper,Neos\Flow\Property $propertyMapper
리턴 Neos\Flow\Property\PropertyMapper

$securityContext 보호되어 있는 프로퍼티

protected Context,Neos\Flow\Security $securityContext
리턴 Neos\Flow\Security\Context

$sourceTypes 보호되어 있는 프로퍼티

protected array $sourceTypes
리턴 array

$targetType 보호되어 있는 프로퍼티

protected string $targetType
리턴 string