QNdefNfcTextRecord Class

QNdefNfcTextRecord class provides an NFC RTD-Text 更多...

头: #include <QNdefNfcTextRecord>
qmake: QT += nfc
Since: Qt 5.2
继承: QNdefRecord

公共类型

enum 编码 { Utf8, Utf16 }

公共函数

QNdefNfcTextRecord ()
QNdefNfcTextRecord (const QNdefRecord & other )
编码 encoding () const
QString locale () const
void setEncoding (Encoding encoding )
void setLocale (const QString & locale )
void setText (const QString text )
QString text () const

详细描述

QNdefNfcTextRecord class provides an NFC RTD-Text

RTD-Text encapsulates a user displayable text record.

成员类型文档编制

enum QNdefNfcTextRecord:: 编码

This enum describes the text encoding standard used.

常量 描述
QNdefNfcTextRecord::Utf8 0 The text is encoded with UTF-8.
QNdefNfcTextRecord::Utf16 1 The text is encoding with UTF-16.

成员函数文档编制

QNdefNfcTextRecord:: QNdefNfcTextRecord ()

Constructs an empty NFC text record of type QNdefRecord::NfcRtd .

QNdefNfcTextRecord:: QNdefNfcTextRecord (const QNdefRecord & other )

Constructs a new NFC text record that is a copy of other .

编码 QNdefNfcTextRecord:: encoding () const

Returns the encoding of the contents.

另请参阅 setEncoding ().

QString QNdefNfcTextRecord:: locale () const

Returns the locale of the text record.

另请参阅 setLocale ().

void QNdefNfcTextRecord:: setEncoding ( 编码 encoding )

Sets the enconding of the contents to encoding .

另请参阅 encoding ().

void QNdefNfcTextRecord:: setLocale (const QString & locale )

Sets the locale of the text record to locale .

另请参阅 locale ().

void QNdefNfcTextRecord:: setText (const QString text )

Sets the contents of the text record to text .

另请参阅 text ().

QString QNdefNfcTextRecord:: text () const

Returns the contents of the text record as a string.

另请参阅 setText ().