Total Complexity | 5 |
Total Lines | 34 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php declare(strict_types=1); |
||
9 | final class ProxyMapping implements Mapping |
||
10 | { |
||
11 | /** @var string */ |
||
12 | private $name; |
||
13 | /** @var ProxyFactory */ |
||
14 | private $proxyFactory; |
||
15 | |||
16 | private function __construct(string $name, ProxyFactory $proxyFactory) |
||
17 | { |
||
18 | $this->name = $name; |
||
19 | $this->proxyFactory = $proxyFactory; |
||
20 | } |
||
21 | |||
22 | public static function inProperty( |
||
23 | string $name, |
||
24 | ProxyFactory $proxyFactory |
||
25 | ): Mapping { |
||
26 | return new self($name, $proxyFactory); |
||
27 | } |
||
28 | |||
29 | public function name(): string |
||
30 | { |
||
31 | return $this->name; |
||
32 | } |
||
33 | |||
34 | public function value(array $data, $owner = null) |
||
43 | } |
||
44 | } |
||
45 | } |
||
46 |