-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathJsonResponse.h
More file actions
42 lines (34 loc) · 803 Bytes
/
JsonResponse.h
File metadata and controls
42 lines (34 loc) · 803 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#ifndef _MONGOOSE_JSON_RESPONSE_H
#define _MONGOOSE_JSON_RESPONSE_H
#include <map>
#include <sstream>
#include <iostream>
#include "json/json.h"
#include "Response.h"
using namespace std;
/**
* A stream response to a request
*/
namespace Mongoose
{
class JsonResponse : public Json::Value, public Response
{
public:
JsonResponse();
/**
* Gets the response body
*
* @return string the response body
*/
virtual string getBody();
/**
* Sets the human readability of the response
*
* @param bool true for human readable
*/
void setHuman(bool human);
protected:
bool humanReadable;
};
}
#endif