From b897f7728f9fe8cd53572bc2a36f6ea1335b4074 Mon Sep 17 00:00:00 2001 From: Patty Date: Tue, 30 Nov 2021 19:56:07 +0800 Subject: [PATCH] Change isCISCentralSupported() to isLeAudioSupported() API Tag: #feature Bug: 200749925 Bug: 150670922 Test: atest BasicAdapterTest Change-Id: Ie606f45e148f6d9026495279d718a3cc1523c36f --- core/api/current.txt | 2 +- core/java/android/bluetooth/BluetoothAdapter.java | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/api/current.txt b/core/api/current.txt index a70a0a9042905..a7293f1181cdf 100644 --- a/core/api/current.txt +++ b/core/api/current.txt @@ -8648,10 +8648,10 @@ package android.bluetooth { method public android.bluetooth.BluetoothDevice getRemoteDevice(byte[]); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_SCAN) public int getScanMode(); method public int getState(); - method public int isCisCentralSupported(); method @RequiresPermission(android.Manifest.permission.BLUETOOTH_SCAN) public boolean isDiscovering(); method public boolean isEnabled(); method public boolean isLe2MPhySupported(); + method public int isLeAudioSupported(); method public boolean isLeCodedPhySupported(); method public boolean isLeExtendedAdvertisingSupported(); method public boolean isLePeriodicAdvertisingSupported(); diff --git a/core/java/android/bluetooth/BluetoothAdapter.java b/core/java/android/bluetooth/BluetoothAdapter.java index cf00cbd584a4e..6154b7149a1e3 100644 --- a/core/java/android/bluetooth/BluetoothAdapter.java +++ b/core/java/android/bluetooth/BluetoothAdapter.java @@ -2286,21 +2286,21 @@ public final class BluetoothAdapter { public @interface LeFeatureReturnValues {} /** - * Returns {@link BluetoothStatusCodes#SUCCESS} if LE Connected Isochronous Stream Central - * feature is supported, returns {@link BluetoothStatusCodes#ERROR_FEATURE_NOT_SUPPORTED} if + * Returns {@link BluetoothStatusCodes#SUCCESS} if the LE audio feature is + * supported, returns {@link BluetoothStatusCodes#ERROR_FEATURE_NOT_SUPPORTED} if * the feature is not supported or an error code. * - * @return whether the chipset supports the LE Connected Isochronous Stream Central feature + * @return whether the LE audio is supported */ @RequiresNoPermission - public @LeFeatureReturnValues int isCisCentralSupported() { + public @LeFeatureReturnValues int isLeAudioSupported() { if (!getLeAccess()) { return BluetoothStatusCodes.ERROR_BLUETOOTH_NOT_ENABLED; } try { mServiceLock.readLock().lock(); if (mService != null) { - return mService.isCisCentralSupported(); + return mService.isLeAudioSupported(); } } catch (RemoteException e) { e.rethrowFromSystemServer();