diff options
| author | Andrei Onea <andreionea@google.com> | 2019-06-17 11:26:14 +0100 |
|---|---|---|
| committer | Andrei Onea <andreionea@google.com> | 2019-06-17 11:29:45 +0100 |
| commit | 147146fb21165bdf7812fa9745ca797b7d12b437 (patch) | |
| tree | 29614d7c7de43e1a149f5bd9804746d81a298977 /framework/java/android/bluetooth/BluetoothAdapter.java | |
| parent | eef5c81a33a1fdf7a133329852d03e32d35d9b75 (diff) | |
Document public alternatives to greylisted APIs
Add known public alternatives or recommendations for greylisted APIs in
Bluetooth.
Bug: 135171386
Test: m
Change-Id: I86e708be37eb7d1b0fafa2d64283b7f81bc02e51
Diffstat (limited to 'framework/java/android/bluetooth/BluetoothAdapter.java')
| -rw-r--r-- | framework/java/android/bluetooth/BluetoothAdapter.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/framework/java/android/bluetooth/BluetoothAdapter.java b/framework/java/android/bluetooth/BluetoothAdapter.java index 31bbd16497..39d63de87d 100644 --- a/framework/java/android/bluetooth/BluetoothAdapter.java +++ b/framework/java/android/bluetooth/BluetoothAdapter.java @@ -1028,7 +1028,8 @@ public final class BluetoothAdapter { */ @RequiresPermission(Manifest.permission.BLUETOOTH) @AdapterState - @UnsupportedAppUsage + @UnsupportedAppUsage(publicAlternatives = "Use {@link #getState()} instead to determine " + + "whether you can use BLE & BT classic.") public int getLeState() { int state = BluetoothAdapter.STATE_OFF; @@ -1484,7 +1485,8 @@ public final class BluetoothAdapter { * @return true if the scan mode was set, false otherwise * @hide */ - @UnsupportedAppUsage + @UnsupportedAppUsage(publicAlternatives = "Use {@link #ACTION_REQUEST_DISCOVERABLE}, which " + + "shows UI that confirms the user wants to go into discoverable mode.") public boolean setScanMode(@ScanMode int mode, int duration) { if (getState() != STATE_ON) { return false; |
