Reason

Why NFC cannot be used.

May gain members in a later release: an exhaustive when over it then stops compiling until the new member is handled. An else branch keeps it compiling without handling the new member: that is your choice, and today the compiler warns that such an else is redundant.

Since

1.0.0

Entries

Link copied to clipboard

The device has no NFC reader, or its NFC reader cannot do what a chip read needs: on Android, the tag cannot be reached as an ISO 14443-4 (ISO-DEP) chip on this device.

Link copied to clipboard

The device has an NFC reader, but it is turned off.

Link copied to clipboard

The app may not use NFC. On iPhone (Core NFC's code 2, "security violation"): the app lacks the NFC tag reading entitlement, or its Info.plist lacks NFCReaderUsageDescription or the ISO 7816 select identifiers the read needs; fix the app's setup. On Android: the platform refused reader mode with a SecurityException.

Link copied to clipboard

The link to the chip was closed, so no more commands can be sent: by the read's own ending, by the app closing a transport it owns, or by the platform (a link it closed with no cause it reports). A chip read that sees the platform close its link ends with ChipReadEnding.EndedBySystem.

Link copied to clipboard

The person ended the reading, for example with the Cancel button of the system's NFC sheet on iPhone.

Link copied to clipboard

The system's NFC reader is busy with something else for now, such as a payment, so it cannot be used at this moment.

Link copied to clipboard

The system ended the NFC session on its own: not the app, and not the person.

Link copied to clipboard

The system's NFC reader refused a request from the SDK, such as a command or a session setting it does not accept, so the request was not carried out.

Link copied to clipboard

The app already has a chip read running, so a second one was not started. Only one read at a time can use the NFC reader: wait for the running read's ending, then start again.

Link copied to clipboard

The screen (the Android Activity) the read belongs to is finishing or destroyed: when the read was started with it (the read does not start), or while the read ran, for example by a configuration change such as a rotation, so reader mode ended with it. The app can start a new read on the new screen, with a new key.

Link copied to clipboard

Android only: NFC is on, but the device's option for reading tags is turned off, so reader mode finds no document. The person can turn it on in the system's NFC settings. The platform tells this from Android 15 (API level 35) on; on earlier versions the SDK cannot know it and never reports it.

Link copied to clipboard

A command was longer than the device's NFC link accepts (Android's "transceive length exceeds" refusal, Core NFC's code 105 on iPhone), so it was not sent.

Link copied to clipboard

iPhone only (Core NFC's code 7): the system setting or the hardware is not eligible for reading tags, as the system decides, for example in some regions. The app cannot fix it itself; tell the person that chip reading is not available on this device now.

Link copied to clipboard

iPhone only (Core NFC's code 8): the person has not yet accepted or declined the app's request to use the NFC reader. The person answers the system's request, then the app starts a new read.

Link copied to clipboard

Something the SDK did not expect went wrong in the platform's NFC code or in the SDK itself, so the read stopped. Not about the document or the person: report it as a bug, with the read's telemetry.

Properties

Link copied to clipboard

Returns a representation of an immutable list of all enum entries, in the order they're declared.

Link copied to clipboard
expect val name: String
Link copied to clipboard
expect val ordinal: Int

Functions

Link copied to clipboard

Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Link copied to clipboard

Returns an array containing the constants of this enum type, in the order they're declared.