__construct()
autoload()
getAutoloadMap()
realPharPath()
register()
registerAutoloadMap()
registerAutoloadMaps()
setOptions()
loadMapFromFile()
$map
$mapsLoaded
Class-map autoloader
Utilizes class-map files to lookup classfile locations.
__construct(null | array | \Traversable $options)
Create a new instance, and optionally configure the autoloader.
nullarray\Traversable
autoload($class) : mixed
mixed
False [if unable to load $class] get_class($class) [if $class is successfully loaded]getAutoloadMap() : array
array
realPharPath(string $path) : string
see | \Zend\Loader\https://bugs.php.net/bug.php?id=52769 |
---|
string
string
register() : void
Typically, the body of this will simply be:
spl_autoload_register(array($this, 'autoload'));
registerAutoloadMap(string | array $map) : \Zend\Loader\ClassMapAutoloader
An autoload map may be either an associative array, or a file returning an associative array.
An autoload map should be an associative array containing classname/file pairs.
stringarray
\Zend\Loader\Exception\InvalidArgumentException |
---|
registerAutoloadMaps(array $locations) : \Zend\Loader\ClassMapAutoloader
setOptions(array | \Traversable $options) : \Zend\Loader\ClassMapAutoloader
loadMapFromFile(string $location) : \Zend\Loader\ClassMapAutoloader | mixed
If the map has been previously loaded, returns the current instance; otherwise, returns whatever was returned by calling include() on the location.
string
\Zend\Loader\Exception\InvalidArgumentException |
for nonexistent locations |
---|
$map : array
$mapsLoaded : array