Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(310)

Unified Diff: remoting/host/oauth_token_getter.h

Issue 294813002: Add auto-refresh support to OAuthTokenGetter (disabled for now). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review comments. Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | remoting/host/oauth_token_getter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/oauth_token_getter.h
diff --git a/remoting/host/oauth_token_getter.h b/remoting/host/oauth_token_getter.h
index 4b48a4e68c35cc342875eb63f79dee907cd36020..a47a3f8267ffccf0be37c6671071ca8e7bcef1e6 100644
--- a/remoting/host/oauth_token_getter.h
+++ b/remoting/host/oauth_token_getter.h
@@ -10,6 +10,8 @@
#include "base/basictypes.h"
#include "base/callback.h"
#include "base/threading/non_thread_safe.h"
+#include "base/time/time.h"
+#include "base/timer/timer.h"
#include "google_apis/gaia/gaia_oauth_client.h"
namespace net {
@@ -56,7 +58,8 @@ class OAuthTokenGetter :
OAuthTokenGetter(
scoped_ptr<OAuthCredentials> oauth_credentials,
- scoped_refptr<net::URLRequestContextGetter> url_request_context_getter);
+ scoped_refptr<net::URLRequestContextGetter> url_request_context_getter,
+ bool auto_refresh);
virtual ~OAuthTokenGetter();
// Call |on_access_token| with an access token, or the failure status.
@@ -84,8 +87,10 @@ class OAuthTokenGetter :
bool refreshing_oauth_token_;
std::string oauth_access_token_;
+ std::string verified_email_;
base::Time auth_token_expiry_time_;
std::queue<OAuthTokenGetter::TokenCallback> pending_callbacks_;
+ scoped_ptr<base::OneShotTimer<OAuthTokenGetter> > refresh_timer_;
DISALLOW_COPY_AND_ASSIGN(OAuthTokenGetter);
};
« no previous file with comments | « no previous file | remoting/host/oauth_token_getter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698