mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 10:38:45 +02:00
extract methods for apply context on oql
This commit is contained in:
@@ -42,8 +42,6 @@ namespace Composer\Autoload;
|
||||
*/
|
||||
class ClassLoader
|
||||
{
|
||||
private $vendorDir;
|
||||
|
||||
// PSR-4
|
||||
private $prefixLengthsPsr4 = array();
|
||||
private $prefixDirsPsr4 = array();
|
||||
@@ -59,13 +57,6 @@ class ClassLoader
|
||||
private $missingClasses = array();
|
||||
private $apcuPrefix;
|
||||
|
||||
private static $registeredLoaders = array();
|
||||
|
||||
public function __construct($vendorDir = null)
|
||||
{
|
||||
$this->vendorDir = $vendorDir;
|
||||
}
|
||||
|
||||
public function getPrefixes()
|
||||
{
|
||||
if (!empty($this->prefixesPsr0)) {
|
||||
@@ -309,17 +300,6 @@ class ClassLoader
|
||||
public function register($prepend = false)
|
||||
{
|
||||
spl_autoload_register(array($this, 'loadClass'), true, $prepend);
|
||||
|
||||
if (null === $this->vendorDir) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ($prepend) {
|
||||
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
|
||||
} else {
|
||||
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||
self::$registeredLoaders[$this->vendorDir] = $this;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -328,10 +308,6 @@ class ClassLoader
|
||||
public function unregister()
|
||||
{
|
||||
spl_autoload_unregister(array($this, 'loadClass'));
|
||||
|
||||
if (null !== $this->vendorDir) {
|
||||
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -391,16 +367,6 @@ class ClassLoader
|
||||
return $file;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the currently registered loaders indexed by their corresponding vendor directories.
|
||||
*
|
||||
* @return self[]
|
||||
*/
|
||||
public static function getRegisteredLoaders()
|
||||
{
|
||||
return self::$registeredLoaders;
|
||||
}
|
||||
|
||||
private function findFileWithExtension($class, $ext)
|
||||
{
|
||||
// PSR-4 lookup
|
||||
|
||||
@@ -371,6 +371,7 @@ return array(
|
||||
'DBObjectSetComparator' => $baseDir . '/core/dbobjectset.class.php',
|
||||
'DBProperty' => $baseDir . '/core/dbproperty.class.inc.php',
|
||||
'DBSearch' => $baseDir . '/core/dbsearch.class.php',
|
||||
'DBSearchHelper' => $baseDir . '/application/DBSearchHelper.php',
|
||||
'DBUnionSearch' => $baseDir . '/core/dbunionsearch.class.php',
|
||||
'DailyRotatingLogFileNameBuilder' => $baseDir . '/core/log.class.inc.php',
|
||||
'Dashboard' => $baseDir . '/application/dashboard.class.inc.php',
|
||||
@@ -1917,7 +1918,7 @@ return array(
|
||||
'TemplateString' => $baseDir . '/core/templatestring.class.inc.php',
|
||||
'TemplateStringPlaceholder' => $baseDir . '/core/templatestring.class.inc.php',
|
||||
'ThemeHandler' => $baseDir . '/application/themehandler.class.inc.php',
|
||||
'ThemeHandlerService' => $baseDir . '/application/themehandlerservice.class.inc.php',
|
||||
'ThemeHandlerService' => $baseDir . '/application/themehandlerservice.class.inc.php',
|
||||
'ToolsLog' => $baseDir . '/core/log.class.inc.php',
|
||||
'Trigger' => $baseDir . '/core/trigger.class.inc.php',
|
||||
'TriggerOnObject' => $baseDir . '/core/trigger.class.inc.php',
|
||||
|
||||
@@ -25,7 +25,7 @@ class ComposerAutoloaderInit0018331147de7601e7552f7da8e3bb8b
|
||||
require __DIR__ . '/platform_check.php';
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInit0018331147de7601e7552f7da8e3bb8b', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit0018331147de7601e7552f7da8e3bb8b', 'loadClassLoader'));
|
||||
|
||||
$includePaths = require __DIR__ . '/include_paths.php';
|
||||
|
||||
@@ -601,6 +601,7 @@ class ComposerStaticInit0018331147de7601e7552f7da8e3bb8b
|
||||
'DBObjectSetComparator' => __DIR__ . '/../..' . '/core/dbobjectset.class.php',
|
||||
'DBProperty' => __DIR__ . '/../..' . '/core/dbproperty.class.inc.php',
|
||||
'DBSearch' => __DIR__ . '/../..' . '/core/dbsearch.class.php',
|
||||
'DBSearchHelper' => __DIR__ . '/../..' . '/application/DBSearchHelper.php',
|
||||
'DBUnionSearch' => __DIR__ . '/../..' . '/core/dbunionsearch.class.php',
|
||||
'DailyRotatingLogFileNameBuilder' => __DIR__ . '/../..' . '/core/log.class.inc.php',
|
||||
'Dashboard' => __DIR__ . '/../..' . '/application/dashboard.class.inc.php',
|
||||
|
||||
Reference in New Issue
Block a user