public class MapSettings extends Settings
Settings. It must be used
only for unit tests. This is not the implementation
deployed at runtime, so non-test code must never cast
Settings to MapSettings.| Constructor and Description |
|---|
MapSettings() |
MapSettings(PropertyDefinitions definitions) |
| Modifier and Type | Method and Description |
|---|---|
MapSettings |
clear()
Delete all properties
|
protected Optional<String> |
get(String key) |
Map<String,String> |
getProperties()
Immutable map of the properties that have non-default values.
|
protected void |
remove(String key) |
protected void |
set(String key,
String value) |
addProperties, addProperties, appendProperty, getBoolean, getDate, getDateTime, getDefaultValue, getDefinition, getDefinitions, getDouble, getEncryption, getFloat, getInt, getKeysStartingWith, getLong, getRawString, getString, getStringArray, getStringArrayBySeparator, getStringLines, hasDefaultValue, hasKey, removeProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setPropertypublic MapSettings()
public MapSettings(PropertyDefinitions definitions)
public Map<String,String> getProperties()
SettingsPropertyDefinitions are ignored,
so the returned values are not the effective values. Basically only
the non-empty results of Settings.getRawString(String) are returned.
Values are not decrypted if they are encrypted with a secret key.
getProperties in class Settingspublic MapSettings clear()
Copyright © 2009–2017 SonarSource. All rights reserved.