2018-05-21 10:54:00 +00:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <drogon/HttpSimpleController.h>
|
|
|
|
using namespace drogon;
|
|
|
|
|
2018-10-14 07:56:54 +00:00
|
|
|
class JsonTestController : public drogon::HttpSimpleController<JsonTestController>
|
2018-05-21 10:54:00 +00:00
|
|
|
{
|
2018-10-14 07:56:54 +00:00
|
|
|
public:
|
2018-05-21 10:54:00 +00:00
|
|
|
//TestController(){}
|
2018-10-14 07:56:54 +00:00
|
|
|
virtual void asyncHandleHttpRequest(const HttpRequestPtr &req, const std::function<void(const HttpResponsePtr &)> &callback) override;
|
2018-05-21 10:54:00 +00:00
|
|
|
|
|
|
|
PATH_LIST_BEGIN
|
2019-01-16 02:03:11 +00:00
|
|
|
PATH_ADD("/json", Get, "drogon::LocalHostFilter");
|
2018-05-21 10:54:00 +00:00
|
|
|
PATH_LIST_END
|
2018-11-16 05:26:14 +00:00
|
|
|
};
|