Completed
Push — master ( 21e214...2bd91c )
by Irfaq
02:34
created

UpdateWasReceived   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 60%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 24
ccs 3
cts 5
cp 0.6
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A getUpdate() 0 4 1
1
<?php
2
3
namespace Telegram\Bot\Events;
4
5
use League\Event\AbstractEvent;
6
use Telegram\Bot\Objects\Update;
7
8
class UpdateWasReceived extends AbstractEvent
9
{
10
    /**
11
     * @var Update
12
     */
13
    private $update;
14
15
    /**
16
     * UpdateWasReceived constructor.
17
     * @param Update $update
18
     */
19 6
    public function __construct(Update $update)
20
    {
21 6
        $this->update = $update;
22 6
    }
23
24
    /**
25
     * @return Update
26
     */
27
    public function getUpdate()
28
    {
29
        return $this->update;
30
    }
31
}
32