ValueFormatter for formatting objects that may be encountered in parameters of ValueValidators\Error objects as wikitext.
More...
|
| __construct (ValueFormatter $dataValueFormatter, EntityIdFormatter $entityIdFormatter, SiteLookup $sites, Language $language) |
|
| format ( $value) |
|
ValueFormatter for formatting objects that may be encountered in parameters of ValueValidators\Error objects as wikitext.
- Copyright
- GPL-2.0-or-later
- Author
- Daniel Kinzler
◆ __construct()
Wikibase\Repo\Localizer\MessageParameterFormatter::__construct |
( |
ValueFormatter |
$dataValueFormatter, |
|
|
EntityIdFormatter |
$entityIdFormatter, |
|
|
SiteLookup |
$sites, |
|
|
Language |
$language |
|
) |
| |
- Parameters
-
ValueFormatter | $dataValueFormatter | A formatter for turning DataValues into wikitext. |
EntityIdFormatter | $entityIdFormatter | An entity id formatter returning wikitext. |
SiteLookup | $sites | |
Language | $language | |
◆ format()
Wikibase\Repo\Localizer\MessageParameterFormatter::format |
( |
|
$value | ) |
|
- See also
- ValueFormatter::format
- Parameters
-
mixed | $value | The value to format |
- Returns
- string The formatted value (as wikitext).
- Exceptions
-
◆ formatEntityId()
Wikibase\Repo\Localizer\MessageParameterFormatter::formatEntityId |
( |
EntityId |
$entityId | ) |
|
|
private |
- Parameters
-
- Returns
- string The formatted ID (as a wikitext link).
◆ formatObject()
Wikibase\Repo\Localizer\MessageParameterFormatter::formatObject |
( |
|
$value | ) |
|
|
private |
- Parameters
-
- Returns
- string The formatted value (as wikitext).
◆ formatSiteLink()
Wikibase\Repo\Localizer\MessageParameterFormatter::formatSiteLink |
( |
SiteLink |
$link | ) |
|
|
private |
- Parameters
-
- Returns
- string The formatted link (as a wikitext link).
◆ formatValueList()
Wikibase\Repo\Localizer\MessageParameterFormatter::formatValueList |
( |
array |
$values | ) |
|
|
private |
◆ $dataValueFormatter
Wikibase\Repo\Localizer\MessageParameterFormatter::$dataValueFormatter |
|
private |
◆ $entityIdFormatter
Wikibase\Repo\Localizer\MessageParameterFormatter::$entityIdFormatter |
|
private |
◆ $language
Wikibase\Repo\Localizer\MessageParameterFormatter::$language |
|
private |
◆ $sites
Wikibase\Repo\Localizer\MessageParameterFormatter::$sites |
|
private |
◆ $valueLocalizer
Wikibase\Repo\Localizer\MessageParameterFormatter::$valueLocalizer |
|
private |
The documentation for this class was generated from the following file: