| 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 NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ | 5 #ifndef NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ |
| 6 #define NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ | 6 #define NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ |
| 7 | 7 |
| 8 #include "base/android/jni_android.h" | 8 #include "base/android/jni_android.h" |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 56 | 56 |
| 57 private: | 57 private: |
| 58 friend class NetworkChangeNotifierAndroidTest; | 58 friend class NetworkChangeNotifierAndroidTest; |
| 59 friend class NetworkChangeNotifierFactoryAndroid; | 59 friend class NetworkChangeNotifierFactoryAndroid; |
| 60 | 60 |
| 61 explicit NetworkChangeNotifierAndroid( | 61 explicit NetworkChangeNotifierAndroid( |
| 62 NetworkChangeNotifierDelegateAndroid* delegate); | 62 NetworkChangeNotifierDelegateAndroid* delegate); |
| 63 | 63 |
| 64 void SetConnectionType(ConnectionType new_connection_type); | 64 void SetConnectionType(ConnectionType new_connection_type); |
| 65 | 65 |
| 66 static NetworkChangeCalculatorParams NetworkChangeCalculatorParamsAndroid(); |
| 67 |
| 66 NetworkChangeNotifierDelegateAndroid* const delegate_; | 68 NetworkChangeNotifierDelegateAndroid* const delegate_; |
| 67 mutable base::Lock connection_type_lock_; // Protects the state below. | 69 mutable base::Lock connection_type_lock_; // Protects the state below. |
| 68 ConnectionType connection_type_; | 70 ConnectionType connection_type_; |
| 69 | 71 |
| 70 DISALLOW_COPY_AND_ASSIGN(NetworkChangeNotifierAndroid); | 72 DISALLOW_COPY_AND_ASSIGN(NetworkChangeNotifierAndroid); |
| 71 }; | 73 }; |
| 72 | 74 |
| 73 } // namespace net | 75 } // namespace net |
| 74 | 76 |
| 75 #endif // NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ | 77 #endif // NET_ANDROID_NETWORK_CHANGE_NOTIFIER_ANDROID_H_ |
| OLD | NEW |