notifiable
abstract fun notifiable(properties: Set<CharacteristicProperty.Notifiable> = setOf(CharacteristicProperty.Notify), encrypted: Boolean = false, onSubscribe: LocalCharacteristic.Notifiable.(ConnectedDevice) -> Unit, onUnsubscribe: LocalCharacteristic.Notifiable.(ConnectedDevice) -> Unit)
Makes this LocalCharacteristic a LocalCharacteristic.Notifiable This method can only be called once.
Parameters
properties
the CharacteristicProperty.Notifiable of the characteristic. Must not be empty
encrypted
true if subscribing to the characteristic should be encrypted.
onSubscribe
the function to call when subscribing to the characteristic. This contains the com.splendo.kaluga.bluetooth.ConnectedDevice that subscribed
onUnsubscribe
the function to call when unsubscribing from the characteristic. This contains the com.splendo.kaluga.bluetooth.ConnectedDevice that unsubscribed