Load values from config

@access private
337282
private function loadValues()
    {
        if (function_exists('CheckAuthentication')) {
            $this->_isEnabled = CheckAuthentication();
        }
        if (isset($GLOBALS['config']['LicenseName'])) {
            $this->_licenseName = (string)$GLOBALS['config']['LicenseName'];
        }
        if (isset($GLOBALS['config']['LicenseKey'])) {
            $this->_licenseKey = (string)$GLOBALS['config']['LicenseKey'];
        }
        if (isset($GLOBALS['config']['FilesystemEncoding'])) {
            $this->_filesystemEncoding = (string)$GLOBALS['config']['FilesystemEncoding'];
        }
        if (isset($GLOBALS['config']['RoleSessionVar'])) {
            $this->_roleSessionVar = (string)$GLOBALS['config']['RoleSessionVar'];
        }
        if (isset($GLOBALS['config']['CheckDoubleExtension'])) {
            $this->_checkDoubleExtension = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['CheckDoubleExtension']);
        }
        if (isset($GLOBALS['config']['DisallowUnsafeCharacters'])) {
            $this->_disallowUnsafeCharacters = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['DisallowUnsafeCharacters']);
        }
        if (isset($GLOBALS['config']['SecureImageUploads'])) {
            $this->_secureImageUploads = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['SecureImageUploads']);
        }
        if (isset($GLOBALS['config']['CheckSizeAfterScaling'])) {
            $this->_checkSizeAfterScaling = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['CheckSizeAfterScaling']);
        }
        if (isset($GLOBALS['config']['ForceAscii'])) {
            $this->_forceAscii = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['ForceAscii']);
        }
        if (isset($GLOBALS['config']['HtmlExtensions'])) {
            $this->_htmlExtensions = (array)$GLOBALS['config']['HtmlExtensions'];
        }
        if (isset($GLOBALS['config']['HideFolders'])) {
            $this->_hideFolders = (array)$GLOBALS['config']['HideFolders'];
        }
        if (isset($GLOBALS['config']['HideFiles'])) {
            $this->_hideFiles = (array)$GLOBALS['config']['HideFiles'];
        }
        if (isset($GLOBALS['config']['ChmodFiles'])) {
            $this->_chmodFiles = $GLOBALS['config']['ChmodFiles'];
        }
        if (isset($GLOBALS['config']['ChmodFolders'])) {
            $this->_chmodFolders = $GLOBALS['config']['ChmodFolders'];
        }
        if (isset($GLOBALS['config']['DefaultResourceTypes'])) {
            $_defaultResourceTypes = (string)$GLOBALS['config']['DefaultResourceTypes'];
            if (strlen($_defaultResourceTypes)) {
                $this->_defaultResourceTypes = explode(",", $_defaultResourceTypes);
            }
        }
        if (isset($GLOBALS['config']['TempDirectory'])) {
          $this->_tempDirectory = $GLOBALS['config']['TempDirectory'];
        }
        if (isset($GLOBALS['config']['XSendfile'])) {
          $this->_xsendfile = CKFinder_Connector_Utils_Misc::booleanValue($GLOBALS['config']['XSendfile']);
        }
        if (isset($GLOBALS['config']['XSendfileNginx'])) {
          $this->_xsendfileNginx = (array)$GLOBALS['config']['XSendfileNginx'];
        }
    }
985000
protected function loadConfig()
    {
        $this->container['app']->getConfig()->load($this->getConfigFiles());

        $this->dispatchEvent(KernelEvents::CONFIG_LOADED, new KernelEvent($this->container));
    }
643617
def load_user():
    """"""
    config_path = get_user_config_path()
    config = {}

    # TODO: This may be overkill and too slow just for reading a config file
    with open(config_path) as f:
        code = compile(f.read(), config_path, 'exec')
    exec(code, config)

    keys = list(six.iterkeys(config))
    for k in keys:
        if k.startswith('_'):
            del config[k]

    return config
1214185
protected function loadData(): void
	{
		$data = $this->store->read($this->sessionId);

		$this->sessionData = $data === false ? [] : $data;
	}
673014
public function loadConfigs()
    {
        $app = $this->app;

        $app['singular.check_directory']('config');

        $this->preloadFiles($app['singular.directory.config']);
        $this->registerConfigs();
    }
191634
protected function loadOptions(): void
    {
        $options = [];

        if ($this->preset == 'custom') {
            $optionsFile = null;
        } else {
            $optionsFile = __DIR__ . '/presets/' . $this->preset . '.php';
        }

        if ($optionsFile !== null) {
            if (!is_file($optionsFile)) {
                throw new InvalidConfigException('The CKEditor options file can not be loaded.');
            }
            $options = require($optionsFile);
        }

        $this->clientOptions = ArrayHelper::merge(
            $options,
            $this->clientOptions
        );
    }
2919
public function loadConfigs(...$names)
    {
        /** @var Config $config */
        $config = $this->make(Config::class);
        foreach ($names as $name) {
            $config->load($name);
        }
    }
617359
def _load_config():
    """"""
    fname = _get_config_fname()
    if fname is None or not op.isfile(fname):
        return dict()
    with open(fname, 'r') as fid:
        config = json.load(fid)
    return config
514511
public function _loadConfigVars(Smarty_Internal_Template $tpl, $_config_vars)
    {
        $this->_assignConfigVars($tpl->parent, $tpl, $_config_vars);
        $scope = $tpl->source->scope;
        if (!$scope && !$tpl->scope) {
            return;
        }
        foreach (array($scope, $tpl->scope) as $s) {
            $s = ($bubble_up = $s >= Smarty::SCOPE_BUBBLE_UP) ? $s - Smarty::SCOPE_BUBBLE_UP : $s;
            if ($bubble_up && $s) {
                $ptr = $tpl->parent->parent;
                if (isset($ptr)) {
                    $this->_assignConfigVars($ptr, $tpl, $_config_vars);
                    $ptr = $ptr->parent;
                }
                if ($s == Smarty::SCOPE_PARENT) {
                    continue;
                }
                while (isset($ptr) && $ptr->_objType == 2) {
                    $this->_assignConfigVars($ptr, $tpl, $_config_vars);
                    $ptr = $ptr->parent;
                }
                if ($s == Smarty::SCOPE_TPL_ROOT) {
                    continue;
                } elseif ($s == Smarty::SCOPE_SMARTY) {
                    $this->_assignConfigVars($tpl->smarty, $tpl, $_config_vars);
                } elseif ($s == Smarty::SCOPE_GLOBAL) {
                    $this->_assignConfigVars($tpl->smarty, $tpl, $_config_vars);
                } elseif ($s == Smarty::SCOPE_ROOT) {
                    while (isset($ptr->parent)) {
                        $ptr = $ptr->parent;
                    }
                    $this->_assignConfigVars($ptr, $tpl, $_config_vars);
                }
            }
        }
    }
1269478
protected static function _loadModulesConfig( )
		{
			$config = array( '..' , '.' );
			foreach ( static::options( ) as $key => $val )
			{
				$config[ ] = $key . '.php';
			}
			foreach ( Module::all( ) as $k => $module )
			{
				$scanned_directory = array_diff( scandir( ptc_path( 'root' ) . '/modules/' . $k . '/config' ) , $config );
				if ( !empty( $scanned_directory ) )
				{
					foreach ( $scanned_directory as $file )
					{
						$option_name = str_replace( '.php' , '' , $file );
						$options = require( ptc_path( 'root' ) . '/modules/' . $k . '/config/' . $file );
						if ( ptc_array_get( $options , '_load' ) )
						{
							$options = call_user_func( ptc_array_get( $options , '_load' ) , $options );
						}
						static::option( $option_name , $options );
					}
				}
			}
		}
1031536
function _load() {
  if (!existsSync(exports.configFile)) {
    _initFile();
  }

  try {
    return JSON.parse(fs.readFileSync(exports.configFile, 'utf8'));
  }
  catch (e) {
    console.error('JSON parse error');
    console.error('See and edit', exports.configFile);
    console.error('or exec `confy clean`');
    process.exit();
  }
}
1001155
private function load_strings() {
		if (file_exists(Config::$cache_directory . '/' . $this->language->name_short . '/' . $this->application_name . '.php')) {
			require Config::$cache_directory . '/' . $this->language->name_short . '/' . $this->application_name . '.php';
			$this->strings = $strings;
		}
	}
955948
public function load_config()
    {
        // defaults
        if ($config = $this->load_config_file(RCUBE_CONFIG_DIR . 'defaults.inc.php')) {
            $this->config   = (array) $config;
            $this->defaults = $this->config;
        }

        $config = null;

        // config
        if ($config = $this->load_config_file(RCUBE_CONFIG_DIR . 'config.inc.php')) {
            $this->config = array_merge($this->config, $config);
        }
        else {
            if ($config = $this->load_config_file(RCUBE_CONFIG_DIR . 'main.inc.php')) {
                $this->config        = array_merge($this->config, $config);
                $this->legacy_config = true;
            }

            if ($config = $this->load_config_file(RCUBE_CONFIG_DIR . 'db.inc.php')) {
                $this->config        = array_merge($this->config, $config);
                $this->legacy_config = true;
            }
        }

        $this->configured = !empty($config);
    }
141138
def load_config(cls, opts, path=None, profile=None):
        """"""
        if path and os.path.exists(path):
            if os.path.isdir(path):
                cls.config_searchpath.insert(0, path)
            else:
                cls.config_files.insert(0, path)

        config = cls.read_config()
        values = config.get("default", {})
        cls._load_values_into_opts(opts, values)

        if profile and profile != "default":
            values = config.get("profile:%s" % profile, {})
            cls._load_values_into_opts(opts, values)

        return values
1021908
def load_config(self):
    """"""
    config = dict([(key, value) for key, value in iteritems(self.options)
                   if key in self.cfg.settings and value is not None])
    for key, value in iteritems(config):
      self.cfg.set(key.lower(), value)
1234862
protected function scanLoadConfig(): void
    {
        /* @var SplFileInfo $directory */
        /* @var SplFileInfo $file */
        foreach (Finder::create()->directories()->depth(1)->name('Config')->in($this->modulePath()) as $directory) {
            foreach (Finder::create()->files()->name('*.php')->in($directory->getPathname()) as $file) {
                $this->mergeConfigFrom($file->getPathname(), Str::snake($directory->getRelativePath()));
            }
        }
    }
1130534
private function loadConfigData()
    {
        //Load config data
        $config = laradooConfig();


        $this->suffix = array_key_exists('api-suffix', $config) ? $config['api-suffix'] : $this->suffix;
        $this->suffix = laradooAddCharacter($this->suffix, '/');

        $this->host = array_key_exists('host', $config) ? $config['host'] : $this->host;
        $this->host = laradooRemoveCharacter($this->host, '/');

        $this->db = array_key_exists('db', $config) ? $config['db'] : $this->db;
        $this->username = array_key_exists('username', $config) ? $config['username'] : $this->username;
        $this->password = array_key_exists('password', $config) ? $config['password'] : $this->password;
    }