diff options
author | Hyundo Moon <hdmoon@google.com> | 2021-11-23 16:33:18 +0900 |
---|---|---|
committer | Hyundo Moon <hdmoon@google.com> | 2021-12-01 05:41:46 +0000 |
commit | 0ea2899f31af41b6cae5da76da92aad0f0f02dc0 (patch) | |
tree | 61248facd680c2d1dc06916f92013f7530f50c51 /framework/java | |
parent | 555c9561a64b6d09c736f97ff81d271f9cdb0774 (diff) |
BluetoothGatt: Deprecate unsupported methods
Bug: 207452114
Test: make update-api -j && make -j;
Change-Id: Ic0534c1e25f9e35fae96886002e5ff1dd33f9fd4
Diffstat (limited to 'framework/java')
-rw-r--r-- | framework/java/android/bluetooth/BluetoothGatt.java | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/framework/java/android/bluetooth/BluetoothGatt.java b/framework/java/android/bluetooth/BluetoothGatt.java index 4e7c01ad2d..fe8d1ba80e 100644 --- a/framework/java/android/bluetooth/BluetoothGatt.java +++ b/framework/java/android/bluetooth/BluetoothGatt.java @@ -1806,32 +1806,33 @@ public final class BluetoothGatt implements BluetoothProfile { } /** - * Not supported - please use {@link BluetoothManager#getConnectedDevices(int)} + * @deprecated Not supported - please use {@link BluetoothManager#getConnectedDevices(int)} * with {@link BluetoothProfile#GATT} as argument - * * @throws UnsupportedOperationException */ @Override @RequiresNoPermission + @Deprecated public int getConnectionState(BluetoothDevice device) { throw new UnsupportedOperationException("Use BluetoothManager#getConnectionState instead."); } /** - * Not supported - please use {@link BluetoothManager#getConnectedDevices(int)} + * @deprecated Not supported - please use {@link BluetoothManager#getConnectedDevices(int)} * with {@link BluetoothProfile#GATT} as argument * * @throws UnsupportedOperationException */ @Override @RequiresNoPermission + @Deprecated public List<BluetoothDevice> getConnectedDevices() { throw new UnsupportedOperationException( "Use BluetoothManager#getConnectedDevices instead."); } /** - * Not supported - please use + * @deprecated Not supported - please use * {@link BluetoothManager#getDevicesMatchingConnectionStates(int, int[])} * with {@link BluetoothProfile#GATT} as first argument * @@ -1839,6 +1840,7 @@ public final class BluetoothGatt implements BluetoothProfile { */ @Override @RequiresNoPermission + @Deprecated public List<BluetoothDevice> getDevicesMatchingConnectionStates(int[] states) { throw new UnsupportedOperationException( "Use BluetoothManager#getDevicesMatchingConnectionStates instead."); |