internal void SaveFile(IEnumerable <string> fileContent) { Configuration.LastDownloadRun = DateTime.Now.ToString("yyyy-MM-dd HH:mm"); Configuration.LastEntryInFile = ContentValidator.GetLastDate(fileContent); File.WriteAllLines(Configuration.TickerFile, fileContent); Configuration.Save(); }
internal static int AsInt(this string line) { return(ContentValidator.IsValid(line) ? Convert.ToInt32(line.Split(',')[0].Replace("-", "")) : string.IsNullOrEmpty(line) ? 99999999 : -1); }