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

Side by Side Diff: components/signin/core/browser/account_reconcilor.h

Issue 344513005: Revert "Improve the no-op reconcilor so that it doesn't "hang" after the first execution, but inste… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_ 4 #ifndef COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_
5 #define COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_ 5 #define COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_
6 6
7 #include <deque> 7 #include <deque>
8 #include <functional> 8 #include <functional>
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, GetAccountsFromCookieFailure); 114 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, GetAccountsFromCookieFailure);
115 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, ValidateAccountsFromTokens); 115 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, ValidateAccountsFromTokens);
116 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, 116 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest,
117 ValidateAccountsFromTokensFailedUserInfo); 117 ValidateAccountsFromTokensFailedUserInfo);
118 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, 118 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest,
119 ValidateAccountsFromTokensFailedTokenRequest); 119 ValidateAccountsFromTokensFailedTokenRequest);
120 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoop); 120 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoop);
121 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoopWithDots); 121 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoopWithDots);
122 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoopMultiple); 122 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileNoopMultiple);
123 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileAddToCookie); 123 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileAddToCookie);
124 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest,
125 StartReconcileAddToCookieTwice);
126 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileAddToChrome); 124 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileAddToChrome);
127 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileBadPrimary); 125 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileBadPrimary);
128 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileOnlyOnce); 126 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, StartReconcileOnlyOnce);
129 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest, 127 FRIEND_TEST_ALL_PREFIXES(AccountReconcilorTest,
130 StartReconcileWithSessionInfoExpiredDefault); 128 StartReconcileWithSessionInfoExpiredDefault);
131 129
132 // Register and unregister with dependent services. 130 // Register and unregister with dependent services.
133 void RegisterForCookieChanges(); 131 void RegisterForCookieChanges();
134 void UnregisterForCookieChanges(); 132 void UnregisterForCookieChanges();
135 void RegisterWithSigninManager(); 133 void RegisterWithSigninManager();
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 void HandleSuccessfulAccountIdCheck(const std::string& account_id); 165 void HandleSuccessfulAccountIdCheck(const std::string& account_id);
168 void HandleFailedAccountIdCheck(const std::string& account_id); 166 void HandleFailedAccountIdCheck(const std::string& account_id);
169 void HandleRefreshTokenFetched(const std::string& account_id, 167 void HandleRefreshTokenFetched(const std::string& account_id,
170 const std::string& refresh_token); 168 const std::string& refresh_token);
171 169
172 void GetAccountsFromCookie(GetAccountsFromCookieCallback callback); 170 void GetAccountsFromCookie(GetAccountsFromCookieCallback callback);
173 void ContinueReconcileActionAfterGetGaiaAccounts( 171 void ContinueReconcileActionAfterGetGaiaAccounts(
174 const GoogleServiceAuthError& error, 172 const GoogleServiceAuthError& error,
175 const std::vector<std::pair<std::string, bool> >& accounts); 173 const std::vector<std::pair<std::string, bool> >& accounts);
176 void ValidateAccountsFromTokenService(); 174 void ValidateAccountsFromTokenService();
177 // Note internally that this |account_id| is added to the cookie jar.
178 void MarkAccountAsAddedToCookie(const std::string& account_id);
179 // Note internally that this |account_id| is added to the token service.
180 void MarkAccountAsAddedToChrome(const std::string& account_id);
181 175
182 void OnCookieChanged(const net::CanonicalCookie* cookie); 176 void OnCookieChanged(const net::CanonicalCookie* cookie);
183 177
184 // Overriden from GaiaAuthConsumer. 178 // Overriden from GaiaAuthConsumer.
185 virtual void OnListAccountsSuccess(const std::string& data) OVERRIDE; 179 virtual void OnListAccountsSuccess(const std::string& data) OVERRIDE;
186 virtual void OnListAccountsFailure(const GoogleServiceAuthError& error) 180 virtual void OnListAccountsFailure(const GoogleServiceAuthError& error)
187 OVERRIDE; 181 OVERRIDE;
188 182
189 // Overriden from MergeSessionHelper::Observer. 183 // Overriden from MergeSessionHelper::Observer.
190 virtual void MergeSessionCompleted(const std::string& account_id, 184 virtual void MergeSessionCompleted(const std::string& account_id,
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 EmailSet invalid_chrome_accounts_; 244 EmailSet invalid_chrome_accounts_;
251 std::vector<std::string> add_to_cookie_; 245 std::vector<std::string> add_to_cookie_;
252 std::vector<std::pair<std::string, int> > add_to_chrome_; 246 std::vector<std::pair<std::string, int> > add_to_chrome_;
253 247
254 std::deque<GetAccountsFromCookieCallback> get_gaia_accounts_callbacks_; 248 std::deque<GetAccountsFromCookieCallback> get_gaia_accounts_callbacks_;
255 249
256 DISALLOW_COPY_AND_ASSIGN(AccountReconcilor); 250 DISALLOW_COPY_AND_ASSIGN(AccountReconcilor);
257 }; 251 };
258 252
259 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_ 253 #endif // COMPONENTS_SIGNIN_CORE_BROWSER_ACCOUNT_RECONCILOR_H_
OLDNEW
« no previous file with comments | « chrome/test/base/uma_histogram_helper.cc ('k') | components/signin/core/browser/account_reconcilor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698