eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway::moveSubtreeNodes PHP Method

moveSubtreeNodes() abstract public method

This query can likely be optimized to use some more advanced string operations, which then depend on the respective database.
abstract public moveSubtreeNodes ( array $fromPathString, array $toPathString )
$fromPathString array
$toPathString array
    public abstract function moveSubtreeNodes(array $fromPathString, array $toPathString);

Usage Example

コード例 #1
0
 /**
  * Moves location identified by $sourceId into new parent identified by $destinationParentId.
  *
  * Performs a full move of the location identified by $sourceId to a new
  * destination, identified by $destinationParentId. Relations do not need
  * to be updated, since they refer to Content. URLs are not touched.
  *
  * @param mixed $sourceId
  * @param mixed $destinationParentId
  *
  * @return boolean
  */
 public function move($sourceId, $destinationParentId)
 {
     $sourceNodeData = $this->locationGateway->getBasicNodeData($sourceId);
     $destinationNodeData = $this->locationGateway->getBasicNodeData($destinationParentId);
     $this->locationGateway->moveSubtreeNodes($sourceNodeData, $destinationNodeData);
     $this->locationGateway->updateNodeAssignment($sourceNodeData['contentobject_id'], $sourceNodeData['parent_node_id'], $destinationParentId, Gateway::NODE_ASSIGNMENT_OP_CODE_MOVE);
 }
All Usage Examples Of eZ\Publish\Core\Persistence\Legacy\Content\Location\Gateway::moveSubtreeNodes