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.
- NfcTag
Record - An NDEF record read from a scanned tag.
- Scan
Request - Arguments of the
Nfc::scanAPI. - Scan
Response - Response of the
Nfc::scanAPI. - UriFilter
- Filters the tags to scan by the URI of their NDEF payload.
Enums§
- Error
- Errors returned by the NFC plugin.
- NFCType
Name Format - The Type Name Format (TNF) of an NDEF record, which defines how the record type is interpreted.
- Scan
Kind - The kind of scan to perform, which defines which tags are matched.
- Tech
Kind - The NFC technologies a tag can support, mirroring the
android.nfc.techclasses.
Traits§
- NfcExt
- Extensions to
tauri::App,tauri::AppHandle,tauri::WebviewWindow,tauri::Webviewandtauri::Windowto access the NFC APIs.
Functions§
- init
- Initializes the plugin.
Type Aliases§
- Result
- Alias for a
std::result::Resultwith the error typeError.