blob: 1672d719d446492d058dc64efc2262c01ae18f7c (
plain) (
blame)
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
#ifndef REQUEST_H_9D3C30E2
#define REQUEST_H_9D3C30E2
#include <string>
#include <sstream>
#include <curl_easy.h>
#include <curl_header.h>
#include "auth.h"
namespace twitter {
class request
{
public:
explicit request(std::string url);
std::string perform();
private:
std::ostringstream output_;
curl::curl_ios<std::ostringstream> ios_;
protected:
curl::curl_easy conn_;
};
class get : public request
{
public:
get(
const auth& tauth,
std::string url);
private:
curl::curl_header headers_;
};
class post : public request
{
public:
post(
const auth& tauth,
std::string url,
std::string datastr);
private:
curl::curl_header headers_;
};
class multipost : public request
{
public:
multipost(
const auth& tauth,
std::string url,
const curl_httppost* fields);
private:
curl::curl_header headers_;
};
}
#endif /* end of include guard: REQUEST_H_9D3C30E2 */
|