DefaultDevices
data class DefaultDevices(val allDevices: Map<Identifier, Device>, val identifiersFoundForDeviceDiscoveryMode: Map<ScanningState.DeviceDiscoveryMode, Set<Identifier>>, val currentScanFilter: ScanningState.DeviceDiscoveryMode.Scanning) : ScanningState.Devices
Default implementation of ScanningState.Devices
Constructors
Link copied to clipboard
Constructor
constructor(allDevices: Map<Identifier, Device>, identifiersFoundForDeviceDiscoveryMode: Map<ScanningState.DeviceDiscoveryMode, Set<Identifier>>, currentScanFilter: ScanningState.DeviceDiscoveryMode.Scanning)
Properties
Link copied to clipboard
The map of Device found for given Identifier
Link copied to clipboard
The DeviceDiscoveryMode.Scanning applied during scanning
Link copied to clipboard
The set of Identifier scanned by currentScanFilter
Link copied to clipboard
open override val identifiersFoundForDeviceDiscoveryMode: Map<ScanningState.DeviceDiscoveryMode, Set<Identifier>>
A map of all Identifier found for scanning per DeviceDiscoveryMode
Functions
Link copied to clipboard
open override fun copyAndAddScanned(identifier: Identifier, createDevice: () -> Device): ScanningState.Devices
Creates a new Devices instance that adds an Identifier to the currentScanFilter and creates the corresponding Device if not yet discovered
Link copied to clipboard
open override fun copyAndSetPaired(devices: Map<Identifier, () -> Device>, filter: Filter, removeForAllPairedFilters: Boolean): ScanningState.Devices
Link copied to clipboard
The list of Device found for the currentScanFilter
Link copied to clipboard
The list of Device found for a given DeviceDiscoveryMode
Link copied to clipboard
open override fun updateScanFilter(filter: Filter, cleanMode: BluetoothService.CleanMode): ScanningState.Devices
Creates a new Devices instance that sets the currentScanFilter for a DeviceDiscoveryMode.Scanning with a given Filter