/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/repofmt/knitrepo.py

  • Committer: Martin Pool
  • Date: 2009-03-13 07:54:48 UTC
  • mfrom: (4144 +trunk)
  • mto: This revision was merged to the branch mainline in revision 4189.
  • Revision ID: mbp@sourcefrog.net-20090313075448-jlz1t7baz7gzipqn
merge trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
118
118
        self._commit_builder_class = _commit_builder_class
119
119
        self._serializer = _serializer
120
120
        self._reconcile_fixes_text_parents = True
121
 
        self._fetch_uses_deltas = True
122
 
        self._fetch_order = 'topological'
123
121
 
124
122
    @needs_read_lock
125
123
    def _all_revision_ids(self):
216
214
        reconciler = KnitReconciler(self, thorough=thorough)
217
215
        reconciler.reconcile()
218
216
        return reconciler
219
 
    
 
217
 
220
218
    def _make_parents_provider(self):
221
219
        return _KnitsParentsProvider(self.revisions)
222
220
 
253
251
 
254
252
 
255
253
class RepositoryFormatKnit(MetaDirRepositoryFormat):
256
 
    """Bzr repository knit format (generalized). 
 
254
    """Bzr repository knit format (generalized).
257
255
 
258
256
    This repository format has:
259
257
     - knits for file texts and inventory
282
280
    supports_ghosts = True
283
281
    # External lookups are not supported in this format.
284
282
    supports_external_lookups = False
 
283
    _fetch_order = 'topological'
 
284
    _fetch_uses_deltas = True
285
285
 
286
286
    def _get_inventories(self, repo_transport, repo, name='inventory'):
287
287
        mapper = versionedfile.ConstantMapper(name)
327
327
        dirs = ['knits']
328
328
        files = []
329
329
        utf8_files = [('format', self.get_format_string())]
330
 
        
 
330
 
331
331
        self._upload_blank_content(a_bzrdir, dirs, files, utf8_files, shared)
332
332
        repo_transport = a_bzrdir.get_repository_transport(None)
333
333
        control_files = lockable_files.LockableFiles(repo_transport,
345
345
 
346
346
    def open(self, a_bzrdir, _found=False, _override_transport=None):
347
347
        """See RepositoryFormat.open().
348
 
        
 
348
 
349
349
        :param _override_transport: INTERNAL USE ONLY. Allows opening the
350
350
                                    repository at a slightly different url
351
351
                                    than normal. I.e. during 'upgrade'.
447
447
        if not getattr(target_format, 'supports_tree_reference', False):
448
448
            raise errors.BadConversionTarget(
449
449
                'Does not support nested trees', target_format)
450
 
            
 
450
 
451
451
    def get_format_string(self):
452
452
        """See RepositoryFormat.get_format_string()."""
453
453
        return "Bazaar Knit Repository Format 3 (bzr 0.15)\n"