PHP Класс Pop\Loader\Autoloader

Автор: Nick Sagona, III ([email protected])
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$classmap array Class map array.
$fallback boolean Flag to make the autoloader the fallback autoloader or not
$prefixes array Array of available namespaces prefixes.
$suppress boolean Flag to suppress warnings

Открытые методы

Метод Описание
__construct ( boolean $self = true ) : Autoloader Constructor
__invoke ( string $class ) : void Invoke the class
factory ( boolean $self = true ) : Autoloader Static method to instantiate the autoloader object
loadClassMap ( string $classmap ) : Autoloader Load a class map file
register ( string $namespace, string $directory ) : Autoloader Register a namespace and directory location with the autoloader
splAutoloadRegister ( boolean $suppress = true, boolean $fallback = false ) : Autoloader Register the autoloader instance with the SPL

Описание методов

__construct() публичный Метод

Instantiate the archive object
public __construct ( boolean $self = true ) : Autoloader
$self boolean
Результат Autoloader

__invoke() публичный Метод

Credit to Andreas Schipplock for helping to improve this method: https://github.com/schipplock
public __invoke ( string $class ) : void
$class string
Результат void

factory() публичный статический Метод

Static method to instantiate the autoloader object
public static factory ( boolean $self = true ) : Autoloader
$self boolean
Результат Autoloader

loadClassMap() публичный Метод

Load a class map file
public loadClassMap ( string $classmap ) : Autoloader
$classmap string
Результат Autoloader

register() публичный Метод

Register a namespace and directory location with the autoloader
public register ( string $namespace, string $directory ) : Autoloader
$namespace string
$directory string
Результат Autoloader

splAutoloadRegister() публичный Метод

Register the autoloader instance with the SPL
public splAutoloadRegister ( boolean $suppress = true, boolean $fallback = false ) : Autoloader
$suppress boolean
$fallback boolean
Результат Autoloader

Описание свойств

$classmap защищенное свойство

Class map array.
protected array $classmap
Результат array

$fallback защищенное свойство

Flag to make the autoloader the fallback autoloader or not
protected bool $fallback
Результат boolean

$prefixes защищенное свойство

Array of available namespaces prefixes.
protected array $prefixes
Результат array

$suppress защищенное свойство

Flag to suppress warnings
protected bool $suppress
Результат boolean