public Worker( ILogger <Worker> logger, IConfiguration configuration) { _logger = logger; _config = new GalleryOptions(); configuration.Bind(_config); }
public static GalleryService Instance(GalleryOptions config) { if (_service != null) { return(_service); } var provider = new GalleryProvider(config); var azureGallery = provider.ReadAzureGalleryJson(); _service = new GalleryService(azureGallery); return(_service); }
public HomeController(IOptions <GalleryOptions> optionsAccessor) { _options = optionsAccessor.Value; }
public FileService(GalleryOptions config) { _config = config; _galleryJsonFullName = Path.Combine(_config.LocalGalleryDirectory, _config.GalleryJsonName); }
public AzureService(GalleryOptions config) { _config = config; _azureAccount = CloudStorageAccount.Parse(_config.AzureStorageConnectionString); }