コード例 #1
0
 /// <summary>
 /// wrap Action callback
 /// </summary>
 public static void UseDefaultTransactionByAction(this System.Data.IsolationLevel defaultIsolationLevel, Action callback)
 {
     UseTransactionByAction(DefaultNewScopeFunc(defaultIsolationLevel.GetTransactionsIsolationLevel(), false), callback);
 }
コード例 #2
0
 /// <summary>
 /// wrap Func&lt;ReturnInfo&gt; callback, ( 应该使用异常,而不是 ReturnInfo , Func&lt;ReturnInfo&gt; 要改造成 Action)
 /// </summary>
 public static ReturnInfo UseDefaultTransactionByReturnInfoFunc(this System.Data.IsolationLevel defaultIsolationLevel, Func <ReturnInfo> callback)
 {
     return(UseTransactionByReturnInfoFunc(DefaultNewScopeFunc(defaultIsolationLevel.GetTransactionsIsolationLevel(), false), callback));
 }