Completed
Push — master ( 7f5a29...8ce298 )
by Scott
13s
created

PhpMdLoaderStrict::getDescription()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 0
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
1
<?php
2
namespace exussum12\CoverageChecker;
3
4
use XMLReader;
5
6
/**
7
 * Class PhpMdLoaderStrict
8
 * Used for parsing phpmd xml output
9
 * Strict mode reports errors multiple times
10
 * @package exussum12\CoverageChecker
11
 */
12
class PhpMdLoaderStrict extends PhpMdLoader
13
{
14
    /**
15
     * {@inheritdoc}
16
     * Strict reports every offending line not just the first
17
     */
18
    public function isValidLine($file, $lineNumber)
19
    {
20
        return empty($this->errors[$file][$lineNumber]);
21
    }
22
23
    /**
24
     * {@inheritdoc}
25
     */
26
    public static function getDescription()
27
    {
28
        return 'Parses the xml report format of phpmd, this mode ' .
29
            'reports multi line violations once per line they occur ';
30
    }
31
}
32