WURFL
[ class tree: WURFL ] [ index: WURFL ] [ all elements ]

Class: WURFL_FileUtils

Source Location: /FileUtils.php

Class Overview


WURFL File Utilities


Methods



Class Details

[line 22]
WURFL File Utilities



[ Top ]


Class Methods


static method cleanFilename [line 120]

static string cleanFilename( string $fileName)

Cleans the filename by removing duplicate directory separators and normalizing them for the current OS



Tags:

access:  public


Parameters:

string   $fileName  

[ Top ]

static method getTempDir [line 107]

static string getTempDir( )

Returns a directory for storing temporary files



Tags:

access:  public


[ Top ]

static method join [line 99]

static string join( [array $strings = array()])

Combines given array of $strings into a proper filesystem path



Tags:

return:  Proper filesystem path
access:  public


Parameters:

array   $strings   Array of (string)path members

[ Top ]

static method mkdir [line 29]

static void mkdir( string $path, [int $mode = 0755])

Create a directory structure recursiveley



Tags:

access:  public


Parameters:

string   $path  
int   $mode  

[ Top ]

static method read [line 68]

static mixed read( string $file)

Returns the unserialized contents of the given $file



Tags:

return:  Unserialized data or null if file does not exist
access:  public


Parameters:

string   $file   filename

[ Top ]

static method rmdir [line 59]

static void rmdir( string $path)

Alias to rmdirContents()



Tags:

see:  WURFL_FileUtils::rmdirContents()
access:  public


Parameters:

string   $path   Directory to be cleaned out

[ Top ]

static method rmdirContents [line 38]

static void rmdirContents( string $path)

Recursiely remove all files from the given directory NOT including the

specified directory itself




Tags:

access:  public


Parameters:

string   $path   Directory to be cleaned out

[ Top ]

static method write [line 83]

static void write( string $path, mixed $data, [integer $mtime = 0])

Serializes and saves $data in the file $path and sets the last modified time to $mtime



Tags:

access:  public


Parameters:

string   $path   filename to save data in
mixed   $data   data to be serialized and saved
integer   $mtime   Last modified date in epoch time

[ Top ]


Documentation generated on Thu, 03 Oct 2013 19:11:49 +0000 by phpDocumentor 1.4.4