Wikibase
MediaWiki Wikibase extension
|
Interface for consumers (typically a formatter) of auto-generated edit summary lines that describe edits made on Wikibase entities. More...
Public Member Functions | |
getMessageKey () | |
Returns a fragment of a message key, missing the "wikibase-…-summary-" prefix. More... | |
getLanguageCode () | |
The language of the content that was edited, e.g. More... | |
getCommentArgs () | |
Comment arguments will be used as parameters for the message. More... | |
getAutoSummaryArgs () | |
An array or associative array of values to describe the new revision this summary represents, for example: More... | |
getUserSummary () | |
The user-provided edit summary, or null if none was given. More... | |
Interface for consumers (typically a formatter) of auto-generated edit summary lines that describe edits made on Wikibase entities.
Wikibase edits are usually atomic, e.g. a single label in a single language was added. The auto-summary describing this edit uses the message "wikibase-entity-summary-wbsetlabel-add", and mentions the new label as well as it's language code.
Wikibase\Lib\FormatableSummary::getAutoSummaryArgs | ( | ) |
An array or associative array of values to describe the new revision this summary represents, for example:
The auto-summary arguments are compiled to a string and form a plain, unlocalized, automatically generated summary that is appended to the message.
A numerically indexed array will be displayed as a comma separated list of values, e.g. "a, b". An associative array will be displayed as a comma separated list of values prefixed with keys, e.g. "en: en-label, fr: fr-label".
Elements in the array that are not strings will be forcefully converted to strings, utilizing proper formatters.
Implemented in Wikibase\Lib\Summary.
Wikibase\Lib\FormatableSummary::getCommentArgs | ( | ) |
Comment arguments will be used as parameters for the message.
The element with index 0 in the array will become $3 in the message, and so on.
Elements in the array that are not strings will be forcefully converted to strings, utilizing proper formatters.
Implemented in Wikibase\Lib\Summary.
Wikibase\Lib\FormatableSummary::getLanguageCode | ( | ) |
The language of the content that was edited, e.g.
when the summary represents an edit of a label, description, or set of aliases in a specific language. Not set if not applicable.
Will be used as argument $2 in the message.
Implemented in Wikibase\Lib\Summary.
Wikibase\Lib\FormatableSummary::getMessageKey | ( | ) |
Returns a fragment of a message key, missing the "wikibase-…-summary-" prefix.
When displayed to the user, the message key will be prefixed with either "wikibase-<entity type>-summary-", or with "wikibase-entity-summary-" if no message specific to the entity type exists.
Parameters of the message will be:
Implemented in Wikibase\Lib\Summary.
Wikibase\Lib\FormatableSummary::getUserSummary | ( | ) |
The user-provided edit summary, or null if none was given.
Typically provided via the API.
If both a user-provided summary as well as auto-summary arguments are provided (
Implemented in Wikibase\Lib\Summary.