Documentation

ForcedRename extends AbstractPlugin
in package

Table of Contents

$filesystem  : FilesystemInterface
getMethod()  : mixed
handle()  : bool
Renames a file, overwriting the destination if it exists.
setFilesystem()  : mixed
Set the Filesystem object.

Properties

Methods

getMethod()

public getMethod() : mixed
Tags
inheritdoc
Return values
mixed

handle()

Renames a file, overwriting the destination if it exists.

public handle(string $path, string $newpath) : bool
Parameters
$path : string

Path to the existing file.

$newpath : string

The new path of the file.

Tags
throws
FileNotFoundException

Thrown if $path does not exist.

throws
FileExistsException
Return values
bool

True on success, false on failure.

Search results