jute alternatives and similar libraries
Based on the "JSON" category.
Alternatively, view jute alternatives based on common mentions on social networks and blogs.
-
simdjson
Parsing gigabytes of JSON per second : used by Facebook/Meta Velox, WatermelonDB, Apache Doris, StarRocks -
RapidJSON
A fast JSON parser/generator for C++ with both SAX/DOM style API -
ArduinoJson
📟 JSON library for Arduino and embedded C++. Simple and efficient. -
json-c
https://github.com/json-c/json-c is the official code repository for json-c. See the wiki for release tarballs for download. API docs at http://json-c.github.io/json-c/ -
JSMN
Jsmn is a world fastest JSON parser/tokenizer. This is the official repo replacing the old one at Bitbucket -
json-parser
Very low footprint DOM-style JSON parser written in portable ANSI C -
frozen
JSON parser and generator for C/C++ with scanf/printf like interface. Targeting embedded systems. -
qt-json
A simple class for parsing JSON data into a QVariant hierarchy and vice versa. -
libjson
a JSON parser and printer library in C. easy to integrate with any model. -
json-voorhees
A killer modern C++ library for interacting with JSON. -
json_dto
A small header-only library for converting data between json representation and c++ structs -
iod.metajson
Non-intrusive, high performance C++17 lightweight JSON de/serializer
Collect and Analyze Billions of Data Points in Real Time
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of jute or a related project?
Popular Comparisons
README
Very simple JSON parser for c++
data.json:
{
"examples": [
{
"tag_name": "a",
"attr": [
{
"key": "href",
"value": "http://amir.saboury.net"
},
{
"key": "target",
"value": "_blank"
}
]
},
{
"this_is": [
"array",
"of",
"strings"
],
"number_array": [
1,
2,
4,
8,
16
],
"pie": 3.14,
"boolean": true,
"bug": null,
"mixed": [
1,
2,
{
"test1": -1.2345,
"test2": false
},
null,
0.4,
[
"nested",
[
"array",
true
]
],
"end of story!"
]
},
{
"done": true
}
]
}
example "main.cpp" file
#include <iostream>
#include <vector>
#include <map>
#include <string>
#include <sstream>
#include <fstream>
#include <cstring>
#include "jute.h"
using namespace std;
int main () {
ifstream in("data.json");
string str = "";
string tmp;
while (getline(in, tmp)) str += tmp;
jute::jValue v = jute::parser::parse(str);
cout << v.to_string() << endl;
cout << " ------ " << endl;
cout << v["examples"][0]["attr"][0]["value"].as_string() << endl;
if (v["examples"][1]["mixed"][5][1][1].as_bool()) {
cout << v["examples"][1]["pie"].as_double() << endl;
cout << v["examples"][2].to_string() << endl;
}
// You can get type of a jValue by calling its get_type() function
// It returns a jType which can be one of these:
// {JSTRING, JOBJECT, JARRAY, JBOOLEAN, JNUMBER, JNULL, JUNKNOWN}
//
// if (v["examples"][1]["mixed"][5][1][1].get_type() == jute::JBOOLEAN) ...
return 0;
}
Note:
This version is not providing error checking. All functions assume the input string is in valid format of JSON. Also number format checking is poor. Improvements are welcome. Read the source code; it is just about 300 LOC :smile:
License: MIT
*Note that all licence references and agreements mentioned in the jute README section above
are relevant to that project's source code only.