Keyple Card Calypso C++ Library 2.1.0
Reference Terminal Reader API for C++
CmdCardAppendRecord.h
Go to the documentation of this file.
1/**************************************************************************************************
2 * Copyright (c) 2021 Calypso Networks Association https://calypsonet.org/ *
3 * *
4 * See the NOTICE file(s) distributed with this work for additional information regarding *
5 * copyright ownership. *
6 * *
7 * This program and the accompanying materials are made available under the terms of the Eclipse *
8 * Public License 2.0 which is available at http://www.eclipse.org/legal/epl-2.0 *
9 * *
10 * SPDX-License-Identifier: EPL-2.0 *
11 **************************************************************************************************/
12
13#pragma once
14
15#include <cstdint>
16#include <map>
17#include <memory>
18#include <vector>
19
20/* Keyple Card Calypso */
21#include "AbstractApduCommand.h"
22#include "AbstractCardCommand.h"
23#include "CalypsoCardClass.h"
24
25/* Keyple Core Util */
26#include "LoggerFactory.h"
27
28namespace keyple {
29namespace card {
30namespace calypso {
31
32using namespace keyple::core::util::cpp;
33
35
43public:
54 CmdCardAppendRecord(const CalypsoCardClass calypsoCardClass,
55 const uint8_t sfi,
56 const std::vector<uint8_t>& newRecordData);
57
64 bool isSessionBufferUsed() const override;
65
72 uint8_t getSfi() const;
73
80 const std::vector<uint8_t>& getData() const;
81
87 const std::map<const int, const std::shared_ptr<StatusProperties>>& getStatusTable() const
88 override;
89
90private:
94 const std::unique_ptr<Logger> mLogger =
95 LoggerFactory::getLogger(typeid(CmdCardAppendRecord));
96
100 static const std::map<const int, const std::shared_ptr<StatusProperties>> STATUS_TABLE;
101
105 static const CalypsoCardCommand mCommand;
106
110 const uint8_t mSfi;
111
115 const std::vector<uint8_t> mData;
116
120 static const std::map<const int, const std::shared_ptr<StatusProperties>> initStatusTable();
121};
122
123}
124}
125}
CmdCardAppendRecord(const CalypsoCardClass calypsoCardClass, const uint8_t sfi, const std::vector< uint8_t > &newRecordData)
const std::vector< uint8_t > & getData() const
const std::map< const int, const std::shared_ptr< StatusProperties > > & getStatusTable() const override
AbstractApduCommand::StatusProperties StatusProperties