Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 3.0175 |
Changes | 0 |
1 | <?php |
||
36 | 303 | public function parse(InlineParserContext $inlineContext): bool |
|
37 | { |
||
38 | 303 | $cursor = $inlineContext->getCursor(); |
|
39 | 303 | if ($cursor->getCharacter() !== '<') { |
|
40 | return false; |
||
41 | } |
||
42 | |||
43 | 303 | if ($m = $cursor->match('/^' . RegexHelper::PARTIAL_HTMLTAG . '/i')) { |
|
44 | 225 | $inlineContext->getContainer()->appendChild(new HtmlInline($m)); |
|
45 | |||
46 | 225 | return true; |
|
47 | } |
||
48 | |||
49 | 81 | return false; |
|
50 | } |
||
51 | } |
||
52 |