History log of /dokuwiki/inc/Parsing/Parser.php (Results 1 – 10 of 10)
Revision Date Author Comments
# 71096e46 18-Apr-2026 Andreas Gohr <andi@splitbrain.org>

move handler methods into ParserMode classes and rename Handler

Each ParserMode class now implements handle() from ModeInterface,
containing the token handling logic that previously lived as individ

move handler methods into ParserMode classes and rename Handler

Each ParserMode class now implements handle() from ModeInterface,
containing the token handling logic that previously lived as individual
methods on Doku_Handler.

The Handler class (formerly Doku_Handler) is the single dispatch point:
Lexer passes tokens to Handler::handleToken() which routes to mode
objects, plugins, or returns false. The Lexer only tokenizes and
resolves mapHandler aliases.

Key changes:
- Add handle() to ModeInterface, implemented by all mode classes
- Move Doku_Handler to dokuwiki\Parsing\Handler namespace
- File extends Code (shared parsing via $type property)
- Quotes uses mapHandler() + Handler::getModeName() for sub-modes
- Media::parseMedia() replaces Doku_Handler_Parse_Media()
- Code::parseHighlightOptions() replaces parse_highlight_options()
- Per-parse state (footnote, doublequote) stays on Handler
- Deprecated wrappers kept for base/header/internallink/media
- Class alias and rector rules added for backward compatibility

show more ...


# 7958e698 16-Apr-2026 Andreas Gohr <andi@splitbrain.org>

decouple hardcoded mode names in Eol and Preformatted

Eol.php hardcoded ['listblock', 'table'] as modes to skip, and
Preformatted.php hardcoded [\*\-] as a negative lookahead for list
markers. Both

decouple hardcoded mode names in Eol and Preformatted

Eol.php hardcoded ['listblock', 'table'] as modes to skip, and
Preformatted.php hardcoded [\*\-] as a negative lookahead for list
markers. Both embed knowledge that belongs to the respective block
modes, not to Eol/Preformatted. Adding a new block mode that handles
its own EOL or uses different line start markers would require editing
these unrelated files — a hidden coupling.

Listblock and Table now register themselves on ModeRegistry during
preConnect(). Eol queries getBlockEolModes() and Preformatted queries
getLineStartMarkers() to build its lookahead dynamically. Each mode
owns its own data, and new block modes can participate without touching
unrelated files.

show more ...


# 093fe67e 07-Mar-2026 Andreas Gohr <andi@splitbrain.org>

updated rector and applied it


# d4f83172 31-Aug-2023 Andreas Gohr <andi@splitbrain.org>

code style: line breaks


# 177d6836 31-Aug-2023 Andreas Gohr <andi@splitbrain.org>

coding style: control flow whitespaces


# d868eb89 30-Aug-2023 Andreas Gohr <andi@splitbrain.org>

codestyle adjustments: function declaration braces/spaces


# 8c7c53b0 30-Aug-2023 Andreas Gohr <andi@splitbrain.org>

codestyle adjustments: class declaration braces


# bcaec9f4 29-Aug-2023 Andreas Gohr <andi@splitbrain.org>

Apply rector fixes to inc/Parsing


# 1b008e87 14-Jan-2020 Michael Große <mic.grosse@googlemail.com>

Restore some backwards compatibility for injected handlers

Some plugins, for example the move plugin, use their own handler class.
We need to give these plugins time to adjust their code.

This shou

Restore some backwards compatibility for injected handlers

Some plugins, for example the move plugin, use their own handler class.
We need to give these plugins time to adjust their code.

This should restore the functionality of the move plugin. We still need
to extract the handler class itself.

It also adds another debug method for triggering the deprecation event,
since none of the two existing methods are suitable here. This
dbgCustomDeprecationEvent method should be used sparingly and only where
the other two don't work.

Co-authored-by: Phy <git@phy25.com>

show more ...


# d4d8fb18 04-May-2018 Andreas Gohr <andi@splitbrain.org>

moved Parser to Parsing namespace