Manual:Preprocessor_DOM.php

From MediaWiki.org
Jump to navigation Jump to search
This page is a translated version of the page Manual:Preprocessor DOM.php and the translation is 50% complete.

Other languages:
English • ‎dansk • ‎español • ‎polski • ‎português do Brasil • ‎日本語

説明

This file contains functions for recursively expanding variables, parser functions, templates, and template parameters. As an intermediate step it creates an XML DOM representation of the wikitext (see also Extension:ExpandTemplates#XML parse tree ).

Parser.php から呼び出される関数は以下を含みます:

  • function preprocessToObj - preprocesses wikitext and returns a document tree, also called DOM tree. 以下を呼び出します:
    • function preprocessToXml - parses the wikitext with respect to double braces {{...}}, triple braces {{{...}}}, and double rectangular brackets [[...]], and also finds the pipes | and the equals signs =. 結果は DOM ツリーです。
  • function expand - produces the expanded wikitext from the DOM tree. It performs double-brace expansion, calling function braceSubstitution in Parser.php, and triple-brace expansion, calling function argSubstitution in Parser.php.

関連項目

外部リンク