Stephan Gatzka
7ed067e680
Rename some variables to avoid shadowing.
8 years ago
Max Bruckner
65ac0a1a2b
cJSON_Utils tests: fix formatting
8 years ago
Max Bruckner
b88da9b0de
Initialize all variables
8 years ago
Max Bruckner
9e31049159
test and test_utils: Make compliant with ANSI C
8 years ago
Dave Gamble
3a7bd6924a
Utility function to generate the patch between two objects.
9 years ago
Dave Gamble
e79fa9472b
cJSONUtils_MergePatch with tests from the RFC.
9 years ago
Max Bruckner
58bc383b28
fix memory leaks
9 years ago
Dave Gamble
491cf029b2
Rework cJSON_Utils object compare functions to use an O(N) algorithm on sorted lists.
It's a bit of a shame to use the sorts, because cJSON is otherwise incredibly stable (json->cJSON->json is unmodified modulo formatting),
but it means we get usable performance, rather than O(N^2) which will make CPUs cry.
git-svn-id: svn://svn.code.sf.net/p/cjson/code@71 e3330c51-1366-4df0-8b21-3ccf24e3d50e
10 years ago
Dave Gamble
c4ddd7aaa3
Correct comment and variable declaration style to be more compatible. Added cJSONUtils_SortObject for sorting the members of an object alphabetically.
git-svn-id: svn://svn.code.sf.net/p/cjson/code@70 e3330c51-1366-4df0-8b21-3ccf24e3d50e
10 years ago
Dave Gamble
060e6563c0
Add more patch functionality and some more utils.
Also add a new #define to cJSON.h for SetNumberValue.
git-svn-id: svn://svn.code.sf.net/p/cjson/code@66 e3330c51-1366-4df0-8b21-3ccf24e3d50e
10 years ago
Dave Gamble
3c6b3cc617
start of JSON Patch implementation. cJSON gained a cJSON_InsertItemToArray which pushes elements up by one.
This is needed for JSON Patch. Everything but Test is implemented for ApplyPatches.
git-svn-id: svn://svn.code.sf.net/p/cjson/code@65 e3330c51-1366-4df0-8b21-3ccf24e3d50e
10 years ago
Dave Gamble
c0f5e2056b
add cJSON_Utils which includes JSON Pointer implementation
git-svn-id: svn://svn.code.sf.net/p/cjson/code@63 e3330c51-1366-4df0-8b21-3ccf24e3d50e
10 years ago