

def _fetch_remote_file(service_url, params={
    
}, use_http_post=False):
    'Retrieves a file from a URL.\n\n    Returns a tuple (mimetype, filename, data)\n    '
    (request_url, response) = _fetch_remote(service_url, params, use_http_post)
    (dummy, params) = cgi.parse_header(response.headers.get('Content-Disposition', ''))
    fn = params['filename']
    return (response.headers.get('content-type'), fn, response.read(), response.geturl())

dataset/ETHPy150Open slimkrazy/python-google-places/googleplaces/__init__.py _fetch_remote_file/original