Why write this blog, because often have colleagues or netizens asked me Hiberante entity class generation problem. So the next time someone asks me if I can save a bunch of words, actually this is really very simple.
Now the application of hibernate in the project is more and more extensive. I started to study it after I started supporting annotation syntax from Hibernate. To be honest, the original hibernate generated a heap of XML files looked dizzy, still inferior to write their own SQL statements to the comfortable, so have been listening to friends and colleagues introduced, but they have been disdain to use it.
But now it's blessed. Hibernate is one of the most common implementations of JPA, and hiberante itself supports annotation syntax. Now you don't need to look at the XML maps of that heap. And Eclipse also provides the tools to generate entity class directly from the database. Since you can write less or do not write SQL statements that happy and for it. Cut the crap and start doing it.
Or start with the first step of our project, the new project. In general, we use Java to do Web projects are file->new->dynamic Web project, the following figure:
The dialog box for the new project appears as shown in the picture