commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
lib
commercetools-api
src
Models
Payment
PaymentAddTransactionActionBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Payment
;
10
11
use
Commercetools\Base\Builder
;
12
use
Commercetools\Base\DateTimeImmutableCollection
;
13
use
Commercetools\Base\JsonObject
;
14
use
Commercetools\Base\JsonObjectModel
;
15
use
Commercetools\Base\MapperFactory
;
16
use stdClass;
17
21
final
class
PaymentAddTransactionActionBuilder
implements
Builder
22
{
27
private
$transaction;
28
35
public
function
getTransaction
()
36
{
37
return
$this->transaction instanceof
TransactionDraftBuilder
? $this->transaction->
build
() : $this->transaction;
38
}
39
44
public
function
withTransaction
(?
TransactionDraft
$transaction)
45
{
46
$this->transaction = $transaction;
47
48
return
$this;
49
}
50
55
public
function
withTransactionBuilder
(?
TransactionDraftBuilder
$transaction)
56
{
57
$this->transaction = $transaction;
58
59
return
$this;
60
}
61
62
public
function
build
():
PaymentAddTransactionAction
63
{
64
return
new
PaymentAddTransactionActionModel
(
65
$this->transaction instanceof
TransactionDraftBuilder
? $this->transaction->
build
() : $this->transaction
66
);
67
}
68
69
public
static
function
of
():
PaymentAddTransactionActionBuilder
70
{
71
return
new
self
();
72
}
73
}
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder
Definition:
PaymentAddTransactionActionBuilder.php:22
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder\getTransaction
getTransaction()
Definition:
PaymentAddTransactionActionBuilder.php:35
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder\of
static of()
Definition:
PaymentAddTransactionActionBuilder.php:69
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder\build
build()
Definition:
PaymentAddTransactionActionBuilder.php:62
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder\withTransactionBuilder
withTransactionBuilder(?TransactionDraftBuilder $transaction)
Definition:
PaymentAddTransactionActionBuilder.php:55
Commercetools\Api\Models\Payment\PaymentAddTransactionActionBuilder\withTransaction
withTransaction(?TransactionDraft $transaction)
Definition:
PaymentAddTransactionActionBuilder.php:44
Commercetools\Api\Models\Payment\PaymentAddTransactionActionModel
Definition:
PaymentAddTransactionActionModel.php:21
Commercetools\Api\Models\Payment\TransactionDraftBuilder
Definition:
TransactionDraftBuilder.php:27
Commercetools\Api\Models\Payment\TransactionDraftBuilder\build
build()
Definition:
TransactionDraftBuilder.php:219
Commercetools\Base\DateTimeImmutableCollection
Definition:
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition:
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition:
MapperFactory.php:16
Commercetools\Api\Models\Payment\PaymentAddTransactionAction
Definition:
PaymentAddTransactionAction.php:15
Commercetools\Api\Models\Payment\TransactionDraft
Definition:
TransactionDraft.php:18
Commercetools\Base\Builder
Definition:
Builder.php:16
Commercetools\Base\JsonObject
Definition:
JsonObject.php:15
Commercetools\Api\Models\Payment
Definition:
Payment.php:9
Generated by
1.9.1