-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjson_8h.html
2214 lines (2057 loc) · 109 KB
/
json_8h.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>libusual: usual/json.h File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td style="padding-left: 0.5em;">
<div id="projectname">libusual
 <span id="projectnumber">0.1</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- Generated by Doxygen 1.7.6.1 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="pages.html"><span>Related Pages</span></a></li>
<li><a href="annotated.html"><span>Data Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="files.html"><span>File List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
</div>
<div class="header">
<div class="summary">
<a href="#typedef-members">Typedefs</a> |
<a href="#enum-members">Enumerations</a> </div>
<div class="headertitle">
<div class="title">usual/json.h File Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Read and write JSON.
<a href="#details">More...</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="typedef-members"></a>
Typedefs</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef bool(* </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#af28e900a0c1f9e2385e97678058ec6b5">json_dict_iter_callback_f</a> )(void *arg, struct <a class="el" href="struct_json_value.html">JsonValue</a> *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> *val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Callback for dict iterator. <a href="#af28e900a0c1f9e2385e97678058ec6b5"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">typedef bool(* </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#af7ba24eecf679d60ac20f4ea449f8737">json_list_iter_callback_f</a> )(void *arg, struct <a class="el" href="struct_json_value.html">JsonValue</a> *elem)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Callback for list iterator. <a href="#af7ba24eecf679d60ac20f4ea449f8737"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="enum-members"></a>
Enumerations</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cb">JsonValueType</a> { <br/>
  <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba03ddcc4e2eef955020a01e10c11bfe48">JSON_NULL</a>,
<a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbafc3a60886010e5b0f57d7aa30d0277b0">JSON_BOOL</a>,
<a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbae6c0bfed3008189ab6f43ce03e118370">JSON_INT</a>,
<a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbac0f759c72ce92c2fa7d88818cb5eab65">JSON_FLOAT</a>,
<br/>
  <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba02bfd03b07e5b9ecd6ee0d257dc37daf">JSON_STRING</a>,
<a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba836769b2b1ad935f1f0d2e37dacd2649">JSON_LIST</a>,
<a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbafbd94db77556fd807e45c50989c33113">JSON_DICT</a>
<br/>
}</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">JSON value types. <a href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cb">More...</a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">enum  </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3">JsonParseOptions</a> { <a class="el" href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3adda2f3f8f1986cab447a7615dcb1ddfc">JSON_STRICT</a>,
<a class="el" href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3af8813b59442095b54e72d6c718e4921e">JSON_PARSE_RELAXED</a>,
<a class="el" href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3a487f864930695f7cec51e4c8ed759110">JSON_PARSE_IGNORE_ENCODING</a>
}</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Options for JSON parser. <a href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3">More...</a><br/></td></tr>
<tr><td colspan="2"><h2><a name="func-members"></a>
Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Allocation context.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_context.html">JsonContext</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ae153146ba40a1d78843292da0e1efdcb">json_new_context</a> (const void *cx_mem, size_t initial_mem)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create allocation context. <a href="#ae153146ba40a1d78843292da0e1efdcb"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ac6d56502e934910ea8cb183b61442f83">json_free_context</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create allocation context. <a href="#ac6d56502e934910ea8cb183b61442f83"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a13a45abb45e5ef4df064582c0a551ce4">json_strerror</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create allocation context. <a href="#a13a45abb45e5ef4df064582c0a551ce4"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Parse JSON</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#afb828e25b8c69b09b0adf86934d5c262">json_parse</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, const char *src, size_t length)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Parse JSON string. <a href="#afb828e25b8c69b09b0adf86934d5c262"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a7f4fb1c58b059a961bbd9fb9a5911ac1">json_set_options</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, unsigned int options)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Set parsing options. <a href="#a7f4fb1c58b059a961bbd9fb9a5911ac1"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Examine single value</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">enum <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cb">JsonValueType</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return type for value. <a href="#a8151895337f689ee32d2f9bd29adf6de"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a8efeb7c1b97e0b4b4847285678392cf0">json_value_size</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return element size. <a href="#a8efeb7c1b97e0b4b4847285678392cf0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a18baab457db1046d85fcbf8d23bb6697">json_value_is_null</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is null. <a href="#a18baab457db1046d85fcbf8d23bb6697"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#acb12511a5b60669abb27b89215c65214">json_value_is_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is boolean. <a href="#acb12511a5b60669abb27b89215c65214"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a73006ade3f2844dc6be4f2f2cc414c07">json_value_is_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is int. <a href="#a73006ade3f2844dc6be4f2f2cc414c07"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a8ab4018bcdea4d470174edc9e7bd606d">json_value_is_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is float. <a href="#a8ab4018bcdea4d470174edc9e7bd606d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ad98cee171f32decff98e1baa9ddfa69e">json_value_is_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is string. <a href="#ad98cee171f32decff98e1baa9ddfa69e"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a0609d4174a1da5e35e22209229f4ab73">json_value_is_list</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is list. <a href="#a0609d4174a1da5e35e22209229f4ab73"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">static bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a3e56b3ce0109ba018ebec619690eb732">json_value_is_dict</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is dict. <a href="#a3e56b3ce0109ba018ebec619690eb732"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ad19cac75cf304386b2200858cd134a67">json_value_as_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, bool *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get bool value. <a href="#ad19cac75cf304386b2200858cd134a67"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab000d734cfbaf1a438dd0587092903bf">json_value_as_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, int64_t *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get int value. <a href="#ab000d734cfbaf1a438dd0587092903bf"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aadc9515bc1222f3030dd8879e519625b">json_value_as_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, double *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get double value. <a href="#aadc9515bc1222f3030dd8879e519625b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ae9e7072e9fb1d510e0f3f37270ef3a44">json_value_as_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char **dst_p, size_t *size_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get string value. <a href="#ae9e7072e9fb1d510e0f3f37270ef3a44"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Get values from dict</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a150766199517c8f65b084477dab0e452">json_dict_get_value</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> **val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get key value from dict. <a href="#a150766199517c8f65b084477dab0e452"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a1efb4880de496c0b42dcb565a62ca091">json_dict_is_null</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is null or missing. <a href="#a1efb4880de496c0b42dcb565a62ca091"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a7233beb70345927895355d21de0299d4">json_dict_get_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, bool *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get boolean value from dict. <a href="#a7233beb70345927895355d21de0299d4"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a57cc59f4e59e4e57da3e84cb3e4a910d">json_dict_get_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, int64_t *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get int value from dict. <a href="#a57cc59f4e59e4e57da3e84cb3e4a910d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a09ac9671cba7c9de4c2291ef3f8423ea">json_dict_get_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, double *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get float value from dict. <a href="#a09ac9671cba7c9de4c2291ef3f8423ea"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab51b77538b71a6f0840941b4a56a52bf">json_dict_get_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, const char **dst_p, size_t *len_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get string value from dict. <a href="#ab51b77538b71a6f0840941b4a56a52bf"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a2f3cfe4948b9b411976b846f63637ed8">json_dict_get_dict</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> **dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get sub-dict from dict. <a href="#a2f3cfe4948b9b411976b846f63637ed8"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ae6c602c176282a3248eaf4c7f354f5ae">json_dict_get_list</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> **dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get list from dict. <a href="#ae6c602c176282a3248eaf4c7f354f5ae"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a13e1c55745161de84250ee46321f393c">json_dict_get_opt_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, bool *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional bool from dict. <a href="#a13e1c55745161de84250ee46321f393c"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aa4ae2a591c3694cb586fecb32c519a19">json_dict_get_opt_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, int64_t *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional int from dict. <a href="#aa4ae2a591c3694cb586fecb32c519a19"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ade15c1344851c9e1361dbd3e25841a10">json_dict_get_opt_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, double *dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional float from dict. <a href="#ade15c1344851c9e1361dbd3e25841a10"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#add3be1cf215bc204317995e87460e773">json_dict_get_opt_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, const char **dst_p, size_t *len_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional string from dict. <a href="#add3be1cf215bc204317995e87460e773"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aecbd1db6e17355aed5c5906661d6d7e4">json_dict_get_opt_list</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> **dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional list from dict. <a href="#aecbd1db6e17355aed5c5906661d6d7e4"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a1d0a88a5d787b35da055e825cf6af913">json_dict_get_opt_dict</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> **dst_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get optional dict from dict. <a href="#a1d0a88a5d787b35da055e825cf6af913"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Get values from list.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ae5acdba1a44873acde9be1f35566bf9d">json_list_get_value</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, struct <a class="el" href="struct_json_value.html">JsonValue</a> **val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get value from list. <a href="#ae5acdba1a44873acde9be1f35566bf9d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a4ac41df990edd76cbc8e50126803990c">json_list_is_null</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Return true if value is null or missing. <a href="#a4ac41df990edd76cbc8e50126803990c"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a0e98bf1bb1d089bfe6df298e8b7680d0">json_list_get_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, bool *val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get bool from list. <a href="#a0e98bf1bb1d089bfe6df298e8b7680d0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a382031bd8d2dd00cf1a322d760c7b0eb">json_list_get_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, int64_t *val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get int from list. <a href="#a382031bd8d2dd00cf1a322d760c7b0eb"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a866ef64389ea8066048143ec91175a60">json_list_get_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, double *val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get float from list. <a href="#a866ef64389ea8066048143ec91175a60"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a51679c77d205dcc0e5b60fb458b56304">json_list_get_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, const char **val_p, size_t *len_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get string from list. <a href="#a51679c77d205dcc0e5b60fb458b56304"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a5363c4547245f59128cc74d321c6776d">json_list_get_list</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, struct <a class="el" href="struct_json_value.html">JsonValue</a> **val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get list value from list. <a href="#a5363c4547245f59128cc74d321c6776d"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aa9b4f246bf5b53437f2c7accdb205b18">json_list_get_dict</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, size_t index, struct <a class="el" href="struct_json_value.html">JsonValue</a> **val_p)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Get dict value from list. <a href="#aa9b4f246bf5b53437f2c7accdb205b18"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Iterate over elements in list/dict.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aa028297125fe1d6ef1feeabdf1c92b13">json_dict_iter</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, <a class="el" href="json_8h.html#af28e900a0c1f9e2385e97678058ec6b5">json_dict_iter_callback_f</a> cb_func, void *cb_arg)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Walk over dict elements. <a href="#aa028297125fe1d6ef1feeabdf1c92b13"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab71b83512d1ac2afa4ce735770491254">json_list_iter</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, <a class="el" href="json_8h.html#af7ba24eecf679d60ac20f4ea449f8737">json_list_iter_callback_f</a> cb_func, void *cb_arg)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Walk over list elements. <a href="#ab71b83512d1ac2afa4ce735770491254"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Output JSON.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a71f716a9dfd47639e2d27fc2088fb2a6">json_render</a> (struct <a class="el" href="struct_m_buf.html">MBuf</a> *dst, struct <a class="el" href="struct_json_value.html">JsonValue</a> *jv)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Render JSON object as string. <a href="#a71f716a9dfd47639e2d27fc2088fb2a6"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Create new values.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a76b1664ee4b4df8ce58eedda55b3519f">json_new_null</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create NULL value. <a href="#a76b1664ee4b4df8ce58eedda55b3519f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a33ef4a6a7aadca9c5894b181552801a9">json_new_bool</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, bool val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create bool value. <a href="#a33ef4a6a7aadca9c5894b181552801a9"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab033990579ec1aefa15dbe2a00aa752f">json_new_int</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, int64_t val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create int value. <a href="#ab033990579ec1aefa15dbe2a00aa752f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#acd85eec2d7c84f5f22e1fbf7b576d02a">json_new_float</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, double val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create float value. <a href="#acd85eec2d7c84f5f22e1fbf7b576d02a"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aad976996f45ae06914fcd7f9348168ba">json_new_string</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx, const char *val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create string value. <a href="#aad976996f45ae06914fcd7f9348168ba"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a85c0825c243c94456c2f6b5480c47fe6">json_new_dict</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create dict value. <a href="#a85c0825c243c94456c2f6b5480c47fe6"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#aec59cddb70515dc18cae26b94ce49930">json_new_list</a> (struct <a class="el" href="struct_json_context.html">JsonContext</a> *ctx)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Create list value. <a href="#aec59cddb70515dc18cae26b94ce49930"></a><br/></td></tr>
<tr><td colspan="2"><div class="groupHeader">Add values to containers.</div></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#af10b56daa1d376d791b7645ff3a72071">json_list_append</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, struct <a class="el" href="struct_json_value.html">JsonValue</a> *elem)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add value to list. <a href="#af10b56daa1d376d791b7645ff3a72071"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ac98c29041f096a55bbbe5ab926ccab94">json_list_append_null</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add null to list. <a href="#ac98c29041f096a55bbbe5ab926ccab94"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ab4670e9b7f552208ff372bd2181e6916">json_list_append_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, bool val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add bool to list. <a href="#ab4670e9b7f552208ff372bd2181e6916"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a1a96d7dfd6fa9539aa7c197abf1bf03b">json_list_append_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, int64_t val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add int to list. <a href="#a1a96d7dfd6fa9539aa7c197abf1bf03b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ac9636edda386279f2e840a286222b0f0">json_list_append_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, double val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add float to list. <a href="#ac9636edda386279f2e840a286222b0f0"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ac582035871783d3080c883c49ea21b7b">json_list_append_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *list, const char *val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add string to list. <a href="#ac582035871783d3080c883c49ea21b7b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a77365a3b547376b0a2959df43efb5f71">json_dict_put</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> *val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add element to dict. <a href="#a77365a3b547376b0a2959df43efb5f71"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a3abbf579e25a00fffc5bf796ad35156b">json_dict_put_null</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add null to dict. <a href="#a3abbf579e25a00fffc5bf796ad35156b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a1669839b81725f5d20ab052fcfb0fe5b">json_dict_put_bool</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, bool val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add bool to dict. <a href="#a1669839b81725f5d20ab052fcfb0fe5b"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ae3c1bc324aa9ffaaabcfb6867ceb5a67">json_dict_put_int</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, int64_t val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add int to dict. <a href="#ae3c1bc324aa9ffaaabcfb6867ceb5a67"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#ade1cb5a01b71d79faf9bfd4f357e6f0f">json_dict_put_float</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, double val)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add float to dict. <a href="#ade1cb5a01b71d79faf9bfd4f357e6f0f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="json_8h.html#a99606731a4d0e483827ce434fd6eeb17">json_dict_put_string</a> (struct <a class="el" href="struct_json_value.html">JsonValue</a> *dict, const char *key, const char *str)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Add string to dict. <a href="#a99606731a4d0e483827ce434fd6eeb17"></a><br/></td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Read and write JSON. </p>
<p>Features:</p>
<ul>
<li>Robust - does not crash or assert() on invalid data.</li>
<li>Fast memory allocation - it uses single pooled area for all objects thus alloc/free are fast.</li>
<li>Strict UTF8 validation.</li>
<li>Full int64_t and double passthrough, except NaN and +-Infinity.</li>
<li>Proper number I/O even in weird locales.</li>
</ul>
<p>Optional features for JSON config files, off by default:</p>
<ul>
<li>Allow C comments.</li>
<li>Allow extra comma in dict/list. </li>
</ul>
</div><hr/><h2>Typedef Documentation</h2>
<a class="anchor" id="af28e900a0c1f9e2385e97678058ec6b5"></a><!-- doxytag: member="json.h::json_dict_iter_callback_f" ref="af28e900a0c1f9e2385e97678058ec6b5" args=")(void *arg, struct JsonValue *key, struct JsonValue *val)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef bool(* <a class="el" href="json_8h.html#af28e900a0c1f9e2385e97678058ec6b5">json_dict_iter_callback_f</a>)(void *arg, struct <a class="el" href="struct_json_value.html">JsonValue</a> *key, struct <a class="el" href="struct_json_value.html">JsonValue</a> *val)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Callback for dict iterator. </p>
</div>
</div>
<a class="anchor" id="af7ba24eecf679d60ac20f4ea449f8737"></a><!-- doxytag: member="json.h::json_list_iter_callback_f" ref="af7ba24eecf679d60ac20f4ea449f8737" args=")(void *arg, struct JsonValue *elem)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef bool(* <a class="el" href="json_8h.html#af7ba24eecf679d60ac20f4ea449f8737">json_list_iter_callback_f</a>)(void *arg, struct <a class="el" href="struct_json_value.html">JsonValue</a> *elem)</td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Callback for list iterator. </p>
</div>
</div>
<hr/><h2>Enumeration Type Documentation</h2>
<a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cb"></a><!-- doxytag: member="json.h::JsonValueType" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cb" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">enum <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cb">JsonValueType</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>JSON value types. </p>
<p>Returned by <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de" title="Return type for value.">json_value_type()</a>. </p>
<dl><dt><b>Enumerator: </b></dt><dd><table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cba03ddcc4e2eef955020a01e10c11bfe48"></a><!-- doxytag: member="JSON_NULL" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cba03ddcc4e2eef955020a01e10c11bfe48" args="" -->JSON_NULL</em> </td><td>
<p>Null value. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cbafc3a60886010e5b0f57d7aa30d0277b0"></a><!-- doxytag: member="JSON_BOOL" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cbafc3a60886010e5b0f57d7aa30d0277b0" args="" -->JSON_BOOL</em> </td><td>
<p>Boolean value. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cbae6c0bfed3008189ab6f43ce03e118370"></a><!-- doxytag: member="JSON_INT" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cbae6c0bfed3008189ab6f43ce03e118370" args="" -->JSON_INT</em> </td><td>
<p>Integer value. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cbac0f759c72ce92c2fa7d88818cb5eab65"></a><!-- doxytag: member="JSON_FLOAT" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cbac0f759c72ce92c2fa7d88818cb5eab65" args="" -->JSON_FLOAT</em> </td><td>
<p>Float value. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cba02bfd03b07e5b9ecd6ee0d257dc37daf"></a><!-- doxytag: member="JSON_STRING" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cba02bfd03b07e5b9ecd6ee0d257dc37daf" args="" -->JSON_STRING</em> </td><td>
<p>String value. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cba836769b2b1ad935f1f0d2e37dacd2649"></a><!-- doxytag: member="JSON_LIST" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cba836769b2b1ad935f1f0d2e37dacd2649" args="" -->JSON_LIST</em> </td><td>
<p>JSON list. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="ab1d0a5abd7705ac9e0a1ae51ec6671cbafbd94db77556fd807e45c50989c33113"></a><!-- doxytag: member="JSON_DICT" ref="ab1d0a5abd7705ac9e0a1ae51ec6671cbafbd94db77556fd807e45c50989c33113" args="" -->JSON_DICT</em> </td><td>
<p>JSON "object", which is key->value map. </p>
</td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="acc918f43fb4571ed93c0d41ed6f49fb3"></a><!-- doxytag: member="json.h::JsonParseOptions" ref="acc918f43fb4571ed93c0d41ed6f49fb3" args="" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">enum <a class="el" href="json_8h.html#acc918f43fb4571ed93c0d41ed6f49fb3">JsonParseOptions</a></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Options for JSON parser. </p>
<dl><dt><b>Enumerator: </b></dt><dd><table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"><em><a class="anchor" id="acc918f43fb4571ed93c0d41ed6f49fb3adda2f3f8f1986cab447a7615dcb1ddfc"></a><!-- doxytag: member="JSON_STRICT" ref="acc918f43fb4571ed93c0d41ed6f49fb3adda2f3f8f1986cab447a7615dcb1ddfc" args="" -->JSON_STRICT</em> </td><td>
<p>Default - do strict parsing. </p>
<p>No comments, no extra comma. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="acc918f43fb4571ed93c0d41ed6f49fb3af8813b59442095b54e72d6c718e4921e"></a><!-- doxytag: member="JSON_PARSE_RELAXED" ref="acc918f43fb4571ed93c0d41ed6f49fb3af8813b59442095b54e72d6c718e4921e" args="" -->JSON_PARSE_RELAXED</em> </td><td>
<p>Allow comments, allow extra comma. </p>
<p>Useful for JSON in config files. </p>
</td></tr>
<tr><td valign="top"><em><a class="anchor" id="acc918f43fb4571ed93c0d41ed6f49fb3a487f864930695f7cec51e4c8ed759110"></a><!-- doxytag: member="JSON_PARSE_IGNORE_ENCODING" ref="acc918f43fb4571ed93c0d41ed6f49fb3a487f864930695f7cec51e4c8ed759110" args="" -->JSON_PARSE_IGNORE_ENCODING</em> </td><td>
<p>Do not validate UTF-8. </p>
<p>The default behavior is to validate UTF-8. </p>
</td></tr>
</table>
</dd>
</dl>
</div>
</div>
<hr/><h2>Function Documentation</h2>
<a class="anchor" id="ae153146ba40a1d78843292da0e1efdcb"></a><!-- doxytag: member="json.h::json_new_context" ref="ae153146ba40a1d78843292da0e1efdcb" args="(const void *cx_mem, size_t initial_mem)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">struct <a class="el" href="struct_json_context.html">JsonContext</a>* <a class="el" href="json_8h.html#ae153146ba40a1d78843292da0e1efdcb">json_new_context</a> </td>
<td>(</td>
<td class="paramtype">const void * </td>
<td class="paramname"><em>cx_mem</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t </td>
<td class="paramname"><em>initial_mem</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td><code> [read]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Create allocation context. </p>
</div>
</div>
<a class="anchor" id="ac6d56502e934910ea8cb183b61442f83"></a><!-- doxytag: member="json.h::json_free_context" ref="ac6d56502e934910ea8cb183b61442f83" args="(struct JsonContext *ctx)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="json_8h.html#ac6d56502e934910ea8cb183b61442f83">json_free_context</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_context.html">JsonContext</a> * </td>
<td class="paramname"><em>ctx</em></td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Create allocation context. </p>
</div>
</div>
<a class="anchor" id="a13a45abb45e5ef4df064582c0a551ce4"></a><!-- doxytag: member="json.h::json_strerror" ref="a13a45abb45e5ef4df064582c0a551ce4" args="(struct JsonContext *ctx)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">const char* <a class="el" href="json_8h.html#a13a45abb45e5ef4df064582c0a551ce4">json_strerror</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_context.html">JsonContext</a> * </td>
<td class="paramname"><em>ctx</em></td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Create allocation context. </p>
</div>
</div>
<a class="anchor" id="afb828e25b8c69b09b0adf86934d5c262"></a><!-- doxytag: member="json.h::json_parse" ref="afb828e25b8c69b09b0adf86934d5c262" args="(struct JsonContext *ctx, const char *src, size_t length)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">struct <a class="el" href="struct_json_value.html">JsonValue</a>* <a class="el" href="json_8h.html#afb828e25b8c69b09b0adf86934d5c262">json_parse</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_context.html">JsonContext</a> * </td>
<td class="paramname"><em>ctx</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>src</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t </td>
<td class="paramname"><em>length</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td><code> [read]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Parse JSON string. </p>
</div>
</div>
<a class="anchor" id="a7f4fb1c58b059a961bbd9fb9a5911ac1"></a><!-- doxytag: member="json.h::json_set_options" ref="a7f4fb1c58b059a961bbd9fb9a5911ac1" args="(struct JsonContext *ctx, unsigned int options)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="json_8h.html#a7f4fb1c58b059a961bbd9fb9a5911ac1">json_set_options</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_context.html">JsonContext</a> * </td>
<td class="paramname"><em>ctx</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">unsigned int </td>
<td class="paramname"><em>options</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Set parsing options. </p>
</div>
</div>
<a class="anchor" id="a8151895337f689ee32d2f9bd29adf6de"></a><!-- doxytag: member="json.h::json_value_type" ref="a8151895337f689ee32d2f9bd29adf6de" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">enum <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cb">JsonValueType</a> <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return type for value. </p>
<p>Referenced by <a class="el" href="json_8h.html#acb12511a5b60669abb27b89215c65214">json_value_is_bool()</a>, <a class="el" href="json_8h.html#a3e56b3ce0109ba018ebec619690eb732">json_value_is_dict()</a>, <a class="el" href="json_8h.html#a8ab4018bcdea4d470174edc9e7bd606d">json_value_is_float()</a>, <a class="el" href="json_8h.html#a73006ade3f2844dc6be4f2f2cc414c07">json_value_is_int()</a>, <a class="el" href="json_8h.html#a0609d4174a1da5e35e22209229f4ab73">json_value_is_list()</a>, <a class="el" href="json_8h.html#a18baab457db1046d85fcbf8d23bb6697">json_value_is_null()</a>, and <a class="el" href="json_8h.html#ad98cee171f32decff98e1baa9ddfa69e">json_value_is_string()</a>.</p>
</div>
</div>
<a class="anchor" id="a8efeb7c1b97e0b4b4847285678392cf0"></a><!-- doxytag: member="json.h::json_value_size" ref="a8efeb7c1b97e0b4b4847285678392cf0" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">size_t <a class="el" href="json_8h.html#a8efeb7c1b97e0b4b4847285678392cf0">json_value_size</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return element size. </p>
<p>For JSON strings, it's bytes in string, for list and dict it returns number of elements. </p>
</div>
</div>
<a class="anchor" id="a18baab457db1046d85fcbf8d23bb6697"></a><!-- doxytag: member="json.h::json_value_is_null" ref="a18baab457db1046d85fcbf8d23bb6697" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#a18baab457db1046d85fcbf8d23bb6697">json_value_is_null</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is null. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba03ddcc4e2eef955020a01e10c11bfe48">JSON_NULL</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="acb12511a5b60669abb27b89215c65214"></a><!-- doxytag: member="json.h::json_value_is_bool" ref="acb12511a5b60669abb27b89215c65214" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#acb12511a5b60669abb27b89215c65214">json_value_is_bool</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is boolean. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbafc3a60886010e5b0f57d7aa30d0277b0">JSON_BOOL</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="a73006ade3f2844dc6be4f2f2cc414c07"></a><!-- doxytag: member="json.h::json_value_is_int" ref="a73006ade3f2844dc6be4f2f2cc414c07" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#a73006ade3f2844dc6be4f2f2cc414c07">json_value_is_int</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is int. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbae6c0bfed3008189ab6f43ce03e118370">JSON_INT</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="a8ab4018bcdea4d470174edc9e7bd606d"></a><!-- doxytag: member="json.h::json_value_is_float" ref="a8ab4018bcdea4d470174edc9e7bd606d" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#a8ab4018bcdea4d470174edc9e7bd606d">json_value_is_float</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is float. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbac0f759c72ce92c2fa7d88818cb5eab65">JSON_FLOAT</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="ad98cee171f32decff98e1baa9ddfa69e"></a><!-- doxytag: member="json.h::json_value_is_string" ref="ad98cee171f32decff98e1baa9ddfa69e" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#ad98cee171f32decff98e1baa9ddfa69e">json_value_is_string</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is string. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba02bfd03b07e5b9ecd6ee0d257dc37daf">JSON_STRING</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="a0609d4174a1da5e35e22209229f4ab73"></a><!-- doxytag: member="json.h::json_value_is_list" ref="a0609d4174a1da5e35e22209229f4ab73" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#a0609d4174a1da5e35e22209229f4ab73">json_value_is_list</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is list. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cba836769b2b1ad935f1f0d2e37dacd2649">JSON_LIST</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="a3e56b3ce0109ba018ebec619690eb732"></a><!-- doxytag: member="json.h::json_value_is_dict" ref="a3e56b3ce0109ba018ebec619690eb732" args="(struct JsonValue *jv)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">static bool <a class="el" href="json_8h.html#a3e56b3ce0109ba018ebec619690eb732">json_value_is_dict</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em></td><td>)</td>
<td><code> [inline, static]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is dict. </p>
<p>References <a class="el" href="json_8h.html#ab1d0a5abd7705ac9e0a1ae51ec6671cbafbd94db77556fd807e45c50989c33113">JSON_DICT</a>, and <a class="el" href="json_8h.html#a8151895337f689ee32d2f9bd29adf6de">json_value_type()</a>.</p>
</div>
</div>
<a class="anchor" id="ad19cac75cf304386b2200858cd134a67"></a><!-- doxytag: member="json.h::json_value_as_bool" ref="ad19cac75cf304386b2200858cd134a67" args="(struct JsonValue *jv, bool *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#ad19cac75cf304386b2200858cd134a67">json_value_as_bool</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get bool value. </p>
</div>
</div>
<a class="anchor" id="ab000d734cfbaf1a438dd0587092903bf"></a><!-- doxytag: member="json.h::json_value_as_int" ref="ab000d734cfbaf1a438dd0587092903bf" args="(struct JsonValue *jv, int64_t *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#ab000d734cfbaf1a438dd0587092903bf">json_value_as_int</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int64_t * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get int value. </p>
</div>
</div>
<a class="anchor" id="aadc9515bc1222f3030dd8879e519625b"></a><!-- doxytag: member="json.h::json_value_as_float" ref="aadc9515bc1222f3030dd8879e519625b" args="(struct JsonValue *jv, double *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#aadc9515bc1222f3030dd8879e519625b">json_value_as_float</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get double value. </p>
</div>
</div>
<a class="anchor" id="ae9e7072e9fb1d510e0f3f37270ef3a44"></a><!-- doxytag: member="json.h::json_value_as_string" ref="ae9e7072e9fb1d510e0f3f37270ef3a44" args="(struct JsonValue *jv, const char **dst_p, size_t *size_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#ae9e7072e9fb1d510e0f3f37270ef3a44">json_value_as_string</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char ** </td>
<td class="paramname"><em>dst_p</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t * </td>
<td class="paramname"><em>size_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get string value. </p>
</div>
</div>
<a class="anchor" id="a150766199517c8f65b084477dab0e452"></a><!-- doxytag: member="json.h::json_dict_get_value" ref="a150766199517c8f65b084477dab0e452" args="(struct JsonValue *dict, const char *key, struct JsonValue **val_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#a150766199517c8f65b084477dab0e452">json_dict_get_value</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>dict</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> ** </td>
<td class="paramname"><em>val_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get key value from dict. </p>
</div>
</div>
<a class="anchor" id="a1efb4880de496c0b42dcb565a62ca091"></a><!-- doxytag: member="json.h::json_dict_is_null" ref="a1efb4880de496c0b42dcb565a62ca091" args="(struct JsonValue *jv, const char *key)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#a1efb4880de496c0b42dcb565a62ca091">json_dict_is_null</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Return true if value is null or missing. </p>
</div>
</div>
<a class="anchor" id="a7233beb70345927895355d21de0299d4"></a><!-- doxytag: member="json.h::json_dict_get_bool" ref="a7233beb70345927895355d21de0299d4" args="(struct JsonValue *jv, const char *key, bool *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#a7233beb70345927895355d21de0299d4">json_dict_get_bool</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">bool * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get boolean value from dict. </p>
</div>
</div>
<a class="anchor" id="a57cc59f4e59e4e57da3e84cb3e4a910d"></a><!-- doxytag: member="json.h::json_dict_get_int" ref="a57cc59f4e59e4e57da3e84cb3e4a910d" args="(struct JsonValue *jv, const char *key, int64_t *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#a57cc59f4e59e4e57da3e84cb3e4a910d">json_dict_get_int</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int64_t * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get int value from dict. </p>
</div>
</div>
<a class="anchor" id="a09ac9671cba7c9de4c2291ef3f8423ea"></a><!-- doxytag: member="json.h::json_dict_get_float" ref="a09ac9671cba7c9de4c2291ef3f8423ea" args="(struct JsonValue *jv, const char *key, double *dst_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#a09ac9671cba7c9de4c2291ef3f8423ea">json_dict_get_float</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double * </td>
<td class="paramname"><em>dst_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get float value from dict. </p>
</div>
</div>
<a class="anchor" id="ab51b77538b71a6f0840941b4a56a52bf"></a><!-- doxytag: member="json.h::json_dict_get_string" ref="ab51b77538b71a6f0840941b4a56a52bf" args="(struct JsonValue *jv, const char *key, const char **dst_p, size_t *len_p)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="json_8h.html#ab51b77538b71a6f0840941b4a56a52bf">json_dict_get_string</a> </td>
<td>(</td>
<td class="paramtype">struct <a class="el" href="struct_json_value.html">JsonValue</a> * </td>
<td class="paramname"><em>jv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char * </td>
<td class="paramname"><em>key</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const char ** </td>
<td class="paramname"><em>dst_p</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">size_t * </td>
<td class="paramname"><em>len_p</em> </td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>Get string value from dict. </p>
</div>
</div>
<a class="anchor" id="a2f3cfe4948b9b411976b846f63637ed8"></a><!-- doxytag: member="json.h::json_dict_get_dict" ref="a2f3cfe4948b9b411976b846f63637ed8" args="(struct JsonValue *jv, const char *key, struct JsonValue **dst_p)" -->
<div class="memitem">
<div class="memproto">