Wizard
Software Engineering Project - Wizard
Loading...
Searching...
No Matches
request_response.h
1//
2// Created by Manuel on 15.02.2021.
3//
4
5#ifndef WIZARD_REQUEST_RESPONSE_H
6#define WIZARD_REQUEST_RESPONSE_H
7
8#include <string>
9#include "server_response.h"
10
11
13private:
14 bool _success;
15 std::string _err;
16 std::string _req_id;
17 rapidjson::Value* _state_json = nullptr;
18
19 request_response(base_class_properties props, std::string req_id, bool success, rapidjson::Value* state_json, std::string& err);
20
21public:
22
23 request_response(std::string game_id, std::string req_id, bool success, rapidjson::Value* state_json, std::string err);
25
26 virtual void write_into_json(rapidjson::Value& json, rapidjson::Document::AllocatorType& allocator) const override;
27 static request_response* from_json(const rapidjson::Value& json);
28
29#ifdef WIZARD_CLIENT
30 virtual void Process() const override;
31#endif
32};
33
34
35#endif //WIZARD_REQUEST_RESPONSE_H
Definition request_response.h:12
Definition server_response.h:24
Definition server_response.h:36