1.引入依賴
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-jpamodelgen</artifactId>
</dependency>
2.idea 的設置
在idea里設置annotation processors,如下圖所示
設置完成后,重新編譯項目,會在對應的目錄生成實體對象的元模型,類似與User_
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-jpamodelgen</artifactId>
</dependency>
在idea里設置annotation processors,如下圖所示
設置完成后,重新編譯項目,會在對應的目錄生成實體對象的元模型,類似與User_
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。