Merge "Add new flag for Tethering w/ SoftApConfig" into main
This commit is contained in:
commit
9d8d167f0f
4 changed files with 24 additions and 15 deletions
|
|
@ -47,8 +47,8 @@ package android.net {
|
|||
}
|
||||
|
||||
public static final class TetheringManager.TetheringRequest implements android.os.Parcelable {
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") @Nullable public String getPackageName();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") public int getUid();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") @Nullable public String getPackageName();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") public int getUid();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -97,16 +97,16 @@ package android.net {
|
|||
}
|
||||
|
||||
public static final class TetheringManager.TetheringRequest implements android.os.Parcelable {
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") public int describeContents();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") public int describeContents();
|
||||
method @Nullable public android.net.LinkAddress getClientStaticIpv4Address();
|
||||
method public int getConnectivityScope();
|
||||
method @Nullable public android.net.LinkAddress getLocalIpv4Address();
|
||||
method public boolean getShouldShowEntitlementUi();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") @Nullable public android.net.wifi.SoftApConfiguration getSoftApConfiguration();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") @Nullable public android.net.wifi.SoftApConfiguration getSoftApConfiguration();
|
||||
method public int getTetheringType();
|
||||
method public boolean isExemptFromEntitlementCheck();
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") public void writeToParcel(@NonNull android.os.Parcel, int);
|
||||
field @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") @NonNull public static final android.os.Parcelable.Creator<android.net.TetheringManager.TetheringRequest> CREATOR;
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") public void writeToParcel(@NonNull android.os.Parcel, int);
|
||||
field @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") @NonNull public static final android.os.Parcelable.Creator<android.net.TetheringManager.TetheringRequest> CREATOR;
|
||||
}
|
||||
|
||||
public static class TetheringManager.TetheringRequest.Builder {
|
||||
|
|
@ -115,7 +115,7 @@ package android.net {
|
|||
method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setConnectivityScope(int);
|
||||
method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setExemptFromEntitlementCheck(boolean);
|
||||
method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setShouldShowEntitlementUi(boolean);
|
||||
method @FlaggedApi("com.android.net.flags.tethering_request_with_soft_ap_config") @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setSoftApConfiguration(@Nullable android.net.wifi.SoftApConfiguration);
|
||||
method @FlaggedApi("com.android.net.flags.tethering_with_soft_ap_config") @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setSoftApConfiguration(@Nullable android.net.wifi.SoftApConfiguration);
|
||||
method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setStaticIpv4Addresses(@NonNull android.net.LinkAddress, @NonNull android.net.LinkAddress);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -699,7 +699,7 @@ public class TetheringManager {
|
|||
/**
|
||||
* @hide
|
||||
*/
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
public TetheringRequest(@NonNull final TetheringRequestParcel request) {
|
||||
mRequestParcel = request;
|
||||
}
|
||||
|
|
@ -708,7 +708,7 @@ public class TetheringManager {
|
|||
mRequestParcel = in.readParcelable(TetheringRequestParcel.class.getClassLoader());
|
||||
}
|
||||
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@NonNull
|
||||
public static final Creator<TetheringRequest> CREATOR = new Creator<>() {
|
||||
@Override
|
||||
|
|
@ -722,13 +722,13 @@ public class TetheringManager {
|
|||
}
|
||||
};
|
||||
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@Override
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@Override
|
||||
public void writeToParcel(@NonNull Parcel dest, int flags) {
|
||||
dest.writeParcelable(mRequestParcel, flags);
|
||||
|
|
@ -820,7 +820,7 @@ public class TetheringManager {
|
|||
* @param softApConfig SoftApConfiguration to use.
|
||||
* @throws IllegalArgumentException if the tethering type isn't TETHERING_WIFI.
|
||||
*/
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED)
|
||||
@NonNull
|
||||
public Builder setSoftApConfiguration(@Nullable SoftApConfiguration softApConfig) {
|
||||
|
|
@ -915,7 +915,7 @@ public class TetheringManager {
|
|||
/**
|
||||
* Get the desired SoftApConfiguration of the request, if one was specified.
|
||||
*/
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@Nullable
|
||||
public SoftApConfiguration getSoftApConfiguration() {
|
||||
return mRequestParcel.softApConfig;
|
||||
|
|
@ -944,7 +944,7 @@ public class TetheringManager {
|
|||
* {@link Process#INVALID_UID} if unset.
|
||||
* @hide
|
||||
*/
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@SystemApi(client = MODULE_LIBRARIES)
|
||||
public int getUid() {
|
||||
return mRequestParcel.uid;
|
||||
|
|
@ -955,7 +955,7 @@ public class TetheringManager {
|
|||
* unset.
|
||||
* @hide
|
||||
*/
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_REQUEST_WITH_SOFT_AP_CONFIG)
|
||||
@FlaggedApi(Flags.FLAG_TETHERING_WITH_SOFT_AP_CONFIG)
|
||||
@SystemApi(client = MODULE_LIBRARIES)
|
||||
@Nullable
|
||||
public String getPackageName() {
|
||||
|
|
|
|||
|
|
@ -49,6 +49,15 @@ flag {
|
|||
is_fixed_read_only: true
|
||||
}
|
||||
|
||||
flag {
|
||||
name: "tethering_with_soft_ap_config"
|
||||
is_exported: true
|
||||
namespace: "android_core_networking"
|
||||
description: "The flag controls the access for the parcelable TetheringRequest with getSoftApConfiguration/setSoftApConfiguration API"
|
||||
bug: "216524590"
|
||||
is_fixed_read_only: true
|
||||
}
|
||||
|
||||
flag {
|
||||
name: "request_restricted_wifi"
|
||||
is_exported: true
|
||||
|
|
|
|||
Loading…
Reference in a new issue