HTTPStream.Adapter behaviour (HTTPStream v1.0.0) View Source
Adapter behaviour for HTTPStream compatible clients.
An adapter must implement the following callbacks:
request/1- Receives anHTTPStream.Request.t()and initiates the HTTP connection to the endpoint.parse_chunks/1- Receives values of any type returned byrequest/1and reads a chunk of data from the connection.close/1- Called when the final value fromparse_chunks/1is read. Should close the connection.
Currently supported adapters: HTTPStream.Adapter.Mint