public static class FeatureAdapter.DefaultSettingsAdapter extends java.lang.Object implements FeatureAdapter.SettingsAdapter
| Modifier and Type | Field and Description |
|---|---|
private java.util.Map<java.lang.String,java.lang.String> |
settings |
| Constructor and Description |
|---|
DefaultSettingsAdapter() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
get(java.lang.String key,
java.lang.String def)
Get settings value for a certain key and provide a default value.
|
boolean |
put(java.lang.String key,
java.lang.String value)
Set a value for a certain setting.
|
private final java.util.Map<java.lang.String,java.lang.String> settings
public DefaultSettingsAdapter()
public java.lang.String get(java.lang.String key, java.lang.String def)
FeatureAdapter.SettingsAdapterget in interface FeatureAdapter.SettingsAdapterkey - the identifier for the settingdef - the default value. For each call of get() with a given key, the
default value must be the same. def may be null.def otherwisepublic boolean put(java.lang.String key, java.lang.String value)
FeatureAdapter.SettingsAdapterput in interface FeatureAdapter.SettingsAdapterkey - the unique identifier for the settingvalue - the value of the setting. Can be null or "" which both removes the key-value entry.true, if something has changed (i.e. value is different than before)