Completed
Push — dev ( e964a0...601310 )
by Zach
04:13
created

SymfonyOutput   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 39
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
dl 0
loc 39
rs 10
c 0
b 0
f 0
wmc 3
lcom 1
cbo 2

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A write() 0 4 1
A getOutput() 0 4 1
1
<?php
2
3
namespace Yarak\Console\Output;
4
5
use Symfony\Component\Console\Output\OutputInterface;
6
7
class SymfonyOutput extends Output
8
{
9
    /**
10
     * Symfony command output.
11
     *
12
     * @var OutputInterface
13
     */
14
    protected $output;
15
16
    /**
17
     * Construct.
18
     *
19
     * @param OutputInterface $output
20
     */
21
    public function __construct(OutputInterface $output)
22
    {
23
        $this->output = $output;
24
    }
25
26
    /**
27
     * Write a message.
28
     *
29
     * @param string $message
30
     */
31
    public function write($message)
32
    {
33
        $this->output->writeln($message);
34
    }
35
36
    /**
37
     * Get the Symfony output class.
38
     *
39
     * @return OutputInterface
40
     */
41
    public function getOutput()
42
    {
43
        return $this->output;
44
    }
45
}
46