public class ConfigParametersBasedConfigData extends Object implements ConfigData
ConfigData
based on two instances of
ConfigParameters
. The second one serves as a set of
default parameters. It will be used if the first one has not the requested
key-value pair.Constructor and Description |
---|
ConfigParametersBasedConfigData(ConfigParameters config,
ConfigParameters defaultConfig)
Creates an instance.
|
Modifier and Type | Method and Description |
---|---|
String |
get(String key)
Returns the value associated with this key.
|
String |
getFullKey(String key)
Returns the full key.
|
ConfigData |
getNode(String key)
Returns the ConfigData object associated with this key.
|
public ConfigParametersBasedConfigData(ConfigParameters config, ConfigParameters defaultConfig)
config
- A set of key-value pairs.defaultConfig
- The default set of key-value pairs.public String getFullKey(String key)
getFullKey
in interface ConfigData
key
- A (relative) key. null is not allowed.public String get(String key)
get
in interface ConfigData
key
- The relative key. null is not allowed.public ConfigData getNode(String key)
getNode
in interface ConfigData
key
- The relative key. null is not allowed.Copyright © 2015. All Rights Reserved.