TinyB  0.5.1
TinyB - The Tiny Bluetooth LE library
Public Member Functions | List of all members
tinyb.BluetoothGattDescriptor Class Reference
Inheritance diagram for tinyb.BluetoothGattDescriptor:
tinyb.BluetoothObject

Public Member Functions

native BluetoothType getBluetoothType ()
 
native BluetoothAdapter clone ()
 
native byte[] readValue ()
 
native boolean writeValue (byte[] argValue) throws BluetoothException
 
native void enableValueNotifications (BluetoothNotification< byte[]> callback)
 
native void disableValueNotifications ()
 
native String getUUID ()
 
native BluetoothGattCharacteristic getCharacteristic ()
 
native byte[] getValue ()
 
- Public Member Functions inherited from tinyb.BluetoothObject
native BluetoothType getBluetoothType ()
 
native BluetoothObject clone ()
 
boolean equals (Object obj)
 
int hashCode ()
 
synchronized void close ()
 

Additional Inherited Members

- Protected Member Functions inherited from tinyb.BluetoothObject
 BluetoothObject (long instance)
 
void finalize ()
 
native String getObjectPath ()
 
- Protected Attributes inherited from tinyb.BluetoothObject
long nativeInstance
 

Detailed Description

Provides access to Bluetooth GATT descriptor. Follows the BlueZ adapter API available at: http://git.kernel.org/cgit/bluetooth/bluez.git/tree/doc/gatt-api.txt

Member Function Documentation

native void tinyb.BluetoothGattDescriptor.disableValueNotifications ( )

Disables notifications of the value and unregisters the callback object passed through the corresponding enable method.

native void tinyb.BluetoothGattDescriptor.enableValueNotifications ( BluetoothNotification< byte[]>  callback)

Enables notifications for the value and calls run function of the BluetoothNotification object.

Parameters
callbackA BluetoothNotification<byte[]> object. Its run function will be called when a notification is issued. The run function will deliver the new value of the value property.
native BluetoothGattCharacteristic tinyb.BluetoothGattDescriptor.getCharacteristic ( )

Returns the characteristic to which this descriptor belongs to.

Returns
The characteristic.
native String tinyb.BluetoothGattDescriptor.getUUID ( )

Get the UUID of this descriptor.

Returns
The 128 byte UUID of this descriptor, NULL if an error occurred
native byte [] tinyb.BluetoothGattDescriptor.getValue ( )

Returns the cached value of this descriptor, if any.

Returns
The cached value of this descriptor.
native byte [] tinyb.BluetoothGattDescriptor.readValue ( )

Reads the value of this descriptor

Returns
A vector<uchar> containing data from this descriptor
native boolean tinyb.BluetoothGattDescriptor.writeValue ( byte[]  argValue) throws BluetoothException

Writes the value of this descriptor.

Parameters
[in]arg_valueThe data as vector<uchar> to be written packed in a GBytes struct
Returns
TRUE if value was written succesfully

The documentation for this class was generated from the following file: