Completed
Push — master ( 201e9c...877b57 )
by Artem
11:08
created

SmsEvent::getFrom()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 1
Metric Value
c 1
b 0
f 1
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
/*
3
 * This file is part of the FreshSinchBundle
4
 *
5
 * (c) Artem Genvald <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
namespace Fresh\SinchBundle\Event;
12
13
/**
14
 * SmsEvent.
15
 *
16
 * @author Artem Genvald <[email protected]>
17
 */
18
class SmsEvent
19
{
20
    /**
21
     * @var string $number Number
22
     */
23
    private $number;
24
25
    /**
26
     * @var string $message Message
27
     */
28
    private $message;
29
30
    /**
31
     * @var string|null $from From
32
     */
33
    private $from;
34
35
    /**
36
     * Constructor.
37
     *
38
     * @param string      $number  Number
39
     * @param string      $message Message
40
     * @param string|null $from    From
41
     */
42
    public function __construct($number, $message, $from = null)
43
    {
44
        $this->number  = $number;
45
        $this->message = $message;
46
        $this->from    = $from;
47
    }
48
49
    /**
50
     * Get number.
51
     *
52
     * @return string Number
53
     */
54
    public function getNumber()
55
    {
56
        return $this->number;
57
    }
58
59
    /**
60
     * Set number.
61
     *
62
     * @param string $number Number
63
     *
64
     * @return $this
65
     */
66
    public function setNumber($number)
67
    {
68
        $this->number = $number;
69
70
        return $this;
71
    }
72
73
    /**
74
     * Get message.
75
     *
76
     * @return string Message
77
     */
78
    public function getMessage()
79
    {
80
        return $this->message;
81
    }
82
83
    /**
84
     * Set message.
85
     *
86
     * @param string $message Message
87
     *
88
     * @return $this
89
     */
90
    public function setMessage($message)
91
    {
92
        $this->message = $message;
93
94
        return $this;
95
    }
96
97
    /**
98
     * Get from.
99
     *
100
     * @return null|string From
101
     */
102
    public function getFrom()
103
    {
104
        return $this->from;
105
    }
106
107
    /**
108
     * Set from.
109
     *
110
     * @param null|string $from From
111
     *
112
     * @return $this
113
     */
114
    public function setFrom($from)
115
    {
116
        $this->from = $from;
117
118
        return $this;
119
    }
120
}
121