I’m new to Java and I was wondering what I should do to save small/medium amounts of data for a Java Application. I’ve heard about YAML but I’m not sure if that’s my best choice. I’m just wondering how I should save small numbers, settings and even save files for simple games.
Share
For really simple data storage needs you can just use the java File Writer library for writing simple primitive data types to a file, then when you need to retrieve the data just use the File Reader Library. This is about as simple as you can get with storing data with java. If that is to simple, then I would suggest look at serializing your data objects and writing them to a file instead. Here’s a link, discusses the merits of object Serialization.