public function copy($destination) {
		$destination = $this->getDestination($destination);

		if (!@copy($this->getPathname(), $destination)) {
			throw new FileException(sprintf('Failed to copy %s to %s', $this->pathname, $destination));
		}
	}
public function copy($destination) {
		$destination = $this->getDestination($destination);

		if (!@copy($this->getPathname(), $destination)) {
			throw new FileException(sprintf('Failed to copy %s to %s', $this->pathname, $destination));
		}
	}
public function copy ( $ destination ) { $ destination = $ this -> getDestination ( $ destination ) ; if ( ! @ copy ( $ this -> getPathname ( ) , $ destination ) ) { throw new FileException ( sprintf ( 'Failed to copy %s to %s' , $ this -> pathname , $ destination ) ) ; } }
Copies the file

If the destination file already exists, it will be overwritten.

@throws FileException When an error appeared.
@param string|Path $destination The destination path.
Copies the file