Fork me on GitHub

读取hibernate.cfg.xml文件

new Configuration().configure().buildSessionFactory()

new Configuration()默认是读取hibernate.properties

所以使用new Configuration().configure()来读取hibernate.cfg.xml配置文件

posted on 2017-06-01 14:53  ScvQ  阅读(486)  评论(0编辑  收藏  举报

导航