generate java domain objects from database table

You can use something like Hibernate to accomplish this

This plugin set for Eclipse called Hibernate Tools for Eclipse and ANT will do most of the work for you.

In particular it will do Reverse Engineering: The most powerful feature of Hibernate Tools is a database reverse engineering tool that can generate domain model classes and Hibernate mapping files, annotated EJB3 entity beans, HTML documentation or even an entire JBoss Seam application in seconds!


Telosys code generator does this kind of job. It's an Eclipse plugin, it uses the database schema to create a light model that is used to generate the Java code.

There are some predefined templates available on GitHub (for JPA, POJO, Documentation, Spring MVC, etc )

See http://www.telosys.org

and http://marketplace.eclipse.org/content/telosys-tools

Templates : https://github.com/telosys-templates-v3

Articles about code generation with Telosys :

  • https://modeling-languages.com/telosys-tools-the-concept-of-lightweight-model-for-code-generation/
  • https://dzone.com/articles/telosys-a-code-generation-tool-by-laurent-guerin