<table><tr><td style="">bruns added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D17302">View Revision</a></tr></table><br /><div><div><p>Currently, both<br />
<tt style="background: #ebebeb; font-size: 13px;">Result::add(prop, "value1"); Result::add(prop, "value2");</tt><br />
and<br />
<tt style="background: #ebebeb; font-size: 13px;">Result::add(prop, {"value1", "value2"});</tt><br />
are serialized (JSON) in the same way as <tt style="background: #ebebeb; font-size: 13px;">{prop: ["value1", "value2"]}</tt> by Baloo, which is IMHO fine.<br />
On the other hand,<br />
<tt style="background: #ebebeb; font-size: 13px;">Result::add(prop, "value1"); Result::add(prop, {"value2", "value3"});</tt><br />
ends up as <tt style="background: #ebebeb; font-size: 13px;">{prop: ["value1", ["value2", "value3"] ]}</tt>, which is nonsense, should be <tt style="background: #ebebeb; font-size: 13px;">{prop: ["value1", "value2", "value3"]}</tt></p>

<p>I am currently moving the serialization (in file/result.cpp) /deserialization (in file/file.cpp) into a separate function so it becomes testable.</p>

<p>After deserializing, we should have <tt style="background: #ebebeb; font-size: 13px;">KFM::Propertymap pm.values(prop)</tt> -> <tt style="background: #ebebeb; font-size: 13px;">QList<QVariant<QString>>({"value1", "value2", "value3"})</tt>.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>R293 Baloo</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D17302">https://phabricator.kde.org/D17302</a></div></div><br /><div><strong>To: </strong>astippich, Baloo, bruns<br /><strong>Cc: </strong>kde-frameworks-devel, ashaposhnikov, michaelh, astippich, spoorun, ngraham, bruns, abrahams<br /></div>