Files
Win32ServiceBundle/lib/Win32ServiceBundle.php
2024-10-23 14:51:15 +02:00

28 lines
837 B
PHP

<?php
declare(strict_types=1);
/**
* @copy Win32Service (c) 2019
* Added by : macintoshplus at 19/02/19 13:30
*/
namespace Win32ServiceBundle;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Win32Service\Model\RunnerServiceInterface;
use Win32ServiceBundle\DependencyInjection\MessengerPass;
use Win32ServiceBundle\DependencyInjection\TagRunnerCompilerPass;
class Win32ServiceBundle extends Bundle
{
public function build(ContainerBuilder $container)
{
$autoconfig = $container->registerForAutoconfiguration(RunnerServiceInterface::class);
$autoconfig->addTag(TagRunnerCompilerPass::WIN32SERVICE_RUNNER_TAG);
$container->addCompilerPass(new TagRunnerCompilerPass());
$container->addCompilerPass(new MessengerPass());
}
}