Http fileComplete
From TrillWiki
The http_fileComplete notification is sent when a file is finished being received after it has been requested with httpFileRequest.
Compatibility: 2.0 and higher
Contents |
Syntax
callback(int window_id, char *icontrol, "http_fileComplete", http_result_t *data, void *userData);
Note that all Trillian functions and notifications begin with a lower-case letter, despite the Wiki requirement that all pages start with a capital letter.
Parameters
Http fileComplete utilitizes the http_result_t structure.
struct http_result_t
{
unsigned int struct_size;
char *url;
char *buffer;
int buffer_size;
/* 3.1
*/
int result_state;
int connection_error_code;
int http_response_code;
char *http_response_headers;
};
- url
- The url requested to be downloaded.
- buffer
- The data received when the url is requested, minus the header.
- buffer_size
- The size of the above buffer.
Return Value
Must return 0.
Remarks
If the file is not received correctly, it will generate an http_fileError instead of this notification.
See also: httpFileRequest
