diff options
author | Petre Eftime <[email protected]> | 2016-03-18 15:32:41 +0200 |
---|---|---|
committer | Petre Eftime <[email protected]> | 2016-03-18 15:32:41 +0200 |
commit | c01b9205b2a0369c45b136e6b8ad7a2a1bb4c2b6 (patch) | |
tree | 0551719061db5523a6564dffbaa85dab484c6fdb /java/BluetoothGattCharacteristic.java | |
parent | cc5ff4de66e4d9bc51a8c3e148699db4e72532cf (diff) |
java: Add description to find functions
Signed-off-by: Petre Eftime <[email protected]>
Diffstat (limited to 'java/BluetoothGattCharacteristic.java')
-rw-r--r-- | java/BluetoothGattCharacteristic.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/java/BluetoothGattCharacteristic.java b/java/BluetoothGattCharacteristic.java index bce2126b..a1b019de 100644 --- a/java/BluetoothGattCharacteristic.java +++ b/java/BluetoothGattCharacteristic.java @@ -40,12 +40,32 @@ public class BluetoothGattCharacteristic extends BluetoothObject static BluetoothType class_type() { return BluetoothType.GATT_CHARACTERISTIC; } + /** Find a BluetoothGattDescriptor. If parameter UUID is not null, + * the returned object will have to match it. + * It will first check for existing objects. It will not turn on discovery + * or connect to devices. + * @parameter UUID optionally specify the UUID of the BluetoothGattDescriptor you are + * waiting for + * @parameter timeout the function will return after timeout time, a + * value of zero means wait forever. If object is not found during this time null will be returned. + * @return An object matching the UUID or null if not found before + * timeout expires or event is canceled. + */ public BluetoothGattDescriptor find(String UUID, Duration duration) { BluetoothManager manager = BluetoothManager.getBluetoothManager(); return (BluetoothGattDescriptor) manager.find(BluetoothType.GATT_DESCRIPTOR, null, UUID, this, duration); } + /** Find a BluetoothGattDescriptor. If parameter UUID is not null, + * the returned object will have to match it. + * It will first check for existing objects. It will not turn on discovery + * or connect to devices. + * @parameter UUID optionally specify the UUID of the BluetoothGattDescriptor you are + * waiting for + * @return An object matching the UUID or null if not found before + * timeout expires or event is canceled. + */ public BluetoothGattDescriptor find(String UUID) { return find(UUID, Duration.ZERO); } |