Message   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 49
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 9
c 1
b 0
f 0
dl 0
loc 49
rs 10
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getType() 0 3 1
A getText() 0 3 1
A setText() 0 5 1
A setType() 0 5 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Dandelion\Operation\Result;
6
7
class Message implements MessageInterface
8
{
9
    /**
10
     * @var string
11
     */
12
    protected $type;
13
14
    /**
15
     * @var string
16
     */
17
    protected $text;
18
19
    /**
20
     * @return string
21
     */
22
    public function getType(): string
23
    {
24
        return $this->type;
25
    }
26
27
    /**
28
     * @param string $type
29
     * @return \Dandelion\Operation\Result\MessageInterface
30
     */
31
    public function setType(string $type): MessageInterface
32
    {
33
        $this->type = $type;
34
35
        return $this;
36
    }
37
38
    /**
39
     * @return string
40
     */
41
    public function getText(): string
42
    {
43
        return $this->text;
44
    }
45
46
    /**
47
     * @param string $text
48
     *
49
     * @return \Dandelion\Operation\Result\MessageInterface
50
     */
51
    public function setText(string $text): MessageInterface
52
    {
53
        $this->text = $text;
54
55
        return $this;
56
    }
57
}
58