~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/plugins/weave_fmt/branch.py

  • Committer: Jelmer Vernooij
  • Date: 2011-05-10 07:46:15 UTC
  • mfrom: (5844 +trunk)
  • mto: This revision was merged to the branch mainline in revision 5845.
  • Revision ID: jelmer@samba.org-20110510074615-eptod049ndjxc4i7
Merge bzr.dev.

Show diffs side-by-side

added added

removed removed

Lines of Context:
25
25
 
26
26
from bzrlib.branch import (
27
27
    BranchFormat,
28
 
    BzrBranch,
 
28
    FullHistoryBzrBranch,
29
29
    )
30
30
 
31
31
 
32
 
class PreSplitOutBzrBranch(BzrBranch):
 
32
class BzrBranch4(FullHistoryBzrBranch):
 
33
    """Branch format 4."""
33
34
 
34
35
    def _get_checkout_format(self):
35
36
        """Return the most suitable metadir for a checkout of this branch.
40
41
        format.repository_format = RepositoryFormat7()
41
42
        return format
42
43
 
 
44
    def unbind(self):
 
45
        raise errors.UpgradeRequired(self.user_url)
 
46
 
 
47
    def bind(self, other):
 
48
        raise errors.UpgradeRequired(self.user_url)
 
49
 
 
50
    def set_bound_location(self, location):
 
51
        raise NotImplementedError(self.set_bound_location)
 
52
 
 
53
    def get_bound_location(self):
 
54
        return None
 
55
 
 
56
    def update(self):
 
57
        return None
 
58
 
 
59
    def get_master_branch(self, possible_transports=None):
 
60
        return None
 
61
 
43
62
 
44
63
class BzrBranchFormat4(BranchFormat):
45
64
    """Bzr branch format 4.
47
66
    This format has:
48
67
     - a revision-history file.
49
68
     - a branch-lock lock file [ to be shared with the bzrdir ]
 
69
 
 
70
    It does not support binding.
50
71
    """
51
72
 
52
73
    def initialize(self, a_bzrdir, name=None, repository=None):
115
136
            raise NotImplementedError
116
137
        if found_repository is None:
117
138
            found_repository = a_bzrdir.open_repository()
118
 
        return PreSplitOutBzrBranch(_format=self,
 
139
        return BzrBranch4(_format=self,
119
140
                         _control_files=a_bzrdir._control_files,
120
141
                         a_bzrdir=a_bzrdir,
121
142
                         name=name,