1 | <?php |
||
8 | final class Joiner |
||
9 | { |
||
10 | /** @var Serializer */ |
||
11 | private $serializer; |
||
12 | |||
13 | /** @var Manipulator */ |
||
14 | private $manipulator; |
||
15 | |||
16 | private $base; |
||
17 | |||
18 | 15 | public function __construct(Serializer $serializer, Manipulator $manipulator) |
|
24 | |||
25 | 15 | public function join($arg) |
|
31 | |||
32 | 12 | public function append($key, $arg) |
|
39 | |||
40 | public function filter(... $key) |
||
41 | { |
||
42 | 3 | array_map(function ($key_to_remove) { |
|
43 | 3 | $this->manipulator->filter($key_to_remove); |
|
44 | 3 | }, $key); |
|
45 | |||
46 | 3 | return $this; |
|
47 | } |
||
48 | |||
49 | 15 | public function execute() |
|
56 | } |
||
57 |