[ Index ] |
PHP Cross Reference of YOURLS |
[Source view] [Print] [Project Stats]
(no description)
File Size: | 579 lines (16 kb) |
Included or required: | 1 time |
Referenced: | 0 times |
Includes or requires: | 0 files |
ClassLoader:: (24 methods):
__construct()
getPrefixes()
getPrefixesPsr4()
getFallbackDirs()
getFallbackDirsPsr4()
getClassMap()
addClassMap()
add()
addPsr4()
set()
setPsr4()
setUseIncludePath()
getUseIncludePath()
setClassMapAuthoritative()
isClassMapAuthoritative()
setApcuPrefix()
getApcuPrefix()
register()
unregister()
loadClass()
findFile()
getRegisteredLoaders()
findFileWithExtension()
initializeIncludeClosure()
Class: ClassLoader - X-Ref
ClassLoader implements a PSR-0, PSR-4 and classmap class loader.__construct($vendorDir = null) X-Ref |
param: string|null $vendorDir |
getPrefixes() X-Ref |
return: array<string, list<string>> |
getPrefixesPsr4() X-Ref |
return: array<string, list<string>> |
getFallbackDirs() X-Ref |
return: list<string> |
getFallbackDirsPsr4() X-Ref |
return: list<string> |
getClassMap() X-Ref |
return: array<string, string> Array of classname => path |
addClassMap(array $classMap) X-Ref |
return: void param: array<string, string> $classMap Class to filename map |
add($prefix, $paths, $prepend = false) X-Ref |
Registers a set of PSR-0 directories for a given prefix, either appending or prepending to the ones previously set for this prefix. return: void param: string $prefix The prefix param: list<string>|string $paths The PSR-0 root directories param: bool $prepend Whether to prepend the directories |
addPsr4($prefix, $paths, $prepend = false) X-Ref |
Registers a set of PSR-4 directories for a given namespace, either appending or prepending to the ones previously set for this namespace. return: void param: string $prefix The prefix/namespace, with trailing '\\' param: list<string>|string $paths The PSR-4 base directories param: bool $prepend Whether to prepend the directories |
set($prefix, $paths) X-Ref |
Registers a set of PSR-0 directories for a given prefix, replacing any others previously set for this prefix. return: void param: string $prefix The prefix param: list<string>|string $paths The PSR-0 base directories |
setPsr4($prefix, $paths) X-Ref |
Registers a set of PSR-4 directories for a given namespace, replacing any others previously set for this namespace. return: void param: string $prefix The prefix/namespace, with trailing '\\' param: list<string>|string $paths The PSR-4 base directories |
setUseIncludePath($useIncludePath) X-Ref |
Turns on searching the include path for class files. return: void param: bool $useIncludePath |
getUseIncludePath() X-Ref |
Can be used to check if the autoloader uses the include path to check for classes. return: bool |
setClassMapAuthoritative($classMapAuthoritative) X-Ref |
Turns off searching the prefix and fallback directories for classes that have not been registered with the class map. return: void param: bool $classMapAuthoritative |
isClassMapAuthoritative() X-Ref |
Should class lookup fail if not found in the current class map? return: bool |
setApcuPrefix($apcuPrefix) X-Ref |
APCu prefix to use to cache found/not-found classes, if the extension is enabled. return: void param: string|null $apcuPrefix |
getApcuPrefix() X-Ref |
The APCu prefix in use, or null if APCu caching is not enabled. return: string|null |
register($prepend = false) X-Ref |
Registers this instance as an autoloader. return: void param: bool $prepend Whether to prepend the autoloader or not |
unregister() X-Ref |
Unregisters this instance as an autoloader. return: void |
loadClass($class) X-Ref |
Loads the given class or interface. return: true|null True if loaded, null otherwise param: string $class The name of the class |
findFile($class) X-Ref |
Finds the path to the file where the class is defined. return: string|false The path if found, false otherwise param: string $class The name of the class |
getRegisteredLoaders() X-Ref |
Returns the currently registered loaders keyed by their corresponding vendor directories. return: array<string, self> |
findFileWithExtension($class, $ext) X-Ref |
return: string|false param: string $class param: string $ext |
initializeIncludeClosure() X-Ref |
return: void |
Generated: Mon Mar 31 05:10:02 2025 | Cross-referenced by PHPXref 0.7.1 |