Refactor RestService interfaces.

This commit is contained in:
Adam Gu
2018-08-24 16:51:08 +08:00
parent e9096d4e53
commit a863b379d0
10 changed files with 227 additions and 265 deletions
+3 -6
View File
@@ -3,12 +3,9 @@
class TestRestService : public webcc::RestService {
public:
bool Handle(const std::string& http_method,
const std::vector<std::string>& url_sub_matches,
const webcc::UrlQuery& query,
const std::string& request_content,
std::string* response_content) override {
return true;
void Handle(const webcc::RestRequest& request,
webcc::RestResponse* response) final {
response->status = webcc::HttpStatus::kOK;
}
};