libfastjson icon indicating copy to clipboard operation
libfastjson copied to clipboard

Docs on how to use libfastjson4

Open PsySc0rpi0n opened this issue 3 years ago • 3 comments

Hello.

Are there any documents or tutorials on how to use the library to parse JSON objects? I have Debian Buster installed but I can't find any tutorials on libfastjson4.

Any help would be appreciated! Thanks Psy

PsySc0rpi0n avatar Apr 29 '21 20:04 PsySc0rpi0n

libfastjson isn't a parser as much as it is a library for manipulating json. It's a fork of the json-c library (fixing some holes that were found there), so documenation and examples of json-c will probably apply.

David Lang

José Carlos Ferreira wrote:

Are there any documents or tutorials on how to use the library to parse JSON objects? I have Debian Buster installed but I can't find any tutorials on libfastjson4.

Any help would be appreciated! Thanks Psy

davidelang avatar Apr 29 '21 22:04 davidelang

libfastjson isn't a parser as much as it is a library for manipulating json. It's a fork of the json-c library (fixing some holes that were found there), so documenation and examples of json-c will probably apply. David Lang José Carlos Ferreira wrote: Are there any documents or tutorials on how to use the library to parse JSON objects? I have Debian Buster installed but I can't find any tutorials on libfastjson4. Any help would be appreciated! Thanks Psy

Ok, but I tried to

#include <json-c/json.h>

but compiler says that such file doesn't exist. Now I compiled json-c repository from their github and installed, and now, json-c works. But it didn't work only with libfastjson4 package installed.

PsySc0rpi0n avatar Apr 29 '21 23:04 PsySc0rpi0n

Waht davidlang means is libfastjson is similar to json-c, so you can just use json-c document. I reconmend you this json-c document.

And the header of libfastjson is a good reference too. The test file in libfastjson repo a good start to learn.

apple-ouyang avatar Mar 16 '23 12:03 apple-ouyang