OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 REMOTING_HOST_SIGNALING_CONNECTOR_H | 5 #ifndef REMOTING_HOST_SIGNALING_CONNECTOR_H |
6 #define REMOTING_HOST_SIGNALING_CONNECTOR_H | 6 #define REMOTING_HOST_SIGNALING_CONNECTOR_H |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/memory/weak_ptr.h" | 9 #include "base/memory/weak_ptr.h" |
10 #include "base/threading/non_thread_safe.h" | 10 #include "base/threading/non_thread_safe.h" |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 virtual void OnSignalStrategyStateChange( | 64 virtual void OnSignalStrategyStateChange( |
65 SignalStrategy::State state) OVERRIDE; | 65 SignalStrategy::State state) OVERRIDE; |
66 | 66 |
67 // NetworkChangeNotifier::IPAddressObserver interface. | 67 // NetworkChangeNotifier::IPAddressObserver interface. |
68 virtual void OnIPAddressChanged() OVERRIDE; | 68 virtual void OnIPAddressChanged() OVERRIDE; |
69 | 69 |
70 // NetworkChangeNotifier::OnlineStateObserver interface. | 70 // NetworkChangeNotifier::OnlineStateObserver interface. |
71 virtual void OnOnlineStateChanged(bool online) OVERRIDE; | 71 virtual void OnOnlineStateChanged(bool online) OVERRIDE; |
72 | 72 |
73 // GaiaOAuthClient::Delegate interface. | 73 // GaiaOAuthClient::Delegate interface. |
74 virtual void OnRefreshTokenResponse(const std::string& user_email, | 74 virtual void OnRefreshTokenResponse(const std::string& access_token, |
75 const std::string& access_token, | |
76 int expires_seconds) OVERRIDE; | 75 int expires_seconds) OVERRIDE; |
77 virtual void OnOAuthError() OVERRIDE; | 76 virtual void OnOAuthError() OVERRIDE; |
78 virtual void OnNetworkError(int response_code) OVERRIDE; | 77 virtual void OnNetworkError(int response_code) OVERRIDE; |
79 | 78 |
80 private: | 79 private: |
81 void ScheduleTryReconnect(); | 80 void ScheduleTryReconnect(); |
82 void ResetAndTryReconnect(); | 81 void ResetAndTryReconnect(); |
83 void TryReconnect(); | 82 void TryReconnect(); |
84 | 83 |
85 void RefreshOAuthToken(); | 84 void RefreshOAuthToken(); |
(...skipping 11 matching lines...) Expand all Loading... |
97 base::Time auth_token_expiry_time_; | 96 base::Time auth_token_expiry_time_; |
98 | 97 |
99 base::OneShotTimer<SignalingConnector> timer_; | 98 base::OneShotTimer<SignalingConnector> timer_; |
100 | 99 |
101 DISALLOW_COPY_AND_ASSIGN(SignalingConnector); | 100 DISALLOW_COPY_AND_ASSIGN(SignalingConnector); |
102 }; | 101 }; |
103 | 102 |
104 } // namespace remoting | 103 } // namespace remoting |
105 | 104 |
106 #endif // REMOTING_HOST_SIGNALING_CONNECTOR_H | 105 #endif // REMOTING_HOST_SIGNALING_CONNECTOR_H |
OLD | NEW |