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

Unified Diff: google_apis/gaia/oauth2_access_token_fetcher.h

Issue 22581003: Handling of multiple concurrent requests from different clients in OAuth2TokenService (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 | « chrome/browser/sync/test_profile_sync_service.cc ('k') | google_apis/gaia/oauth2_access_token_fetcher.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: google_apis/gaia/oauth2_access_token_fetcher.h
diff --git a/google_apis/gaia/oauth2_access_token_fetcher.h b/google_apis/gaia/oauth2_access_token_fetcher.h
index 11ac6ea8b5c702a9611802b444444fdf7c80cce4..0677c8860029b1ecb7fe8c9f5a9741744953d5b6 100644
--- a/google_apis/gaia/oauth2_access_token_fetcher.h
+++ b/google_apis/gaia/oauth2_access_token_fetcher.h
@@ -94,6 +94,9 @@ class OAuth2AccessTokenFetcher : public net::URLFetcherDelegate {
std::string* access_token,
int* expires_in);
+ // Resets |last_fetcher_id_| to 0.
+ static void ResetLastFetcherIdForTest();
fgorski 2013/08/29 23:37:44 To check in you will either need to make the metho
+
// State that is set during construction.
OAuth2AccessTokenConsumer* const consumer_;
net::URLRequestContextGetter* const getter_;
@@ -106,7 +109,11 @@ class OAuth2AccessTokenFetcher : public net::URLFetcherDelegate {
std::string refresh_token_;
std::vector<std::string> scopes_;
+ // The last fetcher id.
+ static int last_fetcher_id_;
+
friend class OAuth2AccessTokenFetcherTest;
+ friend class OAuth2TokenServiceTest;
FRIEND_TEST_ALL_PREFIXES(OAuth2AccessTokenFetcherTest,
ParseGetAccessTokenResponse);
FRIEND_TEST_ALL_PREFIXES(OAuth2AccessTokenFetcherTest,
« no previous file with comments | « chrome/browser/sync/test_profile_sync_service.cc ('k') | google_apis/gaia/oauth2_access_token_fetcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698