function drupal_classloader_register

Registers an additional namespace.

Parameters

string $name: The namespace component to register; e.g., 'node'.

string $path: The relative path to the Drupal component in the filesystem.

3 calls to drupal_classloader_register()
simpletest_classloader_register in drupal/core/modules/simpletest/simpletest.module
Registers namespaces for disabled modules.
system_register in drupal/core/includes/module.inc
Registers an extension in runtime registries for execution.
UpdateModuleHandler::enable in drupal/core/lib/Drupal/Core/Extension/UpdateModuleHandler.php
Enables or installs a given list of modules.

File

drupal/core/includes/bootstrap.inc, line 2837
Functions that need to be loaded on every Drupal request.

Code

function drupal_classloader_register($name, $path) {
  $loader = drupal_classloader();
  $loader
    ->addPrefix('Drupal\\' . $name, DRUPAL_ROOT . '/' . $path . '/lib');
}