Open topic with navigation
|Example: Asynchronous Conversations||Asynchonous Functions|
Called when there is content in the response body buffer and at the end of the response body.
int <function name> ( IN const char * aLastBufferStr, IN int aLastBufferLen, IN const char * aAccumulatedStr, IN int aAccumulatedLen, IN int aHttpStatusCode );
A pointer to one of:
The length of the string pointed-to by aLastBufferStr or zero to denote the end of the response data.
A pointer to one of:
The length of the string pointed-to by aAccumulatedStr, or zero to denote the end of the response data
|aHttpStatusCode||The HTTP status return code.|
Returns a value of WEB_ASYNC_CB_RC_ENUM
A response body buffer callback is a user-created C-language function. It is invoked zero or more times for each response body buffer received for the ConversationAn Asynchronous Conversation is a series of related web tasks, including tasks caused by redirection. An Asynchronous Conversation starts with the request for the desired response, includes all the requests and responses that are caused by this request (authentication, redirection, and so on) and ends when the desired response is received or when the series of interactions is canceled.. After all of the response body data has been passed to the callback, it is invoked once more with an empty last-buffer string. An empty last-buffer string marks the end of the response body for the current conversation. When the response body is empty, the callback is invoked once to mark the end.
The callback is passed the data extracted from the last read buffer and all response body accumulated to this point.
The response data is processed as follows before being passed to the callback:
Chunking overhead or decompression remainders can cause a non-empty received response buffer to yield no data after the processing described above. The callback is not invoked for such buffers.
Decompression can cause the callback to be called multiple times for a single received buffer.
This callback can invoke the utility function "RequestCB" and any of the general utility functions. See Utility Functions: C Language (lr_).