ProgressCallback typedef
The type of a progress listening callback when sending or receiving data.
count is the length of the bytes have been sent/received.
total is the content length of the response/request body.
- When sending data,
totalis the request body length. - When receiving data,
totalwill be -1 if the size of the response body, typically with nocontent-lengthheader.
Implementation
typedef ProgressCallback = void Function(int count, int total);