Created
March 31, 2017 11:02
-
-
Save ebongzzang/591cc4881766317f55ed5636af81e412 to your computer and use it in GitHub Desktop.
Kakaotalk Chatbot using C++ REST SDK (casablanca)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#ifndef LISTENER_H | |
#define LISTENER_H | |
#include <cpprest/http_listener.h> | |
#include <cpprest/json.h> | |
using namespace web::http::experimental::listener; | |
using namespace web::http; | |
using namespace web; | |
using namespace utility; | |
class Listener | |
{ | |
public: | |
Listener(utility::string_t url); | |
~Listener(); | |
virtual pplx::task<void>open(){return m_listener.open();} | |
virtual pplx::task<void>close(){return m_listener.close();} | |
protected: | |
virtual void handle_get(http_request request); | |
virtual void handle_put(http_request request); | |
virtual void handle_post(http_request request); | |
virtual void handle_delete(http_request request); | |
private: | |
http_listener m_listener; | |
}; | |
#endif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment