33#ifndef GENLIB_NET_HTTP_HTTPREADWRITE_H
34#define GENLIB_NET_HTTP_HTTPREADWRITE_H
46#define HTTP_DEFAULT_TIMEOUT 30
53struct tm *http_gmtime_r(
const time_t *clock,
struct tm *result);
55#define http_gmtime_r gmtime_r
58int http_CancelHttpGet(IN
void *Handle);
124 IN http_method_t request_method,
125 IN OUT
int* timeout_secs,
126 OUT
int* http_error_code );
183int http_RequestAndResponse(
185 IN
const char* request,
186 IN
size_t request_length,
187 IN http_method_t req_method,
228 OUT
size_t *doc_length,
229 OUT
char* content_type );
247int http_HttpGetProgress(
315 Upnp_HttpMethod method,
325 const char *contentType,
508int http_SendStatusResponse(
510 IN
int http_status_code,
511 IN
int request_major_version,
512 IN
int request_minor_version );
556 IN
int http_major_version,
558 IN
int http_minor_version,
579void http_CalcResponseVersion(
580 IN
int request_major_vers,
581 IN
int request_minor_vers,
582 OUT
int* response_major_vers,
583 OUT
int* response_minor_vers );
611int http_OpenHttpGetEx(IN
const char *url_str,
612 IN OUT
void **Handle,
613 IN OUT
char **contentType,
614 OUT
int *contentLength,
634void get_sdk_info( OUT
char *info, IN
size_t infoSize );
#define EXPORT_SPEC
Export functions on WIN32 DLLs.
Definition: UpnpGlobal.h:87
int SOCKET
Definition: UpnpInet.h:48
struct s_UpnpString UpnpString
Type of the string objects inside libupnp.
Definition: UpnpString.h:38
int http_RecvMessage(IN SOCKINFO *info, OUT http_parser_t *parser, IN http_method_t request_method, IN OUT int *timeout_secs, OUT int *http_error_code)
Get the data on the socket and take actions based on the read data to modify the parser objects buffe...
Definition: httpreadwrite.c:344
int http_ReadHttpResponse(void *Handle, char *buf, size_t *size, int timeout)
Reads the content of a response using a connection previously created by UpnpOpenHttpConnection.
Definition: httpreadwrite.c:1315
int http_OpenHttpConnection(const char *url_str, void **Handle, int timeout)
Opens a connection to the server.
Definition: httpreadwrite.c:1103
int http_CloseHttpConnection(void *Handle)
Closes the connection created with UpnpOpenHttpConnection and frees any memory associated with the co...
Definition: httpreadwrite.c:1413
int http_SendMessage(SOCKINFO *info, int *TimeOut, const char *fmt,...)
Sends a message to the destination based on the format parameter.
Definition: httpreadwrite.c:437
int http_WriteHttpRequest(void *Handle, char *buf, size_t *size, int timeout)
Writes the content of a HTTP request initiated by a UpnpMakeHttpRequest call. The end of the content ...
Definition: httpreadwrite.c:1191
int http_EndHttpRequest(void *Handle, int timeout)
Indicates the end of a HTTP request previously made by UpnpMakeHttpRequest.
Definition: httpreadwrite.c:1238
int http_GetHttpResponse(void *Handle, UpnpString *headers, char **contentType, int *contentLength, int *httpStatus, int timeout)
Gets the response from the server using a connection previously created by UpnpOpenHttpConnection.
Definition: httpreadwrite.c:1256
int http_MakeHttpRequest(Upnp_HttpMethod method, const char *url_str, void *Handle, UpnpString *headers, const char *contentType, int contentLength, int timeout)
Makes a HTTP request using a connection previously created by UpnpOpenHttpConnection.
Definition: httpreadwrite.c:1162
int http_MakeMessage(membuffer *buf, int http_major_version, int http_minor_version, const char *fmt,...)
Generate an HTTP message based on the format that is specified in the input parameters.
Definition: httpreadwrite.c:1470
Represents a URI used in parse_uri and elsewhere.
Definition: uri.h:136
Definition: httpparser.h:213
Definition: membuffer.h:56