~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/foreign.py

  • Committer: Jelmer Vernooij
  • Date: 2008-12-27 14:00:39 UTC
  • mto: (3920.2.35 dpush)
  • mto: This revision was merged to the branch mainline in revision 4281.
  • Revision ID: jelmer@samba.org-20081227140039-atkg8aakn5vmcnjk
Add ForeignBranch class.

Show diffs side-by-side

added added

removed removed

Lines of Context:
239
239
            self.get_revision(revision_id))
240
240
 
241
241
 
 
242
class ForeignBranch(Branch):
 
243
    """Branch that exists in a foreign version control system."""
 
244
 
 
245
    def __init__(self, mapping):
 
246
        self.mapping = mapping
 
247
        super(ForeignBranch, self).__init__()
 
248
 
 
249
    def dpull(self, source, stop_revision=None):
 
250
        """Pull deltas from another branch.
 
251
 
 
252
        :note: This does not, like pull, retain the revision ids from 
 
253
            the source branch and will, rather than adding bzr-specific 
 
254
            metadata, push only those semantics of the revision that can be 
 
255
            natively represented by this branch' VCS.
 
256
 
 
257
        :param source: Source branch
 
258
        :param stop_revision: Revision to pull, defaults to last revision.
 
259
        """
 
260
        raise NotImplementedError(self.dpull)