D19087: Add standalone conversion functions for PropertyMap to Json and vice versa

Alexander Stippich noreply at phabricator.kde.org
Sat Mar 30 08:41:17 GMT 2019


astippich requested changes to this revision.
astippich added a comment.
This revision now requires changes to proceed.


  This still alters the map during deserialization. Lists are converted into multi single properties afterwards. As I said, due to backwards-compatibility lists should stay lists.

INLINE COMMENTS

> propertyserializationtest.cpp:55
> +
> +// Test empty property map
> +void PropertySerializationTest::testSingleProp()

wrong comment, also everywhere below

> propertyserializationtest.cpp:130
> +    properties.insertMulti(KFMProp::Ensemble, QVariantList({QVariant("ensemble1"), QVariant("ensemble2")}));
> +    properties.insertMulti(KFMProp::Rating, QVariantList({QVariant(10), QVariant(20.0)}));
> +

nitpick: the rating is usually normalized to 0 to 10, so using 20 here is a little bit strange

REPOSITORY
  R293 Baloo

REVISION DETAIL
  https://phabricator.kde.org/D19087

To: bruns, #baloo, #frameworks, ngraham, poboiko, astippich
Cc: kde-frameworks-devel, gennad, domson, ashaposhnikov, michaelh, astippich, spoorun, ngraham, bruns, abrahams
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20190330/c4037c40/attachment.html>


More information about the Kde-frameworks-devel mailing list