Though java.util.properties allows reading and writing properties file, the writing does not preserve the formatting. Not surprising, because it is not tied to the property file.
Is there a PropertyFile class out there -- or some such -- that preserves comments and blank lines and updates property values in in place?