Direct-BT  2.3.1
Direct-BT - Direct Bluetooth Programming.
Public Member Functions | Protected Member Functions | List of all members
jau.direct_bt.DBTGattService Class Reference
Inheritance diagram for jau.direct_bt.DBTGattService:
Collaboration diagram for jau.direct_bt.DBTGattService:

Public Member Functions

boolean equals (final Object obj)
 
String getUUID ()
 Get the UUID of this service. More...
 
BTType getBluetoothType ()
 Returns the BluetoothType of this object. More...
 
final BTGattService clone ()
 
BTGattChar find (final String UUID, final long timeoutMS)
 Find a BTGattChar. More...
 
BTGattChar find (final String UUID)
 Find a BTGattChar. More...
 
final BTDevice getDevice ()
 Returns the device to which this service belongs to. More...
 
final boolean getPrimary ()
 Returns true if this service is a primary service, false if secondary. More...
 
final List< BTGattChargetChars ()
 Returns a list of BTGattChar this service exposes. More...
 
final short getHandleStart ()
 Returns the service start handle. More...
 
final short getHandleEnd ()
 Returns the service end handle. More...
 
final String toString ()
 
- Public Member Functions inherited from jau.direct_bt.DBTObject
final int hashCode ()
 
synchronized void close ()
 Release the native memory associated with this object The object should not be used following a call to close. More...
 

Protected Member Functions

native void deleteImpl (long nativeInstance)
 Deletes the native instance. More...
 
- Protected Member Functions inherited from jau.direct_bt.DBTObject
 DBTObject (final long nativeInstance, final int hashValue)
 
void finalize ()
 

Additional Inherited Members

- Static Public Member Functions inherited from org.direct_bt.BTGattService
static boolean addCharListenerToAll (final BTDevice device, final List< BTGattService > services, final BTGattCharListener listener)
 Adds the given BTGattCharListener to the BTDevice and BTGattChar#enableNotificationOrIndication(boolean[]) for all BTGattChar instances. More...
 
static boolean removeCharListenerFromAll (final BTDevice device, final List< BTGattService > services, final BTGattCharListener listener)
 Removes the given BTGattCharListener from the BTDevice. More...
 
static int removeAllCharListener (final BTDevice device, final List< BTGattService > services)
 Removes all BTGattCharListener from the BTDevice. More...
 

Detailed Description

Definition at line 38 of file DBTGattService.java.

Member Function Documentation

◆ clone()

final BTGattService jau.direct_bt.DBTGattService.clone ( )

Reimplemented from jau.direct_bt.DBTObject.

Definition at line 80 of file DBTGattService.java.

◆ deleteImpl()

native void jau.direct_bt.DBTGattService.deleteImpl ( long  nativeInstance)
protected

Deletes the native instance.

Called via delete() and at this point

  • this java reference has been removed from the native instance, i.e.
    JavaUplink
    's
    javaObjectRef = nullptr
  • the nativeInstance reference has been zeroed, but passed as argument for this final native deletion task.
Parameters
nativeInstancecopy of nativeInstance reference, which has been already zeroed.

Reimplemented from jau.direct_bt.DBTNativeDownlink.

◆ equals()

boolean jau.direct_bt.DBTGattService.equals ( final Object  obj)

Reimplemented from jau.direct_bt.DBTObject.

Definition at line 62 of file DBTGattService.java.

◆ find() [1/2]

BTGattChar jau.direct_bt.DBTGattService.find ( final String  UUID)

Find a BTGattChar.

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

Returns
An object matching the UUID or null if not found before timeout expires or event is canceled.

Implements org.direct_bt.BTGattService.

Definition at line 92 of file DBTGattService.java.

Here is the call graph for this function:

◆ find() [2/2]

BTGattChar jau.direct_bt.DBTGattService.find ( final String  UUID,
final long  timeoutMS 
)

Find a BTGattChar.

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 BTGattChar you are waiting for @parameter timeoutMS the function will return after timeout time in milliseconds, a value of zero means wait forever. If object is not found during this time null will be returned.

Returns
An object matching the UUID or null if not found before timeout expires or event is canceled.

Implements org.direct_bt.BTGattService.

Definition at line 84 of file DBTGattService.java.

Here is the caller graph for this function:

◆ getBluetoothType()

BTType jau.direct_bt.DBTGattService.getBluetoothType ( )

Returns the BluetoothType of this object.

Returns
The BluetoothType of this object

Implements org.direct_bt.BTObject.

Definition at line 75 of file DBTGattService.java.

◆ getChars()

final List<BTGattChar> jau.direct_bt.DBTGattService.getChars ( )

Returns a list of BTGattChar this service exposes.

Returns
A list of BTGattChar exposed by this service

Implements org.direct_bt.BTGattService.

Definition at line 103 of file DBTGattService.java.

◆ getDevice()

final BTDevice jau.direct_bt.DBTGattService.getDevice ( )

Returns the device to which this service belongs to.

Returns
The device.

Implements org.direct_bt.BTGattService.

Definition at line 97 of file DBTGattService.java.

◆ getHandleEnd()

final short jau.direct_bt.DBTGattService.getHandleEnd ( )

Returns the service end handle.

Attribute handles are unique for each device (server) (BT Core Spec v5.2: Vol 3, Part F Protocol..: 3.2.2 Attribute Handle).

Definition at line 119 of file DBTGattService.java.

◆ getHandleStart()

final short jau.direct_bt.DBTGattService.getHandleStart ( )

Returns the service start handle.

Attribute handles are unique for each device (server) (BT Core Spec v5.2: Vol 3, Part F Protocol..: 3.2.2 Attribute Handle).

Definition at line 111 of file DBTGattService.java.

◆ getPrimary()

final boolean jau.direct_bt.DBTGattService.getPrimary ( )

Returns true if this service is a primary service, false if secondary.

Returns
true if this service is a primary service, false if secondary.

Implements org.direct_bt.BTGattService.

Definition at line 100 of file DBTGattService.java.

◆ getUUID()

String jau.direct_bt.DBTGattService.getUUID ( )

Get the UUID of this service.

Returns
The 128 byte UUID of this service, NULL if an error occurred

Implements org.direct_bt.BTGattService.

Definition at line 72 of file DBTGattService.java.

Here is the caller graph for this function:

◆ toString()

final String jau.direct_bt.DBTGattService.toString ( )

Definition at line 122 of file DBTGattService.java.

Here is the call graph for this function:

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