public int translateWeather(DownloadWeather myWeather) { weatherDescription = myWeather.weather[0].description; mainWeatherTemp = myWeather.main.temp; name = myWeather.name; uploadTime = int.Parse(DateTime.Now.ToString("yyyyMMdd")); return(0); }
public int newEntry(string City) { Console.WriteLine("----------------------------------)" + City); DownloadWeather myWeather = new DownloadWeather(); myWeather = JsonConvert.DeserializeObject <DownloadWeather>(myWeather.getWeather(City)); translateWeather(myWeather); return(0); }