Completed
Push — master ( 72342f...ed922a )
by Nikola
06:37
created

Style   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 1
dl 0
loc 28
c 0
b 0
f 0
ccs 0
cts 12
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A info() 0 4 1
A displayLogo() 0 10 2
1
<?php
2
3
namespace RunOpenCode\AbstractBuilder\Command;
4
5
use Symfony\Component\Console\Style\SymfonyStyle;
6
7
class Style extends SymfonyStyle
8
{
9
    /**
10
     * Display information message
11
     *
12
     * @param string $message
13
     */
14
    public function info($message)
15
    {
16
        $this->writeln(sprintf('<fg=green>[OK]</> %s', $message));
17
    }
18
19
    /**
20
     * Display logo.
21
     *
22
     * @return void
23
     */
24
    public function displayLogo()
25
    {
26
        $resource = fopen(__DIR__ . '/../../../../LOGO', 'rb');
27
28
        while (($line = fgets($resource)) !== false) {
29
            $this->write('<fg=green>'.$line.'</>');
30
        }
31
32
        fclose($resource);
33
    }
34
}
35