Table of Contents

Class NdefConfig

Namespace
Yubico.YubiKey.Otp
Assembly
Yubico.YubiKey.dll

A static class containing helpers that encode configurations for different types of NDEF data.

public static class NdefConfig
Inheritance
object
NdefConfig

Methods

CreateTextConfig(string, string, bool)

Create a configuration buffer for the YubiKey to send text when NDEF is triggered.

public static byte[] CreateTextConfig(string value, string languageCode, bool encodeAsUtf16 = false)

Parameters

value string

The text value to send.

languageCode string

The ISO/IANA language code for the language of value.

encodeAsUtf16 bool

Indicates whether UTF16 Big Endian encoding is preferred. Default is false, denoting a UTF8 encoding.

Returns

byte[]

An opaque configuration buffer that can be written to the YubiKey using the ConfigureNdefCommand command class.

CreateUriConfig(Uri)

Create a configuration buffer for the YubiKey to send a URI when NDEF is triggered.

public static byte[] CreateUriConfig(Uri uri)

Parameters

uri Uri

The URI to send over NDEF.

Returns

byte[]

An opaque configuration buffer that can be written to the YubiKey using the ConfigureNdefCommand command class.