Feature summary
Provide a generic data record which can be accessed by key or by attribute.
Use case(s):
The [[file:///C:/pwb/GIT/core/docs/_build/html/api_ref/pywikibot.page.html#page._revision.Revision|Revision]] class is such a Mapping. It holds data retrieved from the API, transforms selected values to higher-level objects, and provides access either by attribute or by item key.
Benefits:
Other Mappings can be provided, e.g. for user contributions, log entries, event streams, and other API data. An upcast function should be available to transform API data into higher-level classes such as Page or Timestamp.
Revision cannot be reused by other API methods because its upcast method is specific to revisions and also takes into account that formatversion=1 is used.