Package com.six.timapi
Class TransactionResponse
- java.lang.Object
-
- com.six.timapi.TransactionResponse
-
public class TransactionResponse extends Object
Contains the result of a transaction finished after callingTerminal.transaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)orTerminal.transactionAsync(com.six.timapi.constants.TransactionType, com.six.timapi.Amount). Immutable class.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classTransactionResponse.ActionAction.
-
Constructor Summary
Constructors Constructor Description TransactionResponse(TransactionType transactionType, Amount amount, Amount amountOther, Amount amountDue, AmountDcc amountDcc, Amount amountSaldo, TransactionInformation transactionInformation, String dccDisclaimer, CardData cardData, PrintData printData, Amount amountTip, Map<Long,String> additionalInfo, Basket basket, Amount amountLoyaltyCashback, Amount amountSurcharge)Create transaction response.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description IntegercardCountryCode()Card country code if present.Map<Long,String>getAdditionalInfo()Additional information list.AmountgetAmount()Amount authorized by the transaction.AmountDccgetAmountDcc()DCC amount authorized by the transaction if present.AmountgetAmountDue()Due amount in the transaction.AmountgetAmountOther()Amount other authorized by the transaction.AmountgetAmountSaldo()Saldo amount if present.AmountgetAmountSurcharge()Surcharge amount or null;AmountgetAmountTip()Tip amount.BasketgetBasket()Petrol: Basket.CardDatagetCardData()Information about payment card used by the cardholder if present.StringgetDccDisclaimer()Disclaimer sent by host.AmountgetLoyaltyCashbackAmount()Loyalty cashback amounr.PrintDatagetPrintData()Print information for merchant and cardholder receipts.AmountgetTipAmount()Deprecated.UsegetAmountTip().TransactionInformationgetTransactionInformation()Information about completed transaction.TransactionTypegetTransactionType()Transaction type.booleanisDomestic()Determines if transaction has been domestic.TransactionResponse.ActionneedsAction()Transaction requires an action.IntegerterminalCountryCode()Terminal country code if present.StringtoString()String representation for debugging purpose.booleanwasDcc()Transaction has been using DCC.booleanwasPartialApproval()Transaction has been partially approved.booleanwasTip()Transaction has been using TIP.
-
-
-
Constructor Detail
-
TransactionResponse
public TransactionResponse(TransactionType transactionType, Amount amount, Amount amountOther, Amount amountDue, AmountDcc amountDcc, Amount amountSaldo, TransactionInformation transactionInformation, String dccDisclaimer, CardData cardData, PrintData printData, Amount amountTip, Map<Long,String> additionalInfo, Basket basket, Amount amountLoyaltyCashback, Amount amountSurcharge)
Create transaction response.
-
-
Method Detail
-
getTransactionType
public TransactionType getTransactionType()
Transaction type.
-
getAmount
public Amount getAmount()
Amount authorized by the transaction.
-
getAmountOther
public Amount getAmountOther()
Amount other authorized by the transaction.
-
getAmountDue
public Amount getAmountDue()
Due amount in the transaction.
-
getAmountDcc
public AmountDcc getAmountDcc()
DCC amount authorized by the transaction if present.
-
getAmountSaldo
public Amount getAmountSaldo()
Saldo amount if present.
-
getTransactionInformation
public TransactionInformation getTransactionInformation()
Information about completed transaction.
-
getDccDisclaimer
public String getDccDisclaimer()
Disclaimer sent by host.
-
getCardData
public CardData getCardData()
Information about payment card used by the cardholder if present.
-
getPrintData
public PrintData getPrintData()
Print information for merchant and cardholder receipts.
-
getAmountTip
public Amount getAmountTip()
Tip amount. This parameter is only used ifGuides.GASTROis enabled.
-
getTipAmount
public Amount getTipAmount()
Deprecated.UsegetAmountTip().
-
getBasket
public Basket getBasket()
Petrol: Basket.
-
getLoyaltyCashbackAmount
public Amount getLoyaltyCashbackAmount()
Loyalty cashback amounr.
-
getAmountSurcharge
public Amount getAmountSurcharge()
Surcharge amount or null;
-
wasDcc
public boolean wasDcc()
Transaction has been using DCC.
-
wasTip
public boolean wasTip()
Transaction has been using TIP.
-
needsAction
public TransactionResponse.Action needsAction()
Transaction requires an action.
-
wasPartialApproval
public boolean wasPartialApproval()
Transaction has been partially approved.
-
cardCountryCode
public Integer cardCountryCode()
Card country code if present.
-
terminalCountryCode
public Integer terminalCountryCode()
Terminal country code if present.
-
isDomestic
public boolean isDomestic()
Determines if transaction has been domestic. Returns true if card country code and terminal country code are both set and are equal.
-
-