protected function registerClassLoaders(GenericStackable $classLoaders)
{
// intialize the additional container class loaders
foreach ($this->getContainerNode()->getClassLoaders() as $classLoaderNode) {
// initialize the storage for the include path
$includePath = array();
// load the application base directory
$appBase = $this->getAppBase();
// load the composer class loader for the configured directories
foreach ($classLoaderNode->getDirectories() as $directory) {
// we prepare the directories to include scripts AFTER registering (in application context)
$includePath[] = $appBase . $directory->getNodeValue();
}
// load the class loader type
$className = $classLoaderNode->getType();
// initialize and register the class loader instance
$classLoaders[$classLoaderNode->getName()] = new $className(new GenericStackable(), $includePath);
$classLoaders[$classLoaderNode->getName()]->register(true, true);
}
}