Horde_Vfs_Base::copy PHP Метод

copy() публичный Метод

Copies a file through the backend.
public copy ( string $path, string $name, string $dest, boolean $autocreate = false )
$path string The path of the original file.
$name string The name of the original file.
$dest string The name of the destination directory.
$autocreate boolean Automatically create directories?
    public function copy($path, $name, $dest, $autocreate = false)
    {
        $this->_checkDestination($path, $dest);
        if ($autocreate) {
            $this->autocreatePath($dest);
        }
        if ($this->isFolder($path, $name)) {
            $this->_copyRecursive($path, $name, $dest);
        } else {
            $this->writeData($dest, $name, $this->read($path, $name), $autocreate);
        }
    }