Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members

HttpHeaders Class Reference

List of all members.

Static Public Member Functions

void buildDefaultHTTPResponseHeader (HttpResponseHeader *)
int buildHTTPRequestHeaderStruct (HttpRequestHeader *request, HttpThreadContext *td, char *input=0)
void buildHTTPResponseHeader (char *, HttpResponseHeader *)
int buildHTTPResponseHeaderStruct (HttpResponseHeader *response, HttpThreadContext *td, char *input=0)
void resetHTTPRequest (HttpRequestHeader *request)
void resetHTTPResponse (HttpResponseHeader *response)
int validHTTPRequest (char *, HttpThreadContext *, u_long *, u_long *)
int validHTTPResponse (char *, HttpThreadContext *, u_long *, u_long *)

Member Function Documentation

void HttpHeaders::buildDefaultHTTPResponseHeader HttpResponseHeader response  )  [static]
 

Set the defaults value for a HttpResponseHeader structure.

Parameters:
response The HTTP response header structure to fullfill with the default data.

int HttpHeaders::buildHTTPRequestHeaderStruct HttpRequestHeader request,
HttpThreadContext td,
char *  input = 0
[static]
 

Build the HTTP REQUEST HEADER string. If no input is setted the input is the main buffer of the HttpThreadContext structure. Returns e_200 if is a valid request. Returns -1 if the request is incomplete. Any other returned value is the HTTP error.

Parameters:
request HTTP request structure to fullfill with data.
td the current executing thread context.
input buffer with the HTTP header.

void HttpHeaders::buildHTTPResponseHeader char *  str,
HttpResponseHeader response
[static]
 

Builds an HTTP header string starting from an HttpResponseHeader structure.

Parameters:
str The buffer where write the HTTP header.
response the HttpResponseHeader where the HTTP data is.

int HttpHeaders::buildHTTPResponseHeaderStruct HttpResponseHeader response,
HttpThreadContext td,
char *  input = 0
[static]
 

Build the HTTP RESPONSE HEADER string. If no input is specified the input is the main buffer of the HttpThreadContext structure. Return 0 on invalid input or internal errors.

Parameters:
response the HTTP response structure to fullfill.
td the current executing thread context.
input the buffer with the HTTP header data.

void HttpHeaders::resetHTTPRequest HttpRequestHeader request  )  [static]
 

Reset all the HTTP_REQUEST_HEADER structure members.

Parameters:
request the HTTP request header to free.

void HttpHeaders::resetHTTPResponse HttpResponseHeader response  )  [static]
 

Reset all the HttpResponseHeader structure members.

Parameters:
response the HTTP response header to free.

int HttpHeaders::validHTTPRequest char *  req,
HttpThreadContext td,
u_long *  nLinesptr,
u_long *  ncharsptr
[static]
 

Controls if the req string is a valid HTTP request header. Returns e_200 if is a valid request. Returns -1 if the request is incomplete. Any other returned value is the HTTP error.

Parameters:
req the buffer with the HTTP request.
td the current executing thread context.
nLinesptr is a value of the lines number in the HEADER.
ncharsptr is a value of the characters number in the HEADER.

int HttpHeaders::validHTTPResponse char *  res,
HttpThreadContext td,
u_long *  nLinesptr,
u_long *  ncharsptr
[static]
 

Controls if the req string is a valid HTTP response header. Returns 0 if req is an invalid header, a non-zero value if is a valid header.

Parameters:
res the buffer with the HTTP header.
td the thread context for the current executing thread.
nLinesptr is a value of the lines number in the HEADER.
ncharsptr is a value of the characters number in the HEADER.


Generated on Wed Nov 8 13:12:49 2006 for MyServer by doxygen 1.3.6