TracyDumper   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
dl 0
loc 16
ccs 5
cts 5
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A dump() 0 3 1
1
<?php
2
3
namespace Yep\WorkflowLogger\ContextDumper;
4
5
use Tracy\Dumper;
6
7
/**
8
 * Class TracyDumper
9
 *
10
 * @package Yep\WorkflowLogger\ContextDumper
11
 * @author  Martin Zeman (Zemistr) <[email protected]>
12
 */
13
class TracyDumper implements DumperInterface
14
{
15
    /**
16
     * @var array
17
     */
18
    protected $options;
19
20 1
    public function __construct(
21
      array $options = [Dumper::DEPTH => 8, Dumper::TRUNCATE => 512]
22
    ) {
23 1
        $this->options = $options;
24 1
    }
25
26 1
    public function dump(array $context)
27
    {
28 1
        return Dumper::toText($context, $this->options);
29
    }
30
}
31