Passed
Push — di ( 61d74f...f00c6d )
by Arnaud
15:03 queued 11:43
created

BuilderFactory   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 2
c 1
b 0
f 0
dl 0
loc 11
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A create() 0 3 1
1
<?php
2
3
/**
4
 * This file is part of Cecil.
5
 *
6
 * (c) Arnaud Ligny <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Cecil;
15
16
use Symfony\Component\DependencyInjection\ContainerInterface;
17
18
/**
19
 * Builder Factory for creating Builder instances.
20
 *
21
 * This factory provides a centralized way to create Builder instances
22
 * from the dependency injection container.
23
 */
24
class BuilderFactory
25
{
26
    /**
27
     * Creates a Builder instance from the dependency injection container.
28
     *
29
     * @param ContainerInterface $container The DI container
30
     * @return Builder The configured Builder instance
31
     */
32
    public static function create(ContainerInterface $container): Builder
33
    {
34
        return $container->get(Builder::class);
35
    }
36
}
37