From: Adam T. <a-t...@st...> - 2007-01-30 16:39:56
|
>> I have however, a different idea. What if .parse() were defined >> for the >> generic class LogFile, and it did all the "generic" things, and >> also called >> self.extract(), which would contain the "for line in >> self.inputfile" loop >> that is specific to each parser (effectively replacing the >> current.parse()). >> This way, we would have only one function more and all the >> benifits, and >> again no change for the user. > > Indeed, I prefer this too. I agree that this is a good idea. I also think ccopen and others should check to see if the logfile exists, and if not, print an error/ warning about it. Adam |