How to reference another property in java.util.Properties?

Chris Mair’s XProperties class may be a good starting point.

You can substitute a constant anywhere in the property value, and even have more than one constant within a value, as in the following example:

CONST_1 = shoes and ships
CONST_2 = sealing wax
SomeValue = {CONST_1} and {CONST_2} 

In this example, the “SomeValue” property evaluates to “shoes and ships and sealing wax.”

Leave a Comment