LocalServiceWrapper

actual interface LocalServiceWrapper

Accessor to the platform level Local Bluetooth service.

Implemented per platform by DefaultLocalServiceWrapper (wrapping the framework service) and mockable in tests, allowing a LocalService graph to be built without a live Bluetooth stack.

Inheritors

actual interface LocalServiceWrapper

Accessor to the platform level Local Bluetooth service.

Implemented per platform by DefaultLocalServiceWrapper (wrapping the framework service) and mockable in tests, allowing a LocalService graph to be built without a live Bluetooth stack.

Inheritors

expect interface LocalServiceWrapper

Accessor to the platform level Local Bluetooth service.

Implemented per platform by DefaultLocalServiceWrapper (wrapping the framework service) and mockable in tests, allowing a LocalService graph to be built without a live Bluetooth stack.

Properties

Link copied to clipboard

Identity used to correlate this service with incoming GATT callbacks.

Identity used to correlate this service with incoming peripheral-manager callbacks.

Link copied to clipboard
actual abstract val uuid: UUID

The UUID of the service

actual abstract val uuid: UUID

The UUID of the service

expect abstract val uuid: UUID

The UUID of the service

Functions

Link copied to clipboard
actual abstract fun addCharacteristic(characteristic: LocalCharacteristicWrapper)

Adds a LocalCharacteristicWrapper to the service

actual abstract fun addCharacteristic(characteristic: LocalCharacteristicWrapper)

Adds a LocalCharacteristicWrapper to the service

expect abstract fun addCharacteristic(characteristic: LocalCharacteristicWrapper)

Adds a LocalCharacteristicWrapper to the service

Link copied to clipboard
actual abstract fun addIncludedService(service: LocalServiceWrapper)

Adds an included LocalServiceWrapper to the service

actual abstract fun addIncludedService(service: LocalServiceWrapper)

Adds an included LocalServiceWrapper to the service

expect abstract fun addIncludedService(service: LocalServiceWrapper)

Adds an included LocalServiceWrapper to the service

Link copied to clipboard
abstract fun addTo(gattServer: BluetoothGattServer): Boolean

Adds the service to a BluetoothGattServer

abstract fun addTo(serverWrapper: KalugaBluetoothServerWrapper)

Adds the service to a KalugaBluetoothServerWrapper

Link copied to clipboard
abstract fun addToParent(parent: BluetoothGattService)

Adds the service to a parent BluetoothGattService as an included service

abstract fun addToParent(parent: CBMutableService)

Adds the service to a parent CBMutableService as an included service

Link copied to clipboard
abstract fun removeFrom(gattServer: BluetoothGattServer)

Removes the service from a BluetoothGattServer

abstract fun removeFrom(serverWrapper: KalugaBluetoothServerWrapper)

Removes the service from a KalugaBluetoothServerWrapper