java HibernateUtil 的作用是什么?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/5078484/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-30 09:18:54 来源:igfitidea点击:
What is the role of HibernateUtil?
提问by Dino
I'm new to Hibernate, and everytime I come across a Hibernate tutorial there is a mention of HibernateUtil class ?
我是 Hibernate 的新手,每次我遇到 Hibernate 教程时都会提到 HibernateUtil 类?
What actually does it do ? And if there is a standard implementation why don't it being included in Hibernate jar itself?
它实际上有什么作用?如果有一个标准的实现,为什么不将它包含在 Hibernate jar 本身中呢?