aboutsummaryrefslogtreecommitdiff
path: root/framework/java/android/bluetooth/BluetoothAdapter.java
diff options
context:
space:
mode:
authorMarie Janssen <jamuraa@google.com>2017-01-12 16:00:30 -0800
committerAndre Eisenbach <eisenbach@google.com>2017-06-22 20:49:55 +0000
commit36354fb05c282dcb0e4b27bd4422fa424b7bc032 (patch)
tree058e289967c311a4c9284ed7f7b3b623ac8fac17 /framework/java/android/bluetooth/BluetoothAdapter.java
parentb1a145641e675ff1befaa576bad046b1e1d99f18 (diff)
Bluetooth: minor documentation fix to de-confuse
It was somewhat unclear which is the preferred method of retrieving a BluetoothAdapter. Make it clear that using BluetoothManager is preferred, and remove references to the old method in BluetoothManager docs since it is only avaialable in API 18 or higher. Test: recompile, check that documentation is updated Fix: 33355430 Change-Id: Ia20b4e45dca03bc2f13c2ab477799b89c5e14f45
Diffstat (limited to 'framework/java/android/bluetooth/BluetoothAdapter.java')
-rw-r--r--framework/java/android/bluetooth/BluetoothAdapter.java15
1 files changed, 8 insertions, 7 deletions
diff --git a/framework/java/android/bluetooth/BluetoothAdapter.java b/framework/java/android/bluetooth/BluetoothAdapter.java
index ff52f27447..838fb72ea3 100644
--- a/framework/java/android/bluetooth/BluetoothAdapter.java
+++ b/framework/java/android/bluetooth/BluetoothAdapter.java
@@ -70,9 +70,10 @@ import java.util.concurrent.locks.ReentrantReadWriteLock;
* devices, and start a scan for Bluetooth LE devices.
*
* <p>To get a {@link BluetoothAdapter} representing the local Bluetooth
- * adapter, when running on JELLY_BEAN_MR1 and below, call the
- * static {@link #getDefaultAdapter} method; when running on JELLY_BEAN_MR2 and
- * higher, call {@link BluetoothManager#getAdapter}.
+ * adapter, call the {@link BluetoothManager#getAdapter} function on {@link BluetoothManager}.
+ * On JELLY_BEAN_MR1 and below you will need to use the static {@link #getDefaultAdapter}
+ * method instead.
+ * </p><p>
* Fundamentally, this is your starting point for all
* Bluetooth actions. Once you have the local adapter, you can get a set of
* {@link BluetoothDevice} objects representing all paired devices with
@@ -81,14 +82,13 @@ import java.util.concurrent.locks.ReentrantReadWriteLock;
* listen for incoming connection requests with
* {@link #listenUsingRfcommWithServiceRecord(String,UUID)}; or start a scan for
* Bluetooth LE devices with {@link #startLeScan(LeScanCallback callback)}.
- *
- * <p>This class is thread safe.
- *
+ * </p>
+ * <p>This class is thread safe.</p>
* <p class="note"><strong>Note:</strong>
* Most methods require the {@link android.Manifest.permission#BLUETOOTH}
* permission and some also require the
* {@link android.Manifest.permission#BLUETOOTH_ADMIN} permission.
- *
+ * </p>
* <div class="special reference">
* <h3>Developer Guides</h3>
* <p>
@@ -565,6 +565,7 @@ public final class BluetoothAdapter {
* <p>Currently Android only supports one Bluetooth adapter, but the API
* could be extended to support more. This will always return the default
* adapter.
+ * </p>
* @return the default local adapter, or null if Bluetooth is not supported
* on this hardware platform
*/