from tornado.httpclient import AsyncHTTPClient
def asynchronous_fetch (url, callback):
http_client = AsyncHTTPClient()
def handle_response(response):
callback(response.body)
http_client.fetch(url, callback=handle_response)
asynchronous_fetch ("http://127.0.0.1:8000")
"there is an example of asynchrony. Where callback is a parameter, it should be an external function call, but it also sets callback=handle_response, what is the function of callback here?