Property | Type | Description | |
---|---|---|---|
$addedNodes | SplObjectStorage | ||
$defaultOrderings | array | ||
$entityManager | Doctrine\Common\Persistence\ObjectManager | .. | |
$highestIndexCache | array | ||
$nodeFactory | |||
$nodeTypeManager | |||
$removedNodes | SplObjectStorage | ||
$securityContext | |||
$systemLogger | Neos\Flow\Log\SystemLoggerInterface |
Method | Description | |
---|---|---|
__construct ( ) | Constructor | |
add ( object $object ) : void | Adds a NodeData object to this repository. | |
addNodeTypeFilterConstraintsToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $nodeTypeFilter ) : void | Add node type filter constraints to the query builder | |
countByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
Counts nodes by its parent and (optionally) by its node type. | |
countByWorkspace ( |
Counts the number of nodes within the specified workspace | |
findByIdentifierWithoutReduce ( string $identifier, |
Find NodeData by identifier path without any dimension reduction | |
findByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
Finds nodes by its parent and (optionally) by its node type. | |
findByParentAndNodeTypeInContext ( string $parentPath, string $nodeTypeFilter, |
Finds nodes by its parent and (optionally) by its node type given a Context | |
findByParentAndNodeTypeRecursively ( string $parentPath, string $nodeTypeFilter, |
Finds recursively nodes by its parent and (optionally) by its node type. | |
findByParentWithoutReduce ( string $parentPath, |
Find NodeData by parent path without any dimension reduction and grouping by identifier | |
findByPathWithoutReduce ( string $path, |
Find all node data in a path matching the given workspace hierarchy | |
findByProperties ( string | array $term, string $nodeTypeFilter, |
Find nodes by a value in properties | |
findByWorkspace ( |
Find all NodeData objects inside a given workspace sorted by path to be used in publishing. The order makes sure that parent nodes are published first. | |
findFirstByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
Finds a single node by its parent and (optionally) by its node type | |
findFirstByParentAndNodeTypeInContext ( string $parentPath, string $nodeTypeFilter, |
Finds a single node by its parent and (optionally) by its node type | |
findNodesByRelatedEntities ( array $relationMap ) : array | Searches for possible relations to the given entity identifiers in NodeData. | |
findOnPath ( string $pathStartingPoint, string $pathEndPoint, |
Finds all nodes of the specified workspace lying on the path specified by (and including) the given starting point and end point and (optionally) a node type filter. | |
findOneByIdentifier ( string $identifier, |
Finds a node by its identifier and workspace. | |
findOneByPath ( string $path, |
Find a single node by exact path. | |
findOneByPathInContext ( string $path, |
Finds a node by its path and context. | |
findShadowNodeByPath ( string $path, |
Find a shadow node by exact path | |
flushNodeRegistry ( ) : void | Flushes the addedNodes and removedNodes registry. | |
isInRemovedNodes ( |
Test if a given NodeData is in the set of removed node data objects | |
pathExists ( string $nodePath ) : boolean | Find out if the given path exists anywhere in the CR. (internal) If you need this functionality use \Neos\ContentRepository\Domain\Service\NodeService::nodePathExistsInAnyContext() | |
persistEntities ( ) : void | Persists all entities managed by the repository and all cascading dependencies | |
remove ( object $object ) : void | Removes an object to the persistence. | |
removeAllInPath ( string $path ) : void | Remove all nodes below a given path. Does not care about workspaces and dimensions. | |
reset ( ) : void | Reset instances (internal). | |
setNewIndex ( |
Assigns an index to the given node which reflects the specified position. |
Method | Description | |
---|---|---|
addDimensionJoinConstraintsToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, array $dimensions ) : void | If $dimensions is not empty, adds join constraints to the given $queryBuilder limiting the query result to matching hits. | |
addIdentifierConstraintToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $identifier ) : void | ||
addParentPathConstraintToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $parentPath, boolean $recursive = false ) : void | ||
addPathConstraintToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $path, boolean $recursive = false ) : void | ||
collectWorkspaceAndAllBaseWorkspaces ( |
Returns an array that contains the given workspace and all base (parent) workspaces of it. | |
createQueryBuilder ( array $workspaces ) : Doctrine\ORM\QueryBuilder | ||
emitRepositoryObjectsPersisted ( ) : void | Signals that persistEntities() in this repository finished correctly. | |
filterNodeDataByBestMatchInContext ( array $nodeDataObjects, |
||
filterOutRemovedObjects ( array &$objects ) : void | Iterates of the array of objects and removes all those which have recently been removed from the repository, but whose removal has not yet been persisted. | |
filterRemovedNodes ( array $nodes, boolean | null $removedNodes ) : array | Removes NodeData with the removed property set from the given array. | |
findNextFreeIndexInParentPath ( string $parentPath ) : integer | Finds the next free index on the level below the given parent path across all workspaces. | |
findNextHigherIndex ( string $parentPath, integer $referenceIndex ) : integer | Returns the next-higher-index seen from the given reference index in the level below the specified parent path. If no node with a higher than the given index exists at that level, NULL is returned. | |
findNextLowerIndex ( string $parentPath, integer $referenceIndex ) : integer | Returns the next-lower-index seen from the given reference index in the level below the specified parent path. If no node with a lower than the given index exists at that level, the reference index is returned. | |
findRawNodesByPath ( string $path, |
This finds nodes by path and delivers a raw, unfiltered result. | |
getNodeDataForParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
Internal method | |
getNodeTypeFilterConstraints ( Neos\Flow\Persistence\QueryInterface $query, $nodeTypeFilter ) : array | ||
getNodeTypeFilterConstraintsForDql ( string $nodeTypeFilter ) : array | Generates a two dimensional array with the filters. First level is: 'excludeNodeTypes' 'includeNodeTypes' | |
openIndexSpace ( string $parentPath, integer $referenceIndex ) | Make room in the sortindex-index space of a given path in preparation to inserting a node. | |
reduceNodeVariantsByWorkspaces ( array $nodes, array $workspaces ) : array | Given an array with duplicate nodes (from different workspaces) those are reduced to uniqueness (by node identifier and dimensions hash) | |
reduceNodeVariantsByWorkspacesAndDimensions ( array $nodes, array $workspaces, array $dimensions ) : array | Given an array with duplicate nodes (from different workspaces and dimensions) those are reduced to uniqueness (by node identifier) | |
setHighestIndexInParentPath ( string $parentPath, integer $highestIndex ) : void | ||
sortNodesByIndex ( array $nodes ) : array | Sorts the given nodes by their index |
protected addDimensionJoinConstraintsToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, array $dimensions ) : void | ||
$queryBuilder | Doctrine\ORM\QueryBuilder | |
$dimensions | array | |
return | void |
protected addIdentifierConstraintToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $identifier ) : void | ||
$queryBuilder | Doctrine\ORM\QueryBuilder | |
$identifier | string | |
return | void |
public addNodeTypeFilterConstraintsToQueryBuilder ( Doctrine\ORM\QueryBuilder $queryBuilder, string $nodeTypeFilter ) : void | ||
$queryBuilder | Doctrine\ORM\QueryBuilder | |
$nodeTypeFilter | string | |
return | void |
protected collectWorkspaceAndAllBaseWorkspaces ( |
||
$workspace | ||
return | array |
public countByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$workspace | The containing workspace | |
$dimensions | array | |
$includeRemovedNodes | boolean | Should removed nodes be included in the result (defaults to FALSE) |
return | integer | The number of nodes a similar call to findByParentAndNodeType() would return without any pending added nodes |
public countByWorkspace ( |
||
$workspace | The containing workspace | |
return | integer | The number of nodes found |
protected createQueryBuilder ( array $workspaces ) : Doctrine\ORM\QueryBuilder | ||
$workspaces | array | |
return | Doctrine\ORM\QueryBuilder |
protected emitRepositoryObjectsPersisted ( ) : void | ||
return | void |
protected filterNodeDataByBestMatchInContext ( array $nodeDataObjects, |
||
$nodeDataObjects | array | |
$workspace | ||
$dimensions | array | |
$includeRemovedNodes | boolean | Should removed nodes be included in the result (defaults to FALSE) |
return | array |
protected filterOutRemovedObjects ( array &$objects ) : void | ||
$objects | array | |
return | void |
protected filterRemovedNodes ( array $nodes, boolean | null $removedNodes ) : array | ||
$nodes | array | NodeData including removed entries |
$removedNodes | boolean | null | If TRUE the result has ONLY removed nodes. If FALSE removed nodes are NOT inside the result. If NULL the result contains BOTH removed and non-removed nodes. |
return | array | NodeData with removed entries removed |
public findByIdentifierWithoutReduce ( string $identifier, |
||
$identifier | string | |
$workspace | ||
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$workspace | The containing workspace | |
$dimensions | array | An array of dimensions to dimension values |
$removedNodes | boolean | If TRUE the result has ONLY removed nodes. If FALSE removed nodes are NOT inside the result. If NULL the result contains BOTH removed and non-removed nodes. (defaults to FALSE) |
$recursive | boolean | If TRUE *all* matching nodes underneath the specified parent path are returned |
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findByParentAndNodeTypeInContext ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$context | The containing workspace | |
$recursive | boolean | If TRUE *all* matching nodes underneath the specified parent path are returned |
return | array<\Neos\ContentRepository\Domain\Model\NodeInterface> |
public findByParentAndNodeTypeRecursively ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$workspace | The containing workspace | |
$dimensions | array | An array of dimensions to dimension values |
$removedNodes | boolean | If TRUE the result has ONLY removed nodes. If FALSE removed nodes are NOT inside the result. If NULL the result contains BOTH removed and non-removed nodes. (defaults to FALSE) |
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findByParentWithoutReduce ( string $parentPath, |
||
$parentPath | string | |
$workspace | ||
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findByPathWithoutReduce ( string $path, |
||
$path | string | |
$workspace | ||
$includeRemovedNodes | boolean | Should removed nodes be included in the result (defaults to FALSE) |
$recursive | boolean | |
return | array |
public findByProperties ( string | array $term, string $nodeTypeFilter, |
||
$term | string | array | Search term |
$nodeTypeFilter | string | Node type filter |
$workspace | ||
$dimensions | array | |
$pathStartingPoint | string | |
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findByWorkspace ( |
||
$workspace | ||
return | array |
public findFirstByParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$workspace | The containing workspace | |
$dimensions | array | |
$removedNodes | boolean | If TRUE the result has ONLY removed nodes. If FALSE removed nodes are NOT inside the result. If NULL the result contains BOTH removed and non-removed nodes. (defaults to FALSE) |
return | The node found or NULL |
public findFirstByParentAndNodeTypeInContext ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | Absolute path of the parent node |
$nodeTypeFilter | string | Filter the node type of the nodes, allows complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
$context | The containing context | |
return | The node found or NULL |
protected findNextFreeIndexInParentPath ( string $parentPath ) : integer | ||
$parentPath | string | Path of the parent node specifying the level in the node tree |
return | integer | The next available index |
protected findNextHigherIndex ( string $parentPath, integer $referenceIndex ) : integer | ||
$parentPath | string | Path of the parent node specifying the level in the node tree |
$referenceIndex | integer | Index of a known node |
return | integer | The currently next higher index or NULL if no node with a higher index exists |
public findNodesByRelatedEntities ( array $relationMap ) : array | ||
$relationMap | array | |
return | array |
public findOnPath ( string $pathStartingPoint, string $pathEndPoint, |
||
$pathStartingPoint | string | Absolute path specifying the starting point |
$pathEndPoint | string | Absolute path specifying the end point |
$workspace | The containing workspace | |
$dimensions | array | Array of dimensions to array of dimension values |
$includeRemovedNodes | boolean | Should removed nodes be included in the result (defaults to FALSE) |
$nodeTypeFilter | string | Optional filter for the node type of the nodes, supports complex expressions (e.g. "Neos.Neos:Page", "!Neos.Neos:Page,Neos.Neos:Text" or NULL) |
return | array<\Neos\ContentRepository\Domain\Model\NodeData> |
public findOneByIdentifier ( string $identifier, |
||
$identifier | string | Identifier of the node |
$workspace | The containing workspace | |
$dimensions | array | An array of dimensions with array of ordered values to use for fallback matching |
return | The matching node if found, otherwise NULL |
public findOneByPath ( string $path, |
||
$path | string | Absolute path of the node |
$workspace | The containing workspace | |
$dimensions | array | An array of dimensions with array of ordered values to use for fallback matching |
$removedNodes | boolean | null | Include removed nodes, NULL (all), FALSE (no removed nodes) or TRUE (only removed nodes) |
return | The matching node if found, otherwise NULL |
public findOneByPathInContext ( string $path, |
||
$path | string | Absolute path of the node |
$context | The containing context | |
return | Neos\ContentRepository\Domain\Model\NodeInterface | null | The matching node if found, otherwise NULL |
public flushNodeRegistry ( ) : void | ||
return | void |
protected getNodeDataForParentAndNodeType ( string $parentPath, string $nodeTypeFilter, |
||
$parentPath | string | |
$nodeTypeFilter | string | |
$workspace | ||
$dimensions | array | |
$removedNodes | boolean | null | |
$recursive | boolean | |
return | array |
protected getNodeTypeFilterConstraints ( Neos\Flow\Persistence\QueryInterface $query, $nodeTypeFilter ) : array | ||
$query | Neos\Flow\Persistence\QueryInterface | |
$nodeTypeFilter | ||
return | array |
protected getNodeTypeFilterConstraintsForDql ( string $nodeTypeFilter ) : array | ||
$nodeTypeFilter | string | |
return | array |
public isInRemovedNodes ( |
||
$nodeData | ||
return | boolean | TRUE If the NodeData was marked for removal |
protected openIndexSpace ( string $parentPath, integer $referenceIndex ) | ||
$parentPath | string | |
$referenceIndex | integer |
public pathExists ( string $nodePath ) : boolean | ||
$nodePath | string | |
return | boolean |
public persistEntities ( ) : void | ||
return | void |
protected reduceNodeVariantsByWorkspacesAndDimensions ( array $nodes, array $workspaces, array $dimensions ) : array | ||
$nodes | array | NodeData result with multiple and duplicate identifiers (different nodes and redundant results for node variants with different dimensions) |
$workspaces | array | |
$dimensions | array | |
return | array | Array of unique node results indexed by identifier |
public removeAllInPath ( string $path ) : void | ||
$path | string | Starting point path underneath all nodes are to be removed. |
return | void |
public setNewIndex ( |
||
$node | The node to set the new index for | |
$position | integer | The position the new index should reflect, must be one of the POSITION_* constants |
$referenceNode | Neos\ContentRepository\Domain\Model\NodeInterface | The reference node. Mandatory for POSITION_BEFORE and POSITION_AFTER |
return | void |
protected sortNodesByIndex ( array $nodes ) : array | ||
$nodes | array | Nodes |
return | array | Nodes sorted by index |
protected ObjectManager,Doctrine\Common\Persistence $entityManager | ||
return | Doctrine\Common\Persistence\ObjectManager |
protected NodeFactory,Neos\ContentRepository\Domain\Factory $nodeFactory | ||
return |
protected NodeTypeManager,Neos\ContentRepository\Domain\Service $nodeTypeManager | ||
return |
protected SplObjectStorage $removedNodes | ||
return | SplObjectStorage |
protected Context,Neos\Flow\Security $securityContext | ||
return |