Added toDB class, that includes all the function for putting the files
into the DB, including necessary changes to Database.java