1 | <?php |
||
20 | final class FrontMatter implements FrontMatterInterface, FrontMatterExistsInterface |
||
21 | { |
||
22 | /** @var string */ |
||
23 | private $startSep; |
||
24 | |||
25 | /** @var string */ |
||
26 | private $endSep; |
||
27 | |||
28 | /** @var ProcessorInterface */ |
||
29 | private $processor; |
||
30 | |||
31 | /** @var string */ |
||
32 | private $regexp; |
||
33 | |||
34 | public static function createYaml(): self |
||
38 | |||
39 | public static function createToml(): self |
||
43 | |||
44 | public static function createJson(): self |
||
48 | |||
49 | public function __construct(ProcessorInterface $processor = null, string $startSep = '---', string $endSep = '---') |
||
57 | |||
58 | /** |
||
59 | * {@inheritdoc} |
||
60 | */ |
||
61 | public function parse(string $source): Document |
||
71 | |||
72 | /** |
||
73 | * {@inheritdoc} |
||
74 | */ |
||
75 | public function dump(Document $document): string |
||
84 | |||
85 | /** |
||
86 | * {@inheritdoc} |
||
87 | */ |
||
88 | public function exists(string $source): bool |
||
92 | } |
||
93 |