[ Index ]
 

Code source de CakePHP 1.1.13.4450

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/cake/libs/ -> file.php (sommaire)

Convenience class for reading, writing and appending to files. PHP versions 4 and 5

Copyright: Copyright 2005-2007, Cake Software Foundation, Inc.
License: http://www.opensource.org/licenses/mit-license.php The MIT License
Version: $Revision: 4409 $
Poids: 293 lignes (6 kb)
Inclus ou requis:0 fois
Référencé: 0 fois
Nécessite: 0 fichiers

Définit 1 class

File:: (21 méthodes):
  __construct()
  read()
  append()
  write()
  getMd5()
  getSize()
  getExt()
  getName()
  getOwner()
  getGroup()
  create()
  exists()
  delete()
  writable()
  executable()
  readable()
  lastAccess()
  lastChange()
  getFolder()
  getChmod()
  getFullPath()


Classe: File  - X-Ref

Convenience class for reading, writing and appending to files.

__construct($path, $create = false)   X-Ref
Constructor

param: string $path
param: boolean $create Create file if it does not exist
return: File

read()   X-Ref
Return the contents of this File as a string.

return: string Contents

append($data)   X-Ref
Append given data string to this File.

param: string $data Data to write
return: boolean Success

write($data, $mode = 'w')   X-Ref
Write given data to this File.

param: string $data    Data to write to this File.
param: string $mode    Mode of writing. {@link http://php.net/fwrite See fwrite()}.
return: boolean Success

getMd5($force = false)   X-Ref
Get md5 Checksum of file with previous check of Filesize

param: string $force    Data to write to this File.
return: string md5 Checksum {@link http://php.net/md5_file See md5_file()}

getSize()   X-Ref
Returns the Filesize, either in bytes or in human-readable format.

param: boolean $humanReadeble    Data to write to this File.
return: string|int filesize as int or as a human-readable string

getExt()   X-Ref
Returns the File extension.

return: string The Fileextension

getName()   X-Ref
Returns the filename.

return: string The Filename

getOwner()   X-Ref
Returns the File's owner.

return: int the Fileowner

getGroup()   X-Ref
Returns the File group.

return: int the Filegroup

create()   X-Ref
Creates the File.

return: boolean Success

exists()   X-Ref
Returns true if the File exists.

return: boolean

delete()   X-Ref
Deletes the File.

return: boolean

writable()   X-Ref
Returns true if the File is writable.

return: boolean

executable()   X-Ref
Returns true if the File is executable.

return: boolean

readable()   X-Ref
Returns true if the File is readable.

return: boolean

lastAccess()   X-Ref
Returns last access time.

return: int timestamp

lastChange()   X-Ref
Returns last modified time.

return: int timestamp

getFolder()   X-Ref
Returns the current folder.

return: Folder

getChmod()   X-Ref
Returns the "chmod" (permissions) of the File.

return: string

getFullPath()   X-Ref
Returns the full path of the File.

return: string



Généré le : Sun Feb 25 19:27:47 2007 par Balluche grâce à PHPXref 0.7