~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

Merge bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
757
757
        return format
758
758
 
759
759
    def create_checkout(self, to_location, revision_id=None,
760
 
                        lightweight=False):
 
760
                        lightweight=False, accelerator_tree=None):
761
761
        """Create a checkout of a branch.
762
762
        
763
763
        :param to_location: The url to produce the checkout at
764
764
        :param revision_id: The revision to check out
765
765
        :param lightweight: If True, produce a lightweight checkout, otherwise,
766
766
        produce a bound branch (heavyweight checkout)
 
767
        :param accelerator_tree: A tree which can be used for retrieving file
 
768
            contents more quickly than the revision tree, i.e. a workingtree.
 
769
            The revision tree will be used for cases where accelerator_tree's
 
770
            content is different.
767
771
        :return: The tree of the created checkout
768
772
        """
769
773
        t = transport.get_transport(to_location)
783
787
            checkout_branch.pull(self, stop_revision=revision_id)
784
788
            from_branch=None
785
789
        tree = checkout.create_workingtree(revision_id,
786
 
                                           from_branch=from_branch)
 
790
                                           from_branch=from_branch,
 
791
                                           accelerator_tree=accelerator_tree)
787
792
        basis_tree = tree.basis_tree()
788
793
        basis_tree.lock_read()
789
794
        try: