MdocConnectionMethod

A single concrete device retrieval method and transport mode in ISO/IEC 18013-5.

Each instance represents exactly one actionable transport mode (e.g., Ble.GattPeripheral, Ble.DirectL2capCentral, Nfc, WifiAware, or Http). Wire-level coalescing of multiple Ble modes into a single [2, 1, BleOptions] DeviceRetrievalMethod or BLE OOB + ChBleOptions NDEF carrier is handled automatically by encodeDeviceRetrievalMethods and encodeNdefHandoverCarriers, and wire-level expansion back into ordered single-mode instances is handled by decodeDeviceRetrievalMethods and decodeNdefHandoverCarrier.

Inheritors

Constructors

Link copied to clipboard
protected constructor()

Types

Link copied to clipboard
sealed class Ble : MdocConnectionMethod

Bluetooth Low Energy (BLE) connection methods according to ISO/IEC 18013-5 Second Edition clauses 11.1.1–11.1.3.

Link copied to clipboard
object Companion
Link copied to clipboard
data class Http(val uri: String) : MdocConnectionMethod

HTTP connection method according to ISO/IEC TS 18013-7:2024 Annex A.

Link copied to clipboard
data class Nfc(val commandDataFieldMaxLength: Long, val responseDataFieldMaxLength: Long) : MdocConnectionMethod

Near Field Communication (NFC) data retrieval connection method according to ISO/IEC 18013-5.

Link copied to clipboard
data class WifiAware(val passphraseInfoPassphrase: String? = null, val channelInfoChannelNumber: Long? = null, val channelInfoOperatingClass: Long? = null, val bandInfoSupportedBands: ByteString? = null) : MdocConnectionMethod

Wi-Fi Aware connection method according to ISO/IEC 18013-5.

Functions

Link copied to clipboard
fun toDeviceEngagement(engagementType: MdocEngagementType = MdocEngagementType.DEVICE_QR): ByteArray

Encodes this single connection method as DeviceRetrievalMethod CBOR.