private IEnumerable <DataAtom> LoadDataFromFile(string file) { List <DataAtom> data = new List <DataAtom>(); using (StreamReader sr = File.OpenText(file)) { string line; while ((line = sr.ReadLine()) != null) { data.Add(DataAtom.FromString(line)); } } return(data); }
private List <DataAtom> ReadAggregatedListFromFile(string fileName) { List <DataAtom> result = new List <DataAtom>(); using (StreamReader sr = File.OpenText(fileName)) { string line; while ((line = sr.ReadLine()) != null) { result.Add(DataAtom.FromString(line)); } } return(result); }