Class Terminal
- java.lang.Object
-
- com.six.timapi.Terminal
-
public class Terminal extends Object
Terminal base implementation. Create instance of TerminalApi to connect to payment terminal.
Most simple usage is using synchronous methods like this example:
// Create settings with Terminal-ID of terminal to connect to com.six.TerminalSettings settings = new com.six.TerminalSettings(); settings.setTerminalId("12345678"); // Create terminal com.six.Terminal terminal = new com.six.Terminal(settings); // Run transaction terminal.transaction(com.six.constants.TransactionType.PURCHASE, new com.six.Amount(8.5, com.six.constants.Currency.CHF)); // Disconnect from terminal and clean up properly terminal.dispose();
The above example blocks until the transaction finishes. To create a responsive application use asynchronous methods like this example:
// Asynchronous listener handling terminal events. class TerminalHandler extends com.six.DefaultTerminalListener { @Override public void transactionCompleted(com.six.TimEvent event, final com.six.TransactionResponse data) { javax.swing.SwingUtilities.invokeLater(new Runnable() { @Override public void run() { // handle transaction finished using data } }); } } // Create settings with Terminal-ID of terminal to connect to com.six.TerminalSettings settings = new com.six.TerminalSettings(); settings.setTerminalId("12345678"); // Create terminal com.six.Terminal terminal = new com.six.Terminal(settings); // Add listener to handle events terminal.addListener(new TerminalHandler()); // Run transaction terminal.transactionAsync(com.six.constants.TransactionType.PURCHASE, new com.six.Amount(8.5, com.six.constants.Currency.CHF)); // Once the transaction completes TerminalHandler.transactionCompleted will be called
-
-
Field Summary
Fields Modifier and Type Field Description static String
COMM_DRIVER_TCPIP
TCP/IP communication driver identifier.static String
LOGGER_NAME
Logging target matching all terminal instances.
-
Constructor Summary
Constructors Constructor Description Terminal(TerminalSettings settings)
Create terminal using configuration.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ActivateResponse
activate()
Opens a user shift.void
activateAsync()
Opens a user shift.void
activateServiceMenu()
Activate service menu.void
activateServiceMenuAsync()
Activate service menu.void
addEcrData(EcrInfo ecrInfo)
Add ECR data replacing existing one if present.void
addListener(TerminalListener listener)
Register listener.void
amtAdjustment(Amount amount)
The AmtAjustment-function is used as a notification to dynamically adjust the transaction amount of an already running transaction.void
amtAdjustment(Amount amount, AmountDiscount amountDiscount, List<LoyaltyCoupon> loyaltyCouponList, List<LoyaltyInformation> loyaltyInformationList)
Dynamically adjusts the transaction amount of an already running transaction.void
applicationInformation()
Requests the list of brands available on the terminal.void
applicationInformationAsync()
Requests the list of brands available on the terminal.BalanceResponse
balance()
Forces the EFT Terminal to transmit all transactions to the host system as well to do the daily closing.void
balanceAsync()
Forces the EFT Terminal to transmit all transactions to the host system as well to do the daily closing.BalanceInquiryResponse
balanceInquiry()
Get information about the current account balance of the inserted card.void
balanceInquiryAsync()
Get information about the current account balance of the inserted card.void
cancel()
Aborts an open asynchronous Financial Transaction or Non-Financial Transaction request, except for acommit()
orrollbackAsync()
request, which cannot be cancelled.void
cancel(boolean silent, boolean retainCard)
Aborts an open asynchronous Financial Transaction or Non-Financial Transaction request, except for acommit()
orrollbackAsync()
request, which cannot be cancelled.boolean
canDcc()
Returns true if at least one payment protocol and the terminal configuration offer DCC i.e.boolean
canDeclinedReceipts()
Support for "Declined Receipts" in at least one payment protocol.boolean
canMultiAccountSelection()
Support for multiple account selection.void
changeLanguageForRequest(String language)
Change the cardholder language for the duration of the current process / open request.void
changeSettings(Map<SettingType,String> settings)
Changes configuration parameters of the EFT Terminal.void
changeSettingsAsync(Map<SettingType,String> settings)
Changes configuration parameters of the EFT Terminal.ClientIdentificationResponse
clientIdentification()
Starts an EFT Client Identification.void
clientIdentificationAsync()
Starts an EFT Client Identification.void
closeDialogMode()
Close dialog mode on the terminal.void
closeDialogModeAsync()
Close dialog mode on the terminal.void
closeMaintenanceWindow()
Closes the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR.void
closeMaintenanceWindowAsync()
Closes the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR.void
closeReader()
Close the shutter of the card reader.void
closeReaderAsync()
Close the shutter of the card reader.void
commit()
Performs Commit-operation after a successful Transaction call.PrintData
commit(Amount amount)
Performs Commit-operation after a successful Transaction call.void
commitAsync()
Performs Commit-operation after a successful call totransaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
ortransactionAsync(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
.void
commitAsync(Amount amount)
Performs Commit-operation after a successful call totransaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
ortransactionAsync(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
.void
connect()
Initiates a connection to the EFT Terminal.void
connectAsync()
Initiates a connection to the EFT Terminal.Counters
counterRequest(CounterType type)
Get counter information's from the EFT Terminal.void
counterRequestAsync(CounterType type)
Get counter information's from the EFT Terminal.PrintData
dccRates()
Requests DCC rates from the EFT Terminal.void
dccRatesAsync()
Requests DCC rates from the EFT Terminal.DeactivateResponse
deactivate()
Closes a user shift.void
deactivateAsync()
Closes a user shift.void
deviceMaintenance(MaintenanceType type)
The DeviceMaintenance-function starts various maintenance processes on the EFT.void
deviceMaintenanceAsync(MaintenanceType type)
The DeviceMaintenance-function starts various maintenance processes on the EFT.void
disconnect()
Interrupts the connection to the EFT Terminal.void
disconnectAsync()
Interrupts the connection to the EFT Terminal.void
dispose()
Dispose of terminal.void
ejectCard()
Eject a card from the card reader.void
ejectCardAsync()
Eject a card from the card reader.VasCheckoutInformation
finishCheckout()
This function is used to finish a previously started checkout process with StartCheckout and to retrieve consumer loyalty data from the terminal that has been collected during this checkout process.void
finishCheckoutAsync()
This function is used to finish a previously started checkout process with StartCheckout and to retrieve consumer loyalty data from the terminal that has been collected during this checkout process.int
getActSeqCounter()
Activation sequence counter.EnumSet<ThirdPartyApps>
getAllowedThirdPartyApps()
Allowed Third Party Apps.List<Brands>
getBrands()
Get brands or null if not retrieved yet.ConfigData
getConfigData()
Get configuration data or null if not retrieved yet.Map<CustomerDataType,String>
getCustomerData()
Customer data.List<EcrInfo>
getEcrData()
ECR Data.Features
getFeatures()
Get features or null if not retrieved yet.AdditionalInfoItem
getItemTextcode(Long itemTextcode)
Convert item text code to AdditionalInfoItem value.String
getItemTextcodeDescription(AdditionalInfoItem item)
Get text description of AdditionalInfoItem.byte[]
getLicense()
Deprecated.Functionality removed.String
getLoggerName()
Logging target matching all this terminal instance.List<MerchantOption>
getMerchantOptions()
Merchant options.String
getPosId()
POS identifier.List<PrintOption>
getPrintOptions()
Print options.ReceiptFormatter
getReceiptFormatter()
Receipt formatter.TerminalSettingsImmutable
getSettings()
Terminal settings.String
getTerminalId()
Terminal identifier of connected terminal.TerminalStatus
getTerminalStatus()
Get terminal status.static String
getTimApiBuildDate()
Tim Api Build date.static String
getTimApiVersion()
Tim Api Build Version.TransactionData
getTransactionData()
Transaction data to use for transaction requests unless overwritten intransaction(TransactionType, TransactionRequest)
ortransactionAsync(TransactionType, TransactionRequest)
.int
getUserId()
User identifier.HardwareInformationResponse
hardwareInformation()
Get hardware information from the EFT Terminal.void
hardwareInformationAsync()
Get hardware information from the EFT Terminal.boolean
hasSwUpdate()
Software update is available.void
holdCommit()
Extends the Commit timeout if the terminal needs additional time before the Commit shall be performed.CardData
initTransaction(boolean displayAmount, Amount amount)
Initialize a transaction knowing the amount or the card type.CardData
initTransaction(boolean displayAmount, Amount amount, FunctionHint functionHint)
void
initTransactionAsync(boolean displayAmount, Amount amount)
Initialize a transaction knowing the amount or the card type.void
initTransactionAsync(boolean displayAmount, Amount amount, FunctionHint functionHint)
InitTransactionResponse
initTransactionWithDialog(Amount amount, FunctionHint functionHint, ShowDialogRequest dialog)
void
initTransactionWithDialogAsync(Amount amount, FunctionHint functionHint, ShowDialogRequest dialog)
void
login()
Activate a communication session between the ECR and the terminal.void
loginAsync()
Activate a communication session between the ECR and the terminal.void
logout()
Terminates an active communication session between the ECR and the terminal.void
logoutAsync()
Terminates an active communication session between the ECR and the terminal.CardData
loyaltyData(LoyaltyFunctionType functionType, String dataType, byte[] data, boolean retainCard)
This function is used to query and configure loyalty information.void
loyaltyDataAsync(LoyaltyFunctionType functionType, String dataType, byte[] data, boolean retainCard)
This function is used to query and configure loyalty information.MobileTopupData
mobileTopup(MobileTopupType type, MobileTopupValue value)
MobileTopupData
mobileTopup(MobileTopupType type, String issuerName, Amount amount)
Mobile Topup transaction.void
mobileTopupAsync(MobileTopupType type, MobileTopupValue value)
void
mobileTopupAsync(MobileTopupType type, String issuerName, Amount amount)
Mobile Topup transaction.List<MobileTopupValue>
mobileTopupIssuerInfo()
Request Mobile Topup Issuer information.void
mobileTopupIssuerInfoAsync()
Request Mobile Topup Issuer information.void
openDialogMode()
Open dialog mode on the terminal.void
openDialogMode(boolean silent)
Open dialog mode on the terminal.void
openDialogModeAsync()
Open dialog mode on the terminal.void
openDialogModeAsync(boolean silent)
Open dialog mode on the terminal.void
openMaintenanceWindow()
Opens the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR.void
openMaintenanceWindowAsync()
Opens the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR.void
openReader()
Open the shutter of the card reader.void
openReaderAsync()
Open the shutter of the card reader.void
printOnTerminal(String ticketData)
The PrintOnTerminal-function is used to send a freetext preformatted ticket from ECR to terminal.void
printOnTerminalAsync(String ticketData)
The PrintOnTerminal-function is used to send a freetext preformatted ticket from ECR to terminal.List<LoyaltyItem>
provideLoyaltyBasket(List<LoyaltyItem> basket)
This function is used to provide the terminal with a LoyaltyBasket if the corresponding loyalty scheme requires it.void
provideLoyaltyBasketAsync(List<LoyaltyItem> basket)
This function is used to provide the terminal with a LoyaltyBasket if the corresponding loyalty scheme requires it.VasResult
provideVasResult(VasResult result)
This function is used to provide several VAS related results to the terminal, which will then send it to the corresponding VAS provider.void
provideVasResultAsync(VasResult result)
This function is used to provide several VAS related results to the terminal, which will then send it to the corresponding VAS provider.void
reboot()
Force the EFT Terminal to reboot.void
rebootAsync()
Force the EFT Terminal to reboot.ReceiptRequestResponse
receiptRequest(ReceiptRequestType type)
Receive the latest receipt or a list of silent receipts.void
receiptRequestAsync(ReceiptRequestType type)
Receive the latest receipt or a list of silent receipts.ReconciliationResponse
reconciliation()
Force the EFT Terminal to transmit all financial transactions to the host system.void
reconciliationAsync()
Force the EFT Terminal to transmit all financial transactions to the host system.PrintData
reconfig()
Force the EFT Terminal to get the configuration from the service center.void
reconfigAsync()
Force the EFT Terminal to get the configuration from the service center.void
removeListener(TerminalListener listener)
Unregister listener.String
requestAlias(String sixTransRef)
The RequestAlias-function is used to request a Saferpay Alias for Alias-based transactions.void
requestAliasAsync(String sixTransRef)
The RequestAlias-function is used to request a Saferpay Alias for Alias-based transactions.PrintData
rollback()
Prevents a transaction from being committed to the transaction log and generates a technical reversal of the authorization.void
rollbackAsync()
Prevents a transaction from being committed to the transaction log and generates a technical reversal of the authorization.void
screenshot()
Send notification to request EFT make a screenshot.List<CommandResponse>
sendCardCommand(List<CommandRequest> requests)
This function is used for a direct communication with the inserted card using APDUs.void
sendCardCommandAsync(List<CommandRequest> requests)
This function is used for a direct communication with the inserted card using APDUs.void
setAllowedThirdPartyApps(EnumSet<ThirdPartyApps> allowedApps)
Set Allowed Third Party Apps.void
setCustomerData(Map<CustomerDataType,String> customerData)
Set customer data.void
setEcrData(List<EcrInfo> ecrData)
Set ECR data.void
setMerchantOptions(List<MerchantOption> merchantOptions)
Set merchant options.void
setPosId(String posId)
Set POS identifier.void
setPrintOptions(List<PrintOption> printOptions)
Set print options.void
setReceiptFormatter(ReceiptFormatter formatter)
Set receipt formatter.void
setTransactionData(TransactionData transactionData)
Transaction data to use for transaction requests unless overwritten intransaction(TransactionType, TransactionRequest)
ortransactionAsync(TransactionType, TransactionRequest)
.void
setUserId(int userId)
Set user identifier.ShowDialogResponse
showDialog(ShowDialogRequest request)
Show dialog on the terminal.void
showDialogAsync(ShowDialogRequest request)
Show dialog on the terminal.ShowSignatureCaptureResponse
showSignatureCapture(ShowSignatureCaptureRequest request)
Show signature capture on the terminal.void
showSignatureCaptureAsync(ShowSignatureCaptureRequest request)
Show signature capture on the terminal.UpdateStatus
softwareUpdate()
Force the EFT Terminal to start a Software Update.void
softwareUpdateAsync()
Force the EFT Terminal to start a Software Update.void
startCheckout()
This function is used to start a Checkout process at the POS to collect card and/or cardholder loyalty information before a transaction is started.void
startCheckoutAsync()
This function is used to start a Checkout process at the POS to collect card and/or cardholder loyalty information before a transaction is started.SystemInformationResponse
systemInformation()
Request system information from the EFT Terminal.void
systemInformationAsync()
Request system information from the EFT Terminal.void
thirdPartyAppData(ThirdPartyAppPayload payload)
Send third party app data notification to EFT.String
toString()
String representation for debugging purpose.TransactionResponse
transaction(TransactionType type, Amount amount)
Starts an EFT Terminal Transaction.TransactionResponse
transaction(TransactionType type, TransactionRequest request)
Starts an EFT Terminal Transaction.void
transactionAsync(TransactionType type, Amount amount)
Starts an EFT Terminal Transaction.void
transactionAsync(TransactionType type, TransactionRequest request)
Starts an EFT Terminal Transaction.TransactionResponse
transactionCashback(TransactionType type, Amount amount, Amount amountOther)
Starts an EFT Terminal Transaction with Cashback amount.void
transactionCashbackAsync(TransactionType type, Amount amount, Amount amountOther)
Starts an EFT Terminal Transaction.TransactionInfoRequestResponse
transactionInfoRequest()
Receive the latest transaction information.void
transactionInfoRequestAsync()
Receive the latest transaction information.TransactionResponse
transactionTip(TransactionType type, Amount amount, Amount tipAmount)
Starts an EFT Terminal Transaction with Tip amount.void
transactionTipAsync(TransactionType type, Amount amount, Amount tipAmount)
Starts an EFT Terminal Transaction.
-
-
-
Field Detail
-
LOGGER_NAME
public static final String LOGGER_NAME
Logging target matching all terminal instances.
-
COMM_DRIVER_TCPIP
public static final String COMM_DRIVER_TCPIP
TCP/IP communication driver identifier.- See Also:
- Constant Field Values
-
-
Constructor Detail
-
Terminal
public Terminal(TerminalSettings settings)
Create terminal using configuration.
-
-
Method Detail
-
getLoggerName
public String getLoggerName()
Logging target matching all this terminal instance.
-
dispose
public void dispose()
Dispose of terminal.
-
getTimApiVersion
public static final String getTimApiVersion()
Tim Api Build Version.
-
getTimApiBuildDate
public static final String getTimApiBuildDate()
Tim Api Build date.
-
getSettings
public TerminalSettingsImmutable getSettings()
Terminal settings.
-
getTerminalId
public String getTerminalId()
Terminal identifier of connected terminal. Returns empty string if the terminal identifier is not known. The terminal identifier is available after logging in to the terminal. The terminal identifier obtained from the terminal is potentially different from the terminal identifier set in theTerminalSettings
. This is especially true ifConnectionMode.ON_FIX_IP
is used.
-
getLicense
public byte[] getLicense()
Deprecated.Functionality removed.Supported licensed features as 8 bytes hex encoded bitmap.
-
getPosId
public String getPosId()
POS identifier.
-
setPosId
public void setPosId(String posId)
Set POS identifier.
-
getUserId
public int getUserId()
User identifier.
-
setUserId
public void setUserId(int userId)
Set user identifier.
-
getAllowedThirdPartyApps
public EnumSet<ThirdPartyApps> getAllowedThirdPartyApps()
Allowed Third Party Apps.
-
setAllowedThirdPartyApps
public void setAllowedThirdPartyApps(EnumSet<ThirdPartyApps> allowedApps)
Set Allowed Third Party Apps.
-
addEcrData
public void addEcrData(EcrInfo ecrInfo)
Add ECR data replacing existing one if present. To remove elements usesetEcrData(java.util.List<com.six.timapi.EcrInfo>)
instead.
-
getPrintOptions
public List<PrintOption> getPrintOptions()
Print options.
-
setPrintOptions
public void setPrintOptions(List<PrintOption> printOptions)
Set print options.
-
getMerchantOptions
public List<MerchantOption> getMerchantOptions()
Merchant options.
-
setMerchantOptions
public void setMerchantOptions(List<MerchantOption> merchantOptions)
Set merchant options.
-
getCustomerData
public Map<CustomerDataType,String> getCustomerData()
Customer data.
-
setCustomerData
public void setCustomerData(Map<CustomerDataType,String> customerData)
Set customer data.
-
getTransactionData
public TransactionData getTransactionData()
Transaction data to use for transaction requests unless overwritten intransaction(TransactionType, TransactionRequest)
ortransactionAsync(TransactionType, TransactionRequest)
.
-
setTransactionData
public void setTransactionData(TransactionData transactionData)
Transaction data to use for transaction requests unless overwritten intransaction(TransactionType, TransactionRequest)
ortransactionAsync(TransactionType, TransactionRequest)
.
-
getReceiptFormatter
public ReceiptFormatter getReceiptFormatter()
Receipt formatter.
-
setReceiptFormatter
public void setReceiptFormatter(ReceiptFormatter formatter)
Set receipt formatter.
-
getTerminalStatus
public TerminalStatus getTerminalStatus()
Get terminal status.
-
getFeatures
public Features getFeatures()
Get features or null if not retrieved yet.
-
getActSeqCounter
public int getActSeqCounter()
Activation sequence counter.
-
getConfigData
public ConfigData getConfigData()
Get configuration data or null if not retrieved yet.
-
activate
public ActivateResponse activate() throws TimException
Opens a user shift. If the shift is already open, no error is returned.- Throws:
TimException
-
activateAsync
public void activateAsync() throws TimException
Opens a user shift. If the shift is already open, no error is returned. Asynchronous version ofactivate()
. Returns immediately and callsTerminalListener.activateCompleted(com.six.timapi.TimEvent, com.six.timapi.ActivateResponse)
on all notifiers once finished.- Throws:
TimException
-
applicationInformation
public void applicationInformation() throws TimException
Requests the list of brands available on the terminal.
Side-Effect: Updates Brands member with all brands available on the terminal. Use
getBrands()
to retrieve them.- Throws:
TimException
-
applicationInformationAsync
public void applicationInformationAsync() throws TimException
Requests the list of brands available on the terminal. Asynchronous version of
applicationInformation()
. Returns immediately and callsTerminalListener.applicationInformationCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Side-Effect: Updates Brands member with all brands available on the terminal. Use Terminal.getBrands() to retrieve them.
- Throws:
TimException
-
balance
public BalanceResponse balance() throws TimException
Forces the EFT Terminal to transmit all transactions to the host system as well to do the daily closing.- Throws:
TimException
-
balanceAsync
public void balanceAsync() throws TimException
Forces the EFT Terminal to transmit all transactions to the host system as well to do the daily closing. Asynchronous version ofbalance()
. Returns immediately and callsTerminalListener.balanceCompleted(com.six.timapi.TimEvent, com.six.timapi.BalanceResponse)
on all notifiers once finished.- Throws:
TimException
-
cancel
public void cancel() throws TimException
Aborts an open asynchronous Financial Transaction or Non-Financial Transaction request, except for a
commit()
orrollbackAsync()
request, which cannot be cancelled.Further information: A Cancel-request is a best effort request. The EFT Terminal can ignore the Cancel-request if the request in progress is in a state it can not be cancelled. A Cancel-request has no effect if there's no open request of a Financial Transaction or Non-financial Transaction. If the EFT Terminal cancels the request in progress an error response is send back for the cancelled request (see chapter Abort Purchase for an example). Cancel-requests can be send multiple times in an attempt to cancel a request in progress but should be spaced by a few seconds. Cancel-requests themselves are never acknowledged by the EFT Terminal.
The Transaction request can only be cancelled before a Commit has been performed. Also the underlying payment protocol can restrict this functionality.
- Throws:
TimException
-
cancel
public void cancel(boolean silent, boolean retainCard) throws TimException
Aborts an open asynchronous Financial Transaction or Non-Financial Transaction request, except for a
commit()
orrollbackAsync()
request, which cannot be cancelled.Further information: A Cancel-request is a best effort request. The EFT Terminal can ignore the Cancel-request if the request in progress is in a state it can not be cancelled. A Cancel-request has no effect if there's no open request of a Financial Transaction or Non-financial Transaction. If the EFT Terminal cancels the request in progress an error response is send back for the cancelled request (see chapter Abort Purchase for an example). Cancel-requests can be send multiple times in an attempt to cancel a request in progress but should be spaced by a few seconds. Cancel-requests themselves are never acknowledged by the EFT Terminal.
The Transaction request can only be cancelled before a Commit has been performed. Also the underlying payment protocol can restrict this functionality.
- Throws:
TimException
-
changeSettings
public void changeSettings(Map<SettingType,String> settings) throws TimException
Changes configuration parameters of the EFT Terminal.- Parameters:
settings
- Dictionary of values for settings types to change.- Throws:
TimException
-
changeSettingsAsync
public void changeSettingsAsync(Map<SettingType,String> settings) throws TimException
Changes configuration parameters of the EFT Terminal. Asynchronous version ofchangeSettings(java.util.Map<com.six.timapi.constants.SettingType, java.lang.String>)
. Returns immediately and callsTerminalListener.changeSettingsCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.- Parameters:
settings
- Dictionary of values for settings types to change.- Throws:
TimException
-
commit
public void commit() throws TimException
Performs Commit-operation after a successful Transaction call.- Throws:
TimException
-
commitAsync
public void commitAsync() throws TimException
Performs Commit-operation after a successful call totransaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
ortransactionAsync(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
. Asynchronous version ofcommit()
. Returns immediately and callsTerminalListener.commitCompleted(com.six.timapi.TimEvent, com.six.timapi.PrintData)
on all notifiers once finished.- Throws:
TimException
-
commit
public PrintData commit(Amount amount) throws TimException
Performs Commit-operation after a successful Transaction call.- Throws:
TimException
-
commitAsync
public void commitAsync(Amount amount) throws TimException
Performs Commit-operation after a successful call totransaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
ortransactionAsync(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
. Asynchronous version ofcommit()
. Returns immediately and callsTerminalListener.commitCompleted(com.six.timapi.TimEvent, com.six.timapi.PrintData)
on all notifiers once finished.- Throws:
TimException
-
connect
public void connect() throws TimException
Initiates a connection to the EFT Terminal. Calling theconnect()
is not needed normally, because all methods make first a connect, if not connected.- Throws:
TimException
-
connectAsync
public void connectAsync() throws TimException
Initiates a connection to the EFT Terminal. Calling theconnect()
is not needed normally, because all methods make first a connect, if not connected.- Throws:
TimException
-
counterRequest
public Counters counterRequest(CounterType type) throws TimException
Get counter information's from the EFT Terminal.- Parameters:
type
- type of counters to request.- Throws:
TimException
-
counterRequestAsync
public void counterRequestAsync(CounterType type) throws TimException
Get counter information's from the EFT Terminal. Asynchronous version ofcounterRequest(com.six.timapi.constants.CounterType)
. Returns immediately and callsTerminalListener.counterRequestCompleted(com.six.timapi.TimEvent, com.six.timapi.Counters)
on all notifiers once finished.- Throws:
TimException
-
deactivate
public DeactivateResponse deactivate() throws TimException
Closes a user shift. If the shift is already closed, no error is returned.- Throws:
TimException
-
deactivateAsync
public void deactivateAsync() throws TimException
Closes a user shift. If the shift is already closed, no error is returned. Asynchronous version ofdeactivate()
. Returns immediately and callsTerminalListener.deactivateCompleted(com.six.timapi.TimEvent, com.six.timapi.DeactivateResponse)
on all notifiers once finished.- Throws:
TimException
-
disconnect
public void disconnect() throws TimException
Interrupts the connection to the EFT Terminal.- Throws:
TimException
-
disconnectAsync
public void disconnectAsync() throws TimException
Interrupts the connection to the EFT Terminal.- Throws:
TimException
-
dccRates
public PrintData dccRates() throws TimException
Requests DCC rates from the EFT Terminal. The DCC rates are returned as receipt.- Throws:
TimException
-
dccRatesAsync
public void dccRatesAsync() throws TimException
Requests DCC rates from the EFT Terminal. The DCC rates are returned as receipt. Asynchronous version ofdccRates()
. Returns immediately and callsTerminalListener.dccRatesCompleted(com.six.timapi.TimEvent, com.six.timapi.PrintData)
on all notifiers once finished.- Throws:
TimException
-
hardwareInformation
public HardwareInformationResponse hardwareInformation() throws TimException
Get hardware information from the EFT Terminal.- Throws:
TimException
-
hardwareInformationAsync
public void hardwareInformationAsync() throws TimException
Get hardware information from the EFT Terminal. Asynchronous version ofhardwareInformation()
. Returns immediately and callsTerminalListener.hardwareInformationCompleted(com.six.timapi.TimEvent, com.six.timapi.HardwareInformationResponse)
on all notifiers once finished.- Throws:
TimException
-
initTransaction
public CardData initTransaction(boolean displayAmount, Amount amount) throws TimException
Initialize a transaction knowing the amount or the card type.- Throws:
TimException
-
initTransaction
public CardData initTransaction(boolean displayAmount, Amount amount, FunctionHint functionHint) throws TimException
- Throws:
TimException
-
initTransactionAsync
public void initTransactionAsync(boolean displayAmount, Amount amount) throws TimException
Initialize a transaction knowing the amount or the card type.- Throws:
TimException
-
initTransactionAsync
public void initTransactionAsync(boolean displayAmount, Amount amount, FunctionHint functionHint) throws TimException
- Throws:
TimException
-
initTransactionWithDialog
public InitTransactionResponse initTransactionWithDialog(Amount amount, FunctionHint functionHint, ShowDialogRequest dialog) throws TimException
- Throws:
TimException
-
initTransactionWithDialogAsync
public void initTransactionWithDialogAsync(Amount amount, FunctionHint functionHint, ShowDialogRequest dialog) throws TimException
- Throws:
TimException
-
login
public void login() throws TimException
Activate a communication session between the ECR and the terminal.
Note: Before calling set the print options, POS identifier and manufacturer flags set in the terminal instance.
Side-Effect: After completing the request updates the features, brands and terminal identifier in the terminal instance. Fetching these information can be disabled if Auto-FetchBrands is disabled in
TerminalSettings
.- Throws:
TimException
-
loginAsync
public void loginAsync() throws TimException
Activate a communication session between the ECR and the terminal. Asynchronous version of
login()
. Returns immediately and callsTerminalListener.loginCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: Before calling set the print options, POS identifier and manufacturer flags properties in the terminal instance.
Side-Effect: After completing the request updates the features, brands and terminal identifier is set in the terminal instance. Fetching these information can be disabled with Auto-FetchBrands in
TerminalSettings
.- Throws:
TimException
-
logout
public void logout() throws TimException
Terminates an active communication session between the ECR and the terminal.- Throws:
TimException
-
logoutAsync
public void logoutAsync() throws TimException
Terminates an active communication session between the ECR and the terminal. Asynchronous version oflogout()
. Returns immediately and callsTerminalListener.logoutCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.- Throws:
TimException
-
reboot
public void reboot() throws TimException
Force the EFT Terminal to reboot.- Throws:
TimException
-
rebootAsync
public void rebootAsync() throws TimException
Force the EFT Terminal to reboot. Asynchronous version ofreboot()
. Returns immediately and callsTerminalListener.rebootCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.- Throws:
TimException
-
reconciliation
public ReconciliationResponse reconciliation() throws TimException
Force the EFT Terminal to transmit all financial transactions to the host system.- Throws:
TimException
-
reconciliationAsync
public void reconciliationAsync() throws TimException
Force the EFT Terminal to transmit all financial transactions to the host system. Asynchronous version ofreconciliation()
. Returns immediately and callsTerminalListener.reconciliationCompleted(com.six.timapi.TimEvent, com.six.timapi.ReconciliationResponse)
on all notifiers once finished.- Throws:
TimException
-
receiptRequest
public ReceiptRequestResponse receiptRequest(ReceiptRequestType type) throws TimException
Receive the latest receipt or a list of silent receipts.- Parameters:
type
- Type of receipts to request from the EFT Terminal.- Throws:
TimException
-
receiptRequestAsync
public void receiptRequestAsync(ReceiptRequestType type) throws TimException
Receive the latest receipt or a list of silent receipts. Asynchronous version ofreceiptRequest(com.six.timapi.constants.ReceiptRequestType)
. Returns immediately and callsTerminalListener.receiptRequestCompleted(com.six.timapi.TimEvent, com.six.timapi.ReceiptRequestResponse)
on all notifiers once finished.- Throws:
TimException
-
transactionInfoRequest
public TransactionInfoRequestResponse transactionInfoRequest() throws TimException
Receive the latest transaction information.- Throws:
TimException
-
transactionInfoRequestAsync
public void transactionInfoRequestAsync() throws TimException
Receive the latest transaction information. Asynchronous version oftransactionInfoRequest()
. Returns immediately and callsTerminalListener.transactionInfoRequestCompleted(com.six.timapi.TimEvent, com.six.timapi.TransactionInfoRequestResponse)
on all notifiers once finished.- Throws:
TimException
-
reconfig
public PrintData reconfig() throws TimException
Force the EFT Terminal to get the configuration from the service center.- Throws:
TimException
-
reconfigAsync
public void reconfigAsync() throws TimException
Force the EFT Terminal to get the configuration from the service center. Asynchronous version ofreconfig()
. Returns immediately and callsTerminalListener.reconfigCompleted(com.six.timapi.TimEvent, com.six.timapi.PrintData)
on all notifiers once finished.- Throws:
TimException
-
rollback
public PrintData rollback() throws TimException
Prevents a transaction from being committed to the transaction log and generates a technical reversal of the authorization. For payment protocols supporting the function a declined receipt may be generated.- Throws:
TimException
-
rollbackAsync
public void rollbackAsync() throws TimException
Prevents a transaction from being committed to the transaction log and generates a technical reversal of the authorization. For payment protocols supporting the function a declined receipt may be generated. Asynchronous version ofrollback()
. Returns immediately and callsTerminalListener.rollbackCompleted(com.six.timapi.TimEvent, com.six.timapi.PrintData)
on all notifiers once finished.- Throws:
TimException
-
softwareUpdate
public UpdateStatus softwareUpdate() throws TimException
Force the EFT Terminal to start a Software Update.- Throws:
TimException
-
softwareUpdateAsync
public void softwareUpdateAsync() throws TimException
Force the EFT Terminal to start a Software Update.- Throws:
TimException
-
systemInformation
public SystemInformationResponse systemInformation() throws TimException
Request system information from the EFT Terminal.
Note: Set EcrData property before calling SystemInformation.
- Throws:
TimException
-
systemInformationAsync
public void systemInformationAsync() throws TimException
Request system information from the EFT Terminal. Asynchronous version of
systemInformation()
. Returns immediately and callsTerminalListener.systemInformationCompleted(com.six.timapi.TimEvent, com.six.timapi.SystemInformationResponse)
on all notifiers once finished.Note: Set EcrData property before calling SystemInformation.
- Throws:
TimException
-
transaction
public TransactionResponse transaction(TransactionType type, Amount amount) throws TimException
Starts an EFT Terminal Transaction.
Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.- Returns:
- Transaction response.
- Throws:
TimException
-
transaction
public TransactionResponse transaction(TransactionType type, TransactionRequest request) throws TimException
Starts an EFT Terminal Transaction.
Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
- Parameters:
type
- Financial Transaction Function.request
- Transaction parameters without using TransactionRequest property.- Returns:
- Transaction response.
- Throws:
TimException
-
transactionAsync
public void transactionAsync(TransactionType type, Amount amount) throws TimException
Starts an EFT Terminal Transaction. Asynchronous version of
transaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
. Returns immediately and callsTerminalListener.transactionCompleted(com.six.timapi.TimEvent, com.six.timapi.TransactionResponse)
on all notifiers once finished.Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.- Throws:
TimException
-
transactionAsync
public void transactionAsync(TransactionType type, TransactionRequest request) throws TimException
Starts an EFT Terminal Transaction.
Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
- Parameters:
type
- Financial Transaction Function.request
- Transaction parameters without using TransactionRequest property.- Throws:
TimException
-
transactionTip
public TransactionResponse transactionTip(TransactionType type, Amount amount, Amount tipAmount) throws TimException
Starts an EFT Terminal Transaction with Tip amount.
Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
Note: This method is only available if
Guides.GASTRO
is enabled.- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.tipAmount
- Proposed tip amount.- Throws:
TimException
-
transactionTipAsync
public void transactionTipAsync(TransactionType type, Amount amount, Amount tipAmount) throws TimException
Starts an EFT Terminal Transaction. Asynchronous version of
transaction(com.six.timapi.constants.TransactionType, com.six.timapi.Amount)
. Returns immediately and callsTerminalListener.transactionCompleted(com.six.timapi.TimEvent, com.six.timapi.TransactionResponse)
on all notifiers once finished.Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
Note: This method is only available if
Guides.GASTRO
is enabled.- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.tipAmount
- Proposed tip amount.- Throws:
TimException
-
transactionCashback
public TransactionResponse transactionCashback(TransactionType type, Amount amount, Amount amountOther) throws TimException
Starts an EFT Terminal Transaction with Cashback amount.
Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
Note: This method is only available if
Guides.ADVANCED_RETAIL
is enabled.- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.amountOther
- Cashback amount.- Throws:
TimException
-
transactionCashbackAsync
public void transactionCashbackAsync(TransactionType type, Amount amount, Amount amountOther) throws TimException
Starts an EFT Terminal Transaction. Asynchronous version of
transactionCashback(com.six.timapi.constants.TransactionType, com.six.timapi.Amount, com.six.timapi.Amount)
. Returns immediately and callsTerminalListener.transactionCompleted(com.six.timapi.TimEvent, com.six.timapi.TransactionResponse)
on all notifiers once finished.Note: The transaction parameters are taken from TransactionRequest terminal property since those do not change often if at all (default parameters).
Note: This method is only available if
Guides.ADVANCED_RETAIL
is enabled.- Parameters:
type
- Financial Transaction Function.amount
- Transaction amount.amountOther
- Cashback amount.- Throws:
TimException
-
clientIdentification
public ClientIdentificationResponse clientIdentification() throws TimException
Starts an EFT Client Identification. Note: This method is only available ifGuides.BANKING
is enabled.- Throws:
TimException
-
clientIdentificationAsync
public void clientIdentificationAsync() throws TimException
Starts an EFT Client Identification. Asynchronous version ofclientIdentification()
. Returns immediately and callsTerminalListener.clientIdentificationCompleted(com.six.timapi.TimEvent, com.six.timapi.ClientIdentificationResponse)
on all notifiers once finished. Note: This method is only available ifGuides.BANKING
is enabled.- Throws:
TimException
-
closeReader
public void closeReader() throws TimException
Close the shutter of the card reader.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
closeReaderAsync
public void closeReaderAsync() throws TimException
Close the shutter of the card reader.
Asynchronous version of
closeReader()
. Returns immediately and callsTerminalListener.closeReaderCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
openReader
public void openReader() throws TimException
Open the shutter of the card reader.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
openReaderAsync
public void openReaderAsync() throws TimException
Open the shutter of the card reader.
Asynchronous version of
openReader()
. Returns immediately and callsTerminalListener.openReaderCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
ejectCard
public void ejectCard() throws TimException
Eject a card from the card reader.
Note: This method is only available if
Guides.UNATTENDED
orGuides.ADVANCED_RETAIL
is enabled.- Throws:
TimException
-
ejectCardAsync
public void ejectCardAsync() throws TimException
Eject a card from the card reader.
Asynchronous version of
ejectCard()
. Returns immediately and callsTerminalListener.ejectCardCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
openMaintenanceWindow
public void openMaintenanceWindow() throws TimException
Opens the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR. The terminal shall respond immediately to the ECR request whether it is able to handle the request or not.
If the terminal is able to handle the request, the ECR is free itself to perform maintenance as well or it can monitor the terminal by reading the TerminalStatus notifications.
It is possible that the connection between ECR and EFT terminal is terminated due to one or multiple reboot processes.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
openMaintenanceWindowAsync
public void openMaintenanceWindowAsync() throws TimException
Opens the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR. The terminal shall respond immediately to the ECR request whether it is able to handle the request or not.
If the terminal is able to handle the request, the ECR is free itself to perform maintenance as well or it can monitor the terminal by reading the TerminalStatus notifications.
It is possible that the connection between ECR and EFT terminal is terminated due to one or multiple reboot processes.
Asynchronous version of
openMaintenanceWindow()
. Returns immediately and callsTerminalListener.openMaintenanceWindowCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
closeMaintenanceWindow
public void closeMaintenanceWindow() throws TimException
Closes the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR. The terminal shall respond immediately to the ECR request whether it is able to handle the request or not.
If the terminal is able to handle the request, the ECR is free itself to perform maintenance as well or it can monitor the terminal by reading the TerminalStatus notifications.
It is possible that the connection between ECR and EFT terminal is terminated due to one or multiple reboot processes.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
closeMaintenanceWindowAsync
public void closeMaintenanceWindowAsync() throws TimException
Closes the maintenance window to the terminal so it can perform collected maintenance requests on its own, without interaction with the ECR. The terminal shall respond immediately to the ECR request whether it is able to handle the request or not.
If the terminal is able to handle the request, the ECR is free itself to perform maintenance as well or it can monitor the terminal by reading the TerminalStatus notifications.
It is possible that the connection between ECR and EFT terminal is terminated due to one or multiple reboot processes.
Asynchronous version of
closeMaintenanceWindow()
. Returns immediately and callsTerminalListener.closeMaintenanceWindowCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
holdCommit
public void holdCommit() throws TimException
Extends the Commit timeout if the terminal needs additional time before the Commit shall be performed. An example could be on a public transport vending machine: if the machine is printing multiple tickets and this printing action would extend the commit timeout, a HoldCommit notification shall be sent to extend the Commit timeout as well. If the printing action fails after some tickets a partial commit can be performed.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
activateServiceMenu
public void activateServiceMenu() throws TimException
Activate service menu.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
activateServiceMenuAsync
public void activateServiceMenuAsync() throws TimException
Activate service menu.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
amtAdjustment
public void amtAdjustment(Amount amount) throws TimException
The AmtAjustment-function is used as a notification to dynamically adjust the transaction amount of an already running transaction. This is a "best effort" function and will be processed as long as the underlaying payment protocol supports it. The amount transmitted in the notification is the new total amount. The EFT does not calculate amounts, this is the ECRs responsibility.
To be able to validate if this notification has been processed correctly the TerminalStatus-notification must return the current adjusted Amount.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
amtAdjustment
public void amtAdjustment(Amount amount, AmountDiscount amountDiscount, List<LoyaltyCoupon> loyaltyCouponList, List<LoyaltyInformation> loyaltyInformationList) throws TimException
Dynamically adjusts the transaction amount of an already running transaction. This is a "best effort" function and will be processed as long as the underlying payment protocol supports it. The amount transmitted in the notification is the new total amount. The EFT does not calculate amounts, this is the ECRs responsibility. To be able to validate if this notification has been processed correctly the TerminalStatus-notification must return the current adjusted Amount.Note: This method is only available if
Guides.UNATTENDED
- Throws:
TimException
-
changeLanguageForRequest
public void changeLanguageForRequest(String language) throws TimException
Change the cardholder language for the duration of the current process / open request. The language is set back to standard after the current request returns. Following interactions need to set the language again. For the main use case in focus, InitTransaction, this means that the language of the InitTransaction idle screen is changed until the InitTransaction finished event occurs. The last screen set by the process is not changed back to the default language. This is a "best effort" function.
Note: This method is only available if
Guides.UNATTENDED
is enabled.- Throws:
TimException
-
loyaltyData
public CardData loyaltyData(LoyaltyFunctionType functionType, String dataType, byte[] data, boolean retainCard) throws TimException
This function is used to query and configure loyalty information.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Parameters:
functionType
- Defines what kind of loyalty mode will be used.dataType
- Specifies type of loyalty data. Mandatory forLoyaltyFunctionType.INIT
,LoyaltyFunctionType.UPDATE
,LoyaltyFunctionType.DEINIT
.data
- Loyalty data.retainCard
- True to not eject card otherwise false.- Throws:
TimException
-
loyaltyDataAsync
public void loyaltyDataAsync(LoyaltyFunctionType functionType, String dataType, byte[] data, boolean retainCard) throws TimException
This function is used to query and configure loyalty information.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Parameters:
functionType
- Defines what kind of loyalty mode will be used.dataType
- Specifies type of loyalty data. Mandatory forLoyaltyFunctionType.INIT
,LoyaltyFunctionType.UPDATE
,LoyaltyFunctionType.DEINIT
.data
- Loyalty data.retainCard
- True to not eject card otherwise false.- Throws:
TimException
-
startCheckout
public void startCheckout() throws TimException
This function is used to start a Checkout process at the POS to collect card and/or cardholder loyalty information before a transaction is started. Therefore the Worldline QR code is displayed at the terminal. The timeout how long the QR code shall be displayed on the terminal before returning to its Idle screen can be defined in the Login request using the OptionType - QRCTimeout, see SIXml Book C: Appendix for further information.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
startCheckoutAsync
public void startCheckoutAsync() throws TimException
This function is used to start a Checkout process at the POS to collect card and/or cardholder loyalty information before a transaction is started. Therefore the Worldline QR code is displayed at the terminal. The timeout how long the QR code shall be displayed on the terminal before returning to its Idle screen can be defined in the Login request using the OptionType - QRCTimeout, see SIXml Book C: Appendix for further information.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
finishCheckout
public VasCheckoutInformation finishCheckout() throws TimException
This function is used to finish a previously started checkout process with StartCheckout and to retrieve consumer loyalty data from the terminal that has been collected during this checkout process.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
finishCheckoutAsync
public void finishCheckoutAsync() throws TimException
This function is used to finish a previously started checkout process with StartCheckout and to retrieve consumer loyalty data from the terminal that has been collected during this checkout process.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
provideLoyaltyBasket
public List<LoyaltyItem> provideLoyaltyBasket(List<LoyaltyItem> basket) throws TimException
This function is used to provide the terminal with a LoyaltyBasket if the corresponding loyalty scheme requires it.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
provideLoyaltyBasketAsync
public void provideLoyaltyBasketAsync(List<LoyaltyItem> basket) throws TimException
This function is used to provide the terminal with a LoyaltyBasket if the corresponding loyalty scheme requires it.Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
provideVasResult
public VasResult provideVasResult(VasResult result) throws TimException
This function is used to provide several VAS related results to the terminal, which will then send it to the corresponding VAS provider.
Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
provideVasResultAsync
public void provideVasResultAsync(VasResult result) throws TimException
This function is used to provide several VAS related results to the terminal, which will then send it to the corresponding VAS provider.
Note: This method is only available if
Guides.VALUE_ADDED_SERVICES
- Throws:
TimException
-
openDialogMode
public void openDialogMode() throws TimException
Open dialog mode on the terminal.
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
openDialogMode
public void openDialogMode(boolean silent) throws TimException
Open dialog mode on the terminal.
Note: This method is only available if
Guides.DIALOG
is enabled.- Parameters:
silent
- After opening the Dialog Mode the last screen content is retained until the the first ShowDialog is received- Throws:
TimException
-
openDialogModeAsync
public void openDialogModeAsync() throws TimException
Open dialog mode on the terminal.
Asynchronous version of
openDialogMode()
. Returns immediately and callsTerminalListener.openDialogModeCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
openDialogModeAsync
public void openDialogModeAsync(boolean silent) throws TimException
Open dialog mode on the terminal.
Asynchronous version of
openDialogMode()
. Returns immediately and callsTerminalListener.openDialogModeCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
closeDialogMode
public void closeDialogMode() throws TimException
Close dialog mode on the terminal.
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
closeDialogModeAsync
public void closeDialogModeAsync() throws TimException
Close dialog mode on the terminal.
Asynchronous version of
closeDialogMode()
. Returns immediately and callsTerminalListener.closeDialogModeCompleted(com.six.timapi.TimEvent)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
showSignatureCapture
public ShowSignatureCaptureResponse showSignatureCapture(ShowSignatureCaptureRequest request) throws TimException
Show signature capture on the terminal.
Can be called only if dialog mode is open.
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
showSignatureCaptureAsync
public void showSignatureCaptureAsync(ShowSignatureCaptureRequest request) throws TimException
Show signature capture on the terminal.
Asynchronous version of
showSignatureCapture(com.six.timapi.ShowSignatureCaptureRequest)
. Returns immediately and callsTerminalListener.showSignatureCaptureCompleted(com.six.timapi.TimEvent, com.six.timapi.ShowSignatureCaptureResponse)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
showDialog
public ShowDialogResponse showDialog(ShowDialogRequest request) throws TimException
Show dialog on the terminal.
Can be called only if dialog mode is open.
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
showDialogAsync
public void showDialogAsync(ShowDialogRequest request) throws TimException
Show dialog on the terminal.
Asynchronous version of
showDialog(com.six.timapi.ShowDialogRequest)
. Returns immediately and callsTerminalListener.showDialogCompleted(com.six.timapi.TimEvent, com.six.timapi.ShowDialogResponse)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
sendCardCommand
public List<CommandResponse> sendCardCommand(List<CommandRequest> requests) throws TimException
This function is used for a direct communication with the inserted card using APDUs. It is possible to send a list of APDU command in the request (sixml:CommandRequestList) and to set responses that shall be accepted as "Positive" responses using sixml:PositiveAnswerList.
Each sixml:CommandRequest is numbered with a unique order number (starting with 1). In the response, the terminal sends the response of the device for each CommandRequest, including the order number of the request.
If the device answers with a negative response (i.e. SW1SW2 != 9000 or other as "positive" defined answers using sixml:PositiveAnswerList), the processing of the sixml:CommandRequests is aborted, and the remaining commands are not sent to the device.
Furthermore it can be defined which dialogs shall be shown using the container sixml:CommandResources in the following use cases:
- Dialog shown as preparation before sending an APDU command: sixml:PreResource
- Dialog shown during APDU command execution: sixml:ExecutionResource
- Dialog shown after receiving a positive response: sixml:PositiveResource
- Dialog shown after receiving a negative response: sixml:NegativeResource
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
sendCardCommandAsync
public void sendCardCommandAsync(List<CommandRequest> requests) throws TimException
This function is used for a direct communication with the inserted card using APDUs. It is possible to send a list of APDU command in the request (sixml:CommandRequestList) and to set responses that shall be accepted as "Positive" responses using sixml:PositiveAnswerList.
Each sixml:CommandRequest is numbered with a unique order number (starting with 1). In the response, the terminal sends the response of the device for each CommandRequest, including the order number of the request.
If the device answers with a negative response (i.e. SW1SW2 != 9000 or other as "positive" defined answers using sixml:PositiveAnswerList), the processing of the sixml:CommandRequests is aborted, and the remaining commands are not sent to the device.
Furthermore it can be defined which dialogs shall be shown using the container sixml:CommandResources in the following use cases:
- Dialog shown as preparation before sending an APDU command: sixml:PreResource
- Dialog shown during APDU command execution: sixml:ExecutionResource
- Dialog shown after receiving a positive response: sixml:PositiveResource
- Dialog shown after receiving a negative response: sixml:NegativeResource
Asynchronous version of
sendCardCommand(java.util.List<com.six.timapi.CommandRequest>)
. Returns immediately and callsTerminalListener.sendCardCommandCompleted(com.six.timapi.TimEvent, java.util.List<com.six.timapi.CommandResponse>)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
printOnTerminal
public void printOnTerminal(String ticketData) throws TimException
The PrintOnTerminal-function is used to send a freetext preformatted ticket from ECR to terminal. The ticket is then printed on the terminal printer. The ticket must be formatted according [B39].
Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
printOnTerminalAsync
public void printOnTerminalAsync(String ticketData) throws TimException
The PrintOnTerminal-function is used to send a freetext preformatted ticket from ECR to terminal. The ticket is then printed on the terminal printer. The ticket must be formatted according [B39].
Asynchronous version of
printOnTerminal(java.lang.String)
. Returns immediately and callsTerminalListener.showDialogCompleted(com.six.timapi.TimEvent, com.six.timapi.ShowDialogResponse)
on all notifiers once finished.Note: This method is only available if
Guides.DIALOG
is enabled.- Throws:
TimException
-
balanceInquiry
public BalanceInquiryResponse balanceInquiry() throws TimException
Get information about the current account balance of the inserted card.
Note: This method is only available if
Guides.ADVANCED_RETAIL
is enabled.- Throws:
TimException
-
balanceInquiryAsync
public void balanceInquiryAsync() throws TimException
Get information about the current account balance of the inserted card.
Asynchronous version of
balanceInquiry()
. Returns immediately and callsTerminalListener.balanceInquiryCompleted(com.six.timapi.TimEvent, com.six.timapi.BalanceInquiryResponse)
on all notifiers once finished.Note: This method is only available if
Guides.ADVANCED_RETAIL
is enabled.- Throws:
TimException
-
requestAlias
public String requestAlias(String sixTransRef) throws TimException
The RequestAlias-function is used to request a Saferpay Alias for Alias-based transactions. Saferpay offers these kind of transactions which can be performed only using a secure Alias that can be created out of card information from a precious transaction. This Alias then can be used to perform a transaction without having the same card present.
An Alias can be used for the following transactions:
- Purchase
- Credit
- Reservation
- Recurring
- Parameters:
sixTransRef
- The SIX omni channel reference number.- Throws:
TimException
-
requestAliasAsync
public void requestAliasAsync(String sixTransRef) throws TimException
The RequestAlias-function is used to request a Saferpay Alias for Alias-based transactions. Saferpay offers these kind of transactions which can be performed only using a secure Alias that can be created out of card information from a precious transaction. This Alias then can be used to perform a transaction without having the same card present.
An Alias can be used for the following transactions:
- Purchase
- Credit
- Reservation
- Recurring
Asynchronous version of
requestAlias(java.lang.String)
. Returns immediately and callsTerminalListener.requestAliasCompleted(com.six.timapi.TimEvent, java.lang.String)
on all notifiers once finished.- Parameters:
sixTransRef
- The SIX omni channel reference number.- Throws:
TimException
-
deviceMaintenance
public void deviceMaintenance(MaintenanceType type) throws TimException
The DeviceMaintenance-function starts various maintenance processes on the EFT.
The processes may require user interaction on the terminal e.g. to insert cleaning cards in the reader cleaning process.
To avoid timeout problems the terminal shall set its state to 'Busy' and then return immediately from the request. When the process is finished the state shall be changed to 'Idle'.- Parameters:
type
- Type of maintenance to perform.- Throws:
TimException
-
deviceMaintenanceAsync
public void deviceMaintenanceAsync(MaintenanceType type) throws TimException
The DeviceMaintenance-function starts various maintenance processes on the EFT.
The processes may require user interaction on the terminal e.g. to insert cleaning cards in the reader cleaning process.
To avoid timeout problems the terminal shall set its state to 'Busy' and then return immediately from the request. When the process is finished the state shall be changed to 'Idle'.- Parameters:
type
- Type of maintenance to perform.- Throws:
TimException
-
screenshot
public void screenshot() throws TimException
Send notification to request EFT make a screenshot. This is a "best effort" function. Note: This method is only available if guideGuides.REMOTE
is enabled.- Throws:
TimException
-
mobileTopupIssuerInfo
public List<MobileTopupValue> mobileTopupIssuerInfo() throws TimException
Request Mobile Topup Issuer information. Note: This method is only available if guideGuides.VALUE_ADDED_SERVICES
is enabled.- Throws:
TimException
-
mobileTopupIssuerInfoAsync
public void mobileTopupIssuerInfoAsync() throws TimException
Request Mobile Topup Issuer information. Asynchronous version ofrequestAlias(java.lang.String)
. Returns immediately and callsTerminalListener.requestAliasCompleted(com.six.timapi.TimEvent, java.lang.String)
on all notifiers once finished. Note: This method is only available if guideGuides.VALUE_ADDED_SERVICES
is enabled.- Throws:
TimException
-
mobileTopup
public MobileTopupData mobileTopup(MobileTopupType type, String issuerName, Amount amount) throws TimException
Mobile Topup transaction. Supported transaction type are PURCHASE and REVERSAL. To use REVERSAL terminal has to be configured to support credit transactions. Note: This method is only available if guideGuides.VALUE_ADDED_SERVICES
is enabled.- Throws:
TimException
-
mobileTopup
public MobileTopupData mobileTopup(MobileTopupType type, MobileTopupValue value) throws TimException
- Throws:
TimException
-
mobileTopupAsync
public void mobileTopupAsync(MobileTopupType type, String issuerName, Amount amount) throws TimException
Mobile Topup transaction. Supported transaction type are PURCHASE and REVERSAL. To use REVERSAL terminal has to be configured to support credit transactions. Asynchronous version ofrequestAlias(java.lang.String)
. Returns immediately and callsTerminalListener.requestAliasCompleted(com.six.timapi.TimEvent, java.lang.String)
on all notifiers once finished. Note: This method is only available if guideGuides.VALUE_ADDED_SERVICES
is enabled.- Throws:
TimException
-
mobileTopupAsync
public void mobileTopupAsync(MobileTopupType type, MobileTopupValue value) throws TimException
- Throws:
TimException
-
thirdPartyAppData
public void thirdPartyAppData(ThirdPartyAppPayload payload) throws TimException
Send third party app data notification to EFT. This is a "best effort" function. Note: This method is only available if guideGuides.VALUE_ADDED_SERVICES
is enabled.- Throws:
TimException
-
canDcc
public boolean canDcc()
Returns true if at least one payment protocol and the terminal configuration offer DCC i.e. if there is a chance to do a DCC transaction.
-
canDeclinedReceipts
public boolean canDeclinedReceipts()
Support for "Declined Receipts" in at least one payment protocol.
-
canMultiAccountSelection
public boolean canMultiAccountSelection()
Support for multiple account selection.
-
hasSwUpdate
public boolean hasSwUpdate()
Software update is available.
-
getItemTextcode
public AdditionalInfoItem getItemTextcode(Long itemTextcode)
Convert item text code to AdditionalInfoItem value.- Returns:
- Matching AdditionalInfoItem enum or null.
-
getItemTextcodeDescription
public String getItemTextcodeDescription(AdditionalInfoItem item)
Get text description of AdditionalInfoItem.
-
addListener
public void addListener(TerminalListener listener)
Register listener.- Throws:
IllegalArgumentException
- listener is null.IllegalArgumentException
- listener is registered.
-
removeListener
public void removeListener(TerminalListener listener)
Unregister listener.- Throws:
IllegalArgumentException
- listener is null.IllegalArgumentException
- listener is not registered.
-
-