Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-vault
Model
AbstractPaymentTokenFactory.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Vault\Model
;
7
8
use
Magento\Framework\ObjectManagerInterface
;
9
use
Magento\Vault\Api\Data\PaymentTokenInterface
;
10
use
Magento\Vault\Api\Data\PaymentTokenInterfaceFactory
;
11
use
Magento\Vault\Api\Data\PaymentTokenFactoryInterface
;
12
18
abstract
class
AbstractPaymentTokenFactory
implements
PaymentTokenInterfaceFactory
19
{
23
private
$objectManager;
24
28
private
$paymentTokenFactory;
29
35
public
function
__construct
(
36
ObjectManagerInterface
$objectManager,
37
PaymentTokenFactoryInterface
$paymentTokenFactory =
null
38
) {
39
if
($paymentTokenFactory ===
null
) {
40
$paymentTokenFactory =
$objectManager
->get(PaymentTokenFactoryInterface::class);
41
}
42
43
$this->objectManager =
$objectManager
;
44
$this->paymentTokenFactory = $paymentTokenFactory;
45
}
46
51
public
function
create
()
52
{
53
return
$this->paymentTokenFactory->create($this->
getType
());
54
}
55
}
Magento\Vault\Model\AbstractPaymentTokenFactory\__construct
__construct(ObjectManagerInterface $objectManager, PaymentTokenFactoryInterface $paymentTokenFactory=null)
Definition:
AbstractPaymentTokenFactory.php:35
$objectManager
$objectManager
Definition:
bootstrap.php:17
Magento\Vault\Model\AbstractPaymentTokenFactory\create
create()
Definition:
AbstractPaymentTokenFactory.php:51
Magento\Framework\ObjectManagerInterface
Definition:
ObjectManagerInterface.php:12
Magento\Vault\Api\Data\PaymentTokenFactoryInterface
Definition:
PaymentTokenFactoryInterface.php:14
Magento\Vault\Api\Data\PaymentTokenInterfaceFactory\getType
getType()
Magento\Vault\Model
Definition:
PaymentTokenRepositoryTest.php:6
Magento\Vault\Model\AbstractPaymentTokenFactory
Definition:
AbstractPaymentTokenFactory.php:18
Magento\Vault\Api\Data\PaymentTokenInterface
Definition:
PaymentTokenInterface.php:14
Magento\Vault\Api\Data\PaymentTokenInterfaceFactory
Definition:
PaymentTokenInterfaceFactory.php:15