Exemplo n.º 1
0
        public CoronavirusResults(ICoronavirusCountryService coronavirusCountryService)
        {
            _coronavirusCountryService = coronavirusCountryService;

            CoronavirusCountryNames      = null;
            CoronavirusCountryCaseCounts = null;
        }
Exemplo n.º 2
0
        public static CoronavirusCountriesChartViewModel LoadViewModel(ICoronavirusCountryService coronavirusCountryService, Action<Task> onLoaded = null)
        {
            CoronavirusCountriesChartViewModel viewModel = new CoronavirusCountriesChartViewModel(coronavirusCountryService);

            viewModel.Load().ContinueWith(t => onLoaded?.Invoke(t));

            return viewModel;
        }
Exemplo n.º 3
0
        public static CoronavirusCountriesChartViewModel LoadViewModel(ICoronavirusCountryService coronavirusCountryService, Action <Task> onLoaded = null)
        {
            CoronavirusCountriesChartViewModel viewModel = new CoronavirusCountriesChartViewModel(coronavirusCountryService);

            viewModel.Load().ContinueWith(t => onLoaded?.Invoke(t));  // to po to by model sie nie wyswietlil nie ladujac wszystkich danych

            return(viewModel);
        }
Exemplo n.º 4
0
        public static CoronavirusResults Factory(ICoronavirusCountryService coronavirusCountryService, Action <Task> onLoaded = null)
        {
            CoronavirusResults coronavirusResults = new CoronavirusResults(coronavirusCountryService);

            coronavirusResults.Load().ContinueWith(t => onLoaded?.Invoke(t));

            return(coronavirusResults);
        }
Exemplo n.º 5
0
        public MainViewModel(CoronaCountriesViewModel coronaCountriesViewModel,
                             CoronaCountryInformationViewModel coronaCountryInformationViewModel)
        {
            _coronavirusCountryService = new APICoronavirusCountryService();

            PageViewModels.Add(coronaCountriesViewModel);
            PageViewModels.Add(coronaCountryInformationViewModel);

            Mediator.Subscribe("GoTo1Screen", OnGo1Screen);
            Mediator.Subscribe("GoTo2Screen", OnGo2Screen);
        }
Exemplo n.º 6
0
        public CoronavirusCountriesChartViewModel(ICoronavirusCountryService coronavirusCountryService)
        {
            _coronavirusCountryService = coronavirusCountryService;

            CoronavirusCountryNames = new ObservableCollection<string>();
        }
Exemplo n.º 7
0
 public CoronavirusCountiresChartViewModel(ICoronavirusCountryService coronavirusCountryService)
 {
     _coronavirusCountryService = coronavirusCountryService;
 }
Exemplo n.º 8
0
 public CoronavirusController(ICoronavirusCountryService coronavirusCountryService)
 {
     _coronavirusCountryService = coronavirusCountryService;
 }
Exemplo n.º 9
0
 //public HomeController(IAuthenticator authenticator, IStringLocalizer<HomeController> localizer)
 public HomeController(IStringLocalizer <HomeController> localizer, ICoronavirusCountryService coronavirusCountryService)
 {
     //_authenticator = authenticator;
     _localizer = localizer;
     _coronavirusCountryService = coronavirusCountryService;
 }