【问题标题】:Hibernate without annotation entity没有注释实体的休眠
【发布时间】:2015-12-15 23:39:28
【问题描述】:

客户需要一个没有@entity 注释的解决方案。是否可以在没有 @entity 注释的情况下使用休眠?我有带有映射实体的hibernate.cfg.xml 文件:

.....
<mapping class="cz.tacr.elza.api.model.FindingAid"/>
....

【问题讨论】:

  • 只需要避免@Entity注解吗?或者你根本不应该使用任何注释?
  • 我只需要避免@Entity 注释

标签: java spring hibernate annotations


【解决方案1】:

看看这是否有帮助。向下滚动到“Hibernate 映射 XML 配置”。

http://www.journaldev.com/2882/hibernate-tutorial-for-beginners-using-xml-annotations-and-property-configurations

【讨论】:

    猜你喜欢
    • 2014-10-16
    • 2017-01-24
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-12-05
    • 2016-02-14
    • 1970-01-01
    相关资源
    最近更新 更多