1 | <?php declare(strict_types=1); |
||
14 | final class Client implements ClientInterface |
||
15 | { |
||
16 | /** |
||
17 | * @var ContainerInterface |
||
18 | */ |
||
19 | private $container; |
||
20 | |||
21 | /** |
||
22 | * @var CommandBusInterface |
||
23 | */ |
||
24 | private $commandBus; |
||
25 | |||
26 | /** |
||
27 | * @param ContainerInterface $container |
||
28 | */ |
||
29 | 7 | public function __construct(ContainerInterface $container) |
|
34 | |||
35 | /** |
||
36 | * @return ContainerInterface |
||
37 | */ |
||
38 | 4 | public function getContainer(): ContainerInterface |
|
42 | |||
43 | /** |
||
44 | * @return mixed |
||
45 | */ |
||
46 | 1 | public function getFromContainer(string $id) |
|
50 | |||
51 | /** |
||
52 | * @param $command |
||
53 | * @return CancellablePromiseInterface |
||
54 | */ |
||
55 | 4 | public function handle($command): CancellablePromiseInterface |
|
59 | |||
60 | 1 | public function hydrate(string $resource): CancellablePromiseInterface |
|
76 | |||
77 | 1 | public function extract(ResourceInterface $resource): CancellablePromiseInterface |
|
90 | } |
||
91 |