Total Complexity | 5 |
Total Lines | 49 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
16 | class FormServiceProvider extends AbstractServiceProvider implements BootableServiceProviderInterface |
||
17 | { |
||
18 | |||
19 | /** |
||
20 | * @inheritdoc |
||
21 | */ |
||
22 | public function provides() |
||
23 | { |
||
24 | return ['form.registry','form.extensions']; |
||
25 | } |
||
26 | |||
27 | /** |
||
28 | * @inheritdoc |
||
29 | */ |
||
30 | public function register() |
||
31 | { |
||
32 | $this->registerFormRegistry(); |
||
33 | $this->registerFormExtensions(); |
||
34 | } |
||
35 | |||
36 | public function boot() |
||
37 | { |
||
38 | // $this->mergeDefaultFilesystem(); |
||
39 | } |
||
40 | |||
41 | /** |
||
42 | * Register the native filesystem implementation. |
||
43 | * |
||
44 | * @return void |
||
45 | */ |
||
46 | protected function registerFormRegistry() |
||
47 | { |
||
48 | $this->getContainer()->share('form.registry', function () { |
||
49 | return new FormRegistry( |
||
50 | $this->getContainer()->get('form.extensions'), |
||
51 | $this->getContainer()->get('form.extensions') |
||
52 | ); |
||
53 | }); |
||
54 | } |
||
55 | |||
56 | /** |
||
57 | * Register the native filesystem implementation. |
||
58 | * |
||
59 | * @return void |
||
60 | */ |
||
61 | protected function registerFormExtensions() |
||
65 | |||
66 | ]; |
||
67 | }); |
||
68 | } |
||
69 | } |
||
70 |