I have a situation where I need to change the value of properties file after the successful execution of a program.
I have a filename called myProperties.properties here I have value process.time='03/24/2010' and I have few other values in this property file. What I need to do is change the process.time value after successful execution of a program with out touching other values.
You could also do it manually. Or you could store that property in a completely separate file and reduce the risk of trashing your properties file. Or put it in a DB, which is where often-changed values really belong, IMO.
I agree but 1 change at the end of the program is not much. I don't think a DB is the solution because then people can't easily read the content and I'm assuming that's what the poster wants because otherwise we wouldn't mind that the format gets ruined.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.
posted 9 years ago
Thanks for your help guys. As per the replies I have created another properties file and always I update this file only.
Have a Good day.
Yes, my master! Here is the tiny ad you asked for: