Configures component by passing configuration parameters.

        :param config: configuration parameters to be set.
420104
def configure(self, config):
        
        self._dependency_resolver.configure(config)
        self._logger.configure(config)
1289921
def configure(defaults, metadata, loader):
    
    config = Configuration(defaults)
    config.merge(loader(metadata))
    validate(defaults, metadata, config)
    return config
1236609
def initialize(**kwargs):
    
    global config
    config_opts = kwargs.setdefault('config',{})

    if isinstance(config_opts,basestring):
        config_opts = {'config_filename':config_opts}
        kwargs['config'] = config_opts

    if 'environment' in kwargs:
        config_opts['environment'] = kwargs['environment']

    config.load_config(**config_opts)

    # Overlay the subconfig
    if kwargs.get('name'):
        subconfig = config.get(kwargs.get('name'),{})
        config.overlay_add(subconfig)

    config.overlay_add(app_config)
655249
def config(*args, **kwargs, &block)
      if block
        configuration_builder.config(*args, **kwargs, &block)
      else
        configuration_builder.config(*args, **kwargs)
      end
    end
204438
def add_config(self, config):
        
        for attr in self.__fixed_attrs:
            if attr in config:
                raise Exception("cannot set '%s' outside of init", attr)

        # pre checkout

        stages = config.get('stages', None)
        if stages:
            self.stages = stages

        # maybe pre checkout

        # validate options
        self.__dry_run = config.get('dry_run', False)

        self.system = str.lower(platform.system())

        self.__start = config.get('start', None)
        self.__end = config.get('end', None)
        self.__only = config.get('only', None)

        self.__build_docs = config.get('build_docs', False)
        self.__chatty = config.get('chatty', False)
        self.__clean = config.get('clean', False)
        self.__devel = config.get('devel', False)
        self.__debug = config.get('debug', False)
        self.__skip_libcheck = config.get('skip_libcheck', False)
        self.__debuginfo = config.get('debuginfo', False)
        self.__release = config.get('release', False)
        self.__skip_unit = config.get('skip_unit', False)
        self.__static = config.get('static', False)
        self.__make_dash_j = int(config.get('j', 0))
        self.__target_only = config.get('target_only', None)

        bits = config.get('bits', None)
        if bits:
            self.bits = int(bits)
        else:
            self.bits = self.sys_bits

        self.compiler = config.get('compiler', None)
        self.test_config = config.get('test_config', '-')
        if not self.test_config:
            self.test_config = '-'
        self.use_ccache = config.get('use_ccache', False)
        self.tmpl_engine = config.get('tmpl_engine', 'jinja2')
        self.__write_codec = config.get('write_codec', None)
        self.__codec = None

        # TODO move out of init
        if not config.get('skip_env_check', False):
            if "LD_LIBRARY_PATH" in os.environ:
                raise Exception("environment variable LD_LIBRARY_PATH is set")

        self.check_config()
68207
protected function configure(array $config = [])
    {
        foreach ($config as $key => $value) {
            $method = 'set' . $key;
            if (method_exists($this, $method)) {
                $this->$method($value);
            }
        }
    }
311863
async def set_config(self, config):
        
        config_facade = client.ModelConfigFacade.from_connection(
            self.connection()
        )
        for key, value in config.items():
            if isinstance(value, ConfigValue):
                config[key] = value.value
        await config_facade.ModelSet(config)
286353
public function setConfiguration($config) {
		if(!($config instanceof Config))
			$config = new Config($config);
		$this->config = $config;
	}
675255
@Override
	public void configure(ConfigParams config) throws ConfigException {
		ConfigParams dependencies = config.getSection("dependencies");
		for (String name : dependencies.keySet()) {
			String locator = dependencies.get(name);
			if (locator == null)
				continue;

			try {
				Descriptor descriptor = Descriptor.fromString(locator);
				if (descriptor != null)
					_dependencies.put(name, descriptor);
				else
					_dependencies.put(name, locator);
			} catch (Exception ex) {
				_dependencies.put(name, locator);
			}
		}
	}
302735
public static void addConfig(Config config) {
		if (config == null) {
			throw new IllegalArgumentException("Config can not be null");
		}
		if (configNameToConfig.containsKey(config.getName())) {
			throw new IllegalArgumentException("Config already exists: " + config.getName());
		}
		
		configNameToConfig.put(config.getName(), config);
		
		/** 
		 * Replace the main config if current config name is MAIN_CONFIG_NAME
		 */
		if (MAIN_CONFIG_NAME.equals(config.getName())) {
			DbKit.config = config;
			Db.init(DbKit.config.getName());
		}
		
		/**
		 * The configName may not be MAIN_CONFIG_NAME,
		 * the main config have to set the first comming Config if it is null
		 */
		if (DbKit.config == null) {
			DbKit.config = config;
			Db.init(DbKit.config.getName());
		}
	}
1287349
public function setConfiguration(Configuration $config)
    {
        if ($config === null) {
            throw new Exception\InvalidArgumentException('$config cannot be null');
        }


        if ($this->config !== null) {
            $this->config->unregisterConfigChangeListener($this->getConfigChangeListener());
        }

        $this->config = $config;
        $this->setOptions($config->getZendLdapConfiguration());
        $this->config->registerConfigChangeListener($this->getConfigChangeListener());
    }
1171501
def load_config(self, config):
        

        self.config = copy_config(config, self.mutable_config_keys)
        if 'cookiejar_cookies' in config['state']:
            self.cookies = CookieManager.from_cookie_list(
                config['state']['cookiejar_cookies'])
696140
public static synchronized void configure(final ApiConfiguration config) {
		
		ApiConfiguration.Builder builder = ApiConfiguration.newBuilder();
		
		builder.apiUrl(config.getApiUrl());
		builder.apiKey(config.getApiKey());
		builder.application(config.getApplication());
		builder.environment(config.getEnvironment());
		
		if (config.getEnvDetail() == null)
		{
			builder.envDetail(EnvironmentDetails.getEnvironmentDetail(config.getApplication(), config.getEnvironment()));
		}
		else
		{
			builder.envDetail(config.getEnvDetail());
		}
		
		CONFIG = builder.build();
	}
879665
@Override
	public void configure(ConfigParams config) {
		_name = config.getAsStringWithDefault("name", _name);
		_name = config.getAsStringWithDefault("info.name", _name);

		_description = config.getAsStringWithDefault("description", _description);
		_description = config.getAsStringWithDefault("info.description", _description);

		_properties = config.getSection("properties");

	}
1047695
public void configure(ConfigParams config, boolean configAsDefault) {
		_connections.addAll(ConnectionParams.manyFromConfig(config, configAsDefault));
	}
1062030
public final void initConfiguration(String config) {

        m_configuration = config;
        m_configurationMap = CmsStringUtil.splitAsMap(config, "|", ":");
        m_configurationMap.put(CmsContentDefinition.PARAM_INIT_CALL, INIT_FUNCTION_PREFIX + getName());
        m_jsonConfig = new JSONObject(new HashMap<String, Object>(m_configurationMap));
    }
513899
def set_config(self, config):
        """"""
        self.config.update(config)
        if self.config_map:
            for child_name in self.config_map:
                child_config = self._compound_children[child_name].get_config()
                for parent_item, child_item in self.config_map[child_name]:
                    child_config[child_item] = self.config[parent_item]
                self._compound_children[child_name].set_config(child_config)
        else:
            for name, child in self._compound_children.items():
                child.set_config(self.config[name])