PHP Class PPI\Framework\Autoload

It is able to load classes that use either: * The technical interoperability standards for PHP 5.3 namespaces and class names (https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-0.md); Example usage: PPI\Framework\Autoload::add('Symfony', PPI_VENDOR_PATH . '/path/to/src/Symfony') PPI\Framework\Autoload::register();
Afficher le fichier Open project: ppi/framework Class Usage Examples

Méthodes publiques

Свойство Type Description
$_options array

Protected Properties

Свойство Type Description
$_loader null | object The ClassLoader object.
$_registeredNamespaces array

Méthodes publiques

Méthode Description
add ( string $key, string $path ) Add a namespace to the autoloader path.
config ( array $config ) Add some items to the class config.
exists ( string $key ) : boolean Check if a namespace has been registered. This is a workaround as the default self::$_options['loader'] class does not have an exists() method.
register ( ) Register the autoloader namespaces or prefixes thus far.

Method Details

add() public static méthode

Add a namespace to the autoloader path.
public static add ( string $key, string $path )
$key string
$path string

config() public static méthode

Add some items to the class config.
public static config ( array $config )
$config array

exists() public static méthode

Check if a namespace has been registered. This is a workaround as the default self::$_options['loader'] class does not have an exists() method.
public static exists ( string $key ) : boolean
$key string
Résultat boolean

register() public static méthode

Register the autoloader namespaces or prefixes thus far.
public static register ( )

Property Details

$_loader protected_oe static_oe property

The ClassLoader object.
protected static null|object $_loader
Résultat null | object

$_options public_oe static_oe property

public static array $_options
Résultat array

$_registeredNamespaces protected_oe static_oe property

protected static array $_registeredNamespaces
Résultat array