GetCurrent() 공개 정적인 메소드

public static GetCurrent ( DataAccessModel dataAccessModel, bool forWrite ) : TransactionContext
dataAccessModel DataAccessModel
forWrite bool
리턴 TransactionContext
예제 #1
0
        public SqlTransactionalCommandsContext GetCurrentCommandsContext()
        {
            var transactionContext = TransactionContext.GetCurrent(this, true);

            if (transactionContext == null)
            {
                throw new InvalidOperationException("No Current DataAccessScope");
            }

            return(transactionContext.GetSqlTransactionalCommandsContext());
        }
예제 #2
0
 internal DataAccessObjectDataContext GetCurrentDataContext(bool forWrite)
 {
     return(TransactionContext.GetCurrent(this, forWrite)?.GetCurrentDataContext());
 }
예제 #3
0
 private TransactionContext GetCurrentContext(bool forWrite)
 {
     return(TransactionContext.GetCurrent(this, forWrite));
 }