linea21-externals
[ class tree: linea21-externals ] [ index: linea21-externals ] [ all elements ]

Class: afiles

Source Location: /class/system/afiles/class.afiles.php

Class Overview




Author(s):

Version:

  • alpha 2.2

Methods



Class Details

[line 14]


Tags:

author:  Sylvain 'Absynthe' Rabot <sylvain@abstraction.fr> , modified by Linea21 <info@linea21.com>
version:  alpha 2.2
link:  http://absynthe.is.free.fr/aFiles/
access:  public
filesource:  Source Code for this file
license:  Absynthe files


[ Top ]


Class Methods


constructor __construct [line 27]

afiles __construct( [string $path = false])

Constructor which allows to chose the path of the entity used for following actions



Parameters:

string   $path  

[ Top ]

method cp [line 393]

boolean cp( string $path, string $where)

Copy files or/and directories



Parameters:

string   $path  
string   $where  

[ Top ]

method filesize [line 669]

int filesize( [string $path = null])

Return the size of an entity



Parameters:

string   $path  

[ Top ]

method format_path [line 788]

string format_path( string $path)

Replace '//' by '/' in paths



Parameters:

string   $path  

[ Top ]

method get_path [line 45]

string get_path( )

Return the path of the entity used by default



[ Top ]

method infos [line 484]

array infos( [string $path = null], [boolean $withroot = true], [boolean $content = true], [boolean $byline = false], [int $length = 1024])

Return infos concerning the entity



Parameters:

string   $path  
boolean   $withroot  
boolean   $content  
boolean   $byline  
int   $length  

[ Top ]

method ll [line 157]

array ll( [string $path = null], [boolean $withroot = true])

Return infos of all entity included in the path



Parameters:

string   $path  
boolean   $withroot  

[ Top ]

method lld [line 199]

array lld( [string $path = null], [boolean $withroot = true])

Return infos of all directories included in the path



Parameters:

string   $path  
boolean   $withroot  

[ Top ]

method ls [line 75]

array ls( [string $path = null], [boolean $withroot = true])

Return the list of all entity included in the path



Parameters:

string   $path  
boolean   $withroot  

[ Top ]

method lsd [line 114]

array lsd( [string $path = null], [boolean $withroot = true])

Return the list of directories included in the path



Parameters:

string   $path  
boolean   $withroot  

[ Top ]

method lsr [line 827]

array lsr( $directory $directory, [ $filter = false], $directory_tree)

Apply the callback function on files with extension "filter" this method is recursive



Parameters:

$directory   $directory  
   $filter  
   $directory_tree  

[ Top ]

method mkdir [line 303]

boolean mkdir( [string $path = null], [int $chmod = null])

Create a directory with/without chmod



Parameters:

string   $path  
int   $chmod  

[ Top ]

method mkfile [line 244]

boolean mkfile( [string $content = ''], [string $path = null])

Create a file with or without content



Parameters:

string   $content  
string   $path  

[ Top ]

method mkini [line 740]

boolean mkini( array $content, [string $path = null])

Make ini file



Parameters:

array   $content  
string   $path  

[ Top ]

method mod [line 441]

int mod( string $path)

Return the mod of a file/directory

Credits goes to Ambriel_Angel (www dot ambriels dot net)




Parameters:

string   $path  

[ Top ]

method mv [line 326]

boolean mv( string $path, string $where)

Move a file or a directory



Parameters:

string   $path  
string   $where  

[ Top ]

method parse_ini [line 724]

array parse_ini( [string $path = null], [ $whithsection = true])

Parse a ini file



Parameters:

string   $path  
   $whithsection  

[ Top ]

method quote_ini [line 803]

anything quote_ini( anything $var)

Quote ini var if needed



Parameters:

anything   $var  

[ Top ]

method read_file [line 270]

string/array read_file( [string $path = null], [boolean $byline = false], [int $length = 1024])

Read the content of a file



Parameters:

string   $path  
boolean   $byline  
int   $length  

[ Top ]

method rm [line 351]

boolean rm( [string $path = null])

Remove files or/and directories



Parameters:

string   $path  

[ Top ]

method serialize [line 694]

boolean serialize( anything $var, [string $path = null])

Serialize and creates a file with the serial



Parameters:

anything   $var  
string   $path  

[ Top ]

method set_path [line 36]

void set_path( [string $path = false])

Methods which allows to chose the path of the entity used for following actions



Parameters:

string   $path  

[ Top ]

method sort_results [line 814]

array sort_results( &$array, array $array)

Sort results



Parameters:

array   $array  
   &$array  

[ Top ]

method test_var [line 777]

void test_var( &$var, anything $default, anything $var)

Set a variable to $default parameter if it's null



Parameters:

anything   $var  
anything   $default  
   &$var  

[ Top ]

method tree [line 600]

array tree( [string $path = null], [boolean $expand2files = true])

Return tree of a directory



Parameters:

string   $path  
boolean   $expand2files  

[ Top ]

method type [line 55]

string type( [string $path = null])

Return the type of an entity



Parameters:

string   $path  

[ Top ]

method unserialize [line 709]

array unserialize( [string $path = null])

Unserialize a file



Parameters:

string   $path  

[ Top ]


Documentation generated on Thu, 03 May 2012 15:02:14 +0200 by phpDocumentor 1.4.1