Home
last modified time | relevance | path

Searched refs:NetworkInfo (Results 1 – 9 of 9) sorted by relevance

/external/robolectric/src/main/java/com/xtremelabs/robolectric/shadows/
DShadowNetworkInfo.java4 import android.net.NetworkInfo;
15 @Implements(NetworkInfo.class)
21 private NetworkInfo.DetailedState detailedState;
23 public static NetworkInfo newInstance() { in newInstance()
27 public static NetworkInfo newInstance(NetworkInfo.DetailedState detailedState) { in newInstance()
31 …public static NetworkInfo newInstance(NetworkInfo.DetailedState detailedState, int type, int subTy… in newInstance()
34 NetworkInfo networkInfo = Robolectric.newInstanceOf(NetworkInfo.class); in newInstance()
55 public NetworkInfo.State getState() { in getState()
56 return isConnected ? NetworkInfo.State.CONNECTED : in getState()
57 NetworkInfo.State.DISCONNECTED; in getState()
[all …]
DShadowConnectivityManager.java4 import android.net.NetworkInfo;
19 private NetworkInfo activeNetwork;
22 … private Map<Integer, NetworkInfo> networkTypeToNetworkInfo = new HashMap<Integer, NetworkInfo>();
29 public NetworkInfo getActiveNetworkInfo() { in getActiveNetworkInfo()
34 public NetworkInfo[] getAllNetworkInfo() { in getAllNetworkInfo()
35 …return networkTypeToNetworkInfo.values().toArray(new NetworkInfo[networkTypeToNetworkInfo.size()]); in getAllNetworkInfo()
39 public NetworkInfo getNetworkInfo(int networkType) { in getNetworkInfo()
48 public void setNetworkInfo(int networkType, NetworkInfo networkInfo) { in setNetworkInfo()
56 public void setActiveNetworkInfo(NetworkInfo info) { in setActiveNetworkInfo()
/external/robolectric/src/test/java/com/xtremelabs/robolectric/shadows/
DNetworkInfoTest.java3 import android.net.NetworkInfo;
18 NetworkInfo networkInfo = Robolectric.newInstanceOf(NetworkInfo.class); in getDetailedState_shouldReturnTheAssignedState()
19 shadowOf(networkInfo).setDetailedState(NetworkInfo.DetailedState.SCANNING); in getDetailedState_shouldReturnTheAssignedState()
20 assertThat(networkInfo.getDetailedState(), equalTo(NetworkInfo.DetailedState.SCANNING)); in getDetailedState_shouldReturnTheAssignedState()
DConnectivityManagerTest.java5 import android.net.NetworkInfo;
48NetworkInfo networkInfo = ShadowNetworkInfo.newInstance(NetworkInfo.DetailedState.CONNECTING); in getNetworkInfoShouldReturnAssignedValue()
50 NetworkInfo actual = connectivityManager.getNetworkInfo(ConnectivityManager.TYPE_WIFI); in getNetworkInfoShouldReturnAssignedValue()
52 assertThat(actual.getDetailedState(), is(NetworkInfo.DetailedState.CONNECTING)); in getNetworkInfoShouldReturnAssignedValue()
87 NetworkInfo info = connectivityManager.getActiveNetworkInfo(); in shouldSetActiveNetworkInfo()
97 NetworkInfo[] infos = connectivityManager.getAllNetworkInfo(); in shouldGetAllNetworkInfo()
/external/chromium_org/ash/system/chromeos/network/
Dnetwork_state_list_detailed_view.h40 struct NetworkInfo;
102 bool UpdateNetworkChild(int index, const NetworkInfo* info);
136 ScopedVector<NetworkInfo> network_list_;
Dnetwork_state_list_detailed_view.cc102 struct NetworkInfo { struct
103 NetworkInfo(const std::string& path) in NetworkInfo() argument
502 NetworkInfo* info = new NetworkInfo(network->path()); in UpdateNetworks()
515 NetworkInfo* info = new NetworkInfo(favorite->path()); in UpdatePreferred()
526 NetworkInfo* info = network_list_[i]; in UpdateNetworkList()
610 const NetworkInfo* info) { in UpdateNetworkChild()
658 const NetworkInfo* info = network_list_[i]; in UpdateNetworkListEntries()
713 const NetworkInfo* info = network_list_[i]; in UpdateNetworkListEntries()
/external/chromium_org/content/public/android/java/src/org/chromium/content/browser/
DMediaResourceGetter.java11 import android.net.NetworkInfo;
77 NetworkInfo info = mConnectivityManager.getActiveNetworkInfo(); in extractMediaMetadata()
/external/chromium/chrome/browser/chromeos/status/
Dnetwork_menu.h32 struct NetworkInfo { struct
33 NetworkInfo() : in NetworkInfo() function
/external/robolectric/src/main/java/com/xtremelabs/robolectric/
DRobolectric.java37 import android.net.NetworkInfo;
755 public static ShadowNetworkInfo shadowOf(NetworkInfo instance) { in shadowOf()