Introduction
Providing some functions for managing files/directories
How to use
You can load File class through Application::getClass method.
Controller
$file = $this->getClass('Tool/File');
$file->copyAll('path/to/foo', 'path/to/bar');
Methods
File::copyAll
Copy all the files to another directory
File::copyDirectory
Copy specified directory to specified location
File::copyFile
Copy specified file to specified location
File::createDirectory
Create directory to specified location
File::moveFile
Move specified file to specified location
File::readFile
Read specified file
File::removeDirectory
Delete specified directory and files in that directory
File::removeExpiredFile
Delete specified file that elapsed specified time
File::removeFile
Delete specified file
File::touchDirectory
Update modified date of files that inside of specified directory
File::writeFile
Put the file to the specified location