SPI  1.2403.0
Secured Payment Interface
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | List of all members
Modularity::SPI::NayaxEngineTransaction Class Reference

This class contains all the input data and output data of NayaxEngineTransaction transactions, including the methods inherited from class EmvTransaction. All data in this class is reachable through various methods which define the behaivor of the operation. More...

#include <NayaxEngineTransaction.h>

Inheritance diagram for Modularity::SPI::NayaxEngineTransaction:
Modularity::SPI::EmvTransaction Modularity::SPI::Transaction

Public Member Functions

SPILIBRARY_API ~NayaxEngineTransaction ()
 Class desrstructor.
 
APIHandle GetNayaxEngineHandle () const
 Handle get - reserved for internal useage.
 
EMV Pre Transaction Information

Those methods can be called before EMV transaction is executed.

SPILIBRARY_API NayaxEngineTransaction (string VendorUID, AmountType Amount)
 Class constructor. When this an item must be added using AddItem()
 
APM Pre Transaction Information

Those methods can be called before transaction is executed for.

SPILIBRARY_API NayaxEngineTransaction (string VendorUID, AmountType Amount, UnsignedNumericType APMCode)
 Class constructor. When this an item must be added using AddItem()
 
SPILIBRARY_API void SetItemsQuantity (CounterType Quantity)
 Set number of items in the sale.
 
SPILIBRARY_API void SetAsRefund (string OriginalTransactionId)
 Set transaction type as refund.
 
SPILIBRARY_API void SetAsDeferredAuthorization ()
 Set transaction type as refund.
 
SPILIBRARY_API void SetCardData (string CardData)
 Set card data for APM transactions.
 
SPILIBRARY_API void SetCibusCompanyCode (UnsignedNumericType CompanyCode)
 Set CompanyCode for APM Cibus (Not related to Cibus service)
 
SPILIBRARY_API void SetSparkId (string &sparkId)
 Set spark id.
 
State data

Those methods can be called at the appropiate state of the transaction.

SPILIBRARY_API string GetQRCodeData () const
 Get QR that represent the transaction on the device. QR should be displayed to the customer. Support only Asynchro API. To be used after Service.StartTransaction was called.
 
SPILIBRARY_API bool TokenReceived () const
 Get indication if token received from broker for QR transaction.
 
Post Transaction Information

Those methods can be called after transaction is executed.

SPILIBRARY_API bool WasSuccessful () const
 A method that tells post transaction weather transaction succeded or not.
 
SPILIBRARY_API
NayaxEngine::NayaxEngineTransactionType 
GetTransactionType () const
 Get transaction type.
 
SPILIBRARY_API string GetTransasctionId () const
 Get transaction identifier on Nayax DCS.
 
SPILIBRARY_API string GetDTID () const
 Get Device Transaction identifier. This Id is generated on the device.
 
SPILIBRARY_API string GetFullName () const
 Get Monyx user full name.
 
SPILIBRARY_API string GetCurrencyCode () const
 Get Currency code used for for transaction.
 
SPILIBRARY_API bool IsPending () const
 Wether DeferredAuth Transaction is in pending state and need to be dispatched.
 
- Public Member Functions inherited from Modularity::SPI::EmvTransaction
virtual SPILIBRARY_API std::string GetTransactionResultMessage () const
 Get transaction result message. Messages are in English.
 
SPILIBRARY_API ~EmvTransaction ()
 Class desrstructor.
 
APIHandle GetEmvHandle () const
 Handle get - reserved for internal useage.
 
SPILIBRARY_API EmvTransaction (string VendorUID, AmountType Amount)
 Class constructor. When this an item must be added using AddItem()
 
SPILIBRARY_API void SetAsCNP (string PAN, string Exp, string CVV)
 Set card data manually.
 
SPILIBRARY_API void SetEmvData (UnsignedNumericType Tag, string Value)
 Set EMV data manually when card was read externally.
 
SPILIBRARY_API bool WasApproved () const
 A method that tells post transaction weather transaction succeded or not.
 
SPILIBRARY_API std::vector
< ReceiptLine > 
GetMerchentRecipt () const
 Get a list of (key,value). Vending application prints the list provided from this function by it's order. Each member of the vector is a line. The key member is the field name and value is the field value. e.g. key=Type , value=SALE e.g. key=AID , value=A00000003010 Receipt exists only if WasSuccessful() is true or GetResultCode() is 0. This function returns all the lines that belongs to the merchant copy.
 
SPILIBRARY_API std::vector
< ReceiptLine > 
GetCustomerRecipt () const
 Get a list of (key,value). Vending application prints the list provided from this function by it's order. Each member of the vector is a line. The key member is the field name and value is the field value. e.g. key=Type , value=SALE e.g. key=AID , value=A00000003010 Receipt exists only if WasSuccessful() is true or GetResultCode() is 0. This function returns all the lines that belongs to the merchant copy.
 
SPILIBRARY_API string GetCurrencyISOCode () const
 Get Currency code used for for transaction.
 
SPILIBRARY_API string GetMaskedPAN () const
 Get PAN with masked digits except 6 first and last 4 digits.
 
SPILIBRARY_API string GetRRN () const
 Get transaction RRN from processor.
 
- Public Member Functions inherited from Modularity::SPI::Transaction
APIHandle GetTransactionHandle () const
 Reserved for internal useage.
 
SPILIBRARY_API Transaction (AmountType Amount, CurrencyType Currency, string VendorUID)
 Transaction constructor. Can't be used explicitly as Transaction is pure virtual.
 
virtual SPILIBRARY_API ~Transaction ()=0
 Class destructor.
 
SPILIBRARY_API PPIDType GetPinPadId () const
 Get device identification number used to make the transaction.
 
SPILIBRARY_API void SetPinPadId (PPIDType PinPadID)
 Set device identification number used to make the transaction.
 
SPILIBRARY_API void SetVendorUID (string Vuid)
 Set VUID during Loyalty phase. This method will override the current Vuid from the Constructor and will assert uniqueness only during Loyalty phase. The method doesn't apply the new Vuid immediately. The new value will be applied only after legal call to service method as mentioned above. It's highly recomanded to assert your new vuid with GetVendorUID() to make sure the new Vuid was applied. Supported services: Ashrait.
 
SPILIBRARY_API string GetVendorUID () const
 Get vendor unique ID as initialized at derived class constructor.
 
SPILIBRARY_API AmountType GetAmount () const
 Get Transaction original amount as initialized at derived class constructor.
 
SPILIBRARY_API CurrencyType GetCurrency () const
 Get currency enumerator as initialized at derived class constructor.
 
SPILIBRARY_API ResultType GetTransactionResultCode () const
 Get transaction result code. If called before transaction was ended, a speical code -999 (Transaction in progress) is returned. Each code has a message. You may see Result Codes Messages for reference.
 

Detailed Description

This class contains all the input data and output data of NayaxEngineTransaction transactions, including the methods inherited from class EmvTransaction. All data in this class is reachable through various methods which define the behaivor of the operation.

Definition at line 32 of file NayaxEngineTransaction.h.

Constructor & Destructor Documentation

SPILIBRARY_API Modularity::SPI::NayaxEngineTransaction::NayaxEngineTransaction ( string  VendorUID,
AmountType  Amount 
)

Class constructor. When this an item must be added using AddItem()

Parameters
[in]VendorUIDis an identifier string generated by the ECR. Can't be empty string.
[in]Amountis the amount with currency configured in the Machine.
SPILIBRARY_API Modularity::SPI::NayaxEngineTransaction::NayaxEngineTransaction ( string  VendorUID,
AmountType  Amount,
UnsignedNumericType  APMCode 
)

Class constructor. When this an item must be added using AddItem()

APM Codes
APMCode
Nayax Prepaid2
10 bis4
Cibus5
Multipass9
Monyx Balance22
Parameters
[in]VendorUIDis an identifier string generated by the ECR. Can't be empty string.

Member Function Documentation

SPILIBRARY_API string Modularity::SPI::NayaxEngineTransaction::GetCurrencyCode ( ) const

Get Currency code used for for transaction.

Returns
Currrency code as std::string ("USD" . "ILS" . etc.. )
SPILIBRARY_API string Modularity::SPI::NayaxEngineTransaction::GetDTID ( ) const

Get Device Transaction identifier. This Id is generated on the device.

Returns
DTID as std::string
SPILIBRARY_API string Modularity::SPI::NayaxEngineTransaction::GetFullName ( ) const

Get Monyx user full name.

Returns
Full Name as std::string
SPILIBRARY_API string Modularity::SPI::NayaxEngineTransaction::GetQRCodeData ( ) const

Get QR that represent the transaction on the device. QR should be displayed to the customer. Support only Asynchro API. To be used after Service.StartTransaction was called.

Returns
QR code as std::string
SPILIBRARY_API NayaxEngine::NayaxEngineTransactionType Modularity::SPI::NayaxEngineTransaction::GetTransactionType ( ) const

Get transaction type.

Returns
transaction type
SPILIBRARY_API string Modularity::SPI::NayaxEngineTransaction::GetTransasctionId ( ) const

Get transaction identifier on Nayax DCS.

Returns
TransasctionId as std::string
SPILIBRARY_API bool Modularity::SPI::NayaxEngineTransaction::IsPending ( ) const

Wether DeferredAuth Transaction is in pending state and need to be dispatched.

Returns
Is pending on device
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetAsDeferredAuthorization ( )

Set transaction type as refund.

Parameters
[in]OriginalTransactionIdis the original TransactionId in Engine system
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetAsRefund ( string  OriginalTransactionId)

Set transaction type as refund.

Parameters
[in]OriginalTransactionIdis the original TransactionId in Engine system
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetCardData ( string  CardData)

Set card data for APM transactions.

Parameters
[in]CardDatacard data or token to APM provider
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetCibusCompanyCode ( UnsignedNumericType  CompanyCode)

Set CompanyCode for APM Cibus (Not related to Cibus service)

Parameters
[in]CompanyCodeCompany code as int
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetItemsQuantity ( CounterType  Quantity)

Set number of items in the sale.

    - Mandatory for Monyx transactions
Parameters
[in]Quantityis the item quntity in the vend
SPILIBRARY_API void Modularity::SPI::NayaxEngineTransaction::SetSparkId ( string &  sparkId)

Set spark id.

Parameters
[in]sparkIdas string
SPILIBRARY_API bool Modularity::SPI::NayaxEngineTransaction::TokenReceived ( ) const

Get indication if token received from broker for QR transaction.

Returns
bool
SPILIBRARY_API bool Modularity::SPI::NayaxEngineTransaction::WasSuccessful ( ) const

A method that tells post transaction weather transaction succeded or not.

Returns
weather transaction succeded or not

The documentation for this class was generated from the following file: