The common way is to translate the object to a table - every field of the object is (toughly) translates to a column of the table. The term for this is object relational mapping. There is plenty of documentation of this on the web (like this) as this is one of the cornerstones of modern day enterprise development.
There are several libraries you can use, and the best is to stick to the standard called JPA - Java Persistence API. The most known libraries (all open source) are
Your user defined object will look like this :
@Entity
@Table(name = "some_table")
public class SomeObject implements Serializable {
static final long serialVersionUID = <some value>;
@Id
@GeneratedValue
protected Long id;
@Column
protected String name;
@Column
protected int value;
// default constructor
// getters, setters
// equals, hashCode, toString
// other methods
}