28 #ifndef HTTP_PARSER_REQUEST_HPP 29 #define HTTP_PARSER_REQUEST_HPP 33 #include <websocketpp/common/memory.hpp> 34 #include <websocketpp/http/parser.hpp> 53 typedef lib::shared_ptr<type> ptr;
56 : m_buf(lib::make_shared<std::string>())
79 size_t consume(
char const * buf,
size_t len);
87 std::string
raw()
const;
110 void process(std::string::iterator begin, std::string::iterator end);
112 lib::shared_ptr<std::string> m_buf;
113 std::string m_method;
122 #include <websocketpp/http/impl/request.hpp> 124 #endif // HTTP_PARSER_REQUEST_HPP std::string raw() const
Returns the full raw request (including the body)
std::string raw_head() const
Returns the raw request headers only (similar to an HTTP HEAD request)
std::string const & get_uri() const
Return the requested URI.
Namespace for the WebSocket++ project.
void set_uri(std::string const &uri)
Set the HTTP uri. Must be a valid HTTP uri.
Stores, parses, and manipulates HTTP requests.
size_t consume(char const *buf, size_t len)
Process bytes in the input buffer.
void set_method(std::string const &method)
Set the HTTP method. Must be a valid HTTP token.
bool ready() const
Returns whether or not the request is ready for reading.
std::string const & get_method() const
Return the request method.