InfobipMessage::content()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1

Importance

Changes 0
Metric Value
dl 0
loc 6
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
crap 1
1
<?php
2
3
namespace NotificationChannels\Infobip;
4
5
class InfobipMessage
6
{
7
    public $content;
8
9
    public $from;
10
11
    /**
12
     * InfobipMessage constructor.
13
     *
14
     * @param string $content
15
     */
16 3
    public function __construct($content = '')
17
    {
18 3
        $this->content = $content;
19 3
    }
20
21
    /**
22
     * @param $content
23
     * @return $this
24
     */
25 1
    public function content($content)
26
    {
27 1
        $this->content = $content;
28
29 1
        return $this;
30
    }
31
32
    /**
33
     * Set the phone number this message is sent from.
34
     *
35
     * @param $from
36
     * @return $this
37
     */
38 1
    public function from($from)
39
    {
40 1
        $this->from = $from;
41
42 1
        return $this;
43
    }
44
45
    /**
46
     * Get the phone number this message is sent from.
47
     *
48
     * @return string
49
     */
50
    public function getFrom()
51
    {
52
        return $this->from;
53
    }
54
}
55