Esempio n. 1
0
 /**
  * Renames the node
  *
  * @param string $name The new name
  * @return void
  */
 public function setName($name)
 {
     list($parentPath, ) = URLUtil::splitPath($this->path);
     list(, $newName) = URLUtil::splitPath($name);
     $newPath = $parentPath . '/' . $newName;
     Utils::renameObject($this->nodeId, $name);
     // rename($this->path,$newPath);
     $this->path = $newPath;
 }
Esempio n. 2
0
 public function setName($name)
 {
     Utils::renameObject($this->nodeId, $name);
 }
Esempio n. 3
0
 /**
  * Deletes all files in this directory, and then itself
  *
  * @return void
  */
 public function delete()
 {
     // don't delete folders when in 'edit' mode
     if ($this->env['mode'] == 'edit') {
         return;
     }
     Utils::deleteObject($this->nodeId);
 }