GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( 00055f...e5d320 )
by Gregorio
06:04
created

TwilioMessage   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 72
Duplicated Lines 0 %

Coupling/Cohesion

Components 2
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 5
lcom 2
cbo 0
dl 0
loc 72
ccs 13
cts 13
cp 1
rs 10
c 0
b 0
f 0

5 Methods

Rating   Name   Duplication   Size   Complexity  
A create() 0 4 1
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\Twilio;
4
5
abstract class TwilioMessage
6
{
7
    /**
8
     * The message content.
9
     *
10
     * @var string
11
     */
12
    public $content;
13
14
    /**
15
     * The phone number the message should be sent from.
16
     *
17
     * @var string
18
     */
19
    public $from;
20
21
    /**
22
     * Create a message object.
23
     * @param string $content
24
     * @return static
25
     */
26 8
    public static function create($content = '')
27
    {
28 8
        return new static($content);
29
    }
30
31
    /**
32
     * Create a new message instance.
33
     *
34
     * @param  string $content
35
     */
36 27
    public function __construct($content = '')
37
    {
38 27
        $this->content = $content;
39 27
    }
40
41
    /**
42
     * Set the message content.
43
     *
44
     * @param  string $content
45
     * @return $this
46
     */
47 2
    public function content($content)
48
    {
49 2
        $this->content = $content;
50
51 2
        return $this;
52
    }
53
54
    /**
55
     * Set the phone number the message should be sent from.
56
     *
57
     * @param  string $from
58
     * @return $this
59
     */
60 6
    public function from($from)
61
    {
62 6
        $this->from = $from;
63
64 6
        return $this;
65
    }
66
67
    /**
68
     * Get the from address.
69
     *
70
     * @return string
71
     */
72 3
    public function getFrom()
73
    {
74 3
        return $this->from;
75
    }
76
}
77