Call this to finalise any additional key bindings we want to create in the mod.
@param settings Minecraft's original GameSettings object which we are appending to.
970395
private void fixAdditionalKeyBindings(GameSettings settings)
    {
        if (this.additionalKeys == null)
        {
            return; // No extra keybindings to add.
        }
    
        // The keybindings are stored in GameSettings as a java built-in array.
        // There is no way to append to such arrays, so instead we create a new
        // array of the correct
        // length, copy across the current keybindings, add our own ones, and
        // set the new array back
        // into the GameSettings:
        KeyBinding[] bindings = (KeyBinding[]) ArrayUtils.addAll(settings.keyBindings, this.additionalKeys.toArray());
        settings.keyBindings = bindings;
    }
50118
@Override
    public void setSetting(String setting) throws CDKException {
        if (settings.contains(setting)) {
            this.setting = setting;
        } else {
            throw new CDKException("Setting " + setting + " is not allowed.");
        }
    }
1039350
public void setSetting(int setting) throws CDKException {
        if (setting < settings.size() + 1 && setting > 0) {
            this.setting = (String) settings.get(setting - 1);
        } else {
            throw new CDKException("Setting " + setting + " does not exist.");
        }
    }
67080
private function setSettings()
    {
        if (!empty($this->settings['url']) && is_string($this->settings['url'])) {
            $this->url = $this->settings['url'];
        } if (!empty($this->settings['version']) && is_string($this->settings['version'])) {
            $this->version = $this->settings['version'];
        } if (isset($this->settings['call']) && is_bool($this->settings['call'])) {
            $this->call = $this->settings['call'];
        } if (isset($this->settings['secured']) && is_bool($this->settings['secured'])) {
            $this->secure = $this->settings['secured'];
        }
        $this->changed = false;
    }
302788
public void setConfigurationSettings(java.util.Collection<ConfigurationSettingsDescription> configurationSettings) {
        if (configurationSettings == null) {
            this.configurationSettings = null;
            return;
        }

        this.configurationSettings = new com.amazonaws.internal.SdkInternalList<ConfigurationSettingsDescription>(configurationSettings);
    }
1190127
public void updateIndividualSettings(Map<String, String> newSettings) {

        m_individualSettings = Collections.unmodifiableMap(newSettings);
        setSettings(getIndividualSettings());
    }
1029240
private function setSettings($settings)
    {
        if ($settings) {
            foreach ($this->settings as $key => &$value) {
                if (!empty($settings->{$key}) && $settings->{$key}) {
                    $value = $settings->{$key};
                }
            }
        }
    }
757959
public function setSettings($settings = [])
    {
        $original = $this->settings;
        $this->mergeSettings($settings, $this->settings);
        if ($this->settings != $original) {
            // @todo - Log Curl equivalent during test mode (adds overhead and risk so only do it during test)
            // if (!isset($this->settings['handler']) && class_exists(
            //         '\Namshi\Cuzzle\Middleware\CurlFormatterMiddleware'
            //     )) {
            //     $this->logger      = new Logger('guzzle.to.curl'); //initialize the logger
            //     $this->testHandler = new TestHandler(); //test logger handler
            //     $this->logger->pushHandler($this->testHandler);
            //
            //     $this->handler = HandlerStack::create();
            //     $this->handler->after('cookies', new \Namshi\Cuzzle\Middleware\CurlFormatterMiddleware($this->logger));
            //     $this->settings['handler'] = $this->handler;
            // }
            $this->client = new Client($this->settings);
        }
    }
435455
public static function setMany($settings = [], $defaultSettings = [])
    {
        $settings = static::parseDefaultOptions($settings, $defaultSettings);

        array_walk($settings, function ($value, $key) {
            static::set($key, $value);
        });
    }
352810
protected function addModelSettings(array &$settings)
    {
        $empty = $this->util->getTranslated()->getEmptyDropdownArray();

        $settings['elementClass'] = 'Select';
        $settings['multiOptions'] = $empty + $this->util->getDbLookup()->getUserConsents();
    }
1273655
def init_match_settings(self):
        
        self.mode_type_combobox.addItems(game_mode_types)
        self.map_type_combobox.addItems(map_types)
969736
public void setSettingsRef(String settingsRef) {
                if (GitTaskUtils.isNullOrBlankString(settingsRef)) {
                        throw new BuildException("Can't set blank git settings reference.");
                }

                // no override
                if (this.settingsRef == null) {
                        this.settingsRef = settingsRef;
                }
        }
569046
public void setSettings(java.util.Collection<OutputDestinationSettings> settings) {
        if (settings == null) {
            this.settings = null;
            return;
        }

        this.settings = new java.util.ArrayList<OutputDestinationSettings>(settings);
    }
1106026
public void setBindings( Collection<VarBindingDef> bindings)
    {
    bindings_ = new HashMap<VarDef,VarBindingDef>();
    properties_ = new PropertySet();
    
    if( bindings != null)
      {
      for( VarBindingDef binding : bindings)
        {
        add( binding);
        }
      }
    }
5009
function HostMapping(settings) {
        settings.init("hostConfig", {});
        settings.init("hostMapping", {});
        settings.init("xdmConfig", {});
        this.settings = settings;
      }
870077
private void applySettings() {
		buttonContainer.reset();
		WButton exampleButton = new WButton(tfButtonLabel.getText());

		exampleButton.setRenderAsLink(cbRenderAsLink.isSelected());

		exampleButton.setText(tfButtonLabel.getText());

		if (cbSetImage.isSelected()) {
			exampleButton.setImage("/image/pencil.png");
			exampleButton.setImagePosition((ImagePosition) ddImagePosition.getSelected());
		}

		exampleButton.setDisabled(cbDisabled.isSelected());

		if (tfAccesskey.getText() != null && tfAccesskey.getText().length() > 0) {
			exampleButton.setAccessKey(tfAccesskey.getText().toCharArray()[0]);
		}

		buttonContainer.add(exampleButton);
	}
37611
def apply_settings(settings):
    
    for key, value in settings.items():
        ConfigManager.SETTINGS[key] = value