Esempio n. 1
0
        public async Task Create(T entity)
        {
            await context.Set <T>().AddAsync(entity);

            foreach (var entityDomainEvent in entity.DomainEvents)
            {
                _queueHelper.EnqueueMessage(entityDomainEvent.Message);
            }
        }
        protected BaseReadRepository(StorageContext context)
        {
            EnsureArg.IsNotNull(context);

            this.entitiesSet = DecorateEntities(context.Set <T>().AsQueryable());
        }