RunCommand::execute()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
c 2
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 2
1
<?php
2
3
namespace Ivan1986\SupervisorBundle\Command;
4
5
use Symfony\Bundle\FrameworkBundle\Command\ContainerAwareCommand;
6
use Symfony\Component\Console\Input\InputInterface;
7
use Symfony\Component\Console\Output\OutputInterface;
8
9
class RunCommand extends ContainerAwareCommand
10
{
11
    protected function configure()
12
    {
13
        $this
14
            ->setName('supervisor:run')
15
            ->setDescription('run supervisor instance')
16
        ;
17
    }
18
19
    protected function execute(InputInterface $input, OutputInterface $output)
20
    {
21
        $this->getContainer()->get('ivan1986_supervisor.supervisor_service')->run();
22
    }
23
}
24