Esempio n. 1
0
        public async Task UpdateAsync(string callSign)
        {
            //download file
            var localPath = Path.Combine(Constants.BaseFilePath, "CurrentConditions", callSign);
            var url       = CurrentConditions.UrlTemplate.Replace("xxxx", callSign);
            var result    = await RssHelper.GetStreamAsync(url, localPath);

            //parse file
            var doc = RssHelper.GetXDocFromFile(localPath);
            var currentConditions = GetCurrentConditionFromXDoc(doc);
            //save to db
        }