HTTP header to set a specific request status. More...
#include <cgicc/HTTPStatusHeader.h>
Public Member Functions | |
| HTTPStatusHeader (int status, const std::string &message) | |
| Create a new status header. More... | |
| virtual | ~HTTPStatusHeader () |
| Destructor. | |
| int | getStatusCode () const |
| Get the status code associated with this header. More... | |
| virtual void | render (std::ostream &out) const |
| Write this HTTPStatusHeader to a stream. More... | |
Public Member Functions inherited from cgicc::HTTPHeader | |
| HTTPHeader (const std::string &data) | |
| Constructor. More... | |
| HTTPHeader (const HTTPHeader &header) | |
| Copy constructor. More... | |
| virtual | ~HTTPHeader () |
| Destructor. More... | |
| HTTPHeader & | setCookie (const HTTPCookie &cookie) |
| Set a cookie to go out with this HTTPResponseHeader. More... | |
| const std::vector< HTTPCookie > & | getCookies () const |
| Get a list of all cookies associated with this header. More... | |
| std::string | getData () const |
Public Member Functions inherited from cgicc::MStreamable | |
| MStreamable () | |
| Empty constructor. More... | |
| virtual | ~MStreamable () |
| Empty destructor. More... | |
HTTP header to set a specific request status.
Definition at line 50 of file HTTPStatusHeader.h.
| cgicc::HTTPStatusHeader::HTTPStatusHeader | ( | int | status, |
| const std::string & | message | ||
| ) |
Create a new status header.
| status | The 3-digit status code, for example 404. |
| message | The message associated with the status code, for example "not found". |
|
inline |
Get the status code associated with this header.
Definition at line 71 of file HTTPStatusHeader.h.
|
virtual |
Write this HTTPStatusHeader to a stream.
| out | The ostream to which to write. |
Implements cgicc::HTTPHeader.