public UnitOfWork(ISessionFactoryCreator sessionFactoryCreator, bool usingDistributedTransaction = true)
        {
            id = Guid.NewGuid();

            //creates the session factory
            sessionFactoryCreator.GetSessionFactory();
            session = sessionFactoryCreator.GetSessionFactory().OpenSession();

            //begins the transaction that will be used in the handler
            if (!usingDistributedTransaction)
            {
                session.BeginTransaction();
            }
        }
Beispiel #2
0
 public ServiceXUoW(ISessionFactoryCreator sessionFactoryCreator)
     : base(sessionFactoryCreator)
 {
 }
 public DomainUnitOfWork(ISessionFactoryCreator sessionFactoryCreator)
     : base(sessionFactoryCreator)
 {
 }