access tokenが取得できるように

This commit is contained in:
keita
2022-04-23 04:55:43 +09:00
parent d43e04506b
commit 560fe707a6
75 changed files with 591 additions and 193 deletions
+4 -3
View File
@@ -2,17 +2,18 @@
#define COCOATWEET_API_INTERFACE_HTTPBASE_H_
#include <functional>
#include "cocoatweet/oauth/oauth.h"
#include <memory>
#include "cocoatweet/authentication/authenticator.h"
namespace CocoaTweet::API::Interface {
class HttpBase {
public:
protected:
std::weak_ptr<CocoaTweet::OAuth::OAuth1> oauth_;
std::weak_ptr<CocoaTweet::Authentication::AuthenticatorBase> oauth_;
std::map<std::string, std::string> bodyParam_;
std::string url_;
std::string contentType_;
virtual void process(std::weak_ptr<CocoaTweet::OAuth::OAuth1> _oauth,
virtual void process(std::weak_ptr<CocoaTweet::Authentication::AuthenticatorBase> _oauth,
std::function<void(const std::string&)> _callback) = 0;
static size_t curlCallback_(char* _ptr, size_t _size, size_t _nmemb, std::string* _stream) {
int realsize = _size * _nmemb;