コード例 #1
0
        public CurrentWeatherDomainModel MapToCurrentWeatherDomainModel(OpenWeatherCurrentWeatherDataModel datamodel)
        {
            CurrentWeatherDomainModel domainModel = new CurrentWeatherDomainModel();

            domainModel.Temperature        = datamodel.Main.Temp;
            domainModel.WeatherDescription = datamodel.Weather[0].Description;

            return(domainModel);
        }
コード例 #2
0
        private static CurrentWeatherDomainModel GetCurrentWeatherForecastDomainModel(OpenWeatherCurrentWeatherDataModel model)
        {
            MapperCurrentWeatherDomainModel mapper = new MapperCurrentWeatherDomainModel();

            return(mapper.MapToCurrentWeatherDomainModel(model));
        }