class Import (View source)

Methods

__construct()

No description

array
logs()

Get log

int|false
boot()

Fill libs from ./system/boot/namespaces.php source.

int
classmap()

Fill libs from autoload_classmap.php source.

int
psr4()

Load autoload_psr4.php classes, used by PSR-4 packages

int
psr0()

Load autoload_namespaces.php classes, used by PSR-0 packages

setItem(string $prefix, string $path, string $delimiter = '\\')

Associate namespace prefix to folder class namespace to file

array
getLibs()

Return array of libs

bool
save(string $path)

Save imported packages path to file in PHP format ()

int
files()

Fill script files from autoload_files.php source.

bool
saveFiles(string $path, bool $removeEmpty = false)

Save imported autoload files path to file in PHP format

Details

__construct()

No description

array logs()

Get log

Return Value

array

int|false boot()

Fill libs from ./system/boot/namespaces.php source.

Return Value

int|false

Returns the total number of loaded packages, if namespaces.php is not accessible returns false

int classmap()

Fill libs from autoload_classmap.php source.

Return Value

int

Return total packages loaded

int psr4()

Load autoload_psr4.php classes, used by PSR-4 packages

Return Value

int

Return total packages loaded

int psr0()

Load autoload_namespaces.php classes, used by PSR-0 packages

Return Value

int

Return total packages loaded, if autoload_namespaces.php

setItem(string $prefix, string $path, string $delimiter = '\\')

Associate namespace prefix to folder class namespace to file

Parameters

string $prefix
string $path
string $delimiter

Exceptions

Exception

array getLibs()

Return array of libs

Return Value

array

bool save(string $path)

Save imported packages path to file in PHP format ()

Parameters

string $path

File to save packages paths (e.g., /foo/namespaces.php)

Return Value

bool

int files()

Fill script files from autoload_files.php source.

Return Value

int

Return total script files loaded

bool saveFiles(string $path, bool $removeEmpty = false)

Save imported autoload files path to file in PHP format

Parameters

string $path

File to save packages paths (e.g., /foo/files.php)

bool $removeEmpty

Remove the destination file if there are no files to be included

Return Value

bool