public final class SvReloadCmdBuild extends AbstractPoCommandBuilder<SvReloadRespPars>
| Constructor and Description |
|---|
SvReloadCmdBuild(PoClass poClass,
PoRevision poRevision,
int amount,
byte kvc,
byte[] date,
byte[] time,
byte[] free)
Instantiates a new SvReloadCmdBuild.
|
| Modifier and Type | Method and Description |
|---|---|
SvReloadRespPars |
createResponseParser(org.eclipse.keyple.core.card.message.ApduResponse apduResponse)
Create the response parser.
|
void |
finalizeBuilder(byte[] reloadComplementaryData)
Complete the construction of the APDU to be sent to the PO with the elements received from the
SAM:
|
byte[] |
getSvReloadData()
Gets the SV Reload part of the data to include in the SAM SV Prepare Load command
|
boolean |
isSessionBufferUsed()
Indicates if the session buffer is used when executing this command.
|
getCommandRefsetApduRequestpublic SvReloadCmdBuild(PoClass poClass, PoRevision poRevision, int amount, byte kvc, byte[] date, byte[] time, byte[] free)
The process is carried out in two steps: first to check and store the PO and application data, then to create the final APDU with the data from the SAM (see finalizeBuilder).
poClass - the PO classpoRevision - the PO revisionamount - amount to debit (signed integer from -8388608 to 8388607)kvc - debit key KVC (not checked by the PO)date - debit date (not checked by the PO)time - debit time (not checked by the PO)free - 2 free bytes stored in the log but not processed by the POjava.lang.IllegalArgumentException - - if the command is inconsistentpublic void finalizeBuilder(byte[] reloadComplementaryData)
4-byte SAM id
3-byte challenge
3-byte transaction number
5 or 10 byte signature (hi part)
reloadComplementaryData - the sam id and the data out from the SvPrepareReload SAM commandpublic byte[] getSvReloadData()
public SvReloadRespPars createResponseParser(org.eclipse.keyple.core.card.message.ApduResponse apduResponse)
A check is made to see if the object has been finalized. If not, an exception IllegalStateException is thrown.
createResponseParser in class AbstractPoCommandBuilder<SvReloadRespPars>apduResponse - the response data from the the cardSvReloadRespPars objectpublic boolean isSessionBufferUsed()
Allows the management of the overflow of this buffer.
This command modified the contents of the PO and therefore uses the session buffer.
isSessionBufferUsed in class AbstractPoCommandBuilder<SvReloadRespPars>