<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Sep 11, 2017 at 6:24 PM, David Thompson <span dir="ltr"><<a href="mailto:david.thompson@kitware.com" target="_blank">david.thompson@kitware.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span class="gmail-">> It seems that we are using a C - library for JSON processing - has anyone looked at C++ 11 libs like:<br>
> <a href="https://github.com/nlohmann/json" rel="noreferrer" target="_blank">https://github.com/nlohmann/<wbr>json</a><br>
<br>
</span>It looks nice. I would like to kick the tires a little, but it looks good enough to replace cJSON if it doesn't have any fatal flaws.<br>
<br>
@Ben jsoncpp is really terrible:<br>
+ it is not concise to use (I'm not sure nlohmann is either because it lives in the "nlohmann" namespace);<br>
+ it is slow -- see <a href="https://github.com/miloyip/nativejson-benchmark#parsing-time" rel="noreferrer" target="_blank">https://github.com/miloyip/<wbr>nativejson-benchmark#parsing-<wbr>time</a> where cJSON takes 25ms and jsoncpp takes 166ms; nlohmann takes 71 ms which is not great but look at how easy it is to use; and<br>
+ it is heavy (243k-LOC vs 42k for nlohmann and 27k for cJSON)<br>
<br>
We should help move CMake/VTK away from jsoncpp instead of designing software by seniority.<br></blockquote><div>While browsing, I come across this data serization format as <span style="color:rgb(38,50,56);font-size:13px"><a href="https://github.com/google/protobuf">protobuf</a></span> developed by Google. It's four times <a href="https://google.github.io/flatbuffers/flatbuffers_benchmarks.html">faster than JSON and using much less space</a>.  Is there any reason why we stick to JSON or can we move to a better data format?</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><span class="gmail-HOEnZb"><font color="#888888">
        David<br>
</font></span><div class="gmail-HOEnZb"><div class="gmail-h5">______________________________<wbr>_________________<br>
Smtk-developers mailing list<br>
<a href="mailto:Smtk-developers@smtk.org">Smtk-developers@smtk.org</a><br>
<a href="http://public.kitware.com/mailman/listinfo/smtk-developers" rel="noreferrer" target="_blank">http://public.kitware.com/<wbr>mailman/listinfo/smtk-<wbr>developers</a><br>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr">Best regards<div>Haocheng</div><div><br></div><div>Haocheng LIU</div><div><span style="color:rgb(0,0,0);font-size:12.8px">Kitware, Inc.</span><br style="color:rgb(0,0,0);font-size:12.8px"><span style="color:rgb(0,0,0);font-size:12.8px">R&D Engineer</span><br style="color:rgb(0,0,0);font-size:12.8px"><span style="color:rgb(0,0,0);font-size:12.8px">21 Corporate Drive</span><br style="color:rgb(0,0,0);font-size:12.8px"><span style="color:rgb(0,0,0);font-size:12.8px">Clifton Park, NY 12065-8662</span><br style="color:rgb(0,0,0);font-size:12.8px"><span style="color:rgb(0,0,0);font-size:12.8px">Phone: </span><a href="tel:(518)%20881-4421" value="+15188814443" style="color:rgb(17,85,204);font-size:12.8px" target="_blank">518-881-4421</a><br></div></div></div></div></div>
</div></div>