Go to the source code of this file.
Typedefs | |
| typedef struct _HTTP_STREAM | HTTP_STREAM |
| typedef void(* | HTTP_CLIENT_HANDLER )(HTTP_STREAM *) |
Functions | |
| int | StreamInit (void) |
| Initialize the stream. | |
| int | StreamClientAccept (HTTP_CLIENT_HANDLER handler, const char *params) |
| Accept stream clients. | |
| int | StreamReadUntilChars (HTTP_STREAM *sp, const char *delim, const char *ignore, char *buf, int siz) |
| Read data from a stream until any of the specified characters appears. | |
| int | StreamReadUntilString (HTTP_STREAM *sp, const char *delim, char *buf, int siz) |
| Read data from a stream until a specified string appears. | |
| int | s_write (const void *buf, size_t size, size_t count, HTTP_STREAM *sp) |
| Write data items to a stream. | |
| int | s_puts (const char *str, HTTP_STREAM *sp) |
| Write a string to a stream. | |
| int | s_vputs (HTTP_STREAM *sp,...) |
| Write a variable number of strings to a stream. | |
| int | s_printf (HTTP_STREAM *sp, const char *fmt,...) |
| Print formatted data to a stream. | |
| int | s_flush (HTTP_STREAM *sp) |
| Flush a stream. | |
| const char * | StreamInfo (HTTP_STREAM *hs, int item) |
Default environment variables | |
| #define | SITEM_REMOTE_ADDR 1 |
| The IP address of the host making this request. | |
| #define | SITEM_REMOTE_PORT 2 |
| The port number used by the remote host when making this request. | |
| #define | SITEM_SERVER_ADDR 3 |
| The IP address of the server for this URL. | |
| #define | SITEM_SERVER_NAME 4 |
| The servers host name, DNS alias or IP address. | |
| #define | SITEM_SERVER_PORT 5 |
| The port number on this server to which this request was directed. | |