I have a java class to store Media objects for a movie/TV/DVD index. I'm planning to try to store these objects in a JavaDB database. It will have many thousands of entries.
I have read about serializing objects, and also a bit about hibernate and the persistence API, although I don't really understand how they work. I'm just getting confused on what exactly I should be learning how to do. Should I worry about these, or instead just make a table with all the info in VARCHAR columns?
Can anyone give me any tips on what system they would use to store all this info into a database? Or maybe just some general pointers on what you would do, and why?
Obviously I'm a newbie with databases. I have just done this codejava tutorial and can successfully create/connect to a JavaDB database.
Thanks!
public class Media {
File file_location;
String filename;
Date date;
int hres;
int vres;
boolean has_tbn;
File tbnloc;
boolean has_ss;
File ssloc;
int length;
String[] actors;
String[] tags;
boolean HD;
long filesize;
String md5 = "origMD5";
Media(File thefile) {
this.file_location = thefile;
}
Media(String thefile) {
this.file_location = new File(thefile);
}
// snipped getters and setters
}