MockBluetoothService

class MockBluetoothService(val discoveredDevicesFlow: MutableStateFlow<List<ConnectableDevice>> = MutableStateFlow(emptyList()), val filteredDevicesFlow: MutableStateFlow<Map<Filter, List<ConnectableDevice>>> = MutableStateFlow(emptyMap()), val pairedDevicesFlow: MutableStateFlow<Map<Set<UUID>, List<ConnectableDevice>>> = MutableStateFlow(emptyMap()), val isEnabled: MutableStateFlow<Boolean> = MutableStateFlow(true), setupMocks: Boolean = true) : BluetoothClient

Constructors

Link copied to clipboard
constructor(discoveredDevicesFlow: MutableStateFlow<List<ConnectableDevice>> = MutableStateFlow(emptyList()), filteredDevicesFlow: MutableStateFlow<Map<Filter, List<ConnectableDevice>>> = MutableStateFlow(emptyMap()), pairedDevicesFlow: MutableStateFlow<Map<Set<UUID>, List<ConnectableDevice>>> = MutableStateFlow(emptyMap()), isEnabled: MutableStateFlow<Boolean> = MutableStateFlow(true), setupMocks: Boolean = true)

Properties

Link copied to clipboard
var currentFilter: MutableStateFlow<Filter>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override val isEnabled: MutableStateFlow<Boolean>
Link copied to clipboard
Link copied to clipboard
val pairedDevicesFlow: MutableStateFlow<Map<Set<UUID>, List<ConnectableDevice>>>
Link copied to clipboard
val pairedDevicesMock: TripleParametersMock<Filter, removeForAllPairedFilters: Boolean, connectionSettings: ConnectionSettings?, Flow<List<ConnectableDevice>>>
Link copied to clipboard

Functions

Link copied to clipboard
open override fun allDevices(): Flow<List<ConnectableDevice>>
Link copied to clipboard
open override fun devices(): Flow<List<ConnectableDevice>>
Link copied to clipboard
open suspend override fun isScanning(): Flow<Boolean>
Link copied to clipboard
open override fun pairedDevices(filter: Filter, removeForAllPairedFilters: Boolean, connectionSettings: ConnectionSettings?): Flow<List<ConnectableDevice>>
Link copied to clipboard
open override fun scannedDevices(filter: Filter): Flow<List<ConnectableDevice>>
Link copied to clipboard
open override fun startScanning(filter: Filter, cleanMode: BluetoothClient.CleanMode, connectionSettings: ConnectionSettings?)
Link copied to clipboard
open override fun stopScanning(cleanMode: BluetoothClient.CleanMode)