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

Side by Side Diff: chromeos/login/auth/online_attempt.h

Issue 856563004: Update {virtual,override,final} to follow C++11 style in chromeos. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « chromeos/login/auth/mock_url_fetchers.h ('k') | chromeos/login/auth/online_attempt_host.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 4
5 #ifndef CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_ 5 #ifndef CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_
6 #define CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_ 6 #define CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 13 matching lines...) Expand all
24 } 24 }
25 25
26 namespace chromeos { 26 namespace chromeos {
27 class AuthAttemptState; 27 class AuthAttemptState;
28 class AuthAttemptStateResolver; 28 class AuthAttemptStateResolver;
29 29
30 class CHROMEOS_EXPORT OnlineAttempt : public GaiaAuthConsumer { 30 class CHROMEOS_EXPORT OnlineAttempt : public GaiaAuthConsumer {
31 public: 31 public:
32 OnlineAttempt(AuthAttemptState* current_attempt, 32 OnlineAttempt(AuthAttemptState* current_attempt,
33 AuthAttemptStateResolver* callback); 33 AuthAttemptStateResolver* callback);
34 virtual ~OnlineAttempt(); 34 ~OnlineAttempt() override;
35 35
36 // Initiate the online login attempt either through client or auth login. 36 // Initiate the online login attempt either through client or auth login.
37 // Status will be recorded in |current_attempt|, and resolver_->Resolve() will 37 // Status will be recorded in |current_attempt|, and resolver_->Resolve() will
38 // be called on the IO thread when useful state is available. 38 // be called on the IO thread when useful state is available.
39 // Must be called on the UI thread. 39 // Must be called on the UI thread.
40 void Initiate(net::URLRequestContextGetter* request_context); 40 void Initiate(net::URLRequestContextGetter* request_context);
41 41
42 // GaiaAuthConsumer overrides. Callbacks from GaiaAuthFetcher 42 // GaiaAuthConsumer overrides. Callbacks from GaiaAuthFetcher
43 virtual void OnClientLoginFailure( 43 void OnClientLoginFailure(const GoogleServiceAuthError& error) override;
44 const GoogleServiceAuthError& error) override; 44 void OnClientLoginSuccess(
45 virtual void OnClientLoginSuccess(
46 const GaiaAuthConsumer::ClientLoginResult& credentials) override; 45 const GaiaAuthConsumer::ClientLoginResult& credentials) override;
47 46
48 private: 47 private:
49 FRIEND_TEST_ALL_PREFIXES(OnlineAttemptTest, LoginSuccess); 48 FRIEND_TEST_ALL_PREFIXES(OnlineAttemptTest, LoginSuccess);
50 FRIEND_TEST_ALL_PREFIXES(OnlineAttemptTest, TwoFactorSuccess); 49 FRIEND_TEST_ALL_PREFIXES(OnlineAttemptTest, TwoFactorSuccess);
51 50
52 // Milliseconds until we timeout our attempt to hit ClientLogin. 51 // Milliseconds until we timeout our attempt to hit ClientLogin.
53 static const int kClientLoginTimeoutMs; 52 static const int kClientLoginTimeoutMs;
54 53
55 void TryClientLogin(); 54 void TryClientLogin();
(...skipping 18 matching lines...) Expand all
74 // Used to cancel the CancelClientLogin closure. 73 // Used to cancel the CancelClientLogin closure.
75 base::WeakPtrFactory<OnlineAttempt> weak_factory_; 74 base::WeakPtrFactory<OnlineAttempt> weak_factory_;
76 75
77 friend class OnlineAttemptTest; 76 friend class OnlineAttemptTest;
78 DISALLOW_COPY_AND_ASSIGN(OnlineAttempt); 77 DISALLOW_COPY_AND_ASSIGN(OnlineAttempt);
79 }; 78 };
80 79
81 } // namespace chromeos 80 } // namespace chromeos
82 81
83 #endif // CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_ 82 #endif // CHROMEOS_LOGIN_AUTH_ONLINE_ATTEMPT_H_
OLDNEW
« no previous file with comments | « chromeos/login/auth/mock_url_fetchers.h ('k') | chromeos/login/auth/online_attempt_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698