public SqlCurrencyRepository( IConetextFactory <DbCurrencyContext> conetextFactory, ICurrecyFactory currecyFactory) { _conetextFactory = conetextFactory; _currecyFactory = currecyFactory; }
private static async Task Load(ICurrencyRepository curencyRepository, ICurrecyFactory currecyFactory, IEnumerable <CnbCurrencyHistory> recordsToHandle) { var currecies = recordsToHandle .Select(e => currecyFactory.Create(e.Code, e.Amount, e.Rate, e.Date)) .ToArray(); await curencyRepository.SaveAsync(currecies); }
public RateReaderService( ICurrencyRepository currencyRepository, ICurrencyDataProvier currencyDataProvier, ICurrecyFactory currecyFactory, RateReaderServiceConfiguration configuration, ILogger <RateReaderService> logger) { _currencyRepository = currencyRepository; _currencyDataProvier = currencyDataProvier; _currecyFactory = currecyFactory; _configuration = configuration; _logger = logger; }