Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CountryStats ¶
type CountryStats struct { Country string `json:"country"` CountryInfo jsons.Country `json:"country_info"` TotalCases int `json:"total_cases"` NewCases int `json:"new_cases"` TotalDeaths int `json:"total_deaths"` NewDeaths int `json:"new_deaths"` TotalRecovered int `json:"total_recovered"` ActiveCases int `json:"active_cases"` SeriousCritical int `json:"serious_critical"` CasesPerOneMillion float64 `json:"cases_per_one_million"` DeathsPerOneMillion float64 `json:"deaths_per_one_million"` TotalTests int `json:"total_tests"` TestsPerOneMillion float64 `json:"tests_per_one_million"` }
CountryStats struct
type Service ¶
type Service interface { GetCountriesData() (*[]CountryStats, error) GetStatesData() (*[]StatesStats, error) FindCountry(string) (*CountryStats, error) FindState(string) (*StatesStats, error) }
Service interface
func NewService ¶
NewService create new service
type StatesStats ¶
type StatesStats struct { State string `json:"state"` StateInfo StateInfo `json:"state_info"` TotalCases int `json:"total_cases"` NewCases int `json:"new_cases"` TotalDeaths int `json:"total_deaths"` NewDeaths int `json:"new_deaths"` TotalRecovered int `json:"total_recovered"` ActiveCases int `json:"active_cases"` SeriousCritical int `json:"serious_critical"` CasesPerOneMillion float64 `json:"cases_per_one_million"` DeathsPerOneMillion float64 `json:"deaths_per_one_million"` TotalTests int `json:"total_tests"` TestsPerOneMillion float64 `json:"tests_per_one_million"` }
StatesStats struct
Click to show internal directories.
Click to hide internal directories.