Add setPollForce to module API
The API was test API in S, but this is not supported in module API surfaces. Make it module API instead. Bug: 197717846 Test: Tests already using this API (cherry-picked from ag/16780943) Change-Id: I9d44b761572f94b08b269478c4a0c20c1171343c Merged-In: I9d44b761572f94b08b269478c4a0c20c1171343c
This commit is contained in:
committed by
junyulai
parent
63d42a25bb
commit
c99a128f51
@@ -27,7 +27,6 @@ import android.annotation.Nullable;
|
||||
import android.annotation.RequiresPermission;
|
||||
import android.annotation.SystemApi;
|
||||
import android.annotation.SystemService;
|
||||
import android.annotation.TestApi;
|
||||
import android.annotation.WorkerThread;
|
||||
import android.app.usage.NetworkStats.Bucket;
|
||||
import android.compat.annotation.UnsupportedAppUsage;
|
||||
@@ -192,9 +191,13 @@ public class NetworkStatsManager {
|
||||
}
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
/**
|
||||
* Set poll force flag to indicate that calling any subsequent query method will force a stats
|
||||
* poll.
|
||||
* @hide
|
||||
*/
|
||||
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
|
||||
@TestApi
|
||||
@SystemApi(client = MODULE_LIBRARIES)
|
||||
public void setPollForce(boolean pollForce) {
|
||||
if (pollForce) {
|
||||
mFlags |= FLAG_POLL_FORCE;
|
||||
|
||||
Reference in New Issue
Block a user