Completed
Push — master ( 51d11c...72fa5d )
by Rougin
01:42
created

Application::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 12

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 12
ccs 0
cts 8
cp 0
rs 9.8666
c 0
b 0
f 0
cc 1
nc 1
nop 3
crap 2
1
<?php
2
3
namespace Rougin\Refinery\Console;
4
5
use Rougin\Describe\Describe;
6
use Rougin\Refinery\Builder;
7
use Rougin\Refinery\Manager;
8
use Symfony\Component\Console\Application as BaseApplication;
9
10
/**
11
 * Console Application
12
 *
13
 * @package Refinery
14
 * @author  Rougin Royce Gutib <[email protected]>
15
 */
16
class Application extends BaseApplication
17
{
18
    const VERSION = '0.4.0';
19
20
    /**
21
     * Initializes the application instance.
22
     *
23
     * @param \Rougin\Refinery\Builder  $builder
24
     * @param \Rougin\Describe\Describe $describe
25
     * @param \Rougin\Refinery\Manager  $manager
26
     */
27
    public function __construct(Builder $builder, Describe $describe, Manager $manager)
28
    {
29
        parent::__construct('Refinery', self::VERSION);
30
31
        $this->add(new CreateCommand($builder, $describe, $manager));
32
33
        $this->add(new RevertCommand($manager));
34
35
        $this->add(new ResetCommand($manager));
36
37
        $this->add(new MigrateCommand($manager));
38
    }
39
}
40