Return an iterator of doc_ids of the documents of the
        specified type.

def by_type(self, type_name):
        '''
        Return an iterator of doc_ids of the documents of the
        specified type.
        '''
        if IRestorator.providedBy(type_name):
            type_name = type_name.type_name
        return (x[1] for x in self._links if x[0] == type_name)