final public function FileTransfer::copyFile

Copies a file.

Parameters

string $source: The source file.

string $destination: The destination file.

1 call to FileTransfer::copyFile()
FileTransfer::copyDirectoryJailed in drupal/core/lib/Drupal/Core/FileTransfer/FileTransfer.php
Copies a directory.

File

drupal/core/lib/Drupal/Core/FileTransfer/FileTransfer.php, line 189
Definition of Drupal\Core\FileTransfer\FileTransfer.

Class

FileTransfer
Defines the base FileTransfer class.

Namespace

Drupal\Core\FileTransfer

Code

public final function copyFile($source, $destination) {
  $source = $this
    ->sanitizePath($source);
  $destination = $this
    ->fixRemotePath($destination);
  $this
    ->checkPath($destination);
  $this
    ->copyFileJailed($source, $destination);
}