This article is part of the series An Exercise in Performance Tuning in C#.Net.
As I look at the code I now have, I wonder if the fileLines variable is an unnecessary
intermediate step. Can I rewrite so that stream.ReadLine()
is passed directly into
the parsing? If I do so, I’ll be leaving the file open longer, but since no other application
should be attempting to access the file, I’m okay with that. This means moving the open file
command into MyClass.ProcessFile()
.