SmsReplyCallbackEvent::getSmsReplyCallback()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
/*
4
 * This file is part of the smsmode-bundle package.
5
 *
6
 * (c) 2019 WEBEWEB
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace WBW\Bundle\SmsModeBundle\Event;
13
14
use WBW\Bundle\CoreBundle\Event\AbstractEvent as BaseEvent;
15
use WBW\Library\SmsMode\Model\SmsReplyCallback;
16
17
/**
18
 * SMS reply callback event.
19
 *
20
 * @author webeweb <https://github.com/webeweb>
21
 * @package WBW\Bundle\SmsModeBundle\Event
22
 */
23
class SmsReplyCallbackEvent extends BaseEvent {
24
25
    /**
26
     * Event name.
27
     *
28
     * @var string
29
     */
30
    const EVENT_NAME = "wbw.smsmode.event.sms_reply_callback";
31
32
    /**
33
     * SMS reply callback.
34
     *
35
     * @var SmsReplyCallback
36
     */
37
    private $smsReplyCallback;
38
39
    /**
40
     * Constructor.
41
     *
42
     * @param SmsReplyCallback $smsReplyCallback The SMS reply callback.
43
     */
44
    public function __construct(SmsReplyCallback $smsReplyCallback) {
45
        parent::__construct(self::EVENT_NAME);
46
47
        $this->setSmsReplyCallback($smsReplyCallback);
48
    }
49
50
    /**
51
     * Get the SMS reply callback.
52
     *
53
     * @return SmsReplyCallback Returns the SMS reply callback.
54
     */
55
    public function getSmsReplyCallback(): SmsReplyCallback {
56
        return $this->smsReplyCallback;
57
    }
58
59
    /**
60
     * Set the SMS reply callback.
61
     *
62
     * @param SmsReplyCallback $smsReplyCallback The SMS reply callback.
63
     * @return SmsReplyCallbackEvent Returns this SMS reply callback event.
64
     */
65
    public function setSmsReplyCallback(SmsReplyCallback $smsReplyCallback): SmsReplyCallbackEvent {
66
        $this->smsReplyCallback = $smsReplyCallback;
67
        return $this;
68
    }
69
}
70