src/Mouf/Composer/ComposerService.php
public static function registerAutoloader()
	{
		if (null !== static::$loader) {
			return static::$loader;
		}

		static::$loader = $loader = new \Composer\Autoload\ClassLoader();
		$vendorDir = dirname(__DIR__);
		$baseDir = dirname($vendorDir);

		$map = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_namespaces.php';
		foreach ($map as $namespace => $path) {
			$loader->set($namespace, $path);
		}

		$map = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_psr4.php';
		foreach ($map as $namespace => $path) {
			$loader->setPsr4($namespace, $path);
		}

		$classMap = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_classmap.php';
		if ($classMap) {
			$loader->addClassMap($classMap);
		}

		$loader->register();

		return $loader;
	}
public static function registerAutoloader()
	{
		if (null !== static::$loader) {
			return static::$loader;
		}

		static::$loader = $loader = new \Composer\Autoload\ClassLoader();
		$vendorDir = dirname(__DIR__);
		$baseDir = dirname($vendorDir);

		$map = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_namespaces.php';
		foreach ($map as $namespace => $path) {
			$loader->set($namespace, $path);
		}

		$map = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_psr4.php';
		foreach ($map as $namespace => $path) {
			$loader->setPsr4($namespace, $path);
		}

		$classMap = require 'phar://'.__DIR__.'/../../../composer.phar/vendor/composer/autoload_classmap.php';
		if ($classMap) {
			$loader->addClassMap($classMap);
		}

		$loader->register();

		return $loader;
	}
public static function registerAutoloader ( ) { if ( null !== static :: $ loader ) { return static :: $ loader ; } static :: $ loader = $ loader = new \ Composer \ Autoload \ ClassLoader ( ) ; $ vendorDir = dirname ( __DIR__ ) ; $ baseDir = dirname ( $ vendorDir ) ; $ map = require 'phar://' . __DIR__ . '/../../../composer.phar/vendor/composer/autoload_namespaces.php' ; foreach ( $ map as $ namespace => $ path ) { $ loader -> set ( $ namespace , $ path ) ; } $ map = require 'phar://' . __DIR__ . '/../../../composer.phar/vendor/composer/autoload_psr4.php' ; foreach ( $ map as $ namespace => $ path ) { $ loader -> setPsr4 ( $ namespace , $ path ) ; } $ classMap = require 'phar://' . __DIR__ . '/../../../composer.phar/vendor/composer/autoload_classmap.php' ; if ( $ classMap ) { $ loader -> addClassMap ( $ classMap ) ; } $ loader -> register ( ) ; return $ loader ; }
Register the autoloader for composer.
Register the autoloader for composer .