mirror of
https://github.com/corda/corda.git
synced 2025-06-16 14:18:20 +00:00
add Properties.getProperty(String,String)
This commit is contained in:
@ -37,6 +37,14 @@ public class Properties extends Hashtable {
|
|||||||
return (String)get(key);
|
return (String)get(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getProperty(String key, String defaultValue) {
|
||||||
|
String value = (String) get(key);
|
||||||
|
if (value == null) {
|
||||||
|
return defaultValue;
|
||||||
|
}
|
||||||
|
return value;
|
||||||
|
}
|
||||||
|
|
||||||
public void setProperty(String key, String value) {
|
public void setProperty(String key, String value) {
|
||||||
put(key, value);
|
put(key, value);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user