File tree Expand file tree Collapse file tree 3 files changed +28
-11
lines changed
lib/internal/Magento/Framework/Module Expand file tree Collapse file tree 3 files changed +28
-11
lines changed Original file line number Diff line number Diff line change 64
64
<preference for =" Magento\Framework\Config\CacheInterface" type =" Magento\Framework\App\Cache\Type\Config" />
65
65
<preference for =" Magento\Framework\Config\ValidationStateInterface" type =" Magento\Framework\App\Arguments\ValidationState" />
66
66
<preference for =" Magento\Framework\Module\ModuleListInterface" type =" Magento\Framework\Module\ModuleList" />
67
+ <preference for =" Magento\Framework\Module\ModuleManagerInterface" type =" Magento\Framework\Module\Manager" />
67
68
<preference for =" Magento\Framework\Component\ComponentRegistrarInterface" type =" Magento\Framework\Component\ComponentRegistrar" />
68
69
<preference for =" Magento\Framework\Event\ConfigInterface" type =" Magento\Framework\Event\Config" />
69
70
<preference for =" Magento\Framework\Event\InvokerInterface" type =" Magento\Framework\Event\Invoker\InvokerDefault" />
Original file line number Diff line number Diff line change 10
10
namespace Magento \Framework \Module ;
11
11
12
12
/**
13
- * Module status manager.
14
- *
15
- * Usage:
16
- * ```php
17
- * $manager->isEnabled('Vendor_Module');
18
- * ```
13
+ * @inheritdoc
19
14
*/
20
- class Manager
15
+ class Manager implements ModuleManagerInterface
21
16
{
22
17
/**
23
18
* @var Output\ConfigInterface
@@ -52,10 +47,7 @@ public function __construct(
52
47
}
53
48
54
49
/**
55
- * Whether a module is enabled in the configuration or not
56
- *
57
- * @param string $moduleName Fully-qualified module name
58
- * @return boolean
50
+ * @inheritdoc
59
51
*/
60
52
public function isEnabled ($ moduleName )
61
53
{
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace Magento \Framework \Module ;
4
+
5
+ /**
6
+ * Module status manager
7
+ *
8
+ * Usage:
9
+ * ```php
10
+ * $manager->isEnabled('Vendor_Module');
11
+ * ```
12
+ *
13
+ * @api
14
+ */
15
+ interface ModuleManagerInterface
16
+ {
17
+ /**
18
+ * Retrieve whether or not a module is enabled by configuration
19
+ *
20
+ * @param string $moduleName Fully-qualified module name, e.g. Magento_Config
21
+ * @return boolean Whether or not the module is enabled in the configuration
22
+ */
23
+ public function isEnabled ($ moduleName );
24
+ }
You can’t perform that action at this time.
0 commit comments