EncodeExplorer
in package
EncodeExplorer
Table of Contents
Properties
- $dirs : array<string|int, mixed>
- array
- $files : array<string|int, mixed>
- array
- $location : Location
- object
- $session : SESSION
- object
- $sort_as : string
- string
- $sort_by : string
- string
Methods
- cmp_mod() : int
- Comparison callback for sorting by Unix time
- cmp_mod_reverse() : int
- Comparison callback for sorting by Unix time reversed
- cmp_name() : string
- Comparison callback for sorting by name
- cmp_name_reverse() : string
- Comparison callback for sorting by name reversed
- cmp_size() : int
- Comparison callback for sorting by size
- cmp_size_reverse() : int
- Comparison callback for sorting by size reversed
- getFilename() : string
- get filename for display
- init() : void
- Determine sorting
- makeArrow() : string
- Make the arrow images
- makeLink() : string
- make an image link
- outputHtml() : string
- Output the HTML
- readDir() : void
- Read the file list from the directory
- run() : array<string|int, mixed>
- Main function, activating tasks
- sort() : void
- Sort the file list
Properties
$dirs
array
public
array<string|int, mixed>
$dirs
$files
array
public
array<string|int, mixed>
$files
$location
object
public
Location
$location
$session
object
public
SESSION
$session
$sort_as
string
public
string
$sort_as
$sort_by
string
public
string
$sort_by
Methods
cmp_mod()
Comparison callback for sorting by Unix time
public
static cmp_mod(int $b, int $a) : int
Parameters
- $b : int
- $a : int
Return values
intcmp_mod_reverse()
Comparison callback for sorting by Unix time reversed
public
static cmp_mod_reverse(int $b, int $a) : int
Parameters
- $b : int
- $a : int
Return values
intcmp_name()
Comparison callback for sorting by name
public
static cmp_name(FileServer $b, FileServer $a) : string
Parameters
- $b : FileServer
- $a : FileServer
Return values
stringcmp_name_reverse()
Comparison callback for sorting by name reversed
public
static cmp_name_reverse(FileServer $b, FileServer $a) : string
Parameters
- $b : FileServer
- $a : FileServer
Return values
stringcmp_size()
Comparison callback for sorting by size
public
static cmp_size(int $b, int $a) : int
Parameters
- $b : int
- $a : int
Return values
intcmp_size_reverse()
Comparison callback for sorting by size reversed
public
static cmp_size_reverse(int $b, int $a) : int
Parameters
- $b : int
- $a : int
Return values
intgetFilename()
get filename for display
public
static getFilename(FileServer $file) : string
Parameters
- $file : FileServer
-
Filename
Return values
string —modified filename
init()
Determine sorting
public
init() : void
makeArrow()
Make the arrow images
public
makeArrow(string $sort_by) : string
Parameters
- $sort_by : string
-
Column to sort on
Return values
stringmakeLink()
make an image link
public
makeLink(string $sort_by, string $sort_as, string $dir) : string
Parameters
- $sort_by : string
-
Which sort by arrow?
- $sort_as : string
-
Sort by ascending or descending?
- $dir : string
-
Directory with arrow images
Return values
stringoutputHtml()
Output the HTML
public
outputHtml() : string
Return values
stringreadDir()
Read the file list from the directory
public
readDir() : void
run()
Main function, activating tasks
public
run(Location $location[, bool $delete = false ]) : array<string|int, mixed>
Parameters
- $location : Location
- $delete : bool = false
-
Default is FALSE (don't output html, just return $this->files object). If TRUE, output html with no return
Return values
array<string|int, mixed> —Optional
sort()
Sort the file list
public
sort() : void