锘??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲日本久久久午夜精品,黑人大战亚洲人精品一区
,精品亚洲AV无码一区二区三区
http://www.tkk7.com/andy199999/category/10906.html-----------------MSN:andy1999999@163.com<br>
-----------------QQ:106256951
<bgsound src="http://club.whinfo.net.cn/bbs/upfile/2005-7/mp3/20057101738283.mp3" loop="-1"><br>
-----------------浜轟負鍠?紱忚櫧鏈嚦紲稿凡榪滅; 浜轟負鎭?紲歌櫧鏈嚦紱忓凡榪滅
zh-cnSat, 26 Jul 2008 08:59:07 GMTSat, 26 Jul 2008 08:59:07 GMT60Difference between getCurrentSession() and openSession() in hibernate.http://www.tkk7.com/andy199999/archive/2008/07/25/217382.html<a target=_blank>104浜哄姏閾惰</a><a target=_blank>104浜哄姏閾惰</a>Fri, 25 Jul 2008 02:32:00 GMThttp://www.tkk7.com/andy199999/archive/2008/07/25/217382.htmlhttp://www.tkk7.com/andy199999/comments/217382.htmlhttp://www.tkk7.com/andy199999/archive/2008/07/25/217382.html#Feedback0http://www.tkk7.com/andy199999/comments/commentRss/217382.htmlhttp://www.tkk7.com/andy199999/services/trackbacks/217382.html
鍘熸枃鏉ヨ嚜錛?/font>
http://www.techfaq360.com/viewFreshers.jsp?tutorialId=840
getCurrentSession() : The "current session" refers to a hibernate Session bound by hibernate behind the scenes, to the transaction scope. A Session is opened when getCurrentSession() is called for the first time and closed when the transaction ends. It is also flushed automatically before the transaction commits. You can call getCurrentSession() as often and anywhere you want as long as the transaction runs. To enable this strategy in your hibernate configuration:
set hibernate.transaction.manager_lookup_class to a lookup strategy for your JEE container set hibernate.transaction.factory_class to org.hibernate.transaction.JTATransactionFactory
Only the Session that you obtained with sf.getCurrentSession() is flushed and closed automatically.
Example : try { UserTransaction tx = (UserTransaction)new InitialContext() .lookup("java:comp/UserTransaction");
tx.begin();
// Do some work sf.getCurrentSession().createQuery(...); sf.getCurrentSession().persist(...);
openSession() : If you decide to use manage the Session yourself the go for sf.openSession() , you have to flush() and close() it. It does not flush and close() automatically. Example : UserTransaction tx = (UserTransaction)new InitialContext() .lookup("java:comp/UserTransaction");
Session session = factory.openSession();
try { tx.begin();
// Do some work session.createQuery(...); session.persist(...);
session.flush(); // Extra work you need to do
tx.commit(); } catch (RuntimeException e) { tx.rollback(); throw e; // or display error message } finally { session.close(); // Extra work you need to do }
]]>appfuse1.8.0瀹夎app_user.enabled data type (1111, 鈥榖it鈥? not recognized and will be ignored閿欒瑙e喅鍔炴硶http://www.tkk7.com/andy199999/archive/2006/10/26/77395.html<a target=_blank>104浜哄姏閾惰</a><a target=_blank>104浜哄姏閾惰</a>Thu, 26 Oct 2006 06:15:00 GMThttp://www.tkk7.com/andy199999/archive/2006/10/26/77395.htmlhttp://www.tkk7.com/andy199999/comments/77395.htmlhttp://www.tkk7.com/andy199999/archive/2006/10/26/77395.html#Feedback0http://www.tkk7.com/andy199999/comments/commentRss/77395.htmlhttp://www.tkk7.com/andy199999/services/trackbacks/77395.html錛堣漿杞斤級榪欎釜鏄疍Bunit鐨勯棶棰橈紝1.8浠ヤ笂鐨勭増鏈墠鏈夎繖涓棶棰橈紒
鍙淇敼User.java
/** 聽聽聽聽 * @return Returns the enabled. 聽聽聽聽 * @hibernate.property column="enabled"聽 聽聽聽聽 */ 聽聽聽 public Boolean getEnabled() { 聽聽聽聽聽聽聽 // isEnabled doesnt' work for copying properties to Struts ActionForms 聽聽聽聽聽聽聽 return enabled; 聽聽聽 }
淇敼鎴?br /> /** 聽聽聽聽 * @return Returns the enabled. 聽聽聽聽 * @hibernate.property column="enabled" type="yes_no" 聽聽聽聽 */ 聽聽聽 public Boolean getEnabled() { 聽聽聽聽聽聽聽 // isEnabled doesnt' work for copying properties to Struts ActionForms 聽聽聽聽聽聽聽 return enabled; 聽聽聽 }