7 #ifndef HTTP_POST_REQUEST_JSON_H 8 #define HTTP_POST_REQUEST_JSON_H 13 #include <boost/shared_ptr.hpp> Represents HTTP POST request with JSON body.
data::ConstElementPtr getJsonElement(const std::string &element_name) const
Retrieves a single JSON element.
Generic exception thrown by HttpRequest class.
virtual void finalize()
Complete parsing of the HTTP request.
Represents HTTP POST request.
virtual const char * what() const
Returns a C-style character string of the cause of the exception.
data::ConstElementPtr getBodyAsJson() const
Retrieves JSON body.
Exception thrown when body of the HTTP message is not JSON.
boost::shared_ptr< PostHttpRequestJson > PostHttpRequestJsonPtr
Pointer to PostHttpRequestJson.
virtual void reset()
Reset the state of the object.
PostHttpRequestJson()
Constructor for inbound HTTP request.
HttpRequestJsonError(const char *file, size_t line, const char *what)
boost::shared_ptr< const Element > ConstElementPtr
Defines the logger used by the top-level component of kea-dhcp-ddns.
void setBodyAsJson(const data::ConstElementPtr &body)
Sets JSON body for an outbound message.
data::ConstElementPtr json_
Pointer to the parsed JSON body.
boost::shared_ptr< const PostHttpRequestJson > ConstPostHttpRequestJsonPtr
Pointer to const PostHttpRequestJson.
int version()
returns Kea hooks version.
void parseBodyAsJson()
Interprets body as JSON, which can be later retrieved using data element objects.