

def _store_object(self, obj_name, content, etag=None, chunked=False, chunk_size=None, headers=None):
    '\n        Handles the low-level creation of a storage object and the uploading of\n        the contents of that object.\n        '
    head_etag = headers.pop('ETag', '')
    if chunked:
        headers.pop('Content-Length', '')
        headers['Transfer-Encoding'] = 'chunked'
    elif ((etag is None) and (content is not None)):
        etag = utils.get_checksum(content)
    if etag:
        headers['ETag'] = etag
    if (not headers.get('Content-Type')):
        headers['Content-Type'] = None
    uri = ('/%s/%s' % (self.uri_base, obj_name))
    (resp, resp_body) = self.api.method_put(uri, data=content, headers=headers)

dataset/ETHPy150Open rackspace/pyrax/pyrax/object_storage.py StorageObjectManager._store_object/original