~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/weave.py

  • Committer: Robert Collins
  • Date: 2008-04-09 00:34:54 UTC
  • mto: This revision was merged to the branch mainline in revision 3350.
  • Revision ID: robertc@robertcollins.net-20080409003454-x19fm1n0o2govzh6
 * ``VersionedFile.annotate_iter`` is deprecated. While in principal this
   allows lower memory use, all users of annotations wanted full file 
   annotations, and there is no storage format suitable for incremental
   line-by-line annotation. (Robert Collins)

Show diffs side-by-side

added added

removed removed

Lines of Context:
466
466
        """
467
467
        return len(other_parents.difference(my_parents)) == 0
468
468
 
469
 
    def annotate_iter(self, version_id):
470
 
        """Yield list of (version-id, line) pairs for the specified version.
 
469
    def annotate(self, version_id):
 
470
        """Return a list of (version-id, line) tuples for version_id.
471
471
 
472
472
        The index indicates when the line originated in the weave."""
473
473
        incls = [self._lookup(version_id)]
474
 
        for origin, lineno, text in self._extract(incls):
475
 
            yield self._idx_to_name(origin), text
 
474
        return [(self._idx_to_name(origin), text) for origin, lineno, text in
 
475
            self._extract(incls)]
476
476
 
477
477
    def iter_lines_added_or_present_in_versions(self, version_ids=None,
478
478
                                                pb=None):