~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/remote.py

  • Committer: Andrew Bennetts
  • Date: 2009-06-17 03:53:51 UTC
  • mto: This revision was merged to the branch mainline in revision 4452.
  • Revision ID: andrew.bennetts@canonical.com-20090617035351-09mh070abzv68feu
Move check onto base Branch class, and add a supports_set_append_revisions_only method to BranchFormat, as suggested by Robert.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1924
1924
        self._ensure_real()
1925
1925
        return self._custom_format.supports_stacking()
1926
1926
 
 
1927
    def supports_set_append_revisions_only(self):
 
1928
        self._ensure_real()
 
1929
        return self._custom_format.supports_set_append_revisions_only()
 
1930
 
1927
1931
 
1928
1932
class RemoteBranch(branch.Branch, _RpcHelper):
1929
1933
    """Branch stored on a server accessed by HPSS RPC.
2340
2344
            raise errors.UnexpectedSmartServerResponse(response)
2341
2345
        self._run_post_change_branch_tip_hooks(old_revno, old_revid)
2342
2346
 
2343
 
    def set_append_revisions_only(self, enabled):
2344
 
        if enabled:
2345
 
            value = 'True'
2346
 
        else:
2347
 
            value = 'False'
2348
 
        self.get_config().set_user_option('append_revisions_only', value,
2349
 
            warn_masked=True)
2350
 
 
2351
2347
    @needs_write_lock
2352
2348
    def set_revision_history(self, rev_history):
2353
2349
        # Send just the tip revision of the history; the server will generate