1 | <?php declare(strict_types = 1); |
||
13 | final class ObjectInflector implements ObjectInflectorContract |
||
14 | { |
||
15 | |||
16 | /** |
||
17 | * @var ArgumentResolverContract |
||
18 | */ |
||
19 | private $argumentResolver; |
||
20 | |||
21 | /** |
||
22 | * A list of methods with arguments which will be invoked on the subject object. |
||
23 | * |
||
24 | * @var string[][] |
||
25 | */ |
||
26 | private $inflections = []; |
||
27 | |||
28 | /** |
||
29 | * ObjectInflector constructor. |
||
30 | * |
||
31 | * @param ArgumentResolverContract $argumentResolver |
||
32 | */ |
||
33 | 2 | public function __construct(ArgumentResolverContract $argumentResolver) |
|
37 | |||
38 | /** |
||
39 | * @inheritDoc |
||
40 | */ |
||
41 | public function addInflection(string $id, string $method, array $arguments = []) |
||
45 | |||
46 | /** |
||
47 | * @inheritDoc |
||
48 | */ |
||
49 | public function applyInflections($object) |
||
82 | |||
83 | } |