ParsedownParser::parse()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 1
dl 0
loc 2
rs 10
c 1
b 0
f 0
1
<?php declare(strict_types=1);
2
namespace html_go\markdown;
3
4
use Parsedown;
5
6
/**
7
 * Implementation for <code>Parsedown</code>.
8
 * @author Marc L. Veary
9
 * @since 1.0
10
 */
11
final class ParsedownParser implements MarkdownParser
12
{
13
    private Parsedown $parser;
14
15
    public function __construct() {
16
        $this->parser = new Parsedown();
17
    }
18
19
    public function parse(string $text): string {
20
        return $this->parser->parse($text);
21
    }
22
}
23