NfcScannerImpl

Provider of NFC scanner functionality

Constructors

Link copied to clipboard
constructor(pointer: Pointer)
constructor(noPointer: NoPointer)

This constructor can be used to instantiate a fake object. Only used for tests. Any attempt to actually use an object constructed this way will fail as there is no connected Rust object.

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open suspend override fun cancelScan(errorMessage: String?)

Stops scanning previously started via scan or disconnects the established session

Link copied to clipboard
open override fun close()
Link copied to clipboard
open override fun destroy()
Link copied to clipboard
open suspend override fun isEnabled(): Boolean

Check whether NFC adapter is enabled on the device (android only, iOS always enabled)

Link copied to clipboard
open suspend override fun isSupported(): Boolean

Check whether NFC scanning is supported on the device

Link copied to clipboard
open suspend override fun scan(message: String?)

Starts scanning for ISO 7816-4 NFC tag

Link copied to clipboard
open suspend override fun setMessage(message: String)

Update UI message on the system NFC scanner overlay (iOS) - previously set via scan

Link copied to clipboard
open suspend override fun transceive(commandApdu: ByteArray): ByteArray

Send APDU request and wait for response APDU

Link copied to clipboard
fun uniffiClonePointer(): Pointer