GenerateTimeZonesMapDataCommand   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 9
dl 0
loc 19
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A configure() 0 8 1
A execute() 0 5 1
1
<?php
2
3
namespace libphonenumber\buildtools\Commands;
4
5
use libphonenumber\buildtools\GenerateTimeZonesMapData;
6
use Symfony\Component\Console\Command\Command;
7
use Symfony\Component\Console\Input\InputArgument;
8
use Symfony\Component\Console\Input\InputInterface;
9
use Symfony\Component\Console\Output\OutputInterface;
10
11
class GenerateTimeZonesMapDataCommand extends Command
12
{
13
    protected function configure()
14
    {
15
        $this->setName('GenerateTimeZonesMapData');
16
        $this->setDescription('Generate time zone data files');
17
        $this->setDefinition(
18
            array(
19
                new InputArgument('InputFile', InputArgument::REQUIRED, 'The input file containing the timezone map data'),
20
                new InputArgument('OutputDirectory', InputArgument::REQUIRED, 'The output directory to save the file'),
21
            )
22
        );
23
    }
24
25
    protected function execute(InputInterface $input, OutputInterface $output)
26
    {
27
        new GenerateTimeZonesMapData($input->getArgument('InputFile'), $input->getArgument('OutputDirectory'));
28
29
        return 0;
30
    }
31
}
32