| Total Complexity | 5 |
| Total Lines | 45 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 9 | class CommonEvents |
||
| 10 | { |
||
| 11 | private const NEW_SERVICE = 'NEW_SERVICE'; |
||
| 12 | private const NEW_VIRTUAL_HOST = 'NEW_VIRTUAL_HOST'; |
||
| 13 | private const NEW_IMAGE = 'NEW_IMAGE'; |
||
| 14 | |||
| 15 | /** @var AentHelper */ |
||
| 16 | private $aentHelper; |
||
| 17 | |||
| 18 | /** @var OutputInterface */ |
||
| 19 | private $output; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * CommonEvents constructor. |
||
| 23 | * @param AentHelper $aentHelper |
||
| 24 | * @param OutputInterface $output |
||
| 25 | */ |
||
| 26 | public function __construct(AentHelper $aentHelper, OutputInterface $output) |
||
| 30 | } |
||
| 31 | |||
| 32 | public function dispatchService(Service $service): void |
||
| 33 | { |
||
| 34 | Aenthill::dispatchJson(self::NEW_SERVICE, $service); |
||
| 35 | } |
||
| 36 | |||
| 37 | public function dispatchNewVirtualHost(string $serviceName, int $virtualPort = 80, string $virtualHost = null): ?array |
||
| 48 | } |
||
| 49 | |||
| 50 | |||
| 51 | public function dispatchImage(Service $service): void |
||
| 56 |