class DebugClassLoader

Autoloader checking if the class is really defined in the file found.

The ClassLoader will wrap all registered autoloaders and will throw an exception if a file is found but does not declare the class.

Methods

__construct(callable $classLoader)

No description

callable
getClassLoader()

Gets the wrapped class loader.

static 
enable()

Wraps all autoloaders.

static 
disable()

Disables the wrapping.

string|null
findFile($class)

No description

loadClass(string $class)

Loads the given class or interface.

checkAnnotations(ReflectionClass $refl, $class)

No description

checkCase(ReflectionClass $refl, $file, $class)

No description

Details

at line 44
__construct(callable $classLoader)

Parameters

callable $classLoader

at line 78
callable getClassLoader()

Gets the wrapped class loader.

Return Value

callable The wrapped class loader

at line 86
static enable()

Wraps all autoloaders.

at line 112
static disable()

Disables the wrapping.

at line 134
string|null findFile($class)

Parameters

$class

Return Value

string|null

at line 146
loadClass(string $class)

Loads the given class or interface.

Parameters

string $class The name of the class

Exceptions

RuntimeException

at line 221
checkAnnotations(ReflectionClass $refl, $class)

Parameters

ReflectionClass $refl
$class

at line 398
checkCase(ReflectionClass $refl, $file, $class)

Parameters

ReflectionClass $refl
$file
$class