InfobipMessage   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 50
Duplicated Lines 0 %

Coupling/Cohesion

Components 2
Dependencies 0

Test Coverage

Coverage 81.82%

Importance

Changes 0
Metric Value
wmc 4
lcom 2
cbo 0
dl 0
loc 50
ccs 9
cts 11
cp 0.8182
rs 10
c 0
b 0
f 0

4 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A content() 0 6 1
A from() 0 6 1
A getFrom() 0 4 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