Configure an SBI for this subarray.

        Args:
            sbi_config (str): SBI configuration JSON

        Returns:
            str,
480948
def configure(self, sbi_config: str):
        
        # print(sbi_config)
        config_dict = json.loads(sbi_config)
        self.debug_stream('SBI configuration:\n%s',
                          json.dumps(config_dict, indent=2))
        try:
            sbi = Subarray(self.get_name()).configure_sbi(config_dict)
        except jsonschema.exceptions.ValidationError as error:
            return json.dumps(dict(path=error.absolute_path.__str__(),
                                   schema_path=error.schema_path.__str__(),
                                   message=error.message), indent=2)
        except RuntimeError as error:
            return json.dumps(dict(error=str(error)), indent=2)
        return 'Accepted SBI: {}'.format(sbi.id)
885875
def connect(self, config):
        
        if isinstance(config, str):
            conn = dbutil.get_database(config_file=config)
        elif isinstance(config, dict):
            conn = dbutil.get_database(settings=config)
        else:
            raise ValueError("Configuration, '{}',  must be a path to "
                             "a configuration file or dict".format(config))
        return conn
249785
def create(configs):
    
    if not configs:
        raise Error(ANDROID_DEVICE_EMPTY_CONFIG_MSG)
    elif configs == ANDROID_DEVICE_PICK_ALL_TOKEN:
        ads = get_all_instances()
    elif not isinstance(configs, list):
        raise Error(ANDROID_DEVICE_NOT_LIST_CONFIG_MSG)
    elif isinstance(configs[0], dict):
        # Configs is a list of dicts.
        ads = get_instances_with_configs(configs)
    elif isinstance(configs[0], basestring):
        # Configs is a list of strings representing serials.
        ads = get_instances(configs)
    else:
        raise Error('No valid config found in: %s' % configs)
    valid_ad_identifiers = list_adb_devices() + list_adb_devices_by_usb_id()

    for ad in ads:
        if ad.serial not in valid_ad_identifiers:
            raise DeviceError(ad, 'Android device is specified in config but'
                              ' is not attached.')
    _start_services_on_ads(ads)
    return ads
1013027
def _get_service_config(self):
        
        key = self._get_or_create_service_key()

        config = {}
        config['service_key'] = [{'name': self.name}]
        config.update(key['entity']['credentials'])

        return config
681776
def configure(self, config):
        
        credentials = CredentialParams.many_from_config(config)
        for credential in credentials:
            self._credentials.append(credential)
426860
def configuration(ctx):
    
    t = [["Key", "Value"]]
    for key in ctx.bitshares.config:
        t.append([key, ctx.bitshares.config[key]])
    print_table(t)
951490
def _config(self):
        
        config = 0
        if self.mode == MODE_NORMAL:
            config += (self._t_standby << 5)
        if self._iir_filter:
            config += (self._iir_filter << 2)
        return config
585885
def configure(cls, impl, **kwargs):
        # type: (Union[None, str, Type[Configurable]], Any) -> None
        
        base = cls.configurable_base()
        if isinstance(impl, str):
            impl = typing.cast(Type[Configurable], import_object(impl))
        if impl is not None and not issubclass(impl, cls):
            raise ValueError("Invalid subclass of %s" % cls)
        base.__impl_class = impl
        base.__impl_kwargs = kwargs
1040114
def get_configuration(self):
        
        mapping = {}
        settings = self.get_settings()
        for service in self.context.getService():
            uid = api.get_uid(service)
            setting = settings.get(uid, {})
            config = {
                "hidden": setting.get("hidden", False),
            }
            mapping[uid] = config
        return mapping
841995
def setConfigKey(key, value):
		
		configFile = ConfigurationManager._configFile()
		return JsonDataManager(configFile).setKey(key, value)
488725
def configs(max_configs=1, offset=None, serial=False, create_uuid=True):
    
    global default_selector
    return default_selector.configs(max_configs, offset, serial, create_uuid)
674585
def set_config(self, config, and_restart=False):
        
        assert isinstance(config, dict)
        self.post('config', data=config)
        if and_restart:
            self.restart()
289963
def _api_config_item(self, item):
        
        response.content_type = 'application/json; charset=utf-8'

        config_dict = self.config.as_dict()
        if item not in config_dict:
            abort(400, "Unknown configuration item %s" % item)

        try:
            # Get the JSON value of the config' dict
            args_json = json.dumps(config_dict[item])
        except Exception as e:
            abort(404, "Cannot get config item (%s)" % str(e))
        return args_json
202373
def _load_json_config(self):
        
        try:
            return json.loads(self._read_config())
        except ValueError as error:
            raise ValueError(
                'Could not read configuration file: {}'.format(error))
1338072
def configure(self):
        # type: () -> None
        
        for i in vars(self):
            if i.startswith("_"):
                continue
            val = self.__get(i, return_type=type(getattr(self, i)))
            if val is not None:
                setattr(self, i, val)
172470
def _configuration(self, *args, **kwargs):
        '''
        
        '''

        data = dict()
        self.db.open()
        for pkg in self.db.get(Package):
            configs = list()
            for pkg_cfg in self.db.get(PackageCfgFile, eq={'pkgid': pkg.id}):
                configs.append(pkg_cfg.path)
            data[pkg.name] = configs

        if not data:
            raise InspectorQueryException("No inspected configuration yet available.")

        return data
395553
def sbi_ids(self) -> List[str]:
        
        return ast.literal_eval(DB.get_hash_value(self._key, 'sbi_ids'))