Merge "Add NetworkRequest#satisfiedBy to SystemApi"
am: 2812b46691
Change-Id: I817020ac31dec9e10ea27fa38f07250f5c447de1
This commit is contained in:
@@ -466,6 +466,19 @@ public class NetworkRequest implements Parcelable {
|
||||
return networkCapabilities.hasUnwantedCapability(capability);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns true iff. the capabilities requested in this NetworkRequest are satisfied by the
|
||||
* provided {@link NetworkCapabilities}.
|
||||
*
|
||||
* @param nc Capabilities that should satisfy this NetworkRequest. null capabilities do not
|
||||
* satisfy any request.
|
||||
* @hide
|
||||
*/
|
||||
@SystemApi
|
||||
public boolean satisfiedBy(@Nullable NetworkCapabilities nc) {
|
||||
return networkCapabilities.satisfiedByNetworkCapabilities(nc);
|
||||
}
|
||||
|
||||
/**
|
||||
* @see Builder#addTransportType(int)
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user