Expose NetworkScore to external caller am: 39907ba9d6 am: 849c987cf6
Original change: https://android-review.googlesource.com/c/platform/frameworks/base/+/1653938 Change-Id: I807cae8d95e8d5fb1f017b1ba11d800772ba3e9c
This commit is contained in:
@@ -316,6 +316,19 @@ package android.net {
|
|||||||
method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SIGNAL_STRENGTH_WAKEUP) public android.net.NetworkRequest.Builder setSignalStrength(int);
|
method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SIGNAL_STRENGTH_WAKEUP) public android.net.NetworkRequest.Builder setSignalStrength(int);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public final class NetworkScore implements android.os.Parcelable {
|
||||||
|
method public int describeContents();
|
||||||
|
method public int getLegacyInt();
|
||||||
|
method public void writeToParcel(@NonNull android.os.Parcel, int);
|
||||||
|
field @NonNull public static final android.os.Parcelable.Creator<android.net.NetworkScore> CREATOR;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static final class NetworkScore.Builder {
|
||||||
|
ctor public NetworkScore.Builder();
|
||||||
|
method @NonNull public android.net.NetworkScore build();
|
||||||
|
method @NonNull public android.net.NetworkScore.Builder setLegacyInt(int);
|
||||||
|
}
|
||||||
|
|
||||||
public final class OemNetworkPreferences implements android.os.Parcelable {
|
public final class OemNetworkPreferences implements android.os.Parcelable {
|
||||||
method public int describeContents();
|
method public int describeContents();
|
||||||
method @NonNull public java.util.Map<java.lang.String,java.lang.Integer> getNetworkPreferences();
|
method @NonNull public java.util.Map<java.lang.String,java.lang.Integer> getNetworkPreferences();
|
||||||
|
|||||||
@@ -17,6 +17,7 @@
|
|||||||
package android.net;
|
package android.net;
|
||||||
|
|
||||||
import android.annotation.NonNull;
|
import android.annotation.NonNull;
|
||||||
|
import android.annotation.SystemApi;
|
||||||
import android.os.Parcel;
|
import android.os.Parcel;
|
||||||
import android.os.Parcelable;
|
import android.os.Parcelable;
|
||||||
|
|
||||||
@@ -29,7 +30,7 @@ import com.android.internal.annotations.VisibleForTesting;
|
|||||||
* network is considered for a particular use.
|
* network is considered for a particular use.
|
||||||
* @hide
|
* @hide
|
||||||
*/
|
*/
|
||||||
// TODO : @SystemApi when the implementation is complete
|
@SystemApi
|
||||||
public final class NetworkScore implements Parcelable {
|
public final class NetworkScore implements Parcelable {
|
||||||
// This will be removed soon. Do *NOT* depend on it for any new code that is not part of
|
// This will be removed soon. Do *NOT* depend on it for any new code that is not part of
|
||||||
// a migration.
|
// a migration.
|
||||||
@@ -62,6 +63,8 @@ public final class NetworkScore implements Parcelable {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @return whether this score has a particular policy.
|
* @return whether this score has a particular policy.
|
||||||
|
*
|
||||||
|
* @hide
|
||||||
*/
|
*/
|
||||||
@VisibleForTesting
|
@VisibleForTesting
|
||||||
public boolean hasPolicy(final int policy) {
|
public boolean hasPolicy(final int policy) {
|
||||||
|
|||||||
Reference in New Issue
Block a user