Passed
Push — main ( e3dcf6...088d44 )
by Osvaldo
01:32
created

DondeYDondeConParametro   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 24
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 8
c 1
b 0
f 0
dl 0
loc 24
rs 10
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A setDonde() 0 3 1
A __construct() 0 4 1
A donde() 0 3 1
A datos() 0 3 1
1
<?php
2
namespace src\pdodatabase\elementos;
3
4
use src\interfaces\DondeYDondeInterface;
5
use src\interfaces\ElementoConParametroInterface;
6
7
class DondeYDondeConParametro
8
{
9
    private $_donde;
10
    private $_datos;
11
12
    public function __construct(DondeYDondeInterface $Donde, ElementoConParametroInterface $ElementosConParametro)
13
    {
14
        $this->_datos = $Donde->datos();
15
        $this->_donde = $this->setDonde($Donde,$ElementosConParametro);
16
    }
17
18
    public function donde(): string
19
    {
20
        return $this->_donde;
21
    }
22
23
    public function datos(): array
24
    {
25
        return $this->_datos;
26
    }
27
28
    private function setDonde($Donde,$elementosConParametro): string
29
    {
30
        return $Donde->donde().$elementosConParametro->parametro();
31
    }
32
}