PHP Класс Paranoia\Payment\Adapter\AdapterAbstract

Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
$configuration Paranoia\Configuration\AbstractConfiguration
$currencyCodes array
$dispatcher Symfony\Component\EventDispatcher\EventDispatcher
$transactionMap array

Открытые методы

Метод Описание
__construct ( AbstractConfiguration $configuration )
cancel ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
pointQuery ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
pointUsage ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
postAuthorization ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
preAuthorization ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
refund ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
sale ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
setConfiguration ( AbstractConfiguration $configuration )

Защищенные методы

Метод Описание
buildCancelRequest ( Request $request ) : mixed build request data for cancel transaction.
buildPostAuthorizationRequest ( Request $request ) : mixed build request data for postauthorization transaction.
buildPreAuthorizationRequest ( Request $request ) : mixed build request data for preauthorization transaction.
buildRefundRequest ( Request $request ) : mixed build request data for refund transaction.
buildRequest ( Request $request, string $requestBuilder ) : mixed build complete raw data for the specified request.
buildSaleRequest ( Request $request ) : mixed build request data for sale transaction.
formatAmount ( string | float $amount, boolean $reverse = false ) : string returns formatted amount with doth or without doth.
formatCurrency ( string $currency ) : integer formats the specified string currency code by iso currency codes.
formatExpireDate ( integer $month, integer $year ) : string formats expire date as month/year
formatInstallment ( integer $installment ) : string returns formatted installment amount
formatOrderId ( $orderId ) : mixed returns formatted order number.
getDispatcher ( ) : EventDispatcher
getProviderTransactionType ( string $transactionType ) : string returns transaction code by expected provider.
maskRequest ( string $rawRequest ) : string mask some critical information in transaction request.
parseResponse ( string $rawResponse, string $transactionType ) : Paranoia\Payment\Response\PaymentResponse parses response from returned provider.
sendRequest ( string $url, mixed $data, array $options = null ) : mixed Makes http request to remote host.

Описание методов

__construct() публичный Метод

public __construct ( AbstractConfiguration $configuration )
$configuration Paranoia\Configuration\AbstractConfiguration

buildCancelRequest() абстрактный защищенный Метод

build request data for cancel transaction.
abstract protected buildCancelRequest ( Request $request ) : mixed
$request Paranoia\Payment\Request
Результат mixed

buildPostAuthorizationRequest() абстрактный защищенный Метод

build request data for postauthorization transaction.
abstract protected buildPostAuthorizationRequest ( Request $request ) : mixed
$request Paranoia\Payment\Request
Результат mixed

buildPreAuthorizationRequest() абстрактный защищенный Метод

build request data for preauthorization transaction.
abstract protected buildPreAuthorizationRequest ( Request $request ) : mixed
$request Paranoia\Payment\Request
Результат mixed

buildRefundRequest() абстрактный защищенный Метод

build request data for refund transaction.
abstract protected buildRefundRequest ( Request $request ) : mixed
$request Paranoia\Payment\Request
Результат mixed

buildRequest() абстрактный защищенный Метод

build complete raw data for the specified request.
abstract protected buildRequest ( Request $request, string $requestBuilder ) : mixed
$request Paranoia\Payment\Request
$requestBuilder string
Результат mixed

buildSaleRequest() абстрактный защищенный Метод

build request data for sale transaction.
abstract protected buildSaleRequest ( Request $request ) : mixed
$request Paranoia\Payment\Request
Результат mixed

cancel() публичный Метод

public cancel ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

formatAmount() защищенный Метод

formatted number returns amount default without doth.
protected formatAmount ( string | float $amount, boolean $reverse = false ) : string
$amount string | float
$reverse boolean
Результат string

formatCurrency() защищенный Метод

formats the specified string currency code by iso currency codes.
protected formatCurrency ( string $currency ) : integer
$currency string
Результат integer

formatExpireDate() защищенный Метод

formats expire date as month/year
protected formatExpireDate ( integer $month, integer $year ) : string
$month integer
$year integer
Результат string

formatInstallment() защищенный Метод

returns formatted installment amount
protected formatInstallment ( integer $installment ) : string
$installment integer
Результат string

formatOrderId() защищенный Метод

returns formatted order number.
protected formatOrderId ( $orderId ) : mixed
$orderId
Результат mixed

getDispatcher() защищенный Метод

protected getDispatcher ( ) : EventDispatcher
Результат Symfony\Component\EventDispatcher\EventDispatcher

getProviderTransactionType() защищенный Метод

returns transaction code by expected provider.
protected getProviderTransactionType ( string $transactionType ) : string
$transactionType string
Результат string

maskRequest() защищенный Метод

mask some critical information in transaction request.
protected maskRequest ( string $rawRequest ) : string
$rawRequest string
Результат string

parseResponse() абстрактный защищенный Метод

parses response from returned provider.
abstract protected parseResponse ( string $rawResponse, string $transactionType ) : Paranoia\Payment\Response\PaymentResponse
$rawResponse string
$transactionType string
Результат Paranoia\Payment\Response\PaymentResponse

pointQuery() публичный Метод

public pointQuery ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

pointUsage() публичный Метод

public pointUsage ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

postAuthorization() публичный Метод

public postAuthorization ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

preAuthorization() публичный Метод

public preAuthorization ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

refund() публичный Метод

public refund ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

sale() публичный Метод

public sale ( Request $request ) : Paranoia\Payment\Response\PaymentResponse
$request Paranoia\Payment\Request
Результат Paranoia\Payment\Response\PaymentResponse

sendRequest() защищенный Метод

Makes http request to remote host.
protected sendRequest ( string $url, mixed $data, array $options = null ) : mixed
$url string
$data mixed
$options array
Результат mixed

setConfiguration() публичный Метод

public setConfiguration ( AbstractConfiguration $configuration )
$configuration Paranoia\Configuration\AbstractConfiguration

Описание свойств

$configuration защищенное свойство

protected AbstractConfiguration,Paranoia\Configuration $configuration
Результат Paranoia\Configuration\AbstractConfiguration

$currencyCodes защищенное свойство

protected array $currencyCodes
Результат array

$dispatcher защищенное свойство

protected EventDispatcher,Symfony\Component\EventDispatcher $dispatcher
Результат Symfony\Component\EventDispatcher\EventDispatcher

$transactionMap защищенное свойство

protected array $transactionMap
Результат array