Completed
Push — master ( ed817b...8d2763 )
by Rob
01:55
created

SoteriaModel::getOutput()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 2
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 4
ccs 2
cts 2
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 1
1
<?php
2
3
namespace devtoolboxuk\soteria\models;
4
5
class SoteriaModel
6
{
7
    private $input = '';
8
    private $output = '';
9
    private $passed = true;
10
11
12 4
    function __construct($input, $output, $passed = true)
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
13
    {
14 4
        $this->input = $input;
15 4
        $this->output = $output;
16 4
        $this->passed = $passed;
17 4
    }
18
19
    /**
20
     * @return string
21
     */
22
    public function getInput()
23
    {
24
        return $this->input;
25
    }
26
27
    /**
28
     * @return mixed
29
     */
30
    public function getResult()
31
    {
32
        return $this->getOutput();
33
    }
34
35
    /**
36
     * @return string
37
     */
38 3
    public function getOutput()
39
    {
40 3
        return $this->output;
41
    }
42
43
    /**
44
     * @return bool
45
     */
46 1
    public function isValid()
47
    {
48 1
        return $this->passed;
49
    }
50
51
}