72
I'm trying to have a default java.util.Properties object in my class, with the default properties it accepts, and let the developer override some of them by specifying another java.util.Properties object, but I couldn't find a nice way for doing that.
The intended usage is the following:
Properties defaultProperties = new Properties();
defaultProperties.put("key1", "value1");
defaultProperties.put("key2", "value2");
Properties otherProperties = new Properties();
otherProperties.put("key2", "value3");
Properties finalProperties = new Properties(defaultProperties);
//
// I'd expect to have something like:
//
// finalProperties.merge(otherProperties);
//