Loads the configuration file
488644
private function _loadConfig($parsedConfig) {
        $this->_defaultLang     = $parsedConfig['moduleConf']['default_language'];
        $this->_saveOnCookies   = $parsedConfig['moduleConf']['save_on_cookies'];
        $this->_cookieName      = $parsedConfig['moduleConf']['cookie_name'];
        $this->_saveOnSession   = $parsedConfig['moduleConf']['save_on_session'];
        $this->_sessionKeyName  = $parsedConfig['moduleConf']['session_key_name'];
        if(isset($parsedConfig['moduleConf']['accepted_languages'])) {
            foreach ($parsedConfig['moduleConf']['accepted_languages'] as $l){
                $this->_accepted_languages[] = $l;
            }
        }
        else {
            $this->_accepted_languages = null;
        }
    }
1118729
def load_config(cls):
        
        config_file = os.path.expanduser(cls.home_config)
        global_conf = cls.load(config_file, 'global')
        cls.load(cls.local_config, 'local')
        # update global configuration if needed
        cls.update_config(config_file, global_conf)
100526
private function loadConfig()
    {
        // Look for .terra.yml
        $fs = new FileSystem();
        if ($fs->exists($this->getSourcePath().'/.terra.yml')) {
            try {
                // Process any string replacements.
                $environment_config_string = file_get_contents($this->getSourcePath().'/.terra.yml');
                $this->config = Yaml::parse(strtr($environment_config_string, array(
                  '{{alias}}' => $this->getDrushAlias(),
                  '{{uri}}' => $this->getUrl(),
                  '{{environment}}' => $this->environment->name,
                  '{{apps}}' => $this->app->name,
                )));
            }
            catch (\Symfony\Component\Yaml\Exception\ParseException $e) {
                $this->config = null;
            }
        } else {
            $this->config = null;
        }
    }
518768
protected function loadConfig()
    {
        if (self::$config_path === null) {
            throw new \BadMethodCallException('Config path is null');
        }

        $key = "$this->cnab/$this->bank_code";

        if (!array_key_exists($key, self::$cache)) {
            $config_file = self::$config_path . "/cnab$key.yml";
            if (file_exists($config_file)) {
                self::$cache[$key] = Yaml::parseFile($config_file);
            } else {
                throw new \RuntimeException(sprintf(
                    "Config file for Bank '%s' in CNAB%s not found",
                    $this->bank_code,
                    $this->cnab
                ));
            }
        }

        $this->config = $key;
    }
1231682
def load_config(filename):
    

    if filename is None:
        filename = ''

    abs_filename = os.path.join(os.getcwd(), filename)

    global FILE

    # find the config file
    if os.path.isfile(filename):
        FILE = filename
    elif os.path.isfile(abs_filename):
        FILE = abs_filename
    elif os.path.isfile(FILE):
        pass
    else:
        if os.path.dirname(filename):
            file_not_found = filename
        else:
            file_not_found = abs_filename
        file_not_found_message(file_not_found)

    # load config
    init(FILE)
91543
def load_dynamic_config(config_file=DEFAULT_DYNAMIC_CONFIG_FILE):
    """"""
    dynamic_configurations = {}

    # Insert config path so we can import it
    sys.path.insert(0, path.dirname(path.abspath(config_file)))
    try:
        config_module = __import__('config')

        dynamic_configurations = config_module.CONFIG
    except ImportError:
        # Provide a default if config not found
        LOG.error('ImportError: Unable to load dynamic config. Check config.py file imports!')

    return dynamic_configurations
751433
protected function loadConfig() {
		$app_root = Registry::getInstance()->app_root;
		if (file_exists($app_root . '/Application/config.php')) {
			require_once $app_root . '/Application/config.php';
		}

		if (file_exists($app_root . '/Application/localconfig.php')) {
			require_once $app_root . '/Application/localconfig.php';
		}

		if (isset($config)) {
			Registry::getInstance()->config = $config;
		} else {
			Registry::getInstance()->config = [];
		}
	}
316097
def load_config(path)
      return unless File.exist?(path)
      buf = File.read(path) 
      eval("#{buf}", binding, path)
    end
1229599
public function loadConfig()
    {
        parent::loadConfig();
        foreach(Config::get('@' . $this->moduleName . '.configs', []) as $name => $fileName)
        {
            Config::addConfig($name, include $fileName);
        }
    }
166425
private function loadingConfig()
    {
        if ($_SERVER['HTTP_HOST'] == SERVER_DEVELOP) {
            if (!is_file(SYSTEM_ROOT . '/config/config.local.php'))
                @copy(SYSTEM_ROOT . '/config/config.sample.php', SYSTEM_ROOT . '/config/config.local.php');
            require_once('config/config.local.php');
        } else {
            if (!is_file(SYSTEM_ROOT . '/config/config.php'))
                @copy(SYSTEM_ROOT . '/config/config.sample.php', SYSTEM_ROOT . '/config/config.php');
            require_once('config/config.php');
        }
    }
1054561
def load_config(path=None):
    """"""
    if not path or not op.exists(path):
        return Config()
    path = op.realpath(path)
    dirpath, filename = op.split(path)
    file_ext = op.splitext(path)[1]
    logger.debug("Load config file `%s`.", path)
    if file_ext == '.py':
        config = PyFileConfigLoader(filename, dirpath,
                                    log=logger).load_config()
    elif file_ext == '.json':
        config = JSONFileConfigLoader(filename, dirpath,
                                      log=logger).load_config()
    return config
1034159
def load_config(file)
      unless File.exists? file
        File.open(file, 'w') do |f| 
          YAML.dump({ default_website: 'default' }, f) 
        end
      end
      YAML.load_file(file)
    end
985000
protected function loadConfig()
    {
        $this->container['app']->getConfig()->load($this->getConfigFiles());

        $this->dispatchEvent(KernelEvents::CONFIG_LOADED, new KernelEvent($this->container));
    }
535520
def load_config_file(self):
        """"""
        config_parser = SafeConfigParser()

        config_parser.read(self.CONFIG_FILE)

        if config_parser.has_section('handlers'):
            self._config['handlers_package'] = config_parser.get('handlers', 'package')

        if config_parser.has_section('auth'):
            self._config['consumer_key'] = config_parser.get('auth', 'consumer_key')
            self._config['consumer_secret'] = config_parser.get('auth', 'consumer_secret')
            self._config['token_key'] = config_parser.get('auth', 'token_key')
            self._config['token_secret'] = config_parser.get('auth', 'token_secret')

        if config_parser.has_section('stream'):
            self._config['user_stream'] = config_parser.get('stream', 'user_stream').lower() == 'true'
        else:
            self._config['user_stream'] = False

        if config_parser.has_option('general', 'min_seconds_between_errors'):
            self._config['min_seconds_between_errors'] = config_parser.get('general', 'min_seconds_between_errors')
        if config_parser.has_option('general', 'sleep_seconds_on_consecutive_errors'):
            self._config['sleep_seconds_on_consecutive_errors'] = config_parser.get(
                'general', 'sleep_seconds_on_consecutive_errors')
307470
def load(self, filename):
        """"""
        content = open(filename)
        return Config(json.load(content))
659720
def _load_config(self):
        """"""
        self._config = ConfigParser.SafeConfigParser()
        self._config.read(self.config_path)
871844
def load(self, file_path):
        '''  '''
        self.clear()
        self.__config = self.read_file(file_path)