~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transform.py

  • Committer: Jelmer Vernooij
  • Date: 2012-01-06 01:58:27 UTC
  • mto: (6437.3.7 2.5)
  • mto: This revision was merged to the branch mainline in revision 6441.
  • Revision ID: jelmer@samba.org-20120106015827-9xy0wl8fcf5fn1d5
Add hooks for tree transforms.

Show diffs side-by-side

added added

removed removed

Lines of Context:
50
50
                           ExistingLimbo, ImmortalLimbo, NoFinalPath,
51
51
                           UnableCreateSymlink)
52
52
from bzrlib.filters import filtered_output_bytes, ContentFilterContext
 
53
from bzrlib.mutabletree import MutableTree
53
54
from bzrlib.osutils import (
54
55
    delete_any,
55
56
    file_kind,
156
157
        if self._tree is None:
157
158
            return
158
159
        for hook in MutableTree.hooks['post_transform']:
159
 
            hook(self)
 
160
            hook(self._tree, self)
160
161
        self._tree.unlock()
161
162
        self._tree = None
162
163
 
1724
1725
        :param _mover: Supply an alternate FileMover, for testing
1725
1726
        """
1726
1727
        for hook in MutableTree.hooks['pre_transform']:
1727
 
            hook(self)
 
1728
            hook(self._tree, self)
1728
1729
        if not no_conflicts:
1729
1730
            self._check_malformed()
1730
1731
        child_pb = ui.ui_factory.nested_progress_bar()