QJson

the easiest way for managing JSON objects with Qt

Introduction

JSON (JavaScript Object Notation) is a lightweight data-interchange format. It can represents integer, real number, string, an ordered sequence of value, and a collection of name/value pairs.

QJson is a qt-based library that maps JSON data to QVariant objects: JSON arrays will be mapped to QVariantList instances, while JSON objects will be mapped to QVariantMap.

Easy to use

QJson is fast and reliable. Don't waste your time writing another JSON parser!

Converting a JSON object to a QVariant requires just three lines of code:

        // create a JSonDriver instance
        JSonDriver driver;
        bool ok;

        // json is a QString containing the data to convert
        QVariant result = driver.parse (json, &ok);
        

Check out the examples section for more code snipplets.