Total Complexity | 5 |
Total Lines | 32 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
17 | class NamedDependency implements DependencyInterface |
||
18 | { |
||
19 | private $id; |
||
20 | |||
21 | private $optional; |
||
22 | |||
23 | /** |
||
24 | * Constructor. |
||
25 | * @param string $id the component ID |
||
26 | */ |
||
27 | public function __construct(string $id, bool $optional) |
||
28 | { |
||
29 | $this->id = $id; |
||
30 | $this->optional = $optional; |
||
31 | } |
||
32 | |||
33 | public static function to(string $id) |
||
36 | } |
||
37 | |||
38 | public function resolve(ContainerInterface $container) |
||
49 | } |
||
50 | } |
||
51 |