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

Side by Side Diff: webrtc/api/java/jni/androidnetworkmonitor_jni.h

Issue 2112963002: Add UNKNOWN_CELLULAR network type and allow unknown network type in NetworkMonitor (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: . Created 4 years, 5 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
OLDNEW
1 /* 1 /*
2 * Copyright 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2015 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 13 matching lines...) Expand all
24 typedef uint32_t NetworkHandle; 24 typedef uint32_t NetworkHandle;
25 25
26 // c++ equivalent of java NetworkMonitorAutoDetect.ConnectionType. 26 // c++ equivalent of java NetworkMonitorAutoDetect.ConnectionType.
27 enum NetworkType { 27 enum NetworkType {
28 NETWORK_UNKNOWN, 28 NETWORK_UNKNOWN,
29 NETWORK_ETHERNET, 29 NETWORK_ETHERNET,
30 NETWORK_WIFI, 30 NETWORK_WIFI,
31 NETWORK_4G, 31 NETWORK_4G,
32 NETWORK_3G, 32 NETWORK_3G,
33 NETWORK_2G, 33 NETWORK_2G,
34 NETWORK_UNKNOWN_CELLULAR,
34 NETWORK_BLUETOOTH, 35 NETWORK_BLUETOOTH,
35 NETWORK_NONE 36 NETWORK_NONE
36 }; 37 };
37 38
38 // The information is collected from Android OS so that the native code can get 39 // The information is collected from Android OS so that the native code can get
39 // the network type and handle (Android network ID) for each interface. 40 // the network type and handle (Android network ID) for each interface.
40 struct NetworkInformation { 41 struct NetworkInformation {
41 std::string interface_name; 42 std::string interface_name;
42 NetworkHandle handle; 43 NetworkHandle handle;
43 NetworkType type; 44 NetworkType type;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 class AndroidNetworkMonitorFactory : public rtc::NetworkMonitorFactory { 83 class AndroidNetworkMonitorFactory : public rtc::NetworkMonitorFactory {
83 public: 84 public:
84 AndroidNetworkMonitorFactory() {} 85 AndroidNetworkMonitorFactory() {}
85 86
86 rtc::NetworkMonitorInterface* CreateNetworkMonitor() override; 87 rtc::NetworkMonitorInterface* CreateNetworkMonitor() override;
87 }; 88 };
88 89
89 } // namespace webrtc_jni 90 } // namespace webrtc_jni
90 91
91 #endif // WEBRTC_API_JAVA_JNI_ANDROIDNETWORKMONITOR_JNI_H_ 92 #endif // WEBRTC_API_JAVA_JNI_ANDROIDNETWORKMONITOR_JNI_H_
OLDNEW
« no previous file with comments | « webrtc/api/java/android/org/webrtc/NetworkMonitorAutoDetect.java ('k') | webrtc/api/java/jni/androidnetworkmonitor_jni.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698