Everything that works gives you good performance and requires the least amount of code.
Java serialization is easy. Be quick if you do not have large object schedules. This may not work if you ever want to interact with another language or want the file to be readable / editabl. It can be fragile.
XML refers to multilingual interaction, can be read and edited by people. If you use Java, Jaxb is very, very easy and fast. If you need to save a lot of settings, SAX / StAX may be required. You might want to use the DOM / JDom in very strange circumstances.
If there are many settings that you want to save and execute the query, the embedded SQL database is an option. I recommend H2.
source share