We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ec95066 commit 3074be4Copy full SHA for 3074be4
common.neon
@@ -1,2 +1,2 @@
1
-services:
2
- - Mathematicator\Statistics\StatisticsManager
+extensions:
+ mathematicator.statistic: Mathematicator\Statistics\StatisticExtension
src/StatisticExtension.php
@@ -0,0 +1,19 @@
+<?php
+
3
+declare(strict_types=1);
4
5
+namespace Mathematicator\Statistics;
6
7
8
+use Nette\DI\CompilerExtension;
9
10
+final class StatisticExtension extends CompilerExtension
11
+{
12
+ public function beforeCompile(): void
13
+ {
14
+ $builder = $this->getContainerBuilder();
15
16
+ $builder->addDefinition($this->prefix('statisticsManager'))
17
+ ->setFactory(StatisticsManager::class);
18
+ }
19
+}
0 commit comments