~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/repofmt/weaverepo.py

  • Committer: Sidnei da Silva
  • Date: 2009-05-29 14:19:29 UTC
  • mto: (4531.1.1 integration)
  • mto: This revision was merged to the branch mainline in revision 4532.
  • Revision ID: sidnei.da.silva@canonical.com-20090529141929-3heywbvj36po72a5
- Add initial config

Show diffs side-by-side

added added

removed removed

Lines of Context:
28
28
lazy_import(globals(), """
29
29
from bzrlib import (
30
30
    xml5,
31
 
    graph as _mod_graph,
32
31
    )
33
32
""")
34
33
from bzrlib import (
320
319
        result.chk_bytes = None
321
320
        return result
322
321
 
 
322
    def check_conversion_target(self, target_format):
 
323
        pass
 
324
 
323
325
 
324
326
class RepositoryFormat4(PreSplitOutRepositoryFormat):
325
327
    """Bzr repository format 4.
492
494
        """See RepositoryFormat.get_format_description()."""
493
495
        return "Weave repository format 7"
494
496
 
 
497
    def check_conversion_target(self, target_format):
 
498
        pass
 
499
 
495
500
    def _get_inventories(self, repo_transport, repo, name='inventory'):
496
501
        mapper = versionedfile.ConstantMapper(name)
497
502
        return versionedfile.ThunkedVersionedFiles(repo_transport,
664
669
            result[key] = parents
665
670
        return result
666
671
 
667
 
    def get_known_graph_ancestry(self, keys):
668
 
        """Get a KnownGraph instance with the ancestry of keys."""
669
 
        keys = self.keys()
670
 
        parent_map = self.get_parent_map(keys)
671
 
        kg = _mod_graph.KnownGraph(parent_map)
672
 
        return kg
673
 
 
674
672
    def get_record_stream(self, keys, sort_order, include_delta_closure):
675
673
        for key in keys:
676
674
            text, parents = self._load_text_parents(key)
688
686
            path, ext = os.path.splitext(relpath)
689
687
            if ext == '.gz':
690
688
                relpath = path
691
 
            if not relpath.endswith('.sig'):
 
689
            if '.sig' not in relpath:
692
690
                relpaths.add(relpath)
693
691
        paths = list(relpaths)
694
692
        return set([self._mapper.unmap(path) for path in paths])