'Return (start, stop) or raise KeyError.'

def _lookup(self, key=None):

    if (self._toc is None):
        self._generate_toc()
    if (key is not None):
        try:
            return self._toc[key]
        except KeyError:
            raise KeyError(('No    message    with    key:    %s' % key))
    return
