DefaultGattServiceWrapper

Default implementation of RemoteServiceWrapper

Parameters

gattService

Constructors

Link copied to clipboard
constructor(gattService: BluetoothGattService)

Properties

Link copied to clipboard

The list of RemoteCharacteristicWrapper associated with the service

Link copied to clipboard

The list of RemoteServiceWrapper included in this service

Link copied to clipboard
open override val instanceId: Int

Returns the instance ID for this service. If a remote device offers multiple services with the same UUID (ex. multiple battery services for different batteries), the instance ID is used to distinguish services.

Link copied to clipboard
open override val type: Service.Type

The Service.Type of this service (primary/secondary)

Link copied to clipboard
open override val uuid: UUID

The UUID of the service

Functions

Link copied to clipboard
open override fun addCharacteristic(characteristic: BluetoothGattCharacteristic): Boolean

Adds a BluetoothGattCharacteristic to the service

Link copied to clipboard
open override fun addService(service: BluetoothGattService): Boolean

Adds an included BluetoothGattService to the service

Link copied to clipboard

Gets the RemoteCharacteristicWrapper for the characteristic with a given java.util.UUID if it belongs to the service