예제 #1
0
        public List <(string, string)> ParseFilesSync(string dataFolderPath)
        {
            var result = new List <(string, string)>();

            foreach (var file in _fileRetriever.GetFilenames(dataFolderPath))
            {
                foreach (var row in _fileRetriever.FileRows(file))
                {
                    result.Add(_csvRowParser.ParseRow(row));
                }
            }

            return(result);
        }
        public async Task <List <(string timestamp, string csvValue)> > ParseFiles(string dataFolderPath)
        {
            var result = new List <(string timestamp, string csvValue)>();

            foreach (var file in _fileRetriever.GetFilenames(dataFolderPath))
            {
                await foreach (var row in _fileRetriever.FileRowsAsync(file))
                {
                    result.Add(_csvRowParser.ParseRow(row));
                }
            }

            return(result);
        }