xref: /dokuwiki/inc/Parsing/ParserMode/Emphasis.php (revision 71096e46fcbfaeaa808667aba794e77fe2780169)
1<?php
2
3namespace dokuwiki\Parsing\ParserMode;
4
5class Emphasis extends AbstractFormatting
6{
7    /** @inheritdoc */
8    public function getSort()
9    {
10        return 80;
11    }
12
13    /** @inheritdoc */
14    protected function getModeName(): string
15    {
16        return 'emphasis';
17    }
18
19    /**
20     * @inheritdoc
21     * @see https://github.com/dokuwiki/dokuwiki/issues/384
22     * @see https://github.com/dokuwiki/dokuwiki/issues/763
23     * @see https://github.com/dokuwiki/dokuwiki/issues/1468
24     */
25    protected function getEntryPattern(): string
26    {
27        return '//(?=[^\x00]*[^:])';
28    }
29
30    /** @inheritdoc */
31    protected function getExitPattern(): string
32    {
33        return '//';
34    }
35}
36