eclipse官网下载相应版本hibernate-tools或使用update site更新
1.下载hibernate-tools
eclipse(Indigo) - help - install new software - work with输入
http://download.jboss.org/jbosstools/updates/stable/indigo/
选择Abridged JBoss Tools 3.3 - Hibernate Tools - next更新
[img]http://dl2.iteye.com/upload/attachment/0091/5530/acbe149e-494c-31a3-9f90-f19a6d8587e5.jpg[/img]
2.eclipse工具栏如没有hibernate code Generation工具栏,在工具栏鼠标右键,选择
customize perspective..,打开customize perspective窗口,选择command groups availability选项,勾选hibernate code Generation。
[img]http://dl2.iteye.com/upload/attachment/0091/5532/1d4e9eb9-c9ff-3be7-8d85-81b6c1b39455.jpg[/img]
[img]http://dl2.iteye.com/upload/attachment/0091/5540/9700cd3d-59df-3b4b-bdd9-a65c117a957a.jpg[/img]
3.参考博客http://maimode.iteye.com/blog/1630670
4.最后生成pojo是选择Main后边的Exporters选项,setting勾选Generate EJB3 annotations,exproters勾选Domain code
[img]http://dl2.iteye.com/upload/attachment/0091/5542/d66901b5-2f23-391c-8bec-9fa51b15104e.jpg[/img]
1.下载hibernate-tools
eclipse(Indigo) - help - install new software - work with输入
http://download.jboss.org/jbosstools/updates/stable/indigo/
选择Abridged JBoss Tools 3.3 - Hibernate Tools - next更新
[img]http://dl2.iteye.com/upload/attachment/0091/5530/acbe149e-494c-31a3-9f90-f19a6d8587e5.jpg[/img]
2.eclipse工具栏如没有hibernate code Generation工具栏,在工具栏鼠标右键,选择
customize perspective..,打开customize perspective窗口,选择command groups availability选项,勾选hibernate code Generation。
[img]http://dl2.iteye.com/upload/attachment/0091/5532/1d4e9eb9-c9ff-3be7-8d85-81b6c1b39455.jpg[/img]
[img]http://dl2.iteye.com/upload/attachment/0091/5540/9700cd3d-59df-3b4b-bdd9-a65c117a957a.jpg[/img]
3.参考博客http://maimode.iteye.com/blog/1630670
4.最后生成pojo是选择Main后边的Exporters选项,setting勾选Generate EJB3 annotations,exproters勾选Domain code
[img]http://dl2.iteye.com/upload/attachment/0091/5542/d66901b5-2f23-391c-8bec-9fa51b15104e.jpg[/img]