![]() |
Keyple Card Calypso C++ Library 2.2.5.6
Reference Terminal Reader API for C++
|
#include <AbstractSamCommand.h>


Public Member Functions | |
| const std::map< const int, const std::shared_ptr< StatusProperties > > & | getStatusTable () const override |
| AbstractSamCommand (const CalypsoSamCommand &commandRef, const int expectedResponseLength, const std::shared_ptr< CalypsoSamAdapter > calypsoSam) | |
| const std::shared_ptr< CalypsoSamAdapter > | getCalypsoSam () const |
| const CalypsoSamCommand & | getCommandRef () const override |
| const CalypsoApduCommandException | buildCommandException (const std::type_info &exceptionClass, const std::string &message) const final |
| const CalypsoApduCommandException | buildUnexpectedResponseLengthException (const std::string &message) const final |
| void | parseApduResponse (const std::shared_ptr< ApduResponseApi > apduResponse) override |
| void | parseApduResponse (const std::shared_ptr< ApduResponseApi > apduResponse, const std::shared_ptr< CalypsoSamAdapter > calypsoSam) |
Public Member Functions inherited from keyple::card::calypso::AbstractApduCommand | |
| AbstractApduCommand (const CardCommand &commandRef, const int expectedResponseLength) | |
| virtual void | addSubName (const std::string &subName) final |
| virtual const std::string & | getName () const final |
| virtual void | setExpectedResponseLength (const int expectedResponseLength) final |
| virtual void | setApduRequest (const std::shared_ptr< ApduRequestAdapter > apduRequest) final |
| virtual const std::shared_ptr< ApduRequestAdapter > | getApduRequest () const final |
| virtual const std::shared_ptr< ApduResponseApi > | getApduResponse () const final |
| virtual bool | isSuccessful () const final |
| virtual const std::string | getStatusInformation () const final |
Static Public Attributes | |
| static const std::map< const int, const std::shared_ptr< StatusProperties > > | STATUS_TABLE = initStatusTable() |
Static Public Attributes inherited from keyple::card::calypso::AbstractApduCommand | |
| static const std::map< const int, const std::shared_ptr< StatusProperties > > | STATUS_TABLE |
(package-private)
Superclass for all SAM command.
Definition at line 35 of file AbstractSamCommand.h.
| keyple::card::calypso::AbstractSamCommand::AbstractSamCommand | ( | const CalypsoSamCommand & | commandRef, |
| const int | expectedResponseLength, | ||
| const std::shared_ptr< CalypsoSamAdapter > | calypsoSam | ||
| ) |
(package-private)
Constructor dedicated for the building of referenced Calypso commands
| commandRef | A command reference from the Calypso command table. |
| expectedResponseLength | The expected response length or -1 if not specified. |
| calypsoSam | The Calypso SAM (it may be null if the SAM selection has not yet been made). |
Definition at line 34 of file AbstractSamCommand.cpp.
|
finalvirtual |
(package-private)
Builds a specific APDU command exception.
| message | The message. |
Implements keyple::card::calypso::AbstractApduCommand.
Definition at line 49 of file AbstractSamCommand.cpp.
|
finalvirtual |
(package-private)
Builds a specific APDU command exception for the case of an unexpected response length.
| message | The message. |
Implements keyple::card::calypso::AbstractApduCommand.
Definition at line 74 of file AbstractSamCommand.cpp.
| const std::shared_ptr< CalypsoSamAdapter > keyple::card::calypso::AbstractSamCommand::getCalypsoSam | ( | ) | const |
(package-private)
Returns the Calypso SAM.
Definition at line 39 of file AbstractSamCommand.cpp.
|
overridevirtual |
(package-private)
Gets CardCommand the current command identification
Reimplemented from keyple::card::calypso::AbstractApduCommand.
Definition at line 44 of file AbstractSamCommand.cpp.
|
overridevirtual |
(package-private)
Returns the internal status table
Reimplemented from keyple::card::calypso::AbstractApduCommand.
Reimplemented in keyple::card::calypso::CmdSamCardCipherPin, keyple::card::calypso::CmdSamCardGenerateKey, keyple::card::calypso::CmdSamDataCipher, keyple::card::calypso::CmdSamDigestAuthenticate, keyple::card::calypso::CmdSamDigestClose, keyple::card::calypso::CmdSamDigestInit, keyple::card::calypso::CmdSamDigestUpdate, keyple::card::calypso::CmdSamDigestUpdateMultiple, keyple::card::calypso::CmdSamGetChallenge, keyple::card::calypso::CmdSamGiveRandom, keyple::card::calypso::CmdSamPsoComputeSignature, keyple::card::calypso::CmdSamPsoVerifySignature, keyple::card::calypso::CmdSamReadCeilings, keyple::card::calypso::CmdSamReadEventCounter, keyple::card::calypso::CmdSamReadKeyParameters, keyple::card::calypso::CmdSamSelectDiversifier, keyple::card::calypso::CmdSamSvCheck, keyple::card::calypso::CmdSamSvPrepareDebitOrUndebit, keyple::card::calypso::CmdSamSvPrepareLoad, keyple::card::calypso::CmdSamUnlock, and keyple::card::calypso::CmdSamWriteKey.
Definition at line 112 of file AbstractSamCommand.cpp.
|
overridevirtual |
(package-private)
Parses the response ApduResponseApi and check the status word.
| apduResponse | The APDU response. |
| CalypsoApduCommandException | if status is not successful or if the length of the response is not equal to the LE field in the request. |
Reimplemented from keyple::card::calypso::AbstractApduCommand.
Reimplemented in keyple::card::calypso::CmdSamDataCipher, keyple::card::calypso::CmdSamPsoComputeSignature, keyple::card::calypso::CmdSamPsoVerifySignature, keyple::card::calypso::CmdSamReadCeilings, and keyple::card::calypso::CmdSamReadEventCounter.
Definition at line 83 of file AbstractSamCommand.cpp.
| void keyple::card::calypso::AbstractSamCommand::parseApduResponse | ( | const std::shared_ptr< ApduResponseApi > | apduResponse, |
| const std::shared_ptr< CalypsoSamAdapter > | calypsoSam | ||
| ) |
(package-private)
Sets the Calypso SAM and invoke the parseApduResponse(ApduResponseApi) method.
Definition at line 117 of file AbstractSamCommand.cpp.
|
static |
(package-private)
Default SAM product type.
Definition at line 43 of file AbstractSamCommand.h.