示例#1
0
 public MongoDbRepository(
     MongoDatabase mongoDatabase,
     IRepositoryEventsHandlers eventHandlers,
     IRepositoryInterceptors repositoryInterceptors)
     : this(
         mongoDatabase,
         new MongoDbQueryRepository(mongoDatabase, eventHandlers, repositoryInterceptors.QueryInterceptor),
         new MongoDbCommandRepository(mongoDatabase, eventHandlers, repositoryInterceptors))
 {
 }
 public MongoDbUnitOfWorkRepository(
     MongoDatabase mongoDatabase,
     IRepositoryEventsHandlers eventHandlers,
     IRepositoryInterceptors repositoryInterceptors)
     : this(
         mongoDatabase,
         new MongoDbQueryRepository(mongoDatabase, eventHandlers, repositoryInterceptors.QueryInterceptor),
         new MongoDbUnitOfWorkCommandRepository(mongoDatabase, eventHandlers, repositoryInterceptors))
 {
 }
        public EntityFrameworkRepository(
            DbContext context,
            IRepositoryEventsHandlers eventHandlers,
            IRepositoryInterceptors repositoryInterceptors)
            : base(
               new EntityFrameworkQueryRepository(context, eventHandlers, repositoryInterceptors.QueryInterceptor),
               new EntityFrameworkCommandRepository(context, eventHandlers, repositoryInterceptors))
        {
            Check.NotNull(context, "context");

            ObjectContext = context;
        }
        public EntityFrameworkRepository(
            DbContext context,
            IRepositoryEventsHandlers eventHandlers,
            IRepositoryInterceptors repositoryInterceptors)
            : base(
                new EntityFrameworkQueryRepository(context, eventHandlers, repositoryInterceptors.QueryInterceptor),
                new EntityFrameworkCommandRepository(context, eventHandlers, repositoryInterceptors))
        {
            Check.NotNull(context, "context");

            ObjectContext = context;
        }
        public InMemoryRepository(
            ICollection<object> collection,
            IRepositoryEventsHandlers eventHandlers,
            IRepositoryInterceptors repositoryInterceptors)
            : base(
               new InMemoryQueryRepository(collection, eventHandlers, repositoryInterceptors.QueryInterceptor),
               new InMemoryCommandRepository(collection, eventHandlers, repositoryInterceptors))
        {
            Check.NotNull(collection, "collection");
            Check.NotNull(eventHandlers, "eventHandlers");
            Check.NotNull(repositoryInterceptors, "repositoryInterceptors");

           ObjectContext = collection;
        }
        public InMemoryRepository(
            ICollection <object> collection,
            IRepositoryEventsHandlers eventHandlers,
            IRepositoryInterceptors repositoryInterceptors)
            : base(
                new InMemoryQueryRepository(collection, eventHandlers, repositoryInterceptors.QueryInterceptor),
                new InMemoryCommandRepository(collection, eventHandlers, repositoryInterceptors))
        {
            Check.NotNull(collection, "collection");
            Check.NotNull(eventHandlers, "eventHandlers");
            Check.NotNull(repositoryInterceptors, "repositoryInterceptors");

            ObjectContext = collection;
        }
示例#7
0
 public MongoDbRepository(MongoDatabase mongoDatabase, IRepositoryInterceptors repositoryInterceptors)
     : this(mongoDatabase, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public InMemoryRepository(
  IRepositoryEventsHandlers eventHandlers,
  IRepositoryInterceptors repositoryInterceptors)
     : this(new List<object>(), eventHandlers, repositoryInterceptors)
 {
 }
 public InMemoryRepository(IRepositoryInterceptors repositoryInterceptors)
     : this(new List<object>(), new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public InMemoryRepository(ICollection<object> collection, IRepositoryInterceptors repositoryInterceptors)
     : this(collection, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public EntityFrameworkRepository(DbContext context, IRepositoryInterceptors repositoryInterceptors)
     : this(context, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public InMemoryRepository(
     IRepositoryEventsHandlers eventHandlers,
     IRepositoryInterceptors repositoryInterceptors)
     : this(new List <object>(), eventHandlers, repositoryInterceptors)
 {
 }
 public InMemoryRepository(IRepositoryInterceptors repositoryInterceptors)
     : this(new List <object>(), new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public InMemoryRepository(ICollection <object> collection, IRepositoryInterceptors repositoryInterceptors)
     : this(collection, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public EntityFrameworkRepository(DbContext context, IRepositoryInterceptors repositoryInterceptors)
     : this(context, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }
 public MongoDbUnitOfWorkRepository(MongoDatabase mongoDatabase, IRepositoryInterceptors repositoryInterceptors)
     : this(mongoDatabase, new DefaultRepositoryEventsHandlers(), repositoryInterceptors)
 {
 }