diff options
author | Jake Hamby <jhamby@google.com> | 2010-09-21 13:39:53 -0700 |
---|---|---|
committer | Jake Hamby <jhamby@google.com> | 2010-09-30 15:43:34 -0700 |
commit | f51eadaf1f83abfe16a609a4ded6d789494689b2 (patch) | |
tree | a004b337ba44a0bda0d2ba2411b43d091d42850c /core | |
parent | 99f8c5ee621d78a24583a10e459ba40aab511a17 (diff) | |
download | frameworks_base-f51eadaf1f83abfe16a609a4ded6d789494689b2.zip frameworks_base-f51eadaf1f83abfe16a609a4ded6d789494689b2.tar.gz frameworks_base-f51eadaf1f83abfe16a609a4ded6d789494689b2.tar.bz2 |
Typo fixes in comments and minor code cleanups.
* Fix some typos in Javadoc and log messages.
* Remove redundant initializer in BluetoothAdapter.readOutOfBandData()
* Use canonical "UTF-8" charset name instead of "UTF8" in
BluetoothDevice.convertPinToBytes()
Change-Id: I58cd5dc48a7ad0053d204c5f590b4b3d438d8672
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/bluetooth/AtCommandResult.java | 2 | ||||
-rw-r--r-- | core/java/android/bluetooth/AtParser.java | 23 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothAdapter.java | 8 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothAudioGateway.java | 2 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothClass.java | 4 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothDevice.java | 28 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothDevicePicker.java | 3 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothHeadset.java | 14 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothPbap.java | 2 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothServerSocket.java | 6 | ||||
-rw-r--r-- | core/java/android/bluetooth/BluetoothSocket.java | 8 | ||||
-rw-r--r-- | core/java/android/bluetooth/HeadsetBase.java | 4 | ||||
-rw-r--r-- | core/java/android/server/BluetoothEventLoop.java | 4 | ||||
-rw-r--r-- | core/java/android/server/BluetoothService.java | 12 |
14 files changed, 58 insertions, 62 deletions
diff --git a/core/java/android/bluetooth/AtCommandResult.java b/core/java/android/bluetooth/AtCommandResult.java index 638be2d..375a6dd 100644 --- a/core/java/android/bluetooth/AtCommandResult.java +++ b/core/java/android/bluetooth/AtCommandResult.java @@ -16,8 +16,6 @@ package android.bluetooth; -import java.util.*; - /** * The result of execution of an single AT command.<p> * diff --git a/core/java/android/bluetooth/AtParser.java b/core/java/android/bluetooth/AtParser.java index 1ea3150..328fb2b 100644 --- a/core/java/android/bluetooth/AtParser.java +++ b/core/java/android/bluetooth/AtParser.java @@ -16,16 +16,13 @@ package android.bluetooth; -import android.bluetooth.AtCommandHandler; -import android.bluetooth.AtCommandResult; - import java.util.*; /** * An AT (Hayes command) Parser based on (a subset of) the ITU-T V.250 standard. * <p> * - * Conforment with the subset of V.250 required for implementation of the + * Conformant with the subset of V.250 required for implementation of the * Bluetooth Headset and Handsfree Profiles, as per Bluetooth SIP * specifications. Also implements some V.250 features not required by * Bluetooth - such as chained commands.<p> @@ -48,7 +45,7 @@ import java.util.*; * are no arguments for get commands. * <li>Set Command. For example "AT+VGM=14". The command name is "VGM", and * there is a single integer argument in this case. In the general case then - * can be zero or more arguments (comma deliminated) each of integer or string + * can be zero or more arguments (comma delimited) each of integer or string * form. * <li>Test Command. For example "AT+VGM=?. No arguments. * </ul> @@ -60,7 +57,7 @@ import java.util.*; * headset/handsfree use this is acceptable, because they only use the basic * commands ATA and ATD, which are not allowed to be chained. For general V.250 * use we would need to improve this class to allow Basic command chaining - - * however its tricky to get right becuase there is no deliminator for Basic + * however it's tricky to get right because there is no delimiter for Basic * command chaining.<p> * * Extended commands can be chained. For example:<p> @@ -71,7 +68,7 @@ import java.util.*; * AT+CIMI * Except that only one final result code is return (although several * intermediate responses may be returned), and as soon as one command in the - * chain fails the rest are abandonded.<p> + * chain fails the rest are abandoned.<p> * * Handlers are registered by there command name via register(Char c, ...) or * register(String s, ...). Handlers for Basic command should be registered by @@ -80,7 +77,7 @@ import java.util.*; * * Refer to:<ul> * <li>ITU-T Recommendation V.250 - * <li>ETSI TS 127.007 (AT Comannd set for User Equipment, 3GPP TS 27.007) + * <li>ETSI TS 127.007 (AT Command set for User Equipment, 3GPP TS 27.007) * <li>Bluetooth Headset Profile Spec (K6) * <li>Bluetooth Handsfree Profile Spec (HFP 1.5) * </ul> @@ -188,7 +185,7 @@ public class AtParser { } /** - * Break an argument string into individual arguments (comma deliminated). + * Break an argument string into individual arguments (comma delimited). * Integer arguments are turned into Integer objects. Otherwise a String * object is used. */ @@ -212,7 +209,7 @@ public class AtParser { } /** - * Return the index of the end of character after the last characeter in + * Return the index of the end of character after the last character in * the extended command name. Uses the V.250 spec for allowed command * names. */ @@ -244,7 +241,7 @@ public class AtParser { * Processes an incoming AT command line.<p> * This method will invoke zero or one command handler methods for each * command in the command line.<p> - * @param raw_input The AT input, without EOL deliminator (e.g. <CR>). + * @param raw_input The AT input, without EOL delimiter (e.g. <CR>). * @return Result object for this command line. This can be * converted to a String[] response with toStrings(). */ @@ -297,8 +294,8 @@ public class AtParser { if (c == '+') { // Option 2: Extended Command - // Search for first non-name character. Shortcircuit if we dont - // handle this command name. + // Search for first non-name character. Short-circuit if + // we don't handle this command name. int i = findEndExtendedName(input, index + 1); String commandName = input.substring(index, i); if (!mExtHandlers.containsKey(commandName)) { diff --git a/core/java/android/bluetooth/BluetoothAdapter.java b/core/java/android/bluetooth/BluetoothAdapter.java index 33fd395..3040319 100644 --- a/core/java/android/bluetooth/BluetoothAdapter.java +++ b/core/java/android/bluetooth/BluetoothAdapter.java @@ -285,7 +285,7 @@ public final class BluetoothAdapter { private static final int ADDRESS_LENGTH = 17; /** - * Lazyily initialized singleton. Guaranteed final after first object + * Lazily initialized singleton. Guaranteed final after first object * constructed. */ private static BluetoothAdapter sAdapter; @@ -410,7 +410,7 @@ public final class BluetoothAdapter { * user action to turn off Bluetooth. * <p>This gracefully shuts down all Bluetooth connections, stops Bluetooth * system services, and powers down the underlying Bluetooth hardware. - * <p class="caution"><strong>Bluetooth should never be disbled without + * <p class="caution"><strong>Bluetooth should never be disabled without * direct user consent</strong>. The {@link #disable()} method is * provided only for applications that include a user interface for changing * system settings, such as a "power manager" app.</p> @@ -876,8 +876,8 @@ public final class BluetoothAdapter { public Pair<byte[], byte[]> readOutOfBandData() { if (getState() != STATE_ON) return null; try { - byte[] hash = new byte[16]; - byte[] randomizer = new byte[16]; + byte[] hash; + byte[] randomizer; byte[] ret = mService.readOutOfBandData(); diff --git a/core/java/android/bluetooth/BluetoothAudioGateway.java b/core/java/android/bluetooth/BluetoothAudioGateway.java index bc32060..9351393 100644 --- a/core/java/android/bluetooth/BluetoothAudioGateway.java +++ b/core/java/android/bluetooth/BluetoothAudioGateway.java @@ -23,7 +23,7 @@ import android.os.Handler; import android.util.Log; /** - * Listen's for incoming RFCOMM connection for the headset / handsfree service. + * Listens for incoming RFCOMM connection for the headset / handsfree service. * * TODO: Use the new generic BluetoothSocket class instead of this legacy code * diff --git a/core/java/android/bluetooth/BluetoothClass.java b/core/java/android/bluetooth/BluetoothClass.java index c7fea9e..6a878d7 100644 --- a/core/java/android/bluetooth/BluetoothClass.java +++ b/core/java/android/bluetooth/BluetoothClass.java @@ -34,8 +34,8 @@ import android.os.Parcelable; * Bluetooth profiles or services are actually supported by a device. Accurate * service discovery is done through SDP requests, which are automatically * performed when creating an RFCOMM socket with {@link - * BluetoothDevice#createRfcommSocketToServiceRecord(UUID)} and {@link - * BluetoothAdapter#listenUsingRfcommWithServiceRecord(String,UUID)}</p> + * BluetoothDevice#createRfcommSocketToServiceRecord} and {@link + * BluetoothAdapter#listenUsingRfcommWithServiceRecord}</p> * * <p>Use {@link BluetoothDevice#getBluetoothClass} to retrieve the class for * a remote device. diff --git a/core/java/android/bluetooth/BluetoothDevice.java b/core/java/android/bluetooth/BluetoothDevice.java index e577ec4..ada3c24 100644 --- a/core/java/android/bluetooth/BluetoothDevice.java +++ b/core/java/android/bluetooth/BluetoothDevice.java @@ -32,7 +32,7 @@ import java.util.UUID; /** * Represents a remote Bluetooth device. A {@link BluetoothDevice} lets you - * create a connection with the repective device or query information about + * create a connection with the respective device or query information about * it, such as the name, address, class, and bonding state. * * <p>This class is really just a thin wrapper for a Bluetooth hardware @@ -48,7 +48,7 @@ import java.util.UUID; * {@link BluetoothAdapter}) or get one from the set of bonded devices * returned by {@link BluetoothAdapter#getBondedDevices() * BluetoothAdapter.getBondedDevices()}. You can then open a - * {@link BluetoothSocket} for communciation with the remote device, using + * {@link BluetoothSocket} for communication with the remote device, using * {@link #createRfcommSocketToServiceRecord(UUID)}. * * <p class="note"><strong>Note:</strong> @@ -226,8 +226,8 @@ public final class BluetoothDevice implements Parcelable { * <p>A shared link keys exists locally for the remote device, so * communication can be authenticated and encrypted. * <p><i>Being bonded (paired) with a remote device does not necessarily - * mean the device is currently connected. It just means that the ponding - * procedure was compeleted at some earlier time, and the link key is still + * mean the device is currently connected. It just means that the pending + * procedure was completed at some earlier time, and the link key is still * stored locally, ready to use on the next connection. * </i> */ @@ -283,7 +283,7 @@ public final class BluetoothDevice implements Parcelable { * not respond to pin request in time * @hide */ public static final int UNBOND_REASON_AUTH_FAILED = 1; - /** A bond attempt failed because the other side explicilty rejected + /** A bond attempt failed because the other side explicitly rejected * bonding * @hide */ public static final int UNBOND_REASON_AUTH_REJECTED = 2; @@ -515,7 +515,7 @@ public final class BluetoothDevice implements Parcelable { * Cancel an in-progress bonding request started with {@link #createBond}. * <p>Requires {@link android.Manifest.permission#BLUETOOTH_ADMIN}. * - * @return true on sucess, false on error + * @return true on success, false on error * @hide */ public boolean cancelBondProcess() { @@ -532,7 +532,7 @@ public final class BluetoothDevice implements Parcelable { * authentication and encryption. * <p>Requires {@link android.Manifest.permission#BLUETOOTH_ADMIN}. * - * @return true on sucess, false on error + * @return true on success, false on error * @hide */ public boolean removeBond() { @@ -617,7 +617,7 @@ public final class BluetoothDevice implements Parcelable { * with the UUIDs supported by the remote end. If there is an error * in getting the SDP records or if the process takes a long time, * an Intent is sent with the UUIDs that is currently present in the - * cache. Clients should use the {@link getUuids} to get UUIDs + * cache. Clients should use the {@link #getUuids} to get UUIDs * is SDP is not to be performed. * * @return False if the sanity check fails, True if the process @@ -693,7 +693,7 @@ public final class BluetoothDevice implements Parcelable { * outgoing connection to this remote device on given channel. * <p>The remote device will be authenticated and communication on this * socket will be encrypted. - * <p>Use {@link BluetoothSocket#connect} to intiate the outgoing + * <p>Use {@link BluetoothSocket#connect} to initiate the outgoing * connection. * <p>Valid RFCOMM channels are in range 1 to 30. * <p>Requires {@link android.Manifest.permission#BLUETOOTH} @@ -715,7 +715,7 @@ public final class BluetoothDevice implements Parcelable { * <p>This is designed to be used with {@link * BluetoothAdapter#listenUsingRfcommWithServiceRecord} for peer-peer * Bluetooth applications. - * <p>Use {@link BluetoothSocket#connect} to intiate the outgoing + * <p>Use {@link BluetoothSocket#connect} to initiate the outgoing * connection. This will also perform an SDP lookup of the given uuid to * determine which channel to connect to. * <p>The remote device will be authenticated and communication on this @@ -772,9 +772,9 @@ public final class BluetoothDevice implements Parcelable { /** * Check that a pin is valid and convert to byte array. * - * Bluetooth pin's are 1 to 16 bytes of UTF8 characters. + * Bluetooth pin's are 1 to 16 bytes of UTF-8 characters. * @param pin pin as java String - * @return the pin code as a UTF8 byte array, or null if it is an invalid + * @return the pin code as a UTF-8 byte array, or null if it is an invalid * Bluetooth pin. * @hide */ @@ -784,9 +784,9 @@ public final class BluetoothDevice implements Parcelable { } byte[] pinBytes; try { - pinBytes = pin.getBytes("UTF8"); + pinBytes = pin.getBytes("UTF-8"); } catch (UnsupportedEncodingException uee) { - Log.e(TAG, "UTF8 not supported?!?"); // this should not happen + Log.e(TAG, "UTF-8 not supported?!?"); // this should not happen return null; } if (pinBytes.length <= 0 || pinBytes.length > 16) { diff --git a/core/java/android/bluetooth/BluetoothDevicePicker.java b/core/java/android/bluetooth/BluetoothDevicePicker.java index 05eed0e..3a07033 100644 --- a/core/java/android/bluetooth/BluetoothDevicePicker.java +++ b/core/java/android/bluetooth/BluetoothDevicePicker.java @@ -36,7 +36,8 @@ public interface BluetoothDevicePicker { /** * Broadcast when one BT device is selected from BT device picker screen. - * Selected BT device address is contained in extra string {@link BluetoothIntent} + * Selected {@link BluetoothDevice} is returned in extra data named + * {@link BluetoothDevice#EXTRA_DEVICE}. */ @SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION) public static final String ACTION_DEVICE_SELECTED = diff --git a/core/java/android/bluetooth/BluetoothHeadset.java b/core/java/android/bluetooth/BluetoothHeadset.java index 4a91a8c..197b022 100644 --- a/core/java/android/bluetooth/BluetoothHeadset.java +++ b/core/java/android/bluetooth/BluetoothHeadset.java @@ -45,7 +45,7 @@ import android.util.Log; * This BluetoothHeadset object is not immediately bound to the * BluetoothHeadset service. Use the ServiceListener interface to obtain a * notification when it is bound, this is especially important if you wish to - * immediately call methods on BluetootHeadset after construction. + * immediately call methods on BluetoothHeadset after construction. * * Android only supports one connected Bluetooth Headset at a time. * @@ -108,7 +108,7 @@ public final class BluetoothHeadset { public static final int RESULT_FAILURE = 0; public static final int RESULT_SUCCESS = 1; - /** Connection canceled before completetion. */ + /** Connection canceled before completion. */ public static final int RESULT_CANCELED = 2; /** Values for {@link #EXTRA_DISCONNECT_INITIATOR} */ @@ -116,11 +116,11 @@ public final class BluetoothHeadset { public static final int LOCAL_DISCONNECT = 1; - /** Default priority for headsets that for which we will accept - * inconing connections and auto-connect */ + /** Default priority for headsets for which we will accept + * incoming connections and auto-connect. */ public static final int PRIORITY_AUTO_CONNECT = 1000; - /** Default priority for headsets that for which we will accept - * inconing connections but not auto-connect */ + /** Default priority for headsets for which we will accept + * incoming connections but not auto-connect. */ public static final int PRIORITY_ON = 100; /** Default priority for headsets that should not be auto-connected * and not allow incoming connections. */ @@ -268,7 +268,7 @@ public final class BluetoothHeadset { /** * Disconnects the current headset. Currently this call blocks, it may soon - * be made asynchornous. Returns false if this proxy object is + * be made asynchronous. Returns false if this proxy object is * not currently connected to the Headset service. */ public boolean disconnectHeadset(BluetoothDevice device) { diff --git a/core/java/android/bluetooth/BluetoothPbap.java b/core/java/android/bluetooth/BluetoothPbap.java index b48f48e..4be077c 100644 --- a/core/java/android/bluetooth/BluetoothPbap.java +++ b/core/java/android/bluetooth/BluetoothPbap.java @@ -197,7 +197,7 @@ public class BluetoothPbap { /** * Disconnects the current Pbap client (PCE). Currently this call blocks, - * it may soon be made asynchornous. Returns false if this proxy object is + * it may soon be made asynchronous. Returns false if this proxy object is * not currently connected to the Pbap service. */ public boolean disconnect() { diff --git a/core/java/android/bluetooth/BluetoothServerSocket.java b/core/java/android/bluetooth/BluetoothServerSocket.java index c9c6c0a..83e59e2 100644 --- a/core/java/android/bluetooth/BluetoothServerSocket.java +++ b/core/java/android/bluetooth/BluetoothServerSocket.java @@ -29,14 +29,14 @@ import java.io.IOException; * side, use a {@link BluetoothServerSocket} to create a listening server * socket. When a connection is accepted by the {@link BluetoothServerSocket}, * it will return a new {@link BluetoothSocket} to manage the connection. - * On the client side, use a single {@link BluetoothSocket} to both intiate + * On the client side, use a single {@link BluetoothSocket} to both initiate * an outgoing connection and to manage the connection. * * <p>The most common type of Bluetooth socket is RFCOMM, which is the type * supported by the Android APIs. RFCOMM is a connection-oriented, streaming * transport over Bluetooth. It is also known as the Serial Port Profile (SPP). * - * <p>To create a listenting {@link BluetoothServerSocket} that's ready for + * <p>To create a listening {@link BluetoothServerSocket} that's ready for * incoming connections, use * {@link BluetoothAdapter#listenUsingRfcommWithServiceRecord * BluetoothAdapter.listenUsingRfcommWithServiceRecord()}. Then call @@ -70,7 +70,7 @@ public final class BluetoothServerSocket implements Closeable { * @param encrypt require the connection to be encrypted * @param port remote port * @throws IOException On error, for example Bluetooth not available, or - * insufficient priveleges + * insufficient privileges */ /*package*/ BluetoothServerSocket(int type, boolean auth, boolean encrypt, int port) throws IOException { diff --git a/core/java/android/bluetooth/BluetoothSocket.java b/core/java/android/bluetooth/BluetoothSocket.java index ad03399..719d730 100644 --- a/core/java/android/bluetooth/BluetoothSocket.java +++ b/core/java/android/bluetooth/BluetoothSocket.java @@ -35,7 +35,7 @@ import java.util.concurrent.locks.ReentrantReadWriteLock; * side, use a {@link BluetoothServerSocket} to create a listening server * socket. When a connection is accepted by the {@link BluetoothServerSocket}, * it will return a new {@link BluetoothSocket} to manage the connection. - * On the client side, use a single {@link BluetoothSocket} to both intiate + * On the client side, use a single {@link BluetoothSocket} to both initiate * an outgoing connection and to manage the connection. * * <p>The most common type of Bluetooth socket is RFCOMM, which is the type @@ -113,7 +113,7 @@ public final class BluetoothSocket implements Closeable { * @param port remote port * @param uuid SDP uuid * @throws IOException On error, for example Bluetooth not available, or - * insufficient priveleges + * insufficient privileges */ /*package*/ BluetoothSocket(int type, int fd, boolean auth, boolean encrypt, BluetoothDevice device, int port, ParcelUuid uuid) throws IOException { @@ -158,7 +158,7 @@ public final class BluetoothSocket implements Closeable { * @param address remote device that this socket can connect to * @param port remote port * @throws IOException On error, for example Bluetooth not available, or - * insufficient priveleges + * insufficient privileges */ private BluetoothSocket(int type, int fd, boolean auth, boolean encrypt, String address, int port) throws IOException { @@ -226,7 +226,7 @@ public final class BluetoothSocket implements Closeable { } // all native calls are guaranteed to immediately return after - // abortNative(), so this lock should immediatley acquire + // abortNative(), so this lock should immediately acquire mLock.writeLock().lock(); try { mClosed = true; diff --git a/core/java/android/bluetooth/HeadsetBase.java b/core/java/android/bluetooth/HeadsetBase.java index e2935c9..22495a7 100644 --- a/core/java/android/bluetooth/HeadsetBase.java +++ b/core/java/android/bluetooth/HeadsetBase.java @@ -89,7 +89,7 @@ public final class HeadsetBase { initializeNativeDataNative(-1); } - /* Create from an already exisiting rfcomm connection */ + /* Create from an already existing rfcomm connection */ public HeadsetBase(PowerManager pm, BluetoothAdapter adapter, BluetoothDevice device, int socketFd, int rfcommChannel, Handler handler) { mDirection = DIRECTION_INCOMING; @@ -128,7 +128,7 @@ public final class HeadsetBase { (System.currentTimeMillis() - timestamp) + " ms"); if (result.getResultCode() == AtCommandResult.ERROR) { - Log.i(TAG, "Error pocessing <" + input + ">"); + Log.i(TAG, "Error processing <" + input + ">"); } sendURC(result.toString()); diff --git a/core/java/android/server/BluetoothEventLoop.java b/core/java/android/server/BluetoothEventLoop.java index bcb151a..94f80cc 100644 --- a/core/java/android/server/BluetoothEventLoop.java +++ b/core/java/android/server/BluetoothEventLoop.java @@ -34,7 +34,7 @@ import java.util.Set; /** * TODO: Move this to * java/services/com/android/server/BluetoothEventLoop.java - * and make the contructor package private again. + * and make the constructor package private again. * * @hide */ @@ -590,7 +590,7 @@ class BluetoothEventLoop { private void onRestartRequired() { if (mBluetoothService.isEnabled()) { - Log.e(TAG, "*** A serious error occured (did bluetoothd crash?) - " + + Log.e(TAG, "*** A serious error occurred (did bluetoothd crash?) - " + "restarting Bluetooth ***"); mHandler.sendEmptyMessage(EVENT_RESTART_BLUETOOTH); } diff --git a/core/java/android/server/BluetoothService.java b/core/java/android/server/BluetoothService.java index dfe3a25..71b4ee2 100644 --- a/core/java/android/server/BluetoothService.java +++ b/core/java/android/server/BluetoothService.java @@ -464,7 +464,7 @@ public class BluetoothService extends IBluetooth.Stub { // forked multiple times in a row, probably because there is // some race in sdptool or bluez when operated in parallel. // As a workaround, delay 500ms between each fork of sdptool. - // TODO: Don't fork sdptool in order to regsiter service + // TODO: Don't fork sdptool in order to register service // records, use a DBUS call instead. switch (msg.arg1) { case 1: @@ -673,7 +673,7 @@ public class BluetoothService extends IBluetooth.Stub { /** local cache of bonding state. /* we keep our own state to track the intermediate state BONDING, which /* bluez does not track. - * All addreses must be passed in upper case. + * All addresses must be passed in upper case. */ public class BondState { private final HashMap<String, Integer> mState = new HashMap<String, Integer>(); @@ -932,7 +932,7 @@ public class BluetoothService extends IBluetooth.Stub { } } - // This function adds a bluetooth address to the auto pairing blacklis + // This function adds a bluetooth address to the auto pairing blacklist // file. These addresses are added to DynamicAddressBlacklistSection private void updateAutoPairingData(String address) { BufferedWriter out = null; @@ -1062,7 +1062,7 @@ public class BluetoothService extends IBluetooth.Stub { * a device discoverable; you need to call setMode() to make the device * explicitly discoverable. * - * @param timeout_s The discoverable timeout in seconds. + * @param timeout The discoverable timeout in seconds. */ public synchronized boolean setDiscoverableTimeout(int timeout) { mContext.enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, @@ -2083,12 +2083,12 @@ public class BluetoothService extends IBluetooth.Stub { /*package*/ String getAddressFromObjectPath(String objectPath) { String adapterObjectPath = getPropertyInternal("ObjectPath"); if (adapterObjectPath == null || objectPath == null) { - Log.e(TAG, "getAddressFromObjectPath: AdpaterObjectPath:" + adapterObjectPath + + Log.e(TAG, "getAddressFromObjectPath: AdapterObjectPath:" + adapterObjectPath + " or deviceObjectPath:" + objectPath + " is null"); return null; } if (!objectPath.startsWith(adapterObjectPath)) { - Log.e(TAG, "getAddressFromObjectPath: AdpaterObjectPath:" + adapterObjectPath + + Log.e(TAG, "getAddressFromObjectPath: AdapterObjectPath:" + adapterObjectPath + " is not a prefix of deviceObjectPath:" + objectPath + "bluetoothd crashed ?"); return null; |