Revision 24ff0a35 kamaki/clients/storage.py

b/kamaki/clients/storage.py
80 80
        :param metakey: (str) metadatum key
81 81
        """
82 82
        headers = self.get_account_info()
83
        self.headers = filter_out(headers,
83
        self.headers = filter_out(
84
            headers,
84 85
            'X-Account-Meta-' + metakey,
85 86
            exactMatch=True)
86 87
        if len(self.headers) == len(headers):
......
159 160
        r = self.put(path, data=data, success=201)
160 161
        r.release()
161 162

  
162
    def create_object(self,
163
        obj,
164
        content_type='application/octet-stream',
165
        content_length=0):
163
    def create_object(
164
            self, obj,
165
            content_type='application/octet-stream', content_length=0):
166 166
        """
167 167
        :param obj: (str) directory-object name
168 168
        :param content_type: (str) explicitly set content_type
......
247 247
        cnt = r.content
248 248
        return cnt, size
249 249

  
250
    def copy_object(self, src_container, src_object, dst_container,
251
        dst_object=False):
250
    def copy_object(
251
            self, src_container, src_object, dst_container,
252
            dst_object=False):
252 253
        """Copy an objects from src_contaier:src_object to
253 254
            dst_container[:dst_object]
254 255

  
......
268 269
        r = self.put(dst_path, success=201)
269 270
        r.release()
270 271

  
271
    def move_object(self, src_container, src_object, dst_container,
272
        dst_object=False):
272
    def move_object(
273
            self, src_container, src_object, dst_container,
274
            dst_object=False):
273 275
        """Move an objects from src_contaier:src_object to
274 276
            dst_container[:dst_object]
275 277

  
......
312 314
        self.set_param('format', 'json')
313 315
        r = self.get(path, success=(200, 204, 304, 404), )
314 316
        if r.status_code == 404:
315
            raise ClientError(\
317
            raise ClientError(
316 318
                "Invalid account (%s) for that container" % self.account,
317 319
                r.status_code)
318 320
        elif r.status_code == 304:
......
334 336
        self.set_param('path', 'path_prefix')
335 337
        r = self.get(path, success=(200, 204, 404))
336 338
        if r.status_code == 404:
337
            raise ClientError(\
339
            raise ClientError(
338 340
                "Invalid account (%s) for that container" % self.account,
339 341
                r.status_code)
340 342
        reply = r.json

Also available in: Unified diff