Skip to main content

Crate tauri_plugin_nfc

Crate tauri_plugin_nfc 

Source
Expand description

Read and write NFC tags on Android and iOS.

This plugin is mobile only: the whole crate is gated behind #[cfg(mobile)], so it expands to nothing when compiling for Linux, macOS or Windows.

Register the plugin with init and use the NfcExt trait to reach the Nfc instance from any tauri::Manager implementation (the app handle, a window, …).

Structs§

Nfc
Access to the nfc APIs.
NfcRecord
An NDEF record to be written to a tag.
NfcTag
An NFC tag that has been scanned.
NfcTagRecord
An NDEF record read from a scanned tag.
ScanRequest
Arguments of the Nfc::scan API.
ScanResponse
Response of the Nfc::scan API.
UriFilter
Filters the tags to scan by the URI of their NDEF payload.

Enums§

Error
Errors returned by the NFC plugin.
NFCTypeNameFormat
The Type Name Format (TNF) of an NDEF record, which defines how the record type is interpreted.
ScanKind
The kind of scan to perform, which defines which tags are matched.
TechKind
The NFC technologies a tag can support, mirroring the android.nfc.tech classes.

Traits§

NfcExt
Extensions to tauri::App, tauri::AppHandle, tauri::WebviewWindow, tauri::Webview and tauri::Window to access the NFC APIs.

Functions§

init
Initializes the plugin.

Type Aliases§

Result
Alias for a std::result::Result with the error type Error.