Zend Framework
3.0
|
Public Member Functions | |
__construct ($options=null) | |
Constructor. | |
setOptions ($options) | |
Configure the autoloader. | |
getModuleClassMap () | |
Retrieves the class map for all loaded modules. | |
setModuleClassMap (array $classmap) | |
Sets the class map used to speed up the module autoloading. | |
autoload ($class) | |
Autoload a class. | |
register () | |
Register the autoloader with spl_autoload registry. | |
unregister () | |
Unregister the autoloader with spl_autoload registry. | |
registerPaths ($paths) | |
registerPaths | |
registerPath ($path, $moduleName=false) | |
registerPath | |
getPaths () | |
getPaths | |
Static Public Member Functions | |
static | normalizePath ($path, $trailingSlash=true) |
Normalize a path for insertion in the stack. | |
Protected Member Functions | |
loadModuleFromDir ($dirPath, $class) | |
loadModuleFromDir | |
loadModuleFromPhar ($pharPath, $class) | |
loadModuleFromPhar | |
pharFileToModuleName ($pharPath) | |
Returns the base module name from the path to a phar. | |
Protected Attributes | |
$paths = array() | |
$explicitPaths = array() | |
$namespacedPaths = array() | |
$pharBasePath = "" | |
$pharExtensions = array() | |
$moduleClassMap = array() | |
__construct | ( | $options = null | ) |
Constructor.
Allow configuration of the autoloader via the constructor.
null | array | Traversable | $options |
Implements SplAutoloader.
autoload | ( | $class | ) |
Autoload a class.
$class |
Implements SplAutoloader.
getModuleClassMap | ( | ) |
Retrieves the class map for all loaded modules.
getPaths | ( | ) |
getPaths
This is primarily for unit testing, but could have other uses.
|
protected |
loadModuleFromDir
string | $dirPath | |
string | $class |
|
protected |
loadModuleFromPhar
string | $pharPath | |
string | $class |
|
static |
Normalize a path for insertion in the stack.
string | $path | |
bool | $trailingSlash | Whether trailing slash should be included |
|
protected |
Returns the base module name from the path to a phar.
string | $pharPath |
register | ( | ) |
registerPath | ( | $path, | |
$moduleName = false |
|||
) |
registerPath
string | $path | |
bool | string | $moduleName |
\InvalidArgumentException |
registerPaths | ( | $paths | ) |
registerPaths
array | Traversable | $paths |
\InvalidArgumentException |
setModuleClassMap | ( | array | $classmap | ) |
Sets the class map used to speed up the module autoloading.
array | $classmap |
setOptions | ( | $options | ) |
Configure the autoloader.
In most cases, $options should be either an associative array or Traversable object.
array | Traversable | $options |
Implements SplAutoloader.
unregister | ( | ) |
Unregister the autoloader with spl_autoload registry.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |