Wikibase
MediaWiki Wikibase extension
Loading...
Searching...
No Matches
Wikibase\Lib\Formatters\UnDeserializableValueFormatter Class Reference

A ValueFormatter for UnDeserializableValue objects. More...

+ Inheritance diagram for Wikibase\Lib\Formatters\UnDeserializableValueFormatter:
+ Collaboration diagram for Wikibase\Lib\Formatters\UnDeserializableValueFormatter:

Public Member Functions

 __construct (FormatterOptions $options=null)
 
 format ( $dataValue)
 

Public Attributes

const OPT_MESSAGE_KEY = 'unDeserializableMessage'
 

Detailed Description

A ValueFormatter for UnDeserializableValue objects.

It acts as a fallback when neither the property type nor the value type are known. It does not show any information from the value, but the message "The value is invalid and cannot be displayed" instead. The message can be changed via an option.

Author
Katie Filbert < aude..nosp@m.wiki.nosp@m.@gmai.nosp@m.l.co.nosp@m.m >

Constructor & Destructor Documentation

◆ __construct()

Wikibase\Lib\Formatters\UnDeserializableValueFormatter::__construct ( FormatterOptions  $options = null)
Parameters
FormatterOptions | null$options

Member Function Documentation

◆ format()

Wikibase\Lib\Formatters\UnDeserializableValueFormatter::format (   $dataValue)
See also
ValueFormatter::format
Parameters
DataValue$dataValueUnused in this implementation.
Returns
string Unescaped message text.

Member Data Documentation

◆ OPT_MESSAGE_KEY

const Wikibase\Lib\Formatters\UnDeserializableValueFormatter::OPT_MESSAGE_KEY = 'unDeserializableMessage'

The documentation for this class was generated from the following file: