Add @UnsupportedAppUsage annotations
For packages:
android.hardware.usb
android.hardware.soundtrigger
android.hardware.radio
android.hardware.location
android.hardware.input
android.hardware.hdmi
android.hardware.fingerprint
android.hardware.display
android.hardware.cas.V1_0
android.hardware.camera2.utils
android.hardware.camera2.params
android.hardware.camera2.marshal.impl
android.hardware.camera2.marshal
android.hardware.camera2.legacy
android.hardware.camera2.impl
android.hardware.camera2.dispatch
android.hardware.camera2
android.hardware
This is an automatically generated CL. See go/UnsupportedAppUsage
for more details.
Exempted-From-Owner-Approval: Mechanical changes to the codebase
which have been approved by Android API council and announced on
android-eng@
Bug: 110868826
Test: m
Change-Id: I046df307d1065a9692e4e7259c59a93ee8f458ef
diff --git a/core/java/android/hardware/display/DisplayManagerGlobal.java b/core/java/android/hardware/display/DisplayManagerGlobal.java
index d968a3e..7304ab4 100644
--- a/core/java/android/hardware/display/DisplayManagerGlobal.java
+++ b/core/java/android/hardware/display/DisplayManagerGlobal.java
@@ -16,6 +16,7 @@
package android.hardware.display;
+import android.annotation.UnsupportedAppUsage;
import android.content.Context;
import android.content.pm.ParceledListSlice;
import android.content.res.Resources;
@@ -66,10 +67,12 @@
public static final int EVENT_DISPLAY_CHANGED = 2;
public static final int EVENT_DISPLAY_REMOVED = 3;
+ @UnsupportedAppUsage
private static DisplayManagerGlobal sInstance;
private final Object mLock = new Object();
+ @UnsupportedAppUsage
private final IDisplayManager mDm;
private DisplayManagerCallback mCallback;
@@ -91,6 +94,7 @@
* @return The display manager instance, may be null early in system startup
* before the display manager has been fully initialized.
*/
+ @UnsupportedAppUsage
public static DisplayManagerGlobal getInstance() {
synchronized (DisplayManagerGlobal.class) {
if (sInstance == null) {
@@ -110,6 +114,7 @@
* @return Information about the specified display, or null if it does not exist.
* This object belongs to an internal cache and should be treated as if it were immutable.
*/
+ @UnsupportedAppUsage
public DisplayInfo getDisplayInfo(int displayId) {
try {
synchronized (mLock) {
@@ -146,6 +151,7 @@
*
* @return An array containing all display ids.
*/
+ @UnsupportedAppUsage
public int[] getDisplayIds() {
try {
synchronized (mLock) {
@@ -209,6 +215,7 @@
* @param displayId The logical display id.
* @return The display object, or null if there is no display with the given id.
*/
+ @UnsupportedAppUsage
public Display getRealDisplay(int displayId) {
return getCompatibleDisplay(displayId, DisplayAdjustments.DEFAULT_DISPLAY_ADJUSTMENTS);
}
@@ -337,6 +344,7 @@
}
}
+ @UnsupportedAppUsage
public void disconnectWifiDisplay() {
try {
mDm.disconnectWifiDisplay();
@@ -369,6 +377,7 @@
}
}
+ @UnsupportedAppUsage
public WifiDisplayStatus getWifiDisplayStatus() {
try {
return mDm.getWifiDisplayStatus();