Load all system structures.
@return type
335534
private function getStructures($direct = true, $rootClass = 'nav navbar-nav', $dropDown = false, $rootId = '')
    {
        $repo = $this->em->getRepository('WebCMS\Entity\Page');

        $structs = $repo->findBy(array(
            'language' => $this->language,
            'parent' => NULL,
        ));

        $structures = array();
        foreach ($structs as $s) {
            $structures[$s->getTitle()] = $this->getStructure($this, $s, $repo, $direct, $rootClass, $dropDown, true, null, '', null, $rootId);
        }

        return $structures;
    }
625187
protected static function fill_all_caches() {
        self::$subsystems = self::fetch_subsystems();

        list(self::$plugintypes, self::$parents, self::$subplugins) = self::fetch_plugintypes();

        self::$plugins = array();
        foreach (self::$plugintypes as $type => $fulldir) {
            self::$plugins[$type] = self::fetch_plugins($type, $fulldir);
        }

        self::fill_classmap_cache();
        self::fill_classmap_renames_cache();
        self::fill_filemap_cache();
        self::fetch_core_version();
    }
154243
public function load() {
		$this->specCsDecs = array();
		
		foreach ($this->moduleNamespaces as $moduleNamespace) {
			$moduleNamespace = (string) $moduleNamespace;
				
			if (!$this->modularConfigSource->containsModuleNamespace($moduleNamespace)) {
				$this->specCsDecs[$moduleNamespace] = null;
				continue;
			}
				
			$this->specCsDecs[$moduleNamespace] = new SpecConfigSourceDecorator(
					$this->modularConfigSource->getOrCreateConfigSourceByModuleNamespace($moduleNamespace), $moduleNamespace);
		}
	}
919954
public static function load()
    {
        if (!extension_loaded('opencensus')) {
            trigger_error('opencensus extension required to load Symfony integrations.', E_USER_WARNING);
            return;
        }

        Doctrine::load();

        // public function handle(Request $request, $type = HttpKernelInterface::MASTER_REQUEST, $catch = true)
        opencensus_trace_method(HttpKernel::class, 'handle', function ($kernel, $request) {
            return [
                'name' => 'kernel/handle'
            ];
        });

        // public function dispatch($eventName, Event $event = null)
        opencensus_trace_method(EventDispatcher::class, 'dispatch', function ($dispatcher, $eventName) {
            return [
                'name' => $eventName,
                'attributes' => ['eventName' => $eventName]
            ];
        });
    }
1080608
public function structureMetadata()
    {
        if ($this->structureMetadata === null || $this->isStructureFinalized === false) {
            $this->structureMetadata = $this->loadStructureMetadata();
        }

        return $this->structureMetadata;
    }
978937
final function LoadToBackend()
    {
        foreach ($this->Dependencies() as $depedency)
        {
            $bundleName = $depedency->BundleName();
            if (!in_array($bundleName, self::$_loadedBundles))
            {
                $depManifest = ClassFinder::Manifest($bundleName);
                $depManifest->LoadToBackend();
            }
        }
        $this->LoadBackendTranslations();
        $this->LoadBackendCode();
        self::$_loadedBundles[] = static::BundleName();
    }
665820
public static function readStructure()
    {
        if(count(self::$structure) == 0 ){
            if(self::USE_CACHE == false){
                //rebuild structure each time
                self::$structure = self::buildStructures();

            } else {
                //cache management
                try {
                    self::$structure = \common_cache_FileCache::singleton()->get(self::CACHE_KEY);
                } catch (\common_cache_NotFoundException $e) {
                    self::$structure = self::buildStructures();
                    \common_cache_FileCache::singleton()->put(self::$structure, self::CACHE_KEY);
                }

            }
        }
        return self::$structure;
    }
1011144
public function load()
    {
        $this->extensions = [];
        foreach ($this->getPackages() as $package) {
            [$v, $p] = explode('/', $package['name']);
            $extension = Extension::findBy([
                'vendor' => $v,
                'package' => $p
            ]);
            if (!$extension) {
                $extension = (new Extension())
                    ->vendor($v)
                    ->package($p);
            }
            $extension
                ->version($package['version'] ?? '')
                ->description($package['description'] ?? '')
                ->save();
            $this->extensions[] = $extension;
        }
        return $this;
    }
5475
protected function loadAllModules()
    {
        $listModules = array_diff(scandir(MODULES_DIR), ['.', '..']);

        foreach ($listModules as $moduleName) {
            $modulePath = realpath(MODULES_DIR.$moduleName); //Symlink

            if (!is_dir($modulePath)) {
                continue;
            }

            $this->moduleList->addModule($moduleName);
        }

        $this->moduleList->readNeedMeDependencies();
        $this->moduleList->generateTree();
    }
412890
public function Structure() {
      if(is_null($this->_Structure)) {
         $Name = $this->Engine . 'Structure';
         $this->_Structure = Gdn::Factory($Name);
         $this->_Structure->Database = $this;
      }
      
      return $this->_Structure;
   }
1130314
public function loadBundles() {
		if($this->loaded)
			return;

		$this->bundles = $this->doGetBundles();
		$container = $this->getContainer();

		if($this->params['env']) {
			if(file_exists($this->params['root'].'/app/bootstrap_'.strtolower($this->params['env']).'.php'))
				include $this->params['root'].'/app/bootstrap_'.strtolower($this->params['env']).'.php';
		}
		if(file_exists($this->params['root'].'/app/bootstrap_all.php'))
			include $this->params['root'].'/app/bootstrap_all.php';

		$this->runBundles();

		$this->loaded = true;

		return $this;
	}
200465
public function load()
    {
        $this->loadChildClasses();

        list($constructorResolvedOptions, $extraResolvedOptions) = $this->resolveOptions();
        $instance = $this->reflected->newInstanceArgs($constructorResolvedOptions);

        $this->loadExtraOptions($extraResolvedOptions, $instance);

        return $instance;
    }
1243917
public function loadTemplates()
    {
        if (!($this->configurationManager instanceof ConfigurationManager)) {
            throw new Exception('You need to install ConfigurationBundle');
        }

        $templates = new ArrayCollection([]);
        $bundles = $this->kernel->getBundles();

        /**
         * @var Bundle $bundle
         */
        foreach ($bundles as $bundle) {
            if ($bundle instanceof TemplateInterface) {
                $bundleName = $bundle->getName();
                $bundleNamespace = $bundle->getNamespace();
                $templates->set($bundleName, [
                    'bundle'    => $bundleName,
                    'namespace' => $bundleNamespace,
                    'name'      => $bundle->getTemplateName(),
                ]);
            }
        }

        $templatesArray = $templates->toArray();

        $this
            ->configurationManager
            ->set('store.templates', $templatesArray);

        return $templatesArray;
    }
815625
public function load() {
        $ext = mb_strtolower(pathinfo($this->_path, PATHINFO_EXTENSION));

        switch ($ext) {
            case 'php':
                return include $this->_path;
            break;
            case 'json':
                return json_decode(file_get_contents($this->_path), true);
            break;
            case 'ini':
                return parse_ini_file($this->_path, true);
            break;
            case 'txt':
                return file($this->_path, FILE_IGNORE_NEW_LINES);
            break;
        }

        throw new UnsupportedTypeException(sprintf('Unsupported FileLoader file type %s', $ext));
    }
1108354
protected function loadExternalConfig()
    {
        $config = new Repository(static::getDefaultConfig());
        $filesystem = new Filesystem();

        foreach ($this->getConfigFiles($filesystem) as $filename) {

            $this->output->writeln("<info>Reading config from <path>{$filename}</path></info>");

            if ($filesystem->extension($filename) == 'php') {
                $configValues = $filesystem->getRequire($filename);
            } else {
                $configValues = Yaml::parse($filesystem->get($filename));
            }

            $config->set(array_dot($configValues));
        }

        $this->container->instance('config', $config);
    }
1374563
protected function loadDependencies()
    {
        if (!empty($this->pharLocation)) {
            include_once 'phar://' . $this->pharLocation . '/vendor/autoload.php';
        }

        $className = '\PHPMD\PHPMD';

        if (!class_exists($className)) {
            @include_once 'PHP/PMD.php';
            $className = "PHP_PMD";
            $this->newVersion = false;
        }

        if (!class_exists($className)) {
            throw new BuildException(
                'PHPMDTask depends on PHPMD being installed and on include_path or listed in pharLocation.',
                $this->getLocation()
            );
        }

        if ($this->newVersion) {
            $minPriority = \PHPMD\AbstractRule::LOWEST_PRIORITY;
            include_once 'phing/tasks/ext/phpmd/PHPMDRendererRemoveFromCache.php';
        } else {
            include_once 'PHP/PMD/AbstractRule.php';
            $minPriority = PHP_PMD_AbstractRule::LOWEST_PRIORITY;
        }

        if (!$this->minimumPriority) {
            $this->minimumPriority = $minPriority;
        }

        return $className;
    }
918232
protected function load()
    {
        $path = $this->vendorDir . '/composer';
        if (!is_dir($path)) throw new InvalidProjectException('"composer" folder has not been found. Be sure to use this bundle on a project managed by Composer');

        $map = require $path . '/autoload_namespaces.php';
        foreach ($map as $namespace => $paths) {
            if ( ! is_array($paths)) {
                $paths = array($paths);
            }
            
            foreach ($paths as $path) {
                if (substr($path, -1) != '/') { 
                    $path .= '/';
                }

                $dir = $path . str_replace('\\', '/', $namespace);

                $bundleName = $this->getBundleName($dir);
                $this->addBundle($bundleName, $dir);
            }
        }
        
        $this->parseExtraFolders();
    }