|
I'm not sure what you mean by a Java object; it could either mean the values currently in an instance of a class or a .class file in the file system.
If you mean the first, look into serialization. This allows you to take the values in an instance and store them in a binary or XML format in your database and then retrieve them into a new instance later on.
If you mean the second, you can open the file as a binary stream and write the stream to the database.
Either way, you would use JDBC to access your database.
|