\Heidelpay\PhpPaymentApi\PaymentMethodsBasicPaymentMethodTrait

This class is the basic payment method trait

It contains the main properties and functions for every payment method

Summary

Methods
Properties
Constants
getPaymentCode()
getBrand()
getClassName()
setRequest()
getRequest()
getResponse()
setAdapter()
getAdapter()
getPaymentUrl()
prepareRequest()
jsonSerialize()
toJson()
getResponseArray()
$dryRun
No constants found
No protected methods found
$adapter
$request
$requestArray
$response
$responseArray
N/A
No private methods found
No private properties found
N/A

Properties

$dryRun

$dryRun : boolean

Dry run

If set to true request will be generated but not send to payment api. This is use full for testing.

Type

boolean — dry run

$requestArray

$requestArray : array

Heidelpay request array

Type

array — request

$responseArray

$responseArray : array

Heidelpay response array

Type

array — response

Methods

getPaymentCode()

getPaymentCode() : string

Returns the payment code for the payment request.

Returns

string

getBrand()

getBrand() : string

Returns the brand for the payment method.

Returns

string

getClassName()

getClassName() : string

Return the name of the used class

Returns

string —

class name

getPaymentUrl()

getPaymentUrl() 

Throws

\Heidelpay\PhpPaymentApi\Exceptions\UndefinedTransactionModeException

prepareRequest()

prepareRequest() 

This function prepares the request for heidelpay api

It will add the used payment method and the brand to the request. If dry run is set the request will only be convert to an array.

Throws

\Heidelpay\PhpPaymentApi\Exceptions\UndefinedTransactionModeException

jsonSerialize()

jsonSerialize() : array

Returns an array for a json representation.

Returns

array

toJson()

toJson(  $options) 

Parameters

$options

getResponseArray()

getResponseArray() : array

Returns

array