Completed
Pull Request — master (#20)
by Kevin
03:55
created

NullClientProfiler   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 3
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 26
ccs 0
cts 7
cp 0
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A startProfiling() 0 4 1
A stopProfiling() 0 4 1
A getCalls() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the JarvisBundle package.
5
 *
6
 * For the full copyright and license information, please view the LICENSE
7
 * file that was distributed with this source code.
8
 */
9
10
namespace LinkValue\JarvisBundle\Profiler;
11
12
use Symfony\Component\Stopwatch\StopwatchEvent;
13
14
/**
15
 * NullClientProfiler.
16
 *
17
 * @package JarvisBundle
18
 * @author Oliver Thebault <[email protected]>
19
 */
20
class NullClientProfiler implements ClientProfilerInterface
21
{
22
    /**
23
     * {@inheritdoc}
24
     */
25
    public function startProfiling($message)
26
    {
27
        return new StopwatchEvent(microtime());
28
    }
29
30
    /**
31
     * {@inheritdoc}
32
     */
33
    public function stopProfiling(StopwatchEvent $event, $result)
34
    {
35
        $event->stop();
36
    }
37
38
    /**
39
     * {@inheritdoc}
40
     */
41
    public function getCalls()
42
    {
43
        return array();
44
    }
45
}
46