45 UnspecifiedAction = -1,
51 QNdefNfcSmartPosterRecord();
52 QNdefNfcSmartPosterRecord(
const QNdefRecord &other);
53 QNdefNfcSmartPosterRecord(
const QNdefNfcSmartPosterRecord &other);
54 QNdefNfcSmartPosterRecord &operator=(
const QNdefNfcSmartPosterRecord &other);
55 ~QNdefNfcSmartPosterRecord();
57 void setPayload(
const QByteArray &payload);
59 bool hasTitle(
const QString &locale = QString())
const;
60 bool hasAction()
const;
61 bool hasIcon(
const QByteArray &mimetype = QByteArray())
const;
63 bool hasTypeInfo()
const;
65 qsizetype titleCount()
const;
66 QNdefNfcTextRecord titleRecord(qsizetype index)
const;
67 QString title(
const QString &locale = QString())
const;
68 QList<QNdefNfcTextRecord> titleRecords()
const;
70 bool addTitle(
const QNdefNfcTextRecord &text);
71 bool addTitle(
const QString &text,
const QString &locale, QNdefNfcTextRecord::Encoding encoding);
72 bool removeTitle(
const QNdefNfcTextRecord &text);
73 bool removeTitle(
const QString &locale);
74 void setTitles(
const QList<QNdefNfcTextRecord> &titles);
77 QNdefNfcUriRecord uriRecord()
const;
78 void setUri(
const QNdefNfcUriRecord &url);
79 void setUri(
const QUrl &url);
81 Action action()
const;
82 void setAction(Action act);
84 qsizetype iconCount()
const;
85 QNdefNfcIconRecord iconRecord(qsizetype index)
const;
86 QByteArray icon(
const QByteArray& mimetype = QByteArray())
const;
88 QList<QNdefNfcIconRecord> iconRecords()
const;
90 void addIcon(
const QNdefNfcIconRecord &icon);
91 void addIcon(
const QByteArray &type,
const QByteArray &data);
92 bool removeIcon(
const QNdefNfcIconRecord &icon);
93 bool removeIcon(
const QByteArray &type);
94 void setIcons(
const QList<QNdefNfcIconRecord> &icons);
97 void setSize(quint32 size);
99 QString typeInfo()
const;
100 void setTypeInfo(
const QString &type);
103 QSharedDataPointer<QNdefNfcSmartPosterRecordPrivate> d;
106 void convertToPayload();
108 bool addTitleInternal(
const QNdefNfcTextRecord &text);
109 void addIconInternal(
const QNdefNfcIconRecord &icon);
The QNdefNfcSmartPosterRecord class provides an NFC RTD-SmartPoster.
#define Q_DECLARE_ISRECORDTYPE_FOR_MIME_NDEF_RECORD(className)
#define Q_DECLARE_MIME_NDEF_RECORD(className, initialPayload)