Total Complexity | 12 |
Total Lines | 46 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
8 | class GroupConsumer extends Consumer |
||
9 | { |
||
10 | /** @var iterable|Consumer[] */ |
||
11 | protected $consumers = array(); |
||
12 | |||
13 | public function addConsumers(iterable $consumers) |
||
14 | { |
||
15 | foreach ($consumers as $consumer) { |
||
16 | $consumer->setChannel($this->ch); |
||
17 | $consumer->setConsumerTag(sprintf("PHPPROCESS_%s_%s_%s", gethostname(), getmypid(), count($this->consumers))); |
||
18 | $this->consumers[] = $consumer; |
||
19 | } |
||
20 | } |
||
21 | |||
22 | public function setupConsumer() |
||
23 | { |
||
24 | foreach ($this->consumers as $consumer) { |
||
25 | $consumer->setupConsumer(); |
||
26 | } |
||
27 | } |
||
28 | |||
29 | public function stopConsuming() |
||
33 | } |
||
34 | } |
||
35 | |||
36 | public function purge() |
||
40 | } |
||
41 | } |
||
42 | |||
43 | public function delete() |
||
47 | } |
||
48 | } |
||
49 | |||
50 | public function disableAutoSetupFabric() |
||
54 | } |
||
55 | } |
||
56 | } |