Example #1
0
    def __init__(self, logfn):
        # fileno -> filename
        self._filemap = {}
        # (fileno, lineno) -> filename, funcname
        self._funcmap = {}

        self._reader = _hotshot.logreader(logfn)
        self._nextitem = self._reader.next
        self._info = self._reader.info
        self._stack = []
Example #2
0
 def __init__(self, logfn):
     self._filemap = {}
     self._funcmap = {}
     self._reader = _hotshot.logreader(logfn)
     self._nextitem = self._reader.next
     self._info = self._reader.info
     if 'current-directory' in self._info:
         self.cwd = self._info['current-directory']
     else:
         self.cwd = None
     self._stack = []
     self._append = self._stack.append
     self._pop = self._stack.pop
     return
Example #3
0
 def __init__(self, logfn):
     self._filemap = {}
     self._funcmap = {}
     self._reader = _hotshot.logreader(logfn)
     self._nextitem = self._reader.next
     self._info = self._reader.info
     if 'current-directory' in self._info:
         self.cwd = self._info['current-directory']
     else:
         self.cwd = None
     self._stack = []
     self._append = self._stack.append
     self._pop = self._stack.pop
     return
Example #4
0
    def __init__(self, logfn):
        # fileno -> filename
        self._filemap = {}
        # (fileno, lineno) -> filename, funcname
        self._funcmap = {}

        self._reader = _hotshot.logreader(logfn)
        self._nextitem = self._reader.next
        self._info = self._reader.info
        if self._info.has_key('current-directory'):
            self.cwd = self._info['current-directory']
        else:
            self.cwd = None
        self._stack = []
        self._append = self._stack.append
        self._pop = self._stack.pop
    def __init__(self, logfn):
        # fileno -> filename
        self._filemap = {}
        # (fileno, lineno) -> filename, funcname
        self._funcmap = {}

        self._reader = _hotshot.logreader(logfn)
        self._nextitem = self._reader.next
        self._info = self._reader.info
        if 'current-directory' in self._info:
            self.cwd = self._info['current-directory']
        else:
            self.cwd = None

        # This mirrors the call stack of the profiled code as the log
        # is read back in.  It contains tuples of the form:
        #
        #   (file name, line number of function def, function name)
        #
        self._stack = []
        self._append = self._stack.append
        self._pop = self._stack.pop
Example #6
0
File: log.py Project: B-Rich/breve
    def __init__(self, logfn):
        # fileno -> filename
        self._filemap = {}
        # (fileno, lineno) -> filename, funcname
        self._funcmap = {}

        self._reader = _hotshot.logreader(logfn)
        self._nextitem = self._reader.next
        self._info = self._reader.info
        if self._info.has_key('current-directory'):
            self.cwd = self._info['current-directory']
        else:
            self.cwd = None

        # This mirrors the call stack of the profiled code as the log
        # is read back in.  It contains tuples of the form:
        #
        #   (file name, line number of function def, function name)
        #
        self._stack = []
        self._append = self._stack.append
        self._pop = self._stack.pop
Example #7
0
import _hotshot
Example #8
0
import _hotshot