Formatter   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 23
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 23
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A setFormatterFactory() 0 4 1
A format() 0 4 1
1
<?php
2
3
namespace Glooby\Debug\Formatter;
4
5
/**
6
 * @author Emil Kilhage
7
 */
8
class Formatter implements FormatterInterface
9
{
10
    /**
11
     * @var FormatterFactoryInterface
12
     */
13
    private $formatterFactory;
14
15
    /**
16
     * @param FormatterFactoryInterface $formatterFactory
17
     */
18
    public function setFormatterFactory($formatterFactory)
19
    {
20
        $this->formatterFactory = $formatterFactory;
21
    }
22
23
    /**
24
     * {@inheritdoc}
25
     */
26
    public function format($response)
27
    {
28
        return $this->formatterFactory->factory($response)->format($response);
29
    }
30
}
31