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;
 }
Ejemplo n.º 2
0
        /// <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>();
        }
Ejemplo n.º 3
0
 public CouchbaseUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter,
     ICluster cluster) : base(connectionStringResolver, defaultOptions, filterExecuter)
 {
     _cluster = cluster;
 }
Ejemplo n.º 4
0
 public NullUnitOfWork(
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         defaultOptions,
         filterExecuter)
 {
 }
Ejemplo n.º 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;
        }
Ejemplo n.º 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>();
 }
Ejemplo n.º 8
0
 public UnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter,
     ILocalDbSessionConfiguration localDbSessionConfiguration)
     : base(connectionStringResolver, defaultOptions, filterExecuter)
 {
     DbSessionConfiguration = localDbSessionConfiguration;
 }
Ejemplo n.º 9
0
        /// <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)
        {
        }
Ejemplo n.º 10
0
 public NullUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
 }
Ejemplo n.º 11
0
 public NullUnitOfWork(
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkDefaultOptions defaultOptions,
     IUnitOfWorkFilterExecuter filterExecuter
     ) : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
 }
Ejemplo n.º 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;
        }
Ejemplo n.º 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;
 }
Ejemplo n.º 15
0
 /// <summary>
 /// Constructor.
 /// </summary>
 public MongoDbUnitOfWork(
     IStudioXMongoDbModuleConfiguration configuration,
     IConnectionStringResolver connectionStringResolver,
     IUnitOfWorkFilterExecuter filterExecuter,
     IUnitOfWorkDefaultOptions defaultOptions)
     : base(
         connectionStringResolver,
         defaultOptions,
         filterExecuter)
 {
     this.configuration = configuration;
 }
Ejemplo n.º 16
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;
 }
Ejemplo n.º 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;
 }
Ejemplo n.º 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;
 }
Ejemplo n.º 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);
 }
Ejemplo n.º 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;
 }
Ejemplo n.º 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;
        }
Ejemplo n.º 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>();
        }
Ejemplo n.º 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>();
        }
Ejemplo n.º 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>();
        }
Ejemplo n.º 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);
        }
Ejemplo n.º 27
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();

            AbpSession = NullAbpSession.Instance;
        }