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-deploy
Console
CommandList.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Deploy\Console
;
7
8
use
Magento\Framework\ObjectManagerInterface
;
9
13
class
CommandList
implements
\Magento\Framework\Console\CommandListInterface
14
{
20
private
$objectManager;
21
25
public
function
__construct
(
ObjectManagerInterface
$objectManager)
26
{
27
$this->objectManager =
$objectManager
;
28
}
29
35
private
function
getCommandsClasses()
36
{
37
return
[
38
\Magento\Deploy\Console\Command\App\ConfigImportCommand::class,
39
];
40
}
41
45
public
function
getCommands
()
46
{
47
$commands = [];
48
foreach
($this->getCommandsClasses() as
$class
) {
49
if
(
class_exists
(
$class
)) {
50
$commands[] = $this->objectManager->get(
$class
);
51
}
else
{
52
throw
new \Exception(
'Class '
.
$class
.
' does not exist'
);
53
}
54
}
55
56
return
$commands;
57
}
58
}
Magento\Deploy\Console\CommandList\__construct
__construct(ObjectManagerInterface $objectManager)
Definition:
CommandList.php:25
Magento\Deploy\Console\CommandList
Definition:
CommandList.php:13
Magento\Framework\Console\CommandListInterface
Definition:
CommandListInterface.php:13
$objectManager
$objectManager
Definition:
bootstrap.php:17
Magento\Framework\ObjectManagerInterface
Definition:
ObjectManagerInterface.php:12
Magento\Deploy\Console
$class
$_option $_optionId $class
Definition:
date.phtml:13
Magento\Framework\Code\Generator\class_exists
class_exists($className)
Definition:
DefinedClassesTest.php:15
Magento\Deploy\Console\CommandList\getCommands
getCommands()
Definition:
CommandList.php:45