summaryrefslogtreecommitdiff
path: root/service
diff options
context:
space:
mode:
authorAhmed ElArabawy <arabawy@google.com>2019-11-01 17:55:34 -0700
committerAhmed ElArabawy <arabawy@google.com>2019-11-01 18:51:09 -0700
commitb7956e20175a9c508de95756a2f0c0e39e202531 (patch)
tree6d7d6e52333af9a30a7797bcee50ba43bb1cb706 /service
parentf19e1891bc23d7a9522b15bac73ec657abfe56e9 (diff)
Change "Technology" to "Standard" in API
This commit is to change the naming from Wifi Technology to Wifi Standard. This is to comply with the API council review. Bug: 143551314 Test: atest com.android.wifi.server Change-Id: I19d3faa0c7243c63a56d378ba5c202486b055745
Diffstat (limited to 'service')
-rw-r--r--service/java/com/android/server/wifi/ClientModeImpl.java4
-rw-r--r--service/java/com/android/server/wifi/SupplicantStaIfaceHal.java29
-rw-r--r--service/java/com/android/server/wifi/WifiNative.java8
3 files changed, 21 insertions, 20 deletions
diff --git a/service/java/com/android/server/wifi/ClientModeImpl.java b/service/java/com/android/server/wifi/ClientModeImpl.java
index 91ff33005..8956f091b 100644
--- a/service/java/com/android/server/wifi/ClientModeImpl.java
+++ b/service/java/com/android/server/wifi/ClientModeImpl.java
@@ -2470,14 +2470,14 @@ public class ClientModeImpl extends StateMachine {
mWifiInfo.setBSSID(stateChangeResult.BSSID);
mWifiInfo.setSSID(stateChangeResult.wifiSsid);
if (state == SupplicantState.ASSOCIATED) {
- mWifiInfo.setWifiTechnology(mWifiNative.getWifiTechnology(mInterfaceName));
+ mWifiInfo.setWifiStandard(mWifiNative.getWifiStandard(mInterfaceName));
}
} else {
// Reset parameters according to WifiInfo.reset()
mWifiInfo.setNetworkId(WifiConfiguration.INVALID_NETWORK_ID);
mWifiInfo.setBSSID(null);
mWifiInfo.setSSID(null);
- mWifiInfo.setWifiTechnology(WifiInfo.WIFI_TECHNOLOGY_UNKNOWN);
+ mWifiInfo.setWifiStandard(WifiInfo.WIFI_STANDARD_UNKNOWN);
}
updateL2KeyAndGroupHint();
// SSID might have been updated, so call updateCapabilities
diff --git a/service/java/com/android/server/wifi/SupplicantStaIfaceHal.java b/service/java/com/android/server/wifi/SupplicantStaIfaceHal.java
index 0a01852ff..187bb8392 100644
--- a/service/java/com/android/server/wifi/SupplicantStaIfaceHal.java
+++ b/service/java/com/android/server/wifi/SupplicantStaIfaceHal.java
@@ -2696,35 +2696,35 @@ public class SupplicantStaIfaceHal {
return keyMgmtMask.value;
}
- private @WifiInfo.WifiTechnology int getWifiTechFromCap(ConnectionCapabilities capa) {
+ private @WifiInfo.WifiStandard int getWifiStandardFromCap(ConnectionCapabilities capa) {
switch(capa.technology) {
case WifiTechnology.HE:
- return WifiInfo.WIFI_TECHNOLOGY_11AX;
+ return WifiInfo.WIFI_STANDARD_11AX;
case WifiTechnology.VHT:
- return WifiInfo.WIFI_TECHNOLOGY_11AC;
+ return WifiInfo.WIFI_STANDARD_11AC;
case WifiTechnology.HT:
- return WifiInfo.WIFI_TECHNOLOGY_11N;
+ return WifiInfo.WIFI_STANDARD_11N;
case WifiTechnology.LEGACY:
- return WifiInfo.WIFI_TECHNOLOGY_LEGACY;
+ return WifiInfo.WIFI_STANDARD_LEGACY;
default:
- return WifiInfo.WIFI_TECHNOLOGY_UNKNOWN;
+ return WifiInfo.WIFI_STANDARD_UNKNOWN;
}
}
/**
- * Returns wifi technology for connected network
+ * Returns wifi standard for connected network
*
* This is a v1.3+ HAL feature.
* On error, or if these features are not supported, 0 is returned.
*/
- public @WifiInfo.WifiTechnology int getWifiTechnology(@NonNull String ifaceName) {
- final String methodStr = "getWifiTechnology";
- MutableInt wifiTechnology = new MutableInt(WifiInfo.WIFI_TECHNOLOGY_UNKNOWN);
+ public @WifiInfo.WifiStandard int getWifiStandard(@NonNull String ifaceName) {
+ final String methodStr = "getWifiStandard";
+ MutableInt wifiStandard = new MutableInt(WifiInfo.WIFI_STANDARD_UNKNOWN);
if (isV1_3()) {
ISupplicantStaIface iface = checkSupplicantStaIfaceAndLogFailure(ifaceName, methodStr);
if (iface == null) {
- return WifiInfo.WIFI_TECHNOLOGY_UNKNOWN;
+ return WifiInfo.WIFI_STANDARD_UNKNOWN;
}
// Get a v1.3 supplicant STA Interface
@@ -2734,7 +2734,7 @@ public class SupplicantStaIfaceHal {
if (staIfaceV13 == null) {
Log.e(TAG, methodStr
+ ": SupplicantStaIface is null, cannot get Connection Capabilities");
- return WifiInfo.WIFI_TECHNOLOGY_UNKNOWN;
+ return WifiInfo.WIFI_STANDARD_UNKNOWN;
}
try {
@@ -2742,7 +2742,8 @@ public class SupplicantStaIfaceHal {
(SupplicantStatus statusInternal,
ConnectionCapabilities connCapabilitiesInternal) -> {
if (statusInternal.code == SupplicantStatusCode.SUCCESS) {
- wifiTechnology.value = getWifiTechFromCap(connCapabilitiesInternal);
+ wifiStandard.value =
+ getWifiStandardFromCap(connCapabilitiesInternal);
}
checkStatusAndLogFailure(statusInternal, methodStr);
});
@@ -2753,7 +2754,7 @@ public class SupplicantStaIfaceHal {
Log.e(TAG, "Method " + methodStr + " is not supported in existing HAL");
}
- return wifiTechnology.value;
+ return wifiStandard.value;
}
/**
diff --git a/service/java/com/android/server/wifi/WifiNative.java b/service/java/com/android/server/wifi/WifiNative.java
index b9e766811..b95f11872 100644
--- a/service/java/com/android/server/wifi/WifiNative.java
+++ b/service/java/com/android/server/wifi/WifiNative.java
@@ -2730,13 +2730,13 @@ public class WifiNative {
}
/**
- * Get the connection Wifi technology
+ * Get the connection Wifi standard
*
* @param ifaceName Name of the interface.
- * @return Wifi technology for connection on this interface
+ * @return Wifi standard for connection on this interface
*/
- public @WifiInfo.WifiTechnology int getWifiTechnology(@NonNull String ifaceName) {
- return mSupplicantStaIfaceHal.getWifiTechnology(ifaceName);
+ public @WifiInfo.WifiStandard int getWifiStandard(@NonNull String ifaceName) {
+ return mSupplicantStaIfaceHal.getWifiStandard(ifaceName);
}
/**