public LinqPadUow(IIocResolver iocResolver, IConnectionStringResolver connectionStringResolver,
                   IUnitOfWorkFilterExecuter filterExecuter, IDbContextResolver dbContextResolver, IUnitOfWorkDefaultOptions defaultOptions,
                   IDbContextTypeMatcher dbContextTypeMatcher, IEfCoreTransactionStrategy transactionStrategy, ILinqPadContextGetter linqPadContextGetter)
     : base(iocResolver, connectionStringResolver, filterExecuter, dbContextResolver, defaultOptions, dbContextTypeMatcher, transactionStrategy)
 {
     Console.WriteLine("LinqPadUow.ctor");
     _linqPadContextGetter = linqPadContextGetter;
 }
        /// <summary>
        ///     Creates a new instance of <see cref="NhUnitOfWork" />.
        /// </summary>
        public NhUnitOfWork(IUnitOfWorkDefaultOptions defaultOptions, IUnitOfWorkFilterExecuter filterExecuter, ISessionFactoryProvider sessionFactoryProvider)
            : base(defaultOptions, filterExecuter)
        {
            _sessionFactoryProvider = sessionFactoryProvider;

            ActiveSessions     = new Dictionary <string, ISession>();
            ActiveTransactions = new Dictionary <string, ActiveTransactionInfo>();
        }
Example #3
0
 public CouchbaseUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter,
     ICluster cluster) : base(connectionStringResolver, defaultOptions, filterExecuter)
 {
     _cluster = cluster;
 }
Example #4
0
 public NullUnitOfWork(
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         defaultOptions,
         filterExecuter)
 {
 }
Example #5
0
 public RavenDBUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter,
     IDocumentStore documentStore)
     : base(connectionStringResolver, defaultOptions, filterExecuter)
 {
     _documentStore = documentStore;
 }
        /// <summary>
        ///     Constructor.
        /// </summary>
        protected UnitOfWorkBase(IUnitOfWorkDefaultOptions defaultOptions, IUnitOfWorkFilterExecuter filterExecuter)
        {
            FilterExecuter = filterExecuter;
            DefaultOptions = defaultOptions;

            Id         = Guid.NewGuid().ToString("N");
            _filters   = defaultOptions.Filters.ToList();
            AppSession = NullSession.Instance;
        }
Example #7
0
 protected UnitOfWorkBase(IConnectionStringResolver connectionStringResolver, IUnitOfWorkDefaultOptions defaultOptions, IUnitOfWorkFilterExecuter filterExecuter)
 {
     FilterExecuter           = filterExecuter;
     DefaultOptions           = defaultOptions;
     ConnectionStringResolver = connectionStringResolver;
     Id       = Guid.NewGuid().ToString("N");
     _filters = defaultOptions.Filters.ToList();
     Items    = new Dictionary <string, object>();
 }
Example #8
0
 public UnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter,
     ILocalDbSessionConfiguration localDbSessionConfiguration)
     : base(connectionStringResolver, defaultOptions, filterExecuter)
 {
     DbSessionConfiguration = localDbSessionConfiguration;
 }
        /// <summary>
        /// Creates a new instance of <see cref="SheshaNhUnitOfWork"/>.
        /// </summary>
        public SheshaNhUnitOfWork(
            ISessionFactory sessionFactory,
            IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IUnitOfWorkFilterExecuter filterExecuter,

            SheshaNHibernateModule nhModule)
            : base(sessionFactory, connectionStringResolver, defaultOptions, filterExecuter, nhModule)
        {
        }
 public NullUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
 }
Example #11
0
 public NullUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
 }
Example #12
0
        /// <summary>
        /// Constructor.
        /// </summary>
        protected UnitOfWorkBase(IConnectionStringResolver connectionStringResolver, IUnitOfWorkDefaultOptions defaultOptions, IUnitOfWorkFilterExecuter filterExecuter)
        {
            FilterExecuter           = filterExecuter;
            DefaultOptions           = defaultOptions;
            ConnectionStringResolver = connectionStringResolver;

            Id       = Guid.NewGuid().ToString("N");
            _filters = defaultOptions.Filters.ToList();

            Session = NullInfrastructureSession.Instance;
        }
Example #13
0
 public FreeSqlUnitOfWork(
     IAbpFreesqlModuleConfiguration configuration,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(connectionStringResolver,
            defaultOptions,
            filterExecuter)
 {
     _configuration = configuration;
 }
 /// <summary>
 /// Constructor.
 /// </summary>
 public MongoDbUnitOfWork(
     IAbpMongoDbModuleConfiguration configuration, 
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
           connectionStringResolver, 
           defaultOptions,
           filterExecuter)
 {
     _configuration = configuration;
 }
Example #15
0
 /// <summary>
 /// Constructor.
 /// </summary>
 public MongoDbUnitOfWork(
     IStudioXMongoDbModuleConfiguration configuration,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
     this.configuration = configuration;
 }
 /// <summary>
 /// Creates a new instance of <see cref="NhUnitOfWork"/>.
 /// </summary>
 public NhUnitOfWork(
     ISessionFactory sessionFactory, 
     IConnectionStringResolver connectionStringResolver, 
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter)
     : base(
           connectionStringResolver, 
           defaultOptions,
           filterExecuter)
 {
     _sessionFactory = sessionFactory;
 }
Example #17
0
 /// <summary>
 /// Creates a new instance of <see cref="NhUnitOfWork"/>.
 /// </summary>
 public NhUnitOfWork(
     ISessionFactory sessionFactory,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter)
     : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
     _sessionFactory = sessionFactory;
 }
Example #18
0
 public CustomActiveUnitOfWork(
     IIocResolver iocResolver,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IDbContextResolver dbContextResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IDbContextTypeMatcher dbContextTypeMatcher,
     IEfCoreTransactionStrategy transactionStrategy)
     : base(iocResolver,
            connectionStringResolver, filterExecuter, dbContextResolver, defaultOptions, dbContextTypeMatcher,
            transactionStrategy)
 {
 }
 /// <summary>
 /// Constructor.
 /// </summary>
 public MemoryDbUnitOfWork(
     IAbpMemoryDbModuleConfiguration configuration, 
     MemoryDatabase memoryDatabase, 
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
           connectionStringResolver, 
           defaultOptions,
           filterExecuter)
 {
     _configuration = configuration;
     _memoryDatabase = memoryDatabase;
 }
Example #20
0
 /// <summary>
 /// Constructor.
 /// </summary>
 public MongoDbUnitOfWork(
     IAbpMongoDbModuleConfiguration configuration,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
     _configuration = configuration;
     Database       = new MongoClient(_configuration.ConnectionString)
                      .GetDatabase(_configuration.DatabaseName);
 }
Example #21
0
 /// <summary>
 /// Constructor.
 /// </summary>
 public MemoryDbUnitOfWork(
     IStudioXMemoryDbModuleConfiguration configuration,
     MemoryDatabase memoryDatabase,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
     this.configuration  = configuration;
     this.memoryDatabase = memoryDatabase;
 }
Example #22
0
        /// <summary>
        /// Constructor.
        /// </summary>
        protected UnitOfWorkBase(
            //IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IUnitOfWorkFilterExecuter filterExecuter)
        {
            FilterExecuter = filterExecuter;
            DefaultOptions = defaultOptions;
            //ConnectionStringResolver = connectionStringResolver;

            Id = Guid.NewGuid().ToString("N");
            //_filters = defaultOptions.Filters.ToList();

            //Session = NullAbpSession.Instance;
        }
Example #23
0
        /// <summary>
        /// Constructor.
        /// </summary>
        protected UnitOfWorkBase(
            IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IUnitOfWorkFilterExecuter filterExecuter)
        {
            FilterExecuter           = filterExecuter;
            DefaultOptions           = defaultOptions;
            ConnectionStringResolver = connectionStringResolver;

            Id       = Guid.NewGuid().ToString("N");
            _filters = defaultOptions.Filters.ToList();
            _auditFieldConfiguration = defaultOptions.AuditFieldConfiguration.ToList();
            AbpSession = NullAbpSession.Instance;
            Items      = new Dictionary <string, object>();
        }
Example #24
0
        public EfCoreUnitOfWork(
            IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IUnitOfWorkFilterExecuter filterExecuter,
            IDbContextResolver dbContextResolver,
            IEfCoreTransactionStrategy transactionStrategy,
            IDbContextTypeMatcher dbContextTypeMatcher)
            : base(connectionStringResolver, defaultOptions, filterExecuter)
        {
            _dbContextResolver    = dbContextResolver;
            _transactionStrategy  = transactionStrategy;
            _dbContextTypeMatcher = dbContextTypeMatcher;

            ActiveDbContexts = new Dictionary <string, DbContext>();
        }
Example #25
0
        /// <summary>
        /// Creates a new <see cref="EfCoreUnitOfWork"/>.
        /// </summary>
        public EfCoreUnitOfWork(
            IIocResolver iocResolver,
            IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkFilterExecuter filterExecuter,
            IDbContextResolver dbContextResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IDbContextTypeMatcher dbContextTypeMatcher)
            : base(
                connectionStringResolver,
                defaultOptions,
                filterExecuter)
        {
            IocResolver           = iocResolver;
            _dbContextResolver    = dbContextResolver;
            _dbContextTypeMatcher = dbContextTypeMatcher;

            ActiveDbContexts = new Dictionary <string, DbContext>();
        }
Example #26
0
        /// <summary>
        /// Creates a new <see cref="EfCoreUnitOfWork"/>.
        /// </summary>
        public EfCoreUnitOfWork(
            IIocResolver iocResolver,
            IConnectionStringResolver connectionStringResolver,
            IUnitOfWorkFilterExecuter filterExecuter,
            IDbContextResolver dbContextResolver,
            IUnitOfWorkDefaultOptions defaultOptions,
            IDbContextTypeMatcher dbContextTypeMatcher,
            IEfCoreTransactionStrategy transactionStrategy)
            : base(
                connectionStringResolver,
                defaultOptions,
                filterExecuter)
        {
            IocResolver           = iocResolver;
            _dbContextResolver    = dbContextResolver;
            _dbContextTypeMatcher = dbContextTypeMatcher;
            _transactionStrategy  = transactionStrategy;

            ActiveDbContexts = new Dictionary <string, DbContext>(StringComparer.OrdinalIgnoreCase);
        }
        /// <summary>
        /// Constructor.
        /// </summary>
        protected UnitOfWorkBase(
            IConnectionStringResolver connectionStringResolver, 
            IUnitOfWorkDefaultOptions defaultOptions,
            IUnitOfWorkFilterExecuter filterExecuter)
        {
            FilterExecuter = filterExecuter;
            DefaultOptions = defaultOptions;
            ConnectionStringResolver = connectionStringResolver;

            Id = Guid.NewGuid().ToString("N");
            _filters = defaultOptions.Filters.ToList();

            AbpSession = NullAbpSession.Instance;
        }