public TokenService(IFileTableStorageService tableStorageService, IBlobStorageService blobStorageService, IGameTableStorageService gameTableStorageService) { TableStorageService = tableStorageService; BlobStorageService = blobStorageService; GameTableStorageService = gameTableStorageService; }
public ProfilesController(IProfileService profileService, IImageService imageService, IBlobStorageService blobStorageService) { _profileService = profileService; _imageService = imageService; _blobStorageService = blobStorageService; }
public ResultLoader(IMapper mapper, ILogger <ResultLoader> logger, IResultsAndCertificationInternalApiClient internalApiClient, IBlobStorageService blobStorageService) { _mapper = mapper; _logger = logger; _internalApiClient = internalApiClient; _blobStorageService = blobStorageService; }
public BlobStorageController( ICourseService courseService, IApprenticeshipService apprenticeshipService, IBlobStorageService blobService, ICourseProvisionHelper courseProvisionHelper, IApprenticeshipProvisionHelper apprenticeshipProvisionHelper) { if (courseService == null) { throw new ArgumentNullException(nameof(courseService)); } if (apprenticeshipService == null) { throw new ArgumentNullException(nameof(apprenticeshipService)); } if (blobService == null) { throw new ArgumentNullException(nameof(blobService)); } if (apprenticeshipProvisionHelper == null) { throw new ArgumentNullException(nameof(apprenticeshipProvisionHelper)); } _courseService = courseService; _blobService = blobService; _courseProvisionHelper = courseProvisionHelper; _apprenticeshipService = apprenticeshipService; _apprenticeshipProvisionHelper = apprenticeshipProvisionHelper; }
public ExploraFileService(IRepository repository, IBlobStorageService directoryBlobStorageService, IMapper mapper, IUnitOfWork unitOfWork) : base(mapper, unitOfWork, repository) { _blobService = directoryBlobStorageService; }
public MediaServicesService(IOrchardServices orchardServices, IShapeFactory shapeFactory, ISiteService siteService, IConfig config, IBlobStorageService blobStorageService, IRepository<EncodedMediaRecord> encodedMediaRepository, IRepository<MediaItemRecord> mediaItemRepository, IRepository<EncodingPresetRecord> encodingPresetRepository, IRepository<ThumbnailRecord> thumbnailRepository, IRepository<VideoMediaItemRecord> videoMediaItemRepository, IWorkContextAccessor workContextAccessor) { _config = config; _blobStorageService = blobStorageService; _encodedMediaRepository = encodedMediaRepository; _mediaItemRepository = mediaItemRepository; _encodingPresetRepository = encodingPresetRepository; _thumbnailRepository = thumbnailRepository; _videoMediaItemRepository = videoMediaItemRepository; _workContextAccessor = workContextAccessor; _orchardServices = orchardServices; _shapeFactory = shapeFactory; _siteService = siteService; _logger = NullLogger.Instance; }
public BauCacheController( IBlobStorageService privateBlobStorageService, IBlobStorageService publicBlobStorageService) { _privateBlobStorageService = privateBlobStorageService; _publicBlobStorageService = publicBlobStorageService; }
public override void Setup() { Logger = Substitute.For <ILogger <DocumentLoader> >(); BlobStorageService = Substitute.For <IBlobStorageService>(); Loader = new DocumentLoader(Logger, BlobStorageService); }
public ConfigService( IBlobStorageService blobStorageService, IConfiguration configuration) { _blobStorageService = blobStorageService; _containerName = configuration["ConfigContainerName"] ?? throw new KeyNotFoundException("Missing key 'ConfigContainerName'"); }
public DashboardController( ICourseService courseService, IBlobStorageService blobStorageService, IWebHostEnvironment env, IEnvironmentHelper environmentHelper) { if (courseService == null) { throw new ArgumentNullException(nameof(courseService)); } if (blobStorageService == null) { throw new ArgumentNullException(nameof(blobStorageService)); } if (environmentHelper == null) { throw new ArgumentNullException(nameof(environmentHelper)); } _courseService = courseService; _blobStorageService = blobStorageService; _environmentHelper = environmentHelper; }
private ReleaseDataFileService SetupReleaseDataFileService( ContentDbContext contentDbContext = null, StatisticsDbContext statisticsDbContext = null, IPersistenceHelper <ContentDbContext> contentPersistenceHelper = null, IBlobStorageService blobStorageService = null, IDataArchiveValidationService dataArchiveValidationService = null, IFileUploadsValidatorService fileUploadsValidatorService = null, IFileRepository fileRepository = null, IReleaseFileRepository releaseFileRepository = null, IImportService importService = null, IImportStatusService importStatusService = null, IUserService userService = null) { return(new ReleaseDataFileService( contentDbContext ?? new Mock <ContentDbContext>().Object, statisticsDbContext ?? new Mock <StatisticsDbContext>().Object, contentPersistenceHelper ?? DefaultPersistenceHelperMock().Object, blobStorageService ?? new Mock <IBlobStorageService>().Object, dataArchiveValidationService ?? new Mock <IDataArchiveValidationService>().Object, fileUploadsValidatorService ?? new Mock <IFileUploadsValidatorService>().Object, fileRepository ?? new FileRepository(contentDbContext), releaseFileRepository ?? new ReleaseFileRepository(contentDbContext), importService ?? new Mock <IImportService>().Object, importStatusService ?? new Mock <IImportStatusService>().Object, userService ?? new Mock <IUserService>().Object )); }
public MissionImageUploader( IAsyncRepository <MissionImage> imageRepository, IBlobStorageService storageService) { _imageRepository = imageRepository; _storageService = storageService; }
public TableStorageService(IConfiguration configuration, IBlobStorageService blobService) { this.configuration = configuration; this.blobService = blobService; storageAccount = CloudStorageAccount.Parse(configuration.GetValue <string>("AzureStorage:ConnectionString")); tableClient = storageAccount.CreateCloudTableClient(); }
/// <summary> /// Constructor method. /// </summary> public BlobService(BlobServiceConfigs configs, IBlobsRepository blobsRepository, IBlobStorageService storageService, IBlobThumbService thumbService) { _configs = configs ?? throw new ArgumentNullException(nameof(configs), nameof(BlobService)); _blobsRepository = blobsRepository ?? throw new ArgumentNullException(nameof(blobsRepository), nameof(BlobService)); _storageService = storageService ?? throw new ArgumentNullException(nameof(storageService), nameof(BlobService)); _thumbService = thumbService ?? throw new ArgumentNullException(nameof(thumbService), nameof(BlobService)); }
public MarketplaceController(IMarketplaceService marketplaceService, IImageService imageService, IBlobStorageService blobStorageService) { _marketplaceService = marketplaceService; _imageService = imageService; _blobStorageService = blobStorageService; }
public CreateContentCommandHandler( IContentRepository contentRepository, IBlobStorageService blobStorageService) { _contentRepository = contentRepository; _blobStorageService = blobStorageService; }
public override void Setup() { Mapper = Substitute.For <IMapper>(); Logger = Substitute.For <ILogger <RegistrationLoader> >(); InternalApiClient = Substitute.For <IResultsAndCertificationInternalApiClient>(); BlobStorageService = Substitute.For <IBlobStorageService>(); }
public override void Setup() { Logger = Substitute.For <ILogger <RegistrationLoader> >(); BlobStorageService = Substitute.For <IBlobStorageService>(); InternalApiClient = Substitute.For <IResultsAndCertificationInternalApiClient>(); HttpContextAccessor = Substitute.For <IHttpContextAccessor>(); HttpContextAccessor.HttpContext.Returns(new DefaultHttpContext { User = new ClaimsPrincipal(new ClaimsIdentity(new[] { new Claim(ClaimTypes.GivenName, Givenname), new Claim(ClaimTypes.Surname, Surname), new Claim(ClaimTypes.Email, Email) })) }); var mapperConfig = new MapperConfiguration(c => { c.AddMaps(typeof(RegistrationMapper).Assembly); c.ConstructServicesUsing(type => type.Name.Contains("UserNameResolver") ? new UserNameResolver <RejoinRegistrationViewModel, RejoinRegistrationRequest>(HttpContextAccessor) : null); }); Uln = 123456789; ProfileId = 1; Mapper = new AutoMapper.Mapper(mapperConfig); Loader = new RegistrationLoader(Mapper, Logger, InternalApiClient, BlobStorageService); }
//private readonly IImageService _imageService; public AnnouncementController(IAnnouncementService announcementService, IBlobStorageService blobStorageService) { _announcementService = announcementService; //_imageService = imageService; _blobStorageService = blobStorageService; }
public RegistrationController(ResultsAndCertificationConfiguration configuration, ICsvHelperService <RegistrationCsvRecord, Registration, ImportResponseRecord <Registration> > csvParserService, IRegistrationService registrationService, IBlobStorageService blobStorageService) { _configuration = configuration; _csvParserService = csvParserService; _registrationService = registrationService; _blobStorageService = blobStorageService; }
public PiServerService() { this.context = new ContextInfoAccessorService(); this.dbContext = new PowerGridEntities(); this.blobStorageService = new BlobStorageService(); this.applicationConfigurationService = new ApplicationConfigurationService(); }
public ReleaseDataFileService( ContentDbContext contentDbContext, IPersistenceHelper <ContentDbContext> persistenceHelper, IBlobStorageService blobStorageService, IDataArchiveValidationService dataArchiveValidationService, IFileUploadsValidatorService fileUploadsValidatorService, IFileRepository fileRepository, IReleaseRepository releaseRepository, IReleaseFileRepository releaseFileRepository, IReleaseDataFileRepository releaseDataFileRepository, IDataImportService dataImportService, IUserService userService) { _contentDbContext = contentDbContext; _persistenceHelper = persistenceHelper; _blobStorageService = blobStorageService; _dataArchiveValidationService = dataArchiveValidationService; _fileUploadsValidatorService = fileUploadsValidatorService; _fileRepository = fileRepository; _releaseRepository = releaseRepository; _releaseFileRepository = releaseFileRepository; _releaseDataFileRepository = releaseDataFileRepository; _dataImportService = dataImportService; _userService = userService; }
//private readonly ITableStorageService _tableStorageService; public GalleryController(IGalleryService galleryService, IBlobStorageService blobStorageService, IImageService imageService) { _galleryService = galleryService; _blobStorageService = blobStorageService; _imageService = imageService; //_tableStorageService = tableStorageService; }
public PetPictureService(ILoggingService log, IBlobStorageService blobStorageService, IPetPictureRepository petPictureRepository) : base(log) { _blobStorageService = blobStorageService; _petPictureRepository = petPictureRepository; }
public AdminController(IRepository <ApplicationUser> userRepository, IRepository <Book> bookRepository, IRepository <Tag> tagRepository, IRepository <Genre> genreRepository, IUpdateService <Book> bookUpdateService, IUpdateService <Genre> genreUpdateService, IUpdateService <Tag> tagUpdateService, IFactory <Book, BookResponseModel> bookFactory, IFactory <Genre, GenreResponseModel> genreFactory, IFactory <Tag, TagResponseModel> tagFactory, IMapper objectMapper, UserManager <ApplicationUser> userManager, BookDataServices bookServices, IBlobStorageService blobStorageService) { this.userRepository = userRepository; this.bookRepository = bookRepository; this.bookUpdateService = bookUpdateService; this.genreUpdateService = genreUpdateService; this.tagUpdateService = tagUpdateService; this.objectMapper = objectMapper; this.userManager = userManager; this.bookServices = bookServices; this.blobStorageService = blobStorageService; this.bookFactory = bookFactory; this.genreFactory = genreFactory; this.tagFactory = tagFactory; }
public EventService(ApplicationDbContext applicationDbContext, IMapper mapper, IBlobStorageService blobStorageService, IUserService userService) { this.applicationDbContext = applicationDbContext; this.mapper = mapper; this.blobStorageService = blobStorageService; this.userService = userService; }
public override void Setup() { ApiClientResponse = new List <PathwayDetails> { new PathwayDetails { Id = 1, Name = "Test", Code = "10000111" }, new PathwayDetails { Id = 2, Name = "Display", Code = "10000112" } }; Logger = Substitute.For <ILogger <RegistrationLoader> >(); BlobStorageService = Substitute.For <IBlobStorageService>(); InternalApiClient = Substitute.For <IResultsAndCertificationInternalApiClient>(); InternalApiClient.GetRegisteredProviderPathwayDetailsAsync(Ukprn, ProviderUkprn).Returns(ApiClientResponse); var mapperConfig = new MapperConfiguration(c => c.AddMaps(typeof(ProviderMapper).Assembly)); Mapper = new AutoMapper.Mapper(mapperConfig); }
public override void Setup() { Uln = 7777777777; ApiClientResponse = true; Logger = Substitute.For <ILogger <RegistrationLoader> >(); BlobStorageService = Substitute.For <IBlobStorageService>(); InternalApiClient = Substitute.For <IResultsAndCertificationInternalApiClient>(); InternalApiClient.AddRegistrationAsync(Arg.Any <RegistrationRequest>()).Returns(ApiClientResponse); HttpContextAccessor = Substitute.For <IHttpContextAccessor>(); HttpContextAccessor.HttpContext.Returns(new DefaultHttpContext { User = new ClaimsPrincipal(new ClaimsIdentity(new[] { new Claim(ClaimTypes.GivenName, Givenname), new Claim(ClaimTypes.Surname, Surname), new Claim(ClaimTypes.Email, Email) })) }); InternalApiClient = Substitute.For <IResultsAndCertificationInternalApiClient>(); var mapperConfig = new MapperConfiguration(c => { c.AddMaps(typeof(RegistrationMapper).Assembly); c.ConstructServicesUsing(type => type.Name.Contains("UserNameResolver") ? new UserNameResolver <ChangeSpecialismQuestionViewModel, ManageRegistration>(HttpContextAccessor) : null); }); Mapper = new AutoMapper.Mapper(mapperConfig); }
public MealService(ApplicationDbContext applicationDbContext, IMapper mapper, IBlobStorageService blobStorageService, IRestaurantService restaurantService) { this.applicationDbContext = applicationDbContext; this.restaurantService = restaurantService; this.mapper = mapper; this.blobStorageService = blobStorageService; }
/// <summary> /// Setup /// </summary> public BlobStorageServiceTest() { _emulator = new AzureStorageEmulatorAutomation(); _emulator.Start(); if (!AzureStorageEmulatorAutomation.IsEmulatorRunning()) { throw new Exception("Azure Storage Emulatorの起動に失敗しました"); } // 設定ファイルの読み込み var configuration = new ConfigurationBuilder() .SetBasePath(Directory.GetCurrentDirectory()) .AddJsonFile("appsettings.json", optional: true, reloadOnChange: true) .Build(); // サービスの構成 var serviceCollection = new ServiceCollection(); serviceCollection.AddSingleton <IBlobStorageService>(factory => new BlobStorageService(configuration["ConnectionStrings:StorageConnection"])); _service = serviceCollection.BuildServiceProvider().GetService <IBlobStorageService>(); // ファイル生成 Directory.CreateDirectory(_testDataPath); foreach (var fileName in _testFiles) { File.WriteAllText(Path.Combine(_testDataPath, fileName), "This is test."); } }
public FastTrackService(ContentDbContext contentDbContext, IBlobStorageService publicBlobStorageService, ITableStorageService tableStorageService) { _contentDbContext = contentDbContext; _publicBlobStorageService = publicBlobStorageService; _tableStorageService = tableStorageService; }
/// <summary> /// /// </summary> /// <param name="sftpService"></param> /// <param name="blobStorageService"></param> public FileService(ISftpService sftpService, IBlobStorageService blobStorageService) { _sftpService = sftpService; _blobStorageService = blobStorageService; }