meth = getattr(self, name)
results[name] = meth()
- pprint(results)
+ return results
def playingDuration(self) :
""" retourne la durée écoulée entre le premier et de dernier message
lfa = LogFileAnalyser(args[0])
- lfa.analyse()
+ pprint(lfa.analyse())
if __name__ == "__main__" :
from os.path import realpath, sep
from glob import glob
from os.path import join as pjoin
from os.path import basename
+from loganalyse import LogFileAnalyser
+from pprint import pprint
class Application(Frame) :
def __init__(self, master=None) :
filepath = self.logFiles[index]
filename = basename(filepath)
self.identFrame.setFileName(filename)
+ rf = ResultsFrame(self.dataFrame, filepath)
+ rf.layResults()
+ rf.grid()
class Navbar(Frame) :
self.commentsText = Text(self, width=40, height=4, undo=True, wrap=WORD)
self.commentsText.grid(row=2, column=1, sticky=W)
+
+class ResultsFrame(Frame) :
+ def __init__(self, master, logFilePath) :
+ Frame.__init__(self, master)
+ self.logFilePath = logFilePath
+ def layResults(self) :
+ lfa = LogFileAnalyser(self.logFilePath)
+ results = lfa.analyse()
+ pprint(results)
+ rawPrint = Label(self, text=str(results))
+ rawPrint.grid()
+
app = Application()
app.master.title("Analyseur des sessions MINWii")