Details
-
Suggestion
-
Resolution: Out of scope
-
Not Evaluated
-
None
-
5.0.0
-
None
Description
JsonDbClient methods create, update, and remove each have one signature with QVariant as the first parameter. They are "dynamically polymorphic": if the QVariant contains a variant map, it is considered to be one Json object, in it's a QMap<QUuid, JsonDbObject>, it's a list of objects (in fact, why does it need to be populated as a map when each object carries its own uuid and the uuids are practically unique by the way of creation?).
Could there be overloaded versions of these methods that would allow to pass JsonDbObject and a collection of such objects as explicit types checked by the C++ compiler?
See also QTBUG-23705 for another issue with the API where too much dynamic typing hurts.