BluetoothBuilder

A default implementation of BaseBluetoothBuilder

Parameters

applicationContext

the Context in which Bluetooth should run

permissionsBuilder

a method for creating the Permissions object to manage the Bluetooth permissions. Needs to have com.splendo.kaluga.permissions.bluetooth.BluetoothPermission and com.splendo.kaluga.permissions.location.LocationPermission registered.

scannerBuilder

the BaseScanner.Builder for creating the BaseScanner to handle scanning

A default implementation of BaseBluetoothBuilder

actual class BluetoothBuilder

A default implementation of BaseBluetoothBuilder

Parameters

permissionsBuilder

a method for creating the Permissions object to manage the Bluetooth permissions. Needs to have com.splendo.kaluga.permissions.bluetooth.BluetoothPermission registered.

scannerBuilder

the BaseScanner.Builder for creating the BaseScanner to handle scanning

bundle

the NSBundle in which Bluetooth should run

A default implementation of BaseBluetoothBuilder

Parameters

permissionsBuilder

a method for creating the Permissions object to manage the Bluetooth permissions. Needs to have com.splendo.kaluga.permissions.bluetooth.BluetoothPermission registered.

A default implementation of BaseBluetoothBuilder

Parameters

permissionsBuilder

a method for creating the Permissions object to manage the Bluetooth permissions. Needs to have com.splendo.kaluga.permissions.bluetooth.BluetoothPermission registered.

Constructors

Link copied to clipboard
constructor(applicationContext: Context = ApplicationHolder.applicationContext, permissionsBuilder: suspend (CoroutineContext) -> Permissions = { context -> Permissions( PermissionsBuilder(PermissionContext(applicationContext)).apply { registerBluetoothPermissionIfNotRegistered() registerLocationPermissionIfNotRegistered() }, coroutineContext = context, ) }, scannerBuilder: BaseScanner.Builder = DefaultScanner.Builder(applicationContext = applicationContext))
constructor(bundle: <Error class: unknown class> = NSBundle.mainBundle, permissionsBuilder: suspend (<Error class: unknown class>) -> <Error class: unknown class> = { context -> Permissions( PermissionsBuilder(bundle).apply { registerBluetoothPermissionIfNotRegistered() }, context, ) }, scannerBuilder: DefaultScanner.Builder = DefaultScanner.Builder())
constructor(permissionsBuilder: suspend (CoroutineContext) -> Permissions = { context -> Permissions( PermissionsBuilder().apply { registerBluetoothPermissionIfNotRegistered() }, context, ) })
constructor(permissionsBuilder: suspend (CoroutineContext) -> Permissions = { context -> Permissions( PermissionsBuilder().apply { registerBluetoothPermissionIfNotRegistered() }, context, ) })

Functions

Link copied to clipboard
open override fun create(scannerSettingsBuilder: (Permissions) -> BaseScanner.Settings, coroutineContext: CoroutineContext): Bluetooth

Creates a Bluetooth object

abstract fun create(scannerSettingsBuilder: (Permissions) -> BaseScanner.Settings = { BaseScanner.Settings(it) }, coroutineContext: CoroutineContext = defaultBluetoothDispatcher): Bluetooth

Creates a Bluetooth object

open fun create(scannerSettingsBuilder: (<Error class: unknown class>) -> <Error class: unknown class>, coroutineContext: <Error class: unknown class>): <Error class: unknown class>
open override fun create(scannerSettingsBuilder: (Permissions) -> BaseScanner.Settings, coroutineContext: CoroutineContext): Bluetooth

Creates a Bluetooth object

open override fun create(scannerSettingsBuilder: (Permissions) -> BaseScanner.Settings, coroutineContext: CoroutineContext): Bluetooth

Creates a Bluetooth object