https://bugzilla.wikimedia.org/show_bug.cgi?id=72183
--- Comment #1 from Adrian Lang <adrian.l...@wikimedia.de> --- After a discussion today we agreed to the following: * The data model has to have knowledge of the fact that an entity can have a term for another language than the term is in * The data model serializers and deserializers have to have knowledge of the fact that there are language fallbacks Premises: * We want to provide a view on our data which includes for example language fallbacks (for the API, for wbEntity, …) * We want to enable users (for example the JavaScript frontend code) to work with these views * Data model deserializers should return data model objects * Data model deserializers should not lose information Necessary steps: * Make TermList a TermMap * Make TermMap::_construct respect the keys of its parameter * Make TermMap::setTerm expect a language parameter (adapt callers in DM) * Make EntityDeserializer::deserializeValuePerLanguageSerialization respect and pass the keys * Make EntityDeserializer::setAliasesFromSerialization respect and pass the keys * Make EntityDeserializer::assertIsValidValueSerialization assert on the key * Make FingerprintSerializer::serializeValuePerLanguageArray (and everybody above it) aware of the fact that there are different ways to serialize a map of terms (with and without keys, with and without fallback terms included) * Write high-level, implementation-independent documentation on this decision -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list Wikibugs-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikibugs-l