public DbContext(IRepositoryFactory repoFactory, string connectionString) { if (string.IsNullOrWhiteSpace(connectionString)) { throw new ArgumentNullException(nameof(connectionString)); } if (null == repoFactory) { throw new ArgumentNullException(nameof(repoFactory)); } this.Services = repoFactory.Create <Entities.Service>(new RepositoryOptions(connectionString, "services")); var servicesIxb = new IndexKeysDefinitionBuilder <Entities.Service>(); this.Services.CreateIndex(servicesIxb.Ascending(u => u.Name), new CreateIndexOptions() { Unique = true }); this.TraceEvents = repoFactory.Create <Entities.TraceEvent>(new RepositoryOptions(connectionString, "events")); var eventsIxb = new IndexKeysDefinitionBuilder <Entities.TraceEvent>(); this.TraceEvents.CreateIndex(eventsIxb.Ascending(u => u.Name), new CreateIndexOptions() { Unique = false }); }
public void AddIncome(IncomeModel model) { using (var repository = repositoryFactory.Create <Income>()) { repository.Insert(mapper.Map <Income>(model)); } }
private async void OnAdd() { var viewModel = _serviceLocator.GetService <CustomerFormViewModel>(); viewModel.DisplayName = "New Customer"; viewModel.Date = DateTime.Now; viewModel.IsDirty = false; viewModel.Submitted += async(sender, e) => { var repo = _repositoryFactory.Create <Customer>(); var model = new Customer(); AutoMapper.Map(viewModel, model); repo.Add(model); viewModel.Id = model.Id; viewModel.IsDirty = false; Refresh(); await _navigator.NavigateBackAsync(); }; SetNavigationRestriction(viewModel); await _navigator.NavigateToAsync(viewModel); }
public CreditSlipManager(IRepositoryFactory repositoryFactory) { _repositoryCreditSlip = repositoryFactory.Create <CreditSlip>(); _repositoryLink = repositoryFactory.Create <RelationshipBetweenDocuments>(); _repositoryCreditSlipSpecs = repositoryFactory.Create <CreditSlipSpecification>(); _repositoryTax = repositoryFactory.Create <Tax>(); }
public PushNotificationService(IRepositoryFactory repositoryFactory, IClientNotificationHub clientNotificationHub, IMapper mapper) { _clientNotificationHub = clientNotificationHub; _mapper = mapper; _pushNotificationRepository = repositoryFactory.Create <PushNotificationEntity>(); _projectRepository = repositoryFactory.Create <ProjectEntity>(); }
private static void TestFactoryCreate(IRepositoryFactory repoFactory) { Assert.NotNull(repoFactory.Create <Customer>()); Assert.NotNull(repoFactory.Create <Customer, int>()); Assert.NotNull(repoFactory.Create <CustomerWithTwoCompositePrimaryKey, int, string>()); Assert.NotNull(repoFactory.Create <CustomerWithThreeCompositePrimaryKey, int, string, int>()); Assert.NotNull(repoFactory.CreateInstance <Repository <Customer> >()); }
private IDenormalizerContext <TModel> BuildContext <TModel>() where TModel : class { var repository = _repositoryFactory.Create <TModel>(); var lookups = new Dictionary <string, object>(); foreach (var lookupType in _denormalizerDescriptors[typeof(TModel).FullName].Lookups) { lookups[lookupType.FullName] = _repositoryFactory.Create(lookupType); } return(new DenormalizerContext <TModel>(repository, lookups)); }
private IRepository <T> GetRepositoryOfType <T>() { var type = typeof(T); if (!_repositories.ContainsKey(type)) { _repositories[type] = _repositoryFactory.Create(this, typeof(T)); } return(_repositories[type] as IRepository <T>); }
public CumulativeWeekReportSet(IRepositoryFactory repositoryFactory, DateTime firstDayOfWeek) { if (firstDayOfWeek.DayOfWeek != DayOfWeek.Monday) { throw new ArgumentException("First day of week should be a monday", nameof(firstDayOfWeek)); } var nrOfDaysInWeek = 7; _activityCumulativeReportBuilder = new ActivityReportBuilder(repositoryFactory.Create($"cumulative_activity_week_report_{firstDayOfWeek:yyyyMMdd}.csv", firstDayOfWeek, nrOfDaysInWeek), firstDayOfWeek, nrOfDaysInWeek); _labelCumulativeReportBuilder = new LabelReportBuilder(repositoryFactory.Create($"cumulative_label_week_report_{firstDayOfWeek:yyyyMMdd}.csv", firstDayOfWeek, nrOfDaysInWeek), firstDayOfWeek, nrOfDaysInWeek); }
public CumulativeMonthReportSet(IRepositoryFactory repositoryFactory, DateTime firstDayOfMonth) { if (firstDayOfMonth.Day != 1) { throw new ArgumentException("First day of month should be 1", nameof(firstDayOfMonth)); } var nrOfDaysInMonth = DateTime.DaysInMonth(firstDayOfMonth.Year, firstDayOfMonth.Month); _activityCumulativeReportBuilder = new ActivityReportBuilder(repositoryFactory.Create($"cumulative_activity_month_report_{firstDayOfMonth:yyyyMMdd}.csv", firstDayOfMonth, nrOfDaysInMonth), firstDayOfMonth, nrOfDaysInMonth); _labelCumulativeReportBuilder = new LabelReportBuilder(repositoryFactory.Create($"cumulative_label_month_report_{firstDayOfMonth:yyyyMMdd}.csv", firstDayOfMonth, nrOfDaysInMonth), firstDayOfMonth, nrOfDaysInMonth); }
public CommandsDbContext(IRepositoryFactory repoFactory, string connectionString, string dbName) { if (string.IsNullOrWhiteSpace(connectionString)) throw new ArgumentNullException("connectionString"); if (string.IsNullOrWhiteSpace(dbName)) throw new ArgumentNullException("dbName"); this.Users = repoFactory.Create<User>(new RepositoryOptions(connectionString, dbName, "users")); this.Ideas = repoFactory.Create<Idea>(new RepositoryOptions(connectionString, dbName, "ideas")); this.IdeaComments = repoFactory.Create<IdeaComment>(new RepositoryOptions(connectionString, dbName, "ideaComments")); this.Areas = repoFactory.Create<Area>(new RepositoryOptions(connectionString, dbName, "areas")); }
public async Task FindTest() { await AddAsync(); await using var repo = _factory.Create(); var one = await repo.FindFirstAsync(x => x.Id.Equals("test")); var two = await repo.FindFirstAsync(x => x.Id.Equals("test2")); Assert.NotNull(one); Assert.Null(two); }
public ProcessedVideoHandler( IRepositoryFactory repositoryFactory, IService<DomainProjectProcessedScreenshot> projectProcessedScreenshotService, Lazy<IService<DomainProjectProcessedVideo>> projectProcessedVideoService, IMapper mapper) { _projectProcessedScreenshotService = projectProcessedScreenshotService; _projectProcessedVideoServiceLazy = projectProcessedVideoService; _mapper = mapper; _processedScreenshotRepository = repositoryFactory.Create<ProcessedScreenshotEntity>(); _processedVideoRepository = repositoryFactory.Create<ProcessedVideoEntity>(); _videoQueueRepository = repositoryFactory.Create<VideoQueueEntity>(); }
public PerEngineerMonthReportSet(IRepositoryFactory repositoryFactory, DateTime firstDayOfMonth) { if (firstDayOfMonth.Day != 1) { throw new ArgumentException("First day of month should be 1", nameof(firstDayOfMonth)); } var nrOfDaysInMonth = DateTime.DaysInMonth(firstDayOfMonth.Year, firstDayOfMonth.Month); _activityPerEngineerReportBuilder = new ActivityReportBuilder(repositoryFactory.Create($"engineer_activity_month_report_{firstDayOfMonth:yyyyMMdd}.csv", firstDayOfMonth, nrOfDaysInMonth), firstDayOfMonth, nrOfDaysInMonth); _labelPerEngineerReportBuilder = new LabelReportBuilder(repositoryFactory.Create($"engineer_label_month_report_{firstDayOfMonth:yyyyMMdd}.csv", firstDayOfMonth, nrOfDaysInMonth), firstDayOfMonth, nrOfDaysInMonth); _accountReportBuilder = new AccountReportBuilder(repositoryFactory.Create($"engineer_customer_month_report_{firstDayOfMonth:yyyyMMdd}.csv", firstDayOfMonth, nrOfDaysInMonth), firstDayOfMonth, nrOfDaysInMonth); }
public ProcessedVideoHandler( IRepositoryFactory repositoryFactory, IService <DomainProjectProcessedScreenshot> projectProcessedScreenshotService, Lazy <IService <DomainProjectProcessedVideo> > projectProcessedVideoService, IMapper mapper) { _projectProcessedScreenshotService = projectProcessedScreenshotService; _projectProcessedVideoServiceLazy = projectProcessedVideoService; _mapper = mapper; _processedScreenshotRepository = repositoryFactory.Create <ProcessedScreenshotEntity>(); _processedVideoRepository = repositoryFactory.Create <ProcessedVideoEntity>(); _videoQueueRepository = repositoryFactory.Create <VideoQueueEntity>(); }
public TRepo GetByUser(int userId) { TRepo rep; lock (padlock) { //bool inDictionary; if (UserRepositories == null) { UserRepositories = new Dictionary <int, TRepo>(); } if (UserRepositories.ContainsKey(userId)) { rep = UserRepositories[userId]; if (rep == null) { rep = _dbRepositoryFactory.Create(userId, this); } } else { rep = _dbRepositoryFactory.Create(userId, this); UserRepositories.Add(userId, rep); } //try //{ // inDictionary = UserRepositories.TryGetValue(userId, out rep); //} //catch (Exception) //{ // throw new Exception(""); //} //if (rep == null) //{ // rep = _dbRepositoryFactory.Create(userId, this); //} //if (!inDictionary) //{ // UserRepositories.Add(userId, rep); //} } return(rep); }
public UserProfileService(IRepositoryFactory repositoryFactory, IMappingEngine mappingEngine, IService <DomainEmailMembership> membershipService, IService <DomainProject> projectService, IConfigurationProvider configurationProvider) { _mappingEngine = mappingEngine; _membershipService = membershipService; _projectService = projectService; _profileRepository = repositoryFactory.Create <UserProfileEntity>(Tables.UserProfile); _storageSpaceRepository = repositoryFactory.Create <StorageSpaceEntity>(Tables.StorageSpace); _userRolesRepository = repositoryFactory.Create <UserRoleEntity>(Tables.UserRole); _authenticationRepository = repositoryFactory.Create <AuthenticationEntity>(Tables.Authentication); _defaultUserStorageSpace = long.Parse(configurationProvider.Get(FrontEndSettings.DefaultMaxUserCapacity)); }
public AdminProjectService(IRepositoryFactory repositoryFactory, IUserRepository userRepository, IProductWriterForAdmin productWriterForAdmin, IFileSystem fileSystem) { _projectRepository = repositoryFactory.Create<ProjectEntity>(); _userRepository = userRepository; _productWriterForAdmin = productWriterForAdmin; _fileSystem = fileSystem; }
private static void TestUpdateRange(IRepositoryFactory repoFactory) { var repo = repoFactory.Create <Customer>(); const string expectedName = "New Random Name"; const string name = "Random Name"; var entities = new List <Customer> { new Customer { Id = 1, Name = name }, new Customer { Id = 2, Name = name } }; repo.Add(entities); var entitiesInDb = repo.FindAll(x => x.Name.Equals(name)); foreach (var entityInDb in entitiesInDb) { entityInDb.Name = expectedName; } repo.Update(entitiesInDb); Assert.Equal(2, repo.Count(x => x.Name.Equals(expectedName))); }
private static void TestToDictionary(IRepositoryFactory repoFactory) { var repo = repoFactory.Create <Customer>(); const string name = "Random Name"; var options = new QueryOptions <Customer>(); var entity = new Customer { Id = 1, Name = name }; var expectedDictionary = new Dictionary <int, Customer>(); var expectedDictionaryByElementSelector = new Dictionary <int, string>(); expectedDictionary.Add(entity.Id, entity); expectedDictionaryByElementSelector.Add(entity.Id, entity.Name); Assert.False(expectedDictionary.All(x => repo.ToDictionary(y => y.Id).ContainsKey(x.Key))); Assert.False(expectedDictionary.All(x => repo.ToDictionary(options, y => y.Id).Result.ContainsKey(x.Key))); Assert.False(expectedDictionaryByElementSelector.All(x => repo.ToDictionary(y => y.Id, y => y.Name).Contains(x))); Assert.False(expectedDictionaryByElementSelector.All(x => repo.ToDictionary(options, y => y.Id, y => y.Name).Result.Contains(x))); repo.Add(entity); Assert.True(expectedDictionary.All(x => repo.ToDictionary(y => y.Id).ContainsKey(x.Key))); Assert.True(expectedDictionary.All(x => repo.ToDictionary(options, y => y.Id).Result.ContainsKey(x.Key))); Assert.True(expectedDictionaryByElementSelector.All(x => repo.ToDictionary(y => y.Id, y => y.Name).Contains(x))); Assert.True(expectedDictionaryByElementSelector.All(x => repo.ToDictionary(options, y => y.Id, y => y.Name).Result.Contains(x))); }
private static void TestGroupByWithOptions(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; repo.Add(customer); var queryOptions = new QueryOptions <Customer>().SatisfyBy(x => x.Id == customer.Id); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.NotEmpty(repo.GroupBy(queryOptions, x => x.Id, (key, g) => key).Result); Assert.False(repo.CacheUsed); Assert.NotEmpty(repo.GroupBy(queryOptions, x => x.Id, (key, g) => key).Result); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.NotEmpty(repo.GroupBy(queryOptions, x => x.Id, (key, g) => key).Result); Assert.False(repo.CacheUsed); }
private static void TestExists(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; repo.Add(customer); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.True(repo.Exists(x => x.Id == customer.Id)); Assert.False(repo.CacheUsed); Assert.True(repo.Exists(x => x.Id == customer.Id)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.True(repo.Exists(x => x.Id == customer.Id)); Assert.False(repo.CacheUsed); }
private static void TestGroupBy(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; repo.Add(customer); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.NotEmpty(repo.GroupBy(x => x.Id, (key, g) => key)); Assert.False(repo.CacheUsed); Assert.NotEmpty(repo.GroupBy(x => x.Id, (key, g) => key)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.NotEmpty(repo.GroupBy(x => x.Id, (key, g) => key)); Assert.False(repo.CacheUsed); }
private static void TestCountWithOptions(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; repo.Add(customer); var queryOptions = new QueryOptions <Customer>().SatisfyBy(x => x.Id == customer.Id); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.Equal(1, repo.Count(queryOptions)); Assert.False(repo.CacheUsed); Assert.Equal(1, repo.Count(queryOptions)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.Equal(1, repo.Count(queryOptions)); Assert.False(repo.CacheUsed); }
private static async Task TestToDictionaryAsync(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; await repo.AddAsync(customer); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.NotEmpty(await repo.ToDictionaryAsync(x => x.Id)); Assert.False(repo.CacheUsed); Assert.NotEmpty(await repo.ToDictionaryAsync(x => x.Id)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.NotEmpty(await repo.ToDictionaryAsync(x => x.Id)); Assert.False(repo.CacheUsed); }
public IEnumerable <RepositoryBase> Load(string path) { var list = new List <RepositoryBase>(); if (!File.Exists(path)) { return(Enumerable.Empty <RepositoryBase>()); } try { var document = new XmlDocument(); document.Load(path); var repositories = document.SelectNodes("repositories/repository"); if (repositories == null) { return(Enumerable.Empty <RepositoryBase>()); } foreach (XmlNode node in repositories) { string type = node.ChildNodes.Item(0).InnerText; string repositoryPath = node.ChildNodes.Item(1).InnerText; list.Add(_repositoryFactory.Create(type, repositoryPath)); } } catch (Exception exception) { throw; } return(list); }
private static async Task TestFindWithIdAsync(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; await repo.AddAsync(customer); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.NotNull(await repo.FindAsync(customer.Id)); Assert.False(repo.CacheUsed); Assert.NotNull(await repo.FindAsync(customer.Id)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.NotNull(await repo.FindAsync(customer.Id)); Assert.False(repo.CacheUsed); }
private static async Task TestCountAsync(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; await repo.AddAsync(customer); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.Equal(1, await repo.CountAsync(x => x.Id == customer.Id)); Assert.False(repo.CacheUsed); Assert.Equal(1, await repo.CountAsync(x => x.Id == customer.Id)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.Equal(1, await repo.CountAsync(x => x.Id == customer.Id)); Assert.False(repo.CacheUsed); }
public T GetById <T>(Guid id) where T : AggregateRoot, new() { var obj = _factory.Create <T>().GetById(id); RegisterForTracking(obj); return(obj); }
private static async Task TestGroupByAsync(IRepositoryFactory repoFactory) { var repo = repoFactory.Create <Customer>(); const string name = "Random Name"; var options = new QueryOptions <Customer>(); var entities = new List <Customer>() { new Customer { Id = 1, Name = name } }; var expectedGroup = entities.GroupBy(y => y.Id); var expectedGroupByElementSelector = entities.GroupBy(y => y.Id, y => y.Name); Assert.False(expectedGroupByElementSelector.All(x => repo.GroupByAsync(y => y.Id, (key, g) => key).Result.Contains(x.Key))); Assert.False(expectedGroupByElementSelector.All(x => repo.GroupByAsync(options, y => y.Id, (key, g) => key).Result.Result.Contains(x.Key))); await repo.AddAsync(entities); Assert.True(expectedGroupByElementSelector.All(x => repo.GroupByAsync(y => y.Id, (key, g) => key).Result.Contains(x.Key))); Assert.True(expectedGroupByElementSelector.All(x => repo.GroupByAsync(options, y => y.Id, (key, g) => key).Result.Result.Contains(x.Key))); }
public void DoSomething() { var repository = _repositoryFactory.Create(); // Используем созданный AbstractRepository repository.Save(); }
public DbContext(IRepositoryFactory repoFactory, string connectionString, string dbName) { if (string.IsNullOrWhiteSpace(connectionString)) { throw new ArgumentNullException("connectionString"); } if (string.IsNullOrWhiteSpace(dbName)) { throw new ArgumentNullException("dbName"); } this.Users = repoFactory.Create <User>(new RepositoryOptions(connectionString, dbName, "Users")); this.Posts = repoFactory.Create <Post>(new RepositoryOptions(connectionString, dbName, "Posts")); this.Friends = repoFactory.Create <Friends>(new RepositoryOptions(connectionString, dbName, "Friends")); this.Comments = repoFactory.Create <Comment>(new RepositoryOptions(connectionString, dbName, "Comments")); }
private static async Task TestExistsWithOptionsAsync(IRepositoryFactory repoFactory) { var repo = (Repository <Customer>)repoFactory.Create <Customer>(); var customer = new Customer { Name = "Random Name" }; await repo.AddAsync(customer); var queryOptions = new QueryOptions <Customer>().SatisfyBy(x => x.Id == customer.Id); Assert.True(repo.CacheEnabled); Assert.False(repo.CacheUsed); Assert.True(await repo.ExistsAsync(queryOptions)); Assert.False(repo.CacheUsed); Assert.True(await repo.ExistsAsync(queryOptions)); Assert.True(repo.CacheUsed); repo.CacheEnabled = false; Assert.True(await repo.ExistsAsync(queryOptions)); Assert.False(repo.CacheUsed); }
public EmailSenderService( IRepositoryFactory repositoryFactory, IMailerRepository mailerRepository, IMapper mapper) { _mailerRepository = mailerRepository; _mapper = mapper; _sendEmailRepository = repositoryFactory.Create<SendEmailEntity>(); }
/// <summary> /// Initializes a new instance of the DashboardHandlerBase class. /// </summary> /// <param name="repositoryFactory">The repository factory to use.</param> protected DashboardHandlerBase(IRepositoryFactory repositoryFactory) { if (repositoryFactory == null) { throw new ArgumentNullException("repositoryFactory", "repositoryFactory cannot be null."); } this.Helper = new HandlerHelper(this); this.Repository = repositoryFactory.Create(); }
public TaskKeeper( IMapper mapper, IRepositoryFactory repositoryFactory, IProjectRepository projectRepository, IService<DomainProjectProcessedScreenshot> projectProcessedScreenshotService, IService<DomainProjectProcessedVideo> projectProcessedVideoService) { _mapper = mapper; _projectRepository = projectRepository; _projectProcessedScreenshotService = projectProcessedScreenshotService; _projectProcessedVideoService = projectProcessedVideoService; _processedScreenshotRepository = repositoryFactory.Create<ProcessedScreenshotEntity>(); _processedVideoRepository = repositoryFactory.Create<ProcessedVideoEntity>(); _videoQueueRepository = repositoryFactory.Create<VideoQueueEntity>(); _lastSave = DateTime.MinValue; }
public CommentService(IRepositoryFactory repositoryFactory, ICommentRepository commentRepository, IUserRepository userRepository, IAuthenticator authenticator, IMapper mapper) { _commentRepository = commentRepository; _userRepository = userRepository; _authenticator = authenticator; _mapper = mapper; _projectRepository = repositoryFactory.Create<ProjectEntity>(); }
public EmailNotificationService( IRepositoryFactory repositoryFactory, IEmailSenderService emailSenderService, IPortalFrontendSettings settings, IUserService userService, IProductIdExtractor productIdExtractor, IProjectUriProvider projectUriProvider, IUserUriProvider userUriProvider) { _emailSenderService = emailSenderService; _settings = settings; _productIdExtractor = productIdExtractor; _userService = userService; _projectUriProvider = projectUriProvider; _userUriProvider = userUriProvider; _emailRepository = repositoryFactory.Create<SendEmailEntity>(); }
public AdminUserService( IRepositoryFactory repositoryFactory, IUserRepository userRepository, IProjectRepository projectRepository, IPasswordService passwordService, IProjectService projectService, IProductWriterForAdmin productWriterForAdmin, IMapper mapper) { _userRepository = userRepository; _passwordService = passwordService; _projectService = projectService; _productWriterForAdmin = productWriterForAdmin; _mapper = mapper; _fileRepository = repositoryFactory.Create<FileEntity>(); _projectRepository = projectRepository; }
public PasswordRecoveryService( IRepositoryFactory repositoryFactory, IUserRepository userRepository, IMailerRepository mailerRepository, IPasswordRecoveryFactory passwordRecoveryFactory, IPortalFrontendSettings settings, IRecoveryLinkService recoveryLinkService, IPasswordService passwordService) { _userRepository = userRepository; _passwordRecoveryFactory = passwordRecoveryFactory; _settings = settings; _recoveryLinkService = recoveryLinkService; _passwordService = passwordService; _mailerRepository = mailerRepository; _passwordRecoverRepository = repositoryFactory.Create<PasswordRecoveryEntity>(); }
public LastProjectService(IRepositoryFactory repositoryFactory) { _projectRepository = repositoryFactory.Create<ProjectEntity>(); }
public FileSystem(IUserRepository userRepository, IRepositoryFactory repositoryFactory, CloudBlobClient blobClient) { _userRepository = userRepository; _blobClient = blobClient; _fileRepository = repositoryFactory.Create<FileEntity>(); }