Expose internal representation of transport types.
Add getTransportTypesInternal as a hidden api for internal callers. This will be used for any metrics that need to store the transport types of a network. Bug: 273451360 Test: atest FrameworksNetTests Change-Id: I527638e5408e7971a450135345e7e51b6125d665
This commit is contained in:
@@ -1347,6 +1347,18 @@ public final class NetworkCapabilities implements Parcelable {
|
||||
return BitUtils.unpackBits(mTransportTypes);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the transports as an int. Internal callers only.
|
||||
*
|
||||
* Prefer getTransportTypes/hasTransportType if not immediately collapsing back into a scalar.
|
||||
*
|
||||
* @return a long integer representing the transport types.
|
||||
* @hide
|
||||
*/
|
||||
public long getTransportTypesInternal() {
|
||||
return mTransportTypes;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets all the transports set on this {@code NetworkCapability} instance.
|
||||
* This overwrites any existing transports.
|
||||
|
||||
Reference in New Issue
Block a user