Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
0.00% covered (danger)
0.00%
0 / 3
0.00% covered (danger)
0.00%
0 / 2
CRAP
0.00% covered (danger)
0.00%
0 / 1
JustChildrenHandler
0.00% covered (danger)
0.00%
0 / 3
0.00% covered (danger)
0.00%
0 / 2
6
0.00% covered (danger)
0.00%
0 / 1
 __construct
0.00% covered (danger)
0.00%
0 / 1
0.00% covered (danger)
0.00%
0 / 1
2
 handle
0.00% covered (danger)
0.00%
0 / 2
0.00% covered (danger)
0.00%
0 / 1
2
1<?php
2declare( strict_types = 1 );
3
4namespace Wikimedia\Parsoid\Html2Wt\DOMHandlers;
5
6// Just serialize the children, ignore the (implicit) tag
7use Wikimedia\Parsoid\DOM\Element;
8use Wikimedia\Parsoid\DOM\Node;
9use Wikimedia\Parsoid\Html2Wt\SerializerState;
10
11class JustChildrenHandler extends DOMHandler {
12
13    public function __construct() {
14        parent::__construct( false );
15    }
16
17    /** @inheritDoc */
18    public function handle(
19        Element $node, SerializerState $state, bool $wrapperUnmodified = false
20    ): ?Node {
21        $state->serializeChildren( $node );
22        return $node->nextSibling;
23    }
24
25}