#include <webserver.hh>
Public Types | |
|
typedef std::pair< std::string, std::string > | header_entry |
| Header entry (name/token). | |
| typedef std::vector< header_entry > | header_type |
| header type (name/token list) | |
Public Member Functions | |
| response_t () | |
| Constructor. | |
| ~response_t () | |
| Destructor. | |
| bool | write (int fd) |
| Write a response to fd. | |
| void | SetStatusLine (const char *p) |
| Set status line. | |
| const char * | GetStatusLine () const |
| Get status line. | |
| void | AddHeader (const std::string &name, const std::string &token) |
| Add header entry. | |
| void | RemoveHeader (const std::string &name) |
| Remove header entry. | |
| header_type & | GetHeader () |
| Get Header. | |
| const header_type & | GetHeader () const |
| Get Header. | |
| const char * | GetData () const |
| Get data. | |
| char * | GetData () |
| Get data. | |
| void | SetData (const char *p, int len) |
| Set data. | |
| void | SetData (const std::string &s) |
| Set Data. | |
| void | Reserve (int len) |
| Reserve data array. | |
| int | GetLength () const |
| Get length. | |
| void | SetCanCompress (bool set=true) |
| Try to compress response data. | |
| bool | GetCanCompress () const |
| Get try compress value. | |
| bool | TryCompress () |
| Try to compress response data. | |
1.5.4