~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/shelf.py

  • Committer: Martin Pool
  • Date: 2009-07-24 03:15:56 UTC
  • mfrom: (4565 +trunk)
  • mto: This revision was merged to the branch mainline in revision 4566.
  • Revision ID: mbp@sourcefrog.net-20090724031556-5zyef6f1ixtn6r3z
merge news

Show diffs side-by-side

added added

removed removed

Lines of Context:
96
96
                elif changed:
97
97
                    yield ('modify text', file_id)
98
98
 
 
99
    def shelve_change(self, change):
 
100
        """Shelve a change in the iter_shelvable format."""
 
101
        if change[0] == 'rename':
 
102
            self.shelve_rename(change[1])
 
103
        elif change[0] == 'delete file':
 
104
            self.shelve_deletion(change[1])
 
105
        elif change[0] == 'add file':
 
106
            self.shelve_creation(change[1])
 
107
        elif change[0] == 'change kind':
 
108
            self.shelve_content_change(change[1])
 
109
        elif change[0] == 'modify target':
 
110
            self.shelve_modify_target(change[1])
 
111
        else:
 
112
            raise ValueError('Unknown change kind: "%s"' % change[0])
 
113
 
99
114
    def shelve_rename(self, file_id):
100
115
        """Shelve a file rename.
101
116