Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Toggle main menu visibility
Loading...
Searching...
No Matches
qapduutils_p.h
Go to the documentation of this file.
1
// Copyright (C) 2022 The Qt Company Ltd.
2
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4
#
ifndef
QAPDUUTILS_P_H
5
#
define
QAPDUUTILS_P_H
6
7
//
8
// W A R N I N G
9
// -------------
10
//
11
// This file is not part of the Qt API. It exists purely as an
12
// implementation detail. This header file may change from version to
13
// version without notice, or even be removed.
14
//
15
// We mean it.
16
//
17
18
#
include
<
QtCore
/
QByteArray
>
19
20
QT_BEGIN_NAMESPACE
21
22
class
QResponseApdu
23
{
24
public
:
25
static
constexpr
uint16_t Empty = 0x0000;
26
static
constexpr
uint16_t Success = 0x9000;
27
28
explicit
QResponseApdu(
const
QByteArray &response = {});
29
30
const
QByteArray &data()
const
{
return
m_data; }
31
uint16_t status()
const
{
return
m_status; }
32
bool
isOk()
const
{
return
m_status == Success; }
33
34
private
:
35
QByteArray m_data;
36
uint16_t m_status;
37
};
38
39
namespace
QCommandApdu
{
40
41
// INS byte values for command APDUs
42
constexpr
uint8_t
Select
= 0xA4;
43
constexpr
uint8_t
ReadBinary
= 0xB0;
44
constexpr
uint8_t
GetData
= 0xCA;
45
constexpr
uint8_t
UpdateBinary
= 0xD6;
46
47
QByteArray
build
(uint8_t cla, uint8_t ins, uint8_t p1, uint8_t p2, QByteArrayView data,
48
uint16_t ne = 0);
49
};
50
51
QT_END_NAMESPACE
52
53
#
endif
// QAPDUUTILS_P_H
QNdefMessage
The QNdefMessage class provides an NFC NDEF message.
Definition
qndefmessage.h:23
QNfcTagType4NdefFsm
Definition
qnfctagtype4ndeffsm_p.h:24
QNfcTagType4NdefFsm::provideResponse
Action provideResponse(const QByteArray &response) override
Definition
qnfctagtype4ndeffsm.cpp:158
QNfcTagType4NdefFsm::writeMessages
Action writeMessages(const QList< QNdefMessage > &messages) override
Definition
qnfctagtype4ndeffsm.cpp:125
QNfcTagType4NdefFsm::readMessages
Action readMessages() override
Definition
qnfctagtype4ndeffsm.cpp:108
QNfcTagType4NdefFsm::getMessage
QNdefMessage getMessage(Action &nextAction) override
Definition
qnfctagtype4ndeffsm.cpp:79
QNfcTagType4NdefFsm::detectNdefSupport
Action detectNdefSupport() override
Definition
qnfctagtype4ndeffsm.cpp:93
QNfcTagType4NdefFsm::getCommand
QByteArray getCommand(Action &nextAction) override
Definition
qnfctagtype4ndeffsm.cpp:19
QCommandApdu
Definition
qapduutils_p.h:39
QCommandApdu::Select
constexpr uint8_t Select
Definition
qapduutils_p.h:42
QCommandApdu::GetData
constexpr uint8_t GetData
Definition
qapduutils_p.h:44
QCommandApdu::build
QByteArray build(uint8_t cla, uint8_t ins, uint8_t p1, uint8_t p2, QByteArrayView data, uint16_t ne=0)
Definition
qapduutils.cpp:41
QCommandApdu::ReadBinary
constexpr uint8_t ReadBinary
Definition
qapduutils_p.h:43
QCommandApdu::UpdateBinary
constexpr uint8_t UpdateBinary
Definition
qapduutils_p.h:45
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qsequentialanimationgroup.cpp:47
qtconnectivity
src
nfc
qapduutils_p.h
Generated on
for Qt by
1.18.0