[ Index ] |
|
Code source de Symfony 1.0.0 |
[Code source] [Imprimer] [Statistiques]
This is an abstract class for platform specific filesystem implementations you have to implement each method in the platform specific filesystem implementation classes Your local filesytem implementation must extend this class. You should also use this class as a template to write your local implementation Some native PHP filesystem specific methods are abstracted here as well. Anyway you _must_ always use this methods via a PhingFile object (that by nature uses the *FileSystem drivers to access the real filesystem via this class using natives. FIXME: - Error handling reduced to min fallthrough runtime excetions more precise errorhandling is done by the PhingFile class
Author: | Charlie Killian <charlie@tizac.com> |
Author: | Hans Lellelid <hans@xmpl.org> |
Version: | $Revision: 1.11 $ |
Poids: | 657 lignes (23 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
getFileSystem() X-Ref |
Static method to return the FileSystem singelton representing this platform's local filesystem driver. |
canonicalize($strPath) X-Ref |
canonicalize filename by checking on disk return: mixed Canonical path or false if the file doesn't exist. |
getBooleanAttributes($f) X-Ref |
Return the simple boolean attributes for the file or directory denoted by the given abstract pathname, or zero if it does not exist or some other I/O error occurs. |
checkAccess(PhingFile $f, $write = false) X-Ref |
Check whether the file or directory denoted by the given abstract pathname may be accessed by this process. If the second argument is false, then a check for read access is made; if the second argument is true, then a check for write (not read-write) access is made. Return false if access is denied or an I/O error occurs. |
getLastModifiedTime(PhingFile $f) X-Ref |
Return the time at which the file or directory denoted by the given abstract pathname was last modified, or zero if it does not exist or some other I/O error occurs. |
getLength(PhingFile $f) X-Ref |
Return the length in bytes of the file denoted by the given abstract pathname, or zero if it does not exist, is a directory, or some other I/O error occurs. |
createNewFile($strPathname) X-Ref |
Create a new empty file with the given pathname. Return true if the file was created and false if a file or directory with the given pathname already exists. Throw an IOException if an I/O error occurs. param: string Path of the file to be created. |
delete(PhingFile $f) X-Ref |
Delete the file or directory denoted by the given abstract pathname, returning true if and only if the operation succeeds. |
deleteOnExit($f) X-Ref |
Arrange for the file or directory denoted by the given abstract pathname to be deleted when Phing::shutdown is called, returning true if and only if the operation succeeds. |
listDir(PhingFile $f) X-Ref |
List the elements of the directory denoted by the given abstract pathname. Return an array of strings naming the elements of the directory if successful; otherwise, return <code>null</code>. |
createDirectory(&$f) X-Ref |
Create a new directory denoted by the given abstract pathname, returning true if and only if the operation succeeds. |
rename(PhingFile $f1, PhingFile $f2) X-Ref |
Rename the file or directory denoted by the first abstract pathname to the second abstract pathname, returning true if and only if the operation succeeds. param: PhingFile $f1 abstract source file param: PhingFile $f2 abstract destination file return: void |
setLastModifiedTime(PhingFile $f, $time) X-Ref |
Set the last-modified time of the file or directory denoted by the given abstract pathname returning true if and only if the operation succeeds. return: void |
setReadOnly($f) X-Ref |
Mark the file or directory denoted by the given abstract pathname as read-only, returning <code>true</code> if and only if the operation succeeds. |
listRoots() X-Ref |
List the available filesystem roots, return array of PhingFile objects |
compare($f1, $f2) X-Ref |
Compare two abstract pathnames lexicographically. |
copy(PhingFile $src, PhingFile $dest) X-Ref |
Copy a file. param: PhingFile $src Source path and name file to copy. param: PhingFile $dest Destination path and name of new file. return: void |
chmod($pathname, $mode) X-Ref |
Change the permissions on a file or directory. param: pathname String. Path and name of file or directory. param: mode Int. The mode (permissions) of the file or return: void |
lock(PhingFile $f) X-Ref |
Locks a file and throws an Exception if this is not possible. return: void |
unlock(PhingFile $f) X-Ref |
Unlocks a file and throws an IO Error if this is not possible. return: void |
unlink($file) X-Ref |
Delete a file. param: file String. Path and/or name of file to delete. return: void |
symlink($target, $link) X-Ref |
Symbolically link a file to another name. Currently symlink is not implemented on Windows. Don't use if the application is to be portable. param: string $target Path and/or name of file to link. param: string $link Path and/or name of link to be created. return: void |
touch($file, $time = null) X-Ref |
Set the modification and access time on a file to the present time. param: string $file Path and/or name of file to touch. param: int $time return: void |
rmdir($dir, $children = false) X-Ref |
Delete an empty directory OR a directory and all of its contents. param: dir String. Path and/or name of directory to delete. param: children Boolean. False: don't delete directory contents. return: void |
umask($mode) X-Ref |
Set the umask for file and directory creation. param: mode Int. Permissions ususally in ocatal. Use leading 0 for return: void |
compareMTimes($file1, $file2) X-Ref |
Compare the modified time of two files. param: file1 String. Path and name of file1. param: file2 String. Path and name of file2. return: Int. 1 if file1 is newer. |
Généré le : Fri Mar 16 22:42:14 2007 | par Balluche grâce à PHPXref 0.7 |