| Conditions | 3 |
| Paths | 3 |
| Total Lines | 14 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 3.0261 |
| Changes | 0 | ||
| 1 | <?php |
||
| 37 | 48 | public function parse(InlineParserContext $inlineContext): bool |
|
| 38 | { |
||
| 39 | 48 | if ($inlineContext->getCursor()->getCharacter() !== '&') { |
|
| 40 | return false; |
||
| 41 | } |
||
| 42 | |||
| 43 | 48 | if ($m = $inlineContext->getCursor()->match('/^' . RegexHelper::PARTIAL_ENTITY . '/i')) { |
|
| 44 | 36 | $inlineContext->getContainer()->appendChild(new Text(Html5EntityDecoder::decode($m))); |
|
| 45 | |||
| 46 | 36 | return true; |
|
| 47 | } |
||
| 48 | |||
| 49 | 18 | return false; |
|
| 50 | } |
||
| 51 | } |
||
| 52 |