DocumentNode   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 2
eloc 4
dl 0
loc 12
ccs 4
cts 4
cp 1
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A render() 0 3 1
A getParent() 0 3 1
1
<?php
2
/**
3
 * (c) Steve Nebes <[email protected]>.
4
 *
5
 *  For the full copyright and license information, please view the LICENSE
6
 *  file that was distributed with this source code.
7
 */
8
9
namespace SN\HtmlSanitizer\Node;
10
11
/**
12
 * Root node of the sanitized HTML. Contains all the other nodes.
13
 *
14
 * @author Steve Nebes <[email protected]>
15
 *
16
 * @internal
17
 */
18
class DocumentNode implements NodeInterface
19
{
20
    use HasChildrenTrait;
21
22 1
    public function getParent(): ?NodeInterface
23
    {
24 1
        return null;
25
    }
26
27 7
    public function render(): string
28
    {
29 7
        return $this->renderChildren();
30
    }
31
}
32