Loading...
Searching...
No Matches
Http.h
Go to the documentation of this file.
7// In no event will the authors be held liable for any damages arising from the use of this software.
121CSFML_NETWORK_API void sfHttpRequest_setField(sfHttpRequest* httpRequest, const char* field, const char* value);
159CSFML_NETWORK_API void sfHttpRequest_setHttpVersion(sfHttpRequest* httpRequest, unsigned int major, unsigned int minor);
195CSFML_NETWORK_API const char* sfHttpResponse_getField(const sfHttpResponse* httpResponse, const char* field);
220CSFML_NETWORK_API unsigned int sfHttpResponse_getMajorVersion(const sfHttpResponse* httpResponse);
230CSFML_NETWORK_API unsigned int sfHttpResponse_getMinorVersion(const sfHttpResponse* httpResponse);
301CSFML_NETWORK_API sfHttpResponse* sfHttp_sendRequest(sfHttp* http, const sfHttpRequest* request, sfTime timeout);
void sfHttp_setHost(sfHttp *http, const char *host, unsigned short port)
Set the target host of a HTTP object.
const char * sfHttpResponse_getBody(const sfHttpResponse *httpResponse)
Get the body of a HTTP response.
unsigned int sfHttpResponse_getMinorVersion(const sfHttpResponse *httpResponse)
Get the minor HTTP version number of a HTTP response.
void sfHttpRequest_setBody(sfHttpRequest *httpRequest, const char *body)
Set the body of a HTTP request.
unsigned int sfHttpResponse_getMajorVersion(const sfHttpResponse *httpResponse)
Get the major HTTP version number of a HTTP response.
void sfHttpRequest_setUri(sfHttpRequest *httpRequest, const char *uri)
Set a HTTP request URI.
void sfHttpResponse_destroy(sfHttpResponse *httpResponse)
Destroy a HTTP response.
void sfHttpRequest_setField(sfHttpRequest *httpRequest, const char *field, const char *value)
Set the value of a header field of a HTTP request.
void sfHttpRequest_setMethod(sfHttpRequest *httpRequest, sfHttpMethod method)
Set a HTTP request method.
void sfHttpRequest_setHttpVersion(sfHttpRequest *httpRequest, unsigned int major, unsigned int minor)
Set the HTTP version of a HTTP request.
sfHttpStatus sfHttpResponse_getStatus(const sfHttpResponse *httpResponse)
Get the status code of a HTTP reponse.
const char * sfHttpResponse_getField(const sfHttpResponse *httpResponse, const char *field)
Get the value of a field of a HTTP response.
sfHttpResponse * sfHttp_sendRequest(sfHttp *http, const sfHttpRequest *request, sfTime timeout)
Send a HTTP request and return the server's response.
@ sfHttpResetContent
The server informs the client that it should clear the view (form) that caused the request to be sent...
Definition Http.h:61
@ sfHttpNotModified
For conditional requests, means the requested page hasn't changed and doesn't need to be refreshed.
Definition Http.h:68
@ sfHttpGatewayTimeout
The gateway server couldn't receive a response from the source server.
Definition Http.h:82
@ sfHttpMultipleChoices
The requested page can be accessed from several locations.
Definition Http.h:65
@ sfHttpPartialContent
The server has sent a part of the resource, as a response to a partial GET request.
Definition Http.h:62
@ sfHttpServiceNotAvailable
The server is temporarily unavailable (overloaded, in maintenance, ...)
Definition Http.h:81
@ sfHttpMovedTemporarily
The requested page has temporarily moved to a new location.
Definition Http.h:67
@ sfHttpMovedPermanently
The requested page has permanently moved to a new location.
Definition Http.h:66
@ sfHttpBadGateway
The gateway server has received an error from the source server.
Definition Http.h:80
@ sfHttpVersionNotSupported
The server doesn't support the requested HTTP version.
Definition Http.h:83
@ sfHttpRangeNotSatisfiable
The server can't satisfy the partial GET request (with a "Range" header field)
Definition Http.h:75
@ sfHttpAccepted
The request has been accepted, but will be processed later by the server.
Definition Http.h:59
@ sfHttpForbidden
The requested page cannot be accessed at all, even with authentication.
Definition Http.h:73