class ApcClassLoader

ApcClassLoader implements a wrapping autoloader cached in APC for PHP 5.3.

It expects an object implementing a findFile method to find the file. This allow using it as a wrapper around the other loaders of the component (the ClassLoader and the UniversalClassLoader for instance) but also around any other autoloader following this convention (the Composer one for instance)

$loader = new ClassLoader();

// register classes with namespaces $loader->add('Symfony\Component', __DIR__.'/component'); $loader->add('Symfony', __DIR__.'/framework');

$cachedLoader = new ApcClassLoader('my_prefix', $loader);

// activate the cached autoloader $cachedLoader->register();

// eventually deactivate the non-cached loader if it was registered previously // to be sure to use the cached one. $loader->unregister();

@author Fabien Potencier <fabien@symfony.com> @author Kris Wallsmith <kris@symfony.com>

@api

Hierarchy

Expanded class hierarchy of ApcClassLoader

1 file declares its use of ApcClassLoader

File

drupal/core/vendor/symfony/class-loader/Symfony/Component/ClassLoader/ApcClassLoader.php, line 42

Namespace

Symfony\Component\ClassLoader
View source

Members

Namesort descending Modifiers Type Description Overrides
ApcClassLoader::$decorated protected property The class loader object being decorated.
ApcClassLoader::$prefix private property
ApcClassLoader::findFile public function Finds a file by class name while caching lookups to APC.
ApcClassLoader::loadClass public function Loads the given class or interface.
ApcClassLoader::register public function Registers this instance as an autoloader.
ApcClassLoader::unregister public function Unregisters this instance as an autoloader.
ApcClassLoader::__call public function Passes through all unknown calls onto the decorated object.
ApcClassLoader::__construct public function Constructor.