Exemplo n.º 1
0
 public PersonController(IGenericRepository <Person> repository,
                         IGenericHandler <PersonCreateCommand> handlerCreate,
                         IGenericHandler <PersonUpdateCommand> handlerUpdate)
 {
     _repository    = repository;
     _handlerCreate = handlerCreate;
     _handlerUpdate = handlerUpdate;
 }
Exemplo n.º 2
0
 public DocumentTypeController(IGenericRepository <DocumentType> repository,
                               IGenericHandler <DocumentTypeCreateCommand> handler,
                               IMapper mapper,
                               IDistributedCache distributedCache,
                               IConfiguration configuration)
 {
     _repository = repository;
     _handler    = handler;
     _mapper     = mapper;
     _cacheStore = new DistributedCacheStore <DocumentTypeDTO>(distributedCache,
                                                               Convert.ToInt32(configuration["RedisSlidingExpirationInSeconds"]),
                                                               Convert.ToInt32(configuration["RedisAbsoluteExpirationInSeconds"]));
 }
Exemplo n.º 3
0
 public DocumentController(IGenericRepository <Document> repository, IGenericHandler <DocumentCreateCommand> handler)
 {
     _repository = repository;
     _handler    = handler;
 }