Expect Django Conf property
339511
def get_property(self, key):
        """"""
        _key = DJANGO_CONF[key]
        return getattr(self, _key, CONF_SPEC[_key])
1357342
function (localConfig, propertyName, propertyObject) {
    var presetCheck = defaultConfig.presets[propertyName][propertyObject];
    if (presetCheck) return $.extend(true, {}, presetCheck, localConfig);
    return localConfig
  }
1028742
def before_all(context):
    
    # Use pytest asserts if behave_pytest is installed
    install_pytest_asserts()

    # Get 'Config_environment' property from user input (e.g. -D Config_environment=ios)
    env = context.config.userdata.get('Config_environment')
    # Deprecated: Get 'env' property from user input (e.g. -D env=ios)
    env = env if env else context.config.userdata.get('env')
    if env:
        os.environ['Config_environment'] = env

    if not hasattr(context, 'config_files'):
        context.config_files = ConfigFiles()
    context.config_files = DriverWrappersPool.initialize_config_files(context.config_files)

    # By default config directory is located in environment path
    if not context.config_files.config_directory:
        context.config_files.set_config_directory(DriverWrappersPool.get_default_config_directory())

    context.global_status = {'test_passed': True}
    create_and_configure_wrapper(context)

    # Behave dynamic environment
    context.dyn_env = DynamicEnvironment(logger=context.logger)
861681
function(newValue,property,config) {
                var thesetter = config.setter;
                if ( typeof(config.setter) === 'string' ) {
                    record[config.setter](newValue, property, config,record);
                } else {
                    //assume function
                    thesetter.call(record,newValue, property, config,record);
                }

            }
1033
def _assert_correct_model(model_to_check, model_reference, obj_name):
        
        if not issubclass(model_to_check, model_reference):
            raise ConfigurationException('The %s model must be a subclass of %s'
                                         % (obj_name, model_reference.__name__))
1217978
def _configure(self, config):
		
		config = config or dict()
		
		# We really need this to be there.
		if 'extensions' not in config: config['extensions'] = list()
		
		if not any(isinstance(ext, BaseExtension) for ext in config['extensions']):
			# Always make sure the BaseExtension is present since request/response objects are handy.
			config['extensions'].insert(0, BaseExtension())
		
		if not any(isinstance(ext, arguments.ArgumentExtension) for ext in config['extensions']):
			# Prepare a default set of argument mutators.
			config['extensions'].extend([
					arguments.ValidateArgumentsExtension(),
					arguments.ContextArgsExtension(),
					arguments.RemainderArgsExtension(),
					arguments.QueryStringArgsExtension(),
					arguments.FormEncodedKwargsExtension(),
					arguments.JSONKwargsExtension(),
				])
		
		config['extensions'].append(self)  # Allow the application object itself to register callbacks.
		
		try:
			addLoggingLevel('trace', logging.DEBUG - 5)
		except AttributeError:
			pass
		
		# Tests are skipped on these as we have no particular need to test Python's own logging mechanism.
		level = config.get('logging', {}).get('level', None)
		if level:  # pragma: no cover
			logging.basicConfig(level=getattr(logging, level.upper()))
		elif 'logging' in config:  # pragma: no cover
			logging.config.dictConfig(config['logging'])
		
		return config
1049135
def check(cls):
        
        attribs = [
            'app_version',
            'app_name',
            'config_file_path',
            'config_sep_str',
        ]
        for attrib in attribs:
            if getattr(cls, attrib) == 'not_set':
                raise IncompleteSetupError(f'elib_config setup is incomplete; missing: {attrib}')
62908
def config_absent(name):
    '''
    

    '''
    name = name.lower()
    ret = {'name': name,
           'changes': {},
           'result': None,
           'comment': ''}

    # load configuration
    config = _load_config()

    if name in config:
        # delete property
        ret['result'] = True
        ret['comment'] = 'property {0} deleted'.format(name)
        ret['changes'][name] = None
        del config[name]
    else:
        # we're good
        ret['result'] = True
        ret['comment'] = 'property {0} is absent'.format(name)

    # apply change if needed
    if not __opts__['test'] and ret['changes']:
        ret['result'] = _write_config(config)

    return ret
200882
def configure_settings(settings, environment_settings=True):
    '''
    
    '''
    changes = 1
    iterations = 0

    while changes:
        changes = 0
        app_names = ['django_autoconfig'] + list(settings['INSTALLED_APPS'])
        if environment_settings:
            app_names.append('django_autoconfig.environment_settings')
        for app_name in app_names:
            import django_autoconfig.contrib
            if autoconfig_module_exists(app_name):
                module = importlib.import_module("%s.autoconfig" % (app_name,))
            elif app_name in django_autoconfig.contrib.CONTRIB_CONFIGS:
                module = django_autoconfig.contrib.CONTRIB_CONFIGS[app_name]
            else:
                continue
            changes += merge_dictionaries(
                settings,
                getattr(module, 'SETTINGS', {}),
                template_special_case=True,
            )
            changes += merge_dictionaries(
                settings,
                getattr(module, 'DEFAULT_SETTINGS', {}),
                only_defaults=True,
            )
            for relationship in getattr(module, 'RELATIONSHIPS', []):
                changes += relationship.apply_changes(settings)

        if iterations >= MAX_ITERATIONS:
            raise ImproperlyConfigured(
                'Autoconfiguration could not reach a consistent state'
            )
        iterations += 1
    LOGGER.debug("Autoconfiguration took %d iterations.", iterations)
831629
def init(opts):
    '''
    
    '''
    if CONFIG_BASE_URL in opts['proxy']:
        CONFIG[CONFIG_BASE_URL] = opts['proxy'][CONFIG_BASE_URL]
    else:
        log.error('missing proxy property %s', CONFIG_BASE_URL)
    log.debug('CONFIG: %s', CONFIG)
355809
def validate_type(prop, value, expected):
    

    # Validate on expected type(s), but ignore None: defaults handled elsewhere
    if value is not None and not isinstance(value, expected):
        _validation_error(prop, type(value).__name__, None, expected)
26111
def pass_config(func=None, **config_kw):
    """"""

    def decorate(func):
        def new_func(*args, **kw):
            config = load_config(**config_kw)
            func(config, *args, **kw)

        return functools.update_wrapper(new_func, func)

    if func is None:
        return decorate
    else:
        return decorate(func)
474989
def config_property(name, type, value)
      RubyAem::Resources::ConfigProperty.new(@client, name, type, value)
    end
951304
def conf(self, key=None, defval=None):
        ''''''
        if key is None:
            return self._ypconf
        val = self._ypconf.conf(key)
        return defval if val is None else val
656748
def configure(self, conf={}):
        
        if not conf: return
        if isinstance(conf, Configuration):
            conf = dict(conf.options())
        for key, value in conf.items():
            opt = self.get(key, None)
            if isinstance(opt, Configuration):
                opt.configure(value)
            else:
                setattr(self, key, value)
1177451
function config(context, cb) {
  var viewModel = {
    package: helper.find(context.data, {kind: 'package'})[0]
  };

  util.view('conf.py', viewModel, cb);
}
336823
private static void autowareStaticConfig(Class<?> cls, Properties prop) throws Exception {

        if (null == prop) {
            throw new Exception("cannot autowareConfig null");
        }

        try {

            Field[] fields = cls.getDeclaredFields();

            for (Field field : fields) {

                if (field.isAnnotationPresent(DisconfFileItem.class)) {

                    if (!Modifier.isStatic(field.getModifiers())) {
                        continue;
                    }

                    field.setAccessible(true);

                    String name = field.getName();
                    Object value = prop.getProperty(name, null);
                    if (value != null) {
                        ClassUtils.setFieldValeByType(field, null, String.valueOf(value));
                    }
                }
            }
        } catch (Exception e) {

            throw new Exception("error while autowire config file", e);
        }
    }