Sustancias   A
last analyzed

Complexity

Total Complexity 11

Size/Duplication

Total Lines 94
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 31
c 1
b 0
f 0
dl 0
loc 94
ccs 32
cts 32
cp 1
rs 10
wmc 11

11 Methods

Rating   Name   Duplication   Size   Complexity  
A sedantes() 0 3 1
A cocaina() 0 3 1
A inhalables() 0 3 1
A cannabis() 0 3 1
A alcohol() 0 3 1
A __construct() 0 22 1
A opiaceos() 0 3 1
A alucinogenos() 0 3 1
A anfetamina() 0 3 1
A otros() 0 3 1
A tabaco() 0 3 1
1
<?php declare(strict_types=1);
2
namespace src\sustancias;
3
4
class Sustancias
5
{
6
    private Tabaco $_tabaco;
7
8
    private Alcohol $_alcohol;
9
10
    private Cannabis $_cannabis;
11
12
    private Cocaina $_cocaina;
13
14
    private Anfetamina $_anfetamina;
15
16
    private Inhalables $_inhalables;
17
18
    private Sedantes $_sedantes;
19
20
    private Alucinogenos $_alucinogenos;
21
22
    private Opiaceos $_opiaceos;
23
24
    private Otros $_otros;
25
26 11
    public function __construct(
27
        Tabaco $tabaco,
28
        Alcohol $alcohol,
29
        Cannabis $cannabis,
30
        Cocaina $cocaina,
31
        Anfetamina $anfetamina,
32
        Inhalables $inhalables,
33
        Sedantes $sedantes,
34
        Alucinogenos $alucinogenos,
35
        Opiaceos $opiaceos,
36
        Otros $otros
37
    ) {
38 11
        $this->_tabaco = $tabaco;
39 11
        $this->_alcohol = $alcohol;
40 11
        $this->_cannabis = $cannabis;
41 11
        $this->_cocaina = $cocaina;
42 11
        $this->_anfetamina = $anfetamina;
43 11
        $this->_inhalables = $inhalables;
44 11
        $this->_sedantes = $sedantes;
45 11
        $this->_alucinogenos = $alucinogenos;
46 11
        $this->_opiaceos = $opiaceos;
47 11
        $this->_otros = $otros;
48 11
    }
49
50 11
    public function tabaco(): Tabaco
51
    {
52 11
        return $this->_tabaco;
53
    }
54
55 11
    public function alcohol(): Alcohol
56
    {
57 11
        return $this->_alcohol;
58
    }
59
60 11
    public function cannabis(): Cannabis
61
    {
62 11
        return $this->_cannabis;
63
    }
64
65 11
    public function cocaina(): Cocaina
66
    {
67 11
        return $this->_cocaina;
68
    }
69
70 11
    public function anfetamina(): Anfetamina
71
    {
72 11
        return $this->_anfetamina;
73
    }
74
75 11
    public function inhalables(): Inhalables
76
    {
77 11
        return $this->_inhalables;
78
    }
79
80 11
    public function sedantes(): Sedantes
81
    {
82 11
        return $this->_sedantes;
83
    }
84
85 11
    public function alucinogenos(): Alucinogenos
86
    {
87 11
        return $this->_alucinogenos;
88
    }
89
90 11
    public function opiaceos(): Opiaceos
91
    {
92 11
        return $this->_opiaceos;
93
    }
94
95 11
    public function otros(): Otros
96
    {
97 11
        return $this->_otros;
98
    }
99
}
100