示例#1
0
 public RatesLogic(Logger logger, IRatesRepository rates_storage, IRatesSource rates_source,
                   IRatesCache rates_cache)
 {
     _logger       = logger;
     _ratesStorage = rates_storage;
     _ratesSource  = rates_source;
     _ratesCache   = rates_cache;
 }
 Timer timer = new Timer(); // name space(using System.Timers;)
 public EcbRateCollectorService(
     EcbRateDownloader ecbRateDownloader,
     IRatesRepository ratesRepository)
 {
     _ecbRateDownloader = ecbRateDownloader;
     _ratesRepository   = ratesRepository;
     InitializeComponent();
 }
示例#3
0
 public RatesController(IMapper mapper, IRatesRepository ratesRepository,
                        IProductRepository productRepository, ApplicationUserManager applicationUserManager)
     : base(applicationUserManager)
 {
     this.productRepository = productRepository;
     this.ratesRepository   = ratesRepository;
     this.mapper            = mapper;
 }
 public StrategiesController(ILogger <CoinsController> logger,
                             IOptions <GdaxOptions> options,
                             IRatesRepository ratesRepository)
 {
     _logger          = logger;
     _ratesRepository = ratesRepository;
     _gdaxOptions     = options.Value;
     _authenticator   = new RequestAuthenticator(_gdaxOptions.ApiKey, _gdaxOptions.Passphrase, _gdaxOptions.Secret);
 }
示例#5
0
 public OrderProcessor(IOrderRepository orderRepository, IEmailSender emailSender, IRatesRepository ratesRepository,
                       IProductRepository productRepository, ApplicationUserManager applicationUserManager)
 {
     this.orderRepository        = orderRepository;
     this.productRepository      = productRepository;
     this.emailSender            = emailSender;
     this.ratesRepository        = ratesRepository;
     this.applicationUserManager = applicationUserManager;
 }
示例#6
0
 public TipsService(
     ICurrencyService currencyService,
     ITransactionsRepository transactionsRepository,
     IRatesRepository ratesRepository)
 {
     this.currencyService        = currencyService ?? throw new ArgumentNullException(nameof(currencyService));
     this.transactionsRepository = transactionsRepository ?? throw new ArgumentNullException(nameof(transactionsRepository));
     this.ratesRepository        = ratesRepository ?? throw new ArgumentNullException(nameof(ratesRepository));
 }
示例#7
0
 public RatesCache(Logger logger, IRatesRepository rates_storage)
 {
     _logger         = logger;
     _ratesStorage   = rates_storage;
     _threadConsumer = new Thread(Consume)
     {
         IsBackground = true
     };
     _threadConsumer.Start();
 }
示例#8
0
 public TicketService(ITicketRepository ticketRepository,
                      IUserRepository userRepository,
                      IGameRepository gameRepository,
                      IRatesRepository ratesRepository,
                      ITicketValidator ticketValidator,
                      IStringLocalizer <ErrorMessages> localizer)
 {
     _ticketRepository = ticketRepository;
     _userRepository   = userRepository;
     _gameRepository   = gameRepository;
     _ratesRepository  = ratesRepository;
     _ticketValidator  = ticketValidator;
     _localizer        = localizer;
 }
示例#9
0
 public OptionsService(ILeagueRepository leagueRepository,
                       IRatesRepository rateRepository,
                       ILeagueManager leagueManager,
                       ITeamManager teamManager,
                       IGameManager gameManager,
                       IRelationCreator relationCreator,
                       IRateCalculator rateCalculator,
                       IOptions <RapidApiConfiguration> configuration,
                       IStringLocalizer <InformationMessages> localizer)
 {
     _leagueRepository = leagueRepository;
     _rateRepository   = rateRepository;
     _leagueManager    = leagueManager;
     _teamManager      = teamManager;
     _gameManager      = gameManager;
     _relationCreator  = relationCreator;
     _rateCalculator   = rateCalculator;
     _localizer        = localizer;
     _configuration    = configuration.Value;
 }
示例#10
0
        private void uxMainWindow_Loaded(object sender, RoutedEventArgs e)
        {
            //repository = new FakeRatesRepository();
            repository   = new StooqService();
            items        = new ObservableCollection <StockRate>();
            ItemsWrapper = new NotifyCollectionChangedWrapper <StockRate>(items);

            // Create a timer that adds an element to the list every two seconds *on seperate threads*
            timer          = new System.Timers.Timer(1000);
            timer.Elapsed +=
                new System.Timers.ElapsedEventHandler
                (
                    (timerSender, timerArgs) =>
                    ThreadPool.QueueUserWorkItem
                    (
                        new WaitCallback
                        (
                            AddRate
                            //(obj) => ItemsWrapper.Add(repository.GetRate())
                        )
                    )
                );
            timer.Start();
        }
示例#11
0
 public RatesService(IRatesRepository ratesRepository, IMapper mapper)
 {
     _ratesRepository = ratesRepository;
     _mapper          = mapper;
 }
示例#12
0
 public RateService(IRatesRepository ratesRepository)
 {
     _ratesRepository = ratesRepository;
 }
示例#13
0
 public RatesService(IRatesRepository ratesRepository)
 {
     this.ratesRepository = ratesRepository ?? throw new ArgumentNullException(nameof(ratesRepository));
 }
 public StatisticsController(IRatesRepository ratesRepository, IStatisticsRepository statisticsRepository)
 {
     StatisticsRepository = statisticsRepository;
 }
 public RatesService(IUnitOfWork unitOfWork, IRatesRepository reponsitory) : base(unitOfWork, reponsitory)
 {
     _unitOfWork      = unitOfWork;
     _ratesRepository = reponsitory;
 }
示例#16
0
 public CurrenciesController(IConfiguration configuration, IRatesRepository ratesRepository)
 {
     _configuration   = configuration;
     _ratesRepository = ratesRepository;
 }
示例#17
0
 public IRatesRepository GetRatesRepository()
 {
     return s_ratesRepository ?? (s_ratesRepository = new RatesRepository(this));
 }
 public ListadoPorSkuController(IRatesRepository ratesRespository, ITransactionsRepository transactionsRepository)
 {
     this.ratesRespository       = ratesRespository;
     this.transactionsRepository = transactionsRepository;
 }
 public RatesController(IRatesRepository repositorio)
 {
     this.ratesRepository = repositorio;
 }
 public RatesController()
 {
     this.ratesRepository = new RatesRepository();
 }
示例#21
0
        private void uxMainWindow_Loaded(object sender, RoutedEventArgs e)
        {
            //repository = new FakeRatesRepository();
            repository = new StooqService();
            items = new ObservableCollection<StockRate>();
            ItemsWrapper = new NotifyCollectionChangedWrapper<StockRate>(items);

            // Create a timer that adds an element to the list every two seconds *on seperate threads*
            timer = new System.Timers.Timer(1000);
            timer.Elapsed +=
                new System.Timers.ElapsedEventHandler
                    (
                    (timerSender, timerArgs) =>
                        ThreadPool.QueueUserWorkItem
                            (
                            new WaitCallback
                                (
                                AddRate
                        //(obj) => ItemsWrapper.Add(repository.GetRate())
                                )
                            )
                    );
            timer.Start();
        }
 public SimpleRatesCache(Logger logger, IRatesRepository rates_storage)
 {
     _logger       = logger;
     _ratesStorage = rates_storage;
 }
 public CurrencyExchangeService(ICurrencyExchangeTransactionsRepository transactionsRepository,
                                IRatesRepository ratesRepository)
 {
     TransactionsRepository = transactionsRepository;
     RatesRepository        = ratesRepository;
 }
 public RatesService(IExternalRatesService externalRatesService, IRatesRepository ratesRepository, IConfiguration configuration)
 {
     _externalRatesService = externalRatesService;
     _ratesRepository      = ratesRepository;
     _configuration        = configuration;
 }
示例#25
0
 public DbService(IRatesRepository rateRepository)
 {
     _ratesRepository = rateRepository;
 }
示例#26
0
 public RatesController(ICoinRepository coinRepository,
                        IRatesRepository ratesRepository)
 {
     _coinRepository  = coinRepository;
     _ratesRepository = ratesRepository;
 }
 public ListadoPorSkuController()
 {
     this.ratesRespository       = new RatesRepository();
     this.transactionsRepository = new TransactionsRepository();
 }
示例#28
0
 public RatesController(webapionlineContext context, IRatesRepository ratesRepository)
 {
     _context         = context;
     _ratesRepository = ratesRepository;
 }