diff options
Diffstat (limited to 'src/client.h')
-rw-r--r-- | src/client.h | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/client.h b/src/client.h index 9282321..1e1b1ab 100644 --- a/src/client.h +++ b/src/client.h | |||
@@ -18,23 +18,23 @@ namespace OAuth { | |||
18 | }; | 18 | }; |
19 | 19 | ||
20 | namespace twitter { | 20 | namespace twitter { |
21 | 21 | ||
22 | class client { | 22 | class client { |
23 | public: | 23 | public: |
24 | 24 | ||
25 | client(const auth& _auth); | 25 | client(const auth& _auth); |
26 | ~client(); | 26 | ~client(); |
27 | 27 | ||
28 | tweet updateStatus(std::string msg, std::list<long> media_ids = {}) const; | 28 | tweet updateStatus(std::string msg, std::list<long> media_ids = {}) const; |
29 | long uploadMedia(std::string media_type, const char* data, long data_length) const; | 29 | long uploadMedia(std::string media_type, const char* data, long data_length) const; |
30 | 30 | ||
31 | tweet replyToTweet(std::string msg, tweet_id in_response_to, std::list<long> media_ids = {}) const; | 31 | tweet replyToTweet(std::string msg, tweet_id in_response_to, std::list<long> media_ids = {}) const; |
32 | tweet replyToTweet(std::string msg, const tweet& in_response_to, std::list<long> media_ids = {}) const; | 32 | tweet replyToTweet(std::string msg, const tweet& in_response_to, std::list<long> media_ids = {}) const; |
33 | 33 | ||
34 | std::set<user_id> getFriends(user_id id) const; | 34 | std::set<user_id> getFriends(user_id id) const; |
35 | std::set<user_id> getFriends(const user& u) const; | 35 | std::set<user_id> getFriends(const user& u) const; |
36 | std::set<user_id> getFriends() const; | 36 | std::set<user_id> getFriends() const; |
37 | 37 | ||
38 | std::set<user_id> getFollowers(user_id id) const; | 38 | std::set<user_id> getFollowers(user_id id) const; |
39 | std::set<user_id> getFollowers(const user& u) const; | 39 | std::set<user_id> getFollowers(const user& u) const; |
40 | std::set<user_id> getFollowers() const; | 40 | std::set<user_id> getFollowers() const; |
@@ -43,28 +43,28 @@ namespace twitter { | |||
43 | 43 | ||
44 | void follow(user_id toFollow) const; | 44 | void follow(user_id toFollow) const; |
45 | void follow(const user& toFollow) const; | 45 | void follow(const user& toFollow) const; |
46 | 46 | ||
47 | void unfollow(user_id toUnfollow) const; | 47 | void unfollow(user_id toUnfollow) const; |
48 | void unfollow(const user& toUnfollow) const; | 48 | void unfollow(const user& toUnfollow) const; |
49 | 49 | ||
50 | const user& getUser() const; | 50 | const user& getUser() const; |
51 | 51 | ||
52 | const configuration& getConfiguration() const; | 52 | const configuration& getConfiguration() const; |
53 | 53 | ||
54 | private: | 54 | private: |
55 | 55 | ||
56 | friend class stream; | 56 | friend class stream; |
57 | 57 | ||
58 | std::unique_ptr<OAuth::Consumer> _oauth_consumer; | 58 | std::unique_ptr<OAuth::Consumer> _oauth_consumer; |
59 | std::unique_ptr<OAuth::Token> _oauth_token; | 59 | std::unique_ptr<OAuth::Token> _oauth_token; |
60 | std::unique_ptr<OAuth::Client> _oauth_client; | 60 | std::unique_ptr<OAuth::Client> _oauth_client; |
61 | 61 | ||
62 | std::unique_ptr<user> _current_user; | 62 | std::unique_ptr<user> _current_user; |
63 | 63 | ||
64 | mutable std::unique_ptr<configuration> _configuration; | 64 | mutable std::unique_ptr<configuration> _configuration; |
65 | mutable time_t _last_configuration_update; | 65 | mutable time_t _last_configuration_update; |
66 | }; | 66 | }; |
67 | 67 | ||
68 | }; | 68 | }; |
69 | 69 | ||
70 | #endif /* end of include guard: TWITTER_H_ABFF6A12 */ | 70 | #endif /* end of include guard: TWITTER_H_ABFF6A12 */ |