/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/transport/memory.py

Add a new method ``Tree.revision_tree`` which allows access to cached
trees for arbitrary revisions. This allows the in development dirstate
tree format to provide access to the callers to cached copies of 
inventory data which are cheaper to access than inventories from the
repository. (Robert Collins, Martin Pool)

Show diffs side-by-side

added added

removed removed

Lines of Context:
98
98
        else:
99
99
            return temp_t.base[:-1]
100
100
 
101
 
    def append(self, relpath, f, mode=None):
102
 
        """See Transport.append()."""
 
101
    def append_file(self, relpath, f, mode=None):
 
102
        """See Transport.append_file()."""
103
103
        _abspath = self._abspath(relpath)
104
104
        self._check_parent(_abspath)
105
105
        orig_content, orig_mode = self._files.get(_abspath, ("", None))
133
133
            raise NoSuchFile(relpath)
134
134
        return StringIO(self._files[_abspath][0])
135
135
 
136
 
    def put(self, relpath, f, mode=None):
137
 
        """See Transport.put()."""
 
136
    def put_file(self, relpath, f, mode=None):
 
137
        """See Transport.put_file()."""
138
138
        _abspath = self._abspath(relpath)
139
139
        self._check_parent(_abspath)
140
140
        self._files[_abspath] = (f.read(), mode)