Completed
Branch 4.0 (c710b5)
by Serhii
02:04
created

Result   A

Complexity

Total Complexity 5

Size/Duplication

Total Lines 64
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 4

Importance

Changes 0
Metric Value
wmc 5
lcom 0
cbo 4
dl 0
loc 64
rs 10
c 0
b 0
f 0

5 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 7 1
A getOs() 0 4 1
A getBrowser() 0 4 1
A getDevice() 0 4 1
A getRobot() 0 4 1
1
<?php
2
3
namespace EndorphinStudio\Detector\Data;
4
5
class Result
6
{
7
    /**
8
     * @var Os
9
     */
10
    protected $os;
11
    /**
12
     * @var Browser
13
     */
14
    protected $browser;
15
    /**
16
     * @var Device
17
     */
18
    protected $device;
19
    /**
20
     * @var Robot
21
     */
22
    protected $robot;
23
24
    /**
25
     * @var boolean
26
     */
27
    protected $isRobot = false;
28
29
    public function __construct()
30
    {
31
        $this->os = new Os($this);
32
        $this->device = new Device($this);
33
        $this->browser = new Browser($this);
34
        $this->robot = new Robot($this);
35
    }
36
37
    /**
38
     * @return Os
39
     */
40
    public function getOs(): Os
41
    {
42
        return $this->os;
43
    }
44
45
    /**
46
     * @return Browser
47
     */
48
    public function getBrowser(): Browser
49
    {
50
        return $this->browser;
51
    }
52
53
    /**
54
     * @return Device
55
     */
56
    public function getDevice(): Device
57
    {
58
        return $this->device;
59
    }
60
61
    /**
62
     * @return Robot
63
     */
64
    public function getRobot(): Robot
65
    {
66
        return $this->robot;
67
    }
68
}