EscapingValueFormatter wraps another ValueFormatter and applies a transformation (escaping) to that formatter's output.
More...
EscapingValueFormatter wraps another ValueFormatter and applies a transformation (escaping) to that formatter's output.
- Copyright
- GPL-2.0-or-later
- Author
- Daniel Kinzler
◆ __construct()
Wikibase\Lib\Formatters\EscapingValueFormatter::__construct |
( |
ValueFormatter | $formatter, |
|
|
| $escapeCallback ) |
- Parameters
-
ValueFormatter | $formatter | A formatter returning plain text. |
callable | $escapeCallback | A callable taking plain text and returning escaped text. |
- Exceptions
-
◆ format()
Wikibase\Lib\Formatters\EscapingValueFormatter::format |
( |
| $value | ) |
|
- See also
- ValueFormatter::format
- Parameters
-
- Returns
- string Typically wikitext or HTML, depending on the $escapeCallback provided.
◆ $escapeCallback
Wikibase\Lib\Formatters\EscapingValueFormatter::$escapeCallback |
|
private |
◆ $formatter
Wikibase\Lib\Formatters\EscapingValueFormatter::$formatter |
|
private |
The documentation for this class was generated from the following file: