Example #1
0
 /**
  * {@inheritdoc}
  */
 public function rename($path, $newpath)
 {
     $location = $this->applyPathPrefix($path);
     $destination = $this->applyPathPrefix($newpath);
     if (!$this->client->rename($location, $destination)) {
         return false;
     }
     return true;
 }
Example #2
0
 /**
  * Rename an object (file or dir)
  *
  * @param   string  $path
  * @param   string  $newpath
  * @return  array   file metadata
  */
 public function rename($path, $newpath)
 {
     $location = $this->applyPathPrefix($path);
     $destination = $this->applyPathPrefix($newpath);
     if (!($result = $this->client->rename($location, $destination))) {
         return false;
     }
     return $this->normalizeObject($result, $newpath);
 }
Example #3
0
 /**
  * {@inheritdoc}
  */
 public function rename($path, $newpath)
 {
     $location = $this->applyPathPrefix($path);
     $destination = $this->applyPathPrefix($newpath);
     if (!$this->client->rename($location, $destination)) {
         return false;
     }
     unset($this->metaCache[$location], $this->metaCache[$destination]);
     return true;
 }