2017-12-07 18:06:19 -05:00
<!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" / >
2018-03-05 23:18:59 -05:00
< meta name = "generator" content = "Doxygen 1.8.8" / >
2017-12-07 18:06:19 -05:00
< title > json-c: linkhash.h File Reference< / title >
< link href = "tabs.css" rel = "stylesheet" type = "text/css" / >
< script type = "text/javascript" src = "jquery.js" > < / script >
< script type = "text/javascript" src = "dynsections.js" > < / script >
< link href = "doxygen.css" rel = "stylesheet" type = "text/css" / >
< / head >
< body >
< div id = "top" > <!-- do not remove this div, it is closed by doxygen! -->
< div id = "titlearea" >
< table cellspacing = "0" cellpadding = "0" >
< tbody >
< tr style = "height: 56px;" >
2018-03-05 23:18:59 -05:00
< td style = "padding-left: 0.5em;" >
2017-12-07 18:06:19 -05:00
< div id = "projectname" > json-c
2018-03-05 23:18:59 -05:00
  < span id = "projectnumber" > 0.13.1< / span >
2017-12-07 18:06:19 -05:00
< / div >
< / td >
< / tr >
< / tbody >
< / table >
< / div >
<!-- end header part -->
2018-03-05 23:18:59 -05:00
<!-- Generated by Doxygen 1.8.8 -->
< 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 >
2017-12-07 18:06:19 -05:00
< / div > <!-- top -->
< div class = "header" >
< div class = "summary" >
< a href = "#nested-classes" > Data Structures< / a > |
< a href = "#define-members" > Macros< / a > |
< a href = "#typedef-members" > Typedefs< / a > |
< a href = "#func-members" > Functions< / a > < / div >
< div class = "headertitle" >
< div class = "title" > linkhash.h File Reference< / div > < / div >
< / div > <!-- header -->
< div class = "contents" >
< p > Internal methods for working with json_type_object objects. Although this is exposed by the < a class = "el" href = "json__object_8h.html#a2caa52ae1863bd073444f3737138a4db" > json_object_get_object()< / a > function and within the < a class = "el" href = "structjson__object__iter.html" > json_object_iter< / a > type, it is not recommended for direct use.
< a href = "#details" > More...< / a > < / p >
< table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "nested-classes" > < / a >
Data Structures< / h2 > < / td > < / tr >
< tr class = "memitem:" > < td class = "memItemLeft" align = "right" valign = "top" > struct   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structlh__entry.html" > lh_entry< / a > < / td > < / tr >
< tr class = "separator:" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:" > < td class = "memItemLeft" align = "right" valign = "top" > struct   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structlh__table.html" > lh_table< / a > < / td > < / tr >
< tr class = "separator:" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "define-members" > < / a >
Macros< / h2 > < / td > < / tr >
< tr class = "memitem:a032f1bd115df254dda325437203ce5fb" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a032f1bd115df254dda325437203ce5fb" > LH_PRIME< / a >       0x9e370001UL< / td > < / tr >
< tr class = "separator:a032f1bd115df254dda325437203ce5fb" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a66b61772c29d85eb52b697e0b0dc0aaf" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a66b61772c29d85eb52b697e0b0dc0aaf" > LH_LOAD_FACTOR< / a >       0.66< / td > < / tr >
< tr class = "separator:a66b61772c29d85eb52b697e0b0dc0aaf" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a93fad7f8ae44575dc89c9567859972d2" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a93fad7f8ae44575dc89c9567859972d2" > LH_EMPTY< / a >       (void*)-1< / td > < / tr >
< tr class = "separator:a93fad7f8ae44575dc89c9567859972d2" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ac69428f2de0a6fb080b6fb373d506aa7" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ac69428f2de0a6fb080b6fb373d506aa7" > LH_FREED< / a >       (void*)-2< / td > < / tr >
< tr class = "separator:ac69428f2de0a6fb080b6fb373d506aa7" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ac32e80138c5be6dd9b0483a9cbcc8799" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ac32e80138c5be6dd9b0483a9cbcc8799" > JSON_C_STR_HASH_DFLT< / a >       0< / td > < / tr >
< tr class = "separator:ac32e80138c5be6dd9b0483a9cbcc8799" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a62316f34fd42941b97a8e9a6b6e68faa" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a62316f34fd42941b97a8e9a6b6e68faa" > JSON_C_STR_HASH_PERLLIKE< / a >       1< / td > < / tr >
< tr class = "separator:a62316f34fd42941b97a8e9a6b6e68faa" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:ad7dd67da915065dce2c6f44cb03e2d82" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ad7dd67da915065dce2c6f44cb03e2d82" > lh_foreach< / a > (table, entry)      for(entry = table-> head; entry; entry = entry-> next)< / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "separator:ad7dd67da915065dce2c6f44cb03e2d82" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:abcbb0df08b4976d0649b826b6bacfca1" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#abcbb0df08b4976d0649b826b6bacfca1" > lh_foreach_safe< / a > (table, entry, tmp)      for(entry = table-> head; entry & & ((tmp = entry-> next) || 1); entry = tmp)< / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "separator:abcbb0df08b4976d0649b826b6bacfca1" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a77c5cddef96e6f1ab036ccf911783456" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a77c5cddef96e6f1ab036ccf911783456" > _LH_INLINE< / a >       inline< / td > < / tr >
< tr class = "separator:a77c5cddef96e6f1ab036ccf911783456" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:afb856ed4a9bcfd090dde5151fa3ad9ae" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#afb856ed4a9bcfd090dde5151fa3ad9ae" > _LH_UNCONST< / a > (a)      ((void *)(uintptr_t)(const void *)(a))< / td > < / tr >
< tr class = "separator:afb856ed4a9bcfd090dde5151fa3ad9ae" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a7579ce28b8366fc9b8656f14270aa3aa" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a7579ce28b8366fc9b8656f14270aa3aa" > lh_entry_k< / a > (entry)      < a class = "el" href = "linkhash_8h.html#afb856ed4a9bcfd090dde5151fa3ad9ae" > _LH_UNCONST< / a > ((entry)-> k)< / td > < / tr >
< tr class = "separator:a7579ce28b8366fc9b8656f14270aa3aa" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a0d4052ccfd8c5d351a9c1d3ba07671b3" > < td class = "memItemLeft" align = "right" valign = "top" > #define  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a0d4052ccfd8c5d351a9c1d3ba07671b3" > lh_entry_v< / a > (entry)      < a class = "el" href = "linkhash_8h.html#afb856ed4a9bcfd090dde5151fa3ad9ae" > _LH_UNCONST< / a > ((entry)-> v)< / td > < / tr >
< tr class = "separator:a0d4052ccfd8c5d351a9c1d3ba07671b3" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "typedef-members" > < / a >
Typedefs< / h2 > < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:a671553d0ee3c2a123190ba0f8ed2b635" > < td class = "memItemLeft" align = "right" valign = "top" > typedef void(  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > )(struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *e)< / td > < / tr >
< tr class = "separator:a671553d0ee3c2a123190ba0f8ed2b635" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a38bae27995dcfb6ee3fb109a9be229b2" > < td class = "memItemLeft" align = "right" valign = "top" > typedef unsigned long(  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a38bae27995dcfb6ee3fb109a9be229b2" > lh_hash_fn< / a > )(const void *k)< / td > < / tr >
< tr class = "separator:a38bae27995dcfb6ee3fb109a9be229b2" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a91fd85fc81b0c7c83c62f00e84729091" > < td class = "memItemLeft" align = "right" valign = "top" > typedef int(  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a91fd85fc81b0c7c83c62f00e84729091" > lh_equal_fn< / a > )(const void *k1, const void *k2)< / td > < / tr >
< tr class = "separator:a91fd85fc81b0c7c83c62f00e84729091" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "memitem:a766e90057496fc6712d6be0da180a21f" > < td class = "memItemLeft" align = "right" valign = "top" > typedef struct < a class = "el" href = "structlh__table.html" > lh_table< / a >   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a766e90057496fc6712d6be0da180a21f" > lh_table< / a > < / td > < / tr >
< tr class = "separator:a766e90057496fc6712d6be0da180a21f" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "func-members" > < / a >
Functions< / h2 > < / td > < / tr >
< tr class = "memitem:ac8e1d61af44d9c0824d8c7980385bcd3" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ac8e1d61af44d9c0824d8c7980385bcd3" > json_global_set_string_hash< / a > (const int h)< / td > < / tr >
< tr class = "separator:ac8e1d61af44d9c0824d8c7980385bcd3" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:a9c4f8a71dbe4d3390d9f7adb331beb0e" > < td class = "memItemLeft" align = "right" valign = "top" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a9c4f8a71dbe4d3390d9f7adb331beb0e" > lh_table_new< / a > (int size, < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *free_fn, < a class = "el" href = "linkhash_8h.html#a38bae27995dcfb6ee3fb109a9be229b2" > lh_hash_fn< / a > *hash_fn, < a class = "el" href = "linkhash_8h.html#a91fd85fc81b0c7c83c62f00e84729091" > lh_equal_fn< / a > *equal_fn)< / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "separator:a9c4f8a71dbe4d3390d9f7adb331beb0e" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:a6bf630754affe92612639542a6c49c3f" > < td class = "memItemLeft" align = "right" valign = "top" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a6bf630754affe92612639542a6c49c3f" > lh_kchar_table_new< / a > (int size, < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *free_fn)< / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "separator:a6bf630754affe92612639542a6c49c3f" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
2018-03-05 23:18:59 -05:00
< tr class = "memitem:af8108563b961dbf5471fe2c0e51f40a5" > < td class = "memItemLeft" align = "right" valign = "top" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#af8108563b961dbf5471fe2c0e51f40a5" > lh_kptr_table_new< / a > (int size, < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *free_fn)< / td > < / tr >
2017-12-07 18:06:19 -05:00
< tr class = "separator:af8108563b961dbf5471fe2c0e51f40a5" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a81653acf740cf8c9fe672e6cd16df0cf" > < td class = "memItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a81653acf740cf8c9fe672e6cd16df0cf" > lh_table_free< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t)< / td > < / tr >
< tr class = "separator:a81653acf740cf8c9fe672e6cd16df0cf" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a86c0cd547be1e2c2486a73bd58e1352c" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a86c0cd547be1e2c2486a73bd58e1352c" > lh_table_insert< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k, const void *v)< / td > < / tr >
< tr class = "separator:a86c0cd547be1e2c2486a73bd58e1352c" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a4558a9347a422e03a15b0b7a29b82dc3" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a4558a9347a422e03a15b0b7a29b82dc3" > lh_table_insert_w_hash< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k, const void *v, const unsigned long h, const unsigned opts)< / td > < / tr >
< tr class = "separator:a4558a9347a422e03a15b0b7a29b82dc3" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ad3b6ca2d967a6c3021ee6c39e014a918" > < td class = "memItemLeft" align = "right" valign = "top" > struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ad3b6ca2d967a6c3021ee6c39e014a918" > lh_table_lookup_entry< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k)< / td > < / tr >
< tr class = "separator:ad3b6ca2d967a6c3021ee6c39e014a918" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a59ecaf34ef59280952f4459b2de63677" > < td class = "memItemLeft" align = "right" valign = "top" > struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a59ecaf34ef59280952f4459b2de63677" > lh_table_lookup_entry_w_hash< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k, const unsigned long h)< / td > < / tr >
< tr class = "separator:a59ecaf34ef59280952f4459b2de63677" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a49c27f18a174eaf126d1b7953df13cb1" > < td class = "memItemLeft" align = "right" valign = "top" > const void *  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a49c27f18a174eaf126d1b7953df13cb1" > lh_table_lookup< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k)< / td > < / tr >
< tr class = "separator:a49c27f18a174eaf126d1b7953df13cb1" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a81c270bb0dd9d5c8a3e7ae20bc4d67f3" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "el" href = "json__object_8h.html#a81f02022906fafc71eb9197049f07f73" > json_bool< / a >   < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a81c270bb0dd9d5c8a3e7ae20bc4d67f3" > lh_table_lookup_ex< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k, void **v)< / td > < / tr >
< tr class = "separator:a81c270bb0dd9d5c8a3e7ae20bc4d67f3" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ae5885a71c3457190fb1dc2d6e20dde3b" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ae5885a71c3457190fb1dc2d6e20dde3b" > lh_table_delete_entry< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *e)< / td > < / tr >
< tr class = "separator:ae5885a71c3457190fb1dc2d6e20dde3b" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a2fed2c78f70d229edb2d00775ffe593c" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a2fed2c78f70d229edb2d00775ffe593c" > lh_table_delete< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, const void *k)< / td > < / tr >
< tr class = "separator:a2fed2c78f70d229edb2d00775ffe593c" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ac9ba631c91fe80fb905f04c7cd526f2b" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#ac9ba631c91fe80fb905f04c7cd526f2b" > lh_table_length< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t)< / td > < / tr >
< tr class = "separator:ac9ba631c91fe80fb905f04c7cd526f2b" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a1294160fa0e80cee04cd745a401f43a4" > < td class = "memItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a1294160fa0e80cee04cd745a401f43a4" > lh_abort< / a > (const char *msg,...)< / td > < / tr >
< tr class = "separator:a1294160fa0e80cee04cd745a401f43a4" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a30c8414e31aeee7669acc938116d933f" > < td class = "memItemLeft" align = "right" valign = "top" > int  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "linkhash_8h.html#a30c8414e31aeee7669acc938116d933f" > lh_table_resize< / a > (struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *t, int new_size)< / td > < / tr >
< tr class = "separator:a30c8414e31aeee7669acc938116d933f" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table >
< a name = "details" id = "details" > < / a > < h2 class = "groupheader" > Detailed Description< / h2 >
< div class = "textblock" > < p > Internal methods for working with json_type_object objects. Although this is exposed by the < a class = "el" href = "json__object_8h.html#a2caa52ae1863bd073444f3737138a4db" > json_object_get_object()< / a > function and within the < a class = "el" href = "structjson__object__iter.html" > json_object_iter< / a > type, it is not recommended for direct use. < / p >
< / div > < h2 class = "groupheader" > Macro Definition Documentation< / h2 >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a77c5cddef96e6f1ab036ccf911783456" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define _LH_INLINE      inline< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< dl class = "deprecated" > < dt > < b > < a class = "el" href = "deprecated.html#_deprecated000009" > Deprecated:< / a > < / b > < / dt > < dd > Don't use this outside of < a class = "el" href = "linkhash_8h.html" title = "Internal methods for working with json_type_object objects. Although this is exposed by the json_obje..." > linkhash.h< / a > : < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "afb856ed4a9bcfd090dde5151fa3ad9ae" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define _LH_UNCONST< / td >
< td > (< / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > a< / td > < td > )< / td >
< td >       ((void *)(uintptr_t)(const void *)(a))< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< dl class = "deprecated" > < dt > < b > < a class = "el" href = "deprecated.html#_deprecated000010" > Deprecated:< / a > < / b > < / dt > < dd > Don't use this outside of < a class = "el" href = "linkhash_8h.html" title = "Internal methods for working with json_type_object objects. Although this is exposed by the json_obje..." > linkhash.h< / a > : < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ac32e80138c5be6dd9b0483a9cbcc8799" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define JSON_C_STR_HASH_DFLT      0< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > default string hash function < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a62316f34fd42941b97a8e9a6b6e68faa" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define JSON_C_STR_HASH_PERLLIKE      1< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > perl-like string hash function < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a93fad7f8ae44575dc89c9567859972d2" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define LH_EMPTY      (void*)-1< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > sentinel pointer value for empty slots < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a7579ce28b8366fc9b8656f14270aa3aa" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define lh_entry_k< / td >
< td > (< / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > entry< / td > < td > )< / td >
< td >       < a class = "el" href = "linkhash_8h.html#afb856ed4a9bcfd090dde5151fa3ad9ae" > _LH_UNCONST< / a > ((entry)-> k)< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Return a non-const version of < a class = "el" href = "structlh__entry.html#a79d9f1ef0dc444e17105aaeaf167e22c" > lh_entry.k< / a > .< / p >
< p > < a class = "el" href = "structlh__entry.html#a79d9f1ef0dc444e17105aaeaf167e22c" > lh_entry.k< / a > is const to indicate and help ensure that linkhash itself doesn't modify it, but callers are allowed to do what they want with it. See also < a class = "el" href = "structlh__entry.html#a14f40cc124c32b03f81151ae7934d2e7" > lh_entry.k_is_constant< / a > < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a0d4052ccfd8c5d351a9c1d3ba07671b3" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define lh_entry_v< / td >
< td > (< / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > entry< / td > < td > )< / td >
< td >       < a class = "el" href = "linkhash_8h.html#afb856ed4a9bcfd090dde5151fa3ad9ae" > _LH_UNCONST< / a > ((entry)-> v)< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Return a non-const version of < a class = "el" href = "structlh__entry.html#a1b676732ab2ad3eeaedf6ec60a6a0835" > lh_entry.v< / a > .< / p >
< p > v is const to indicate and help ensure that linkhash itself doesn't modify it, but callers are allowed to do what they want with it. < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ad7dd67da915065dce2c6f44cb03e2d82" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define lh_foreach< / td >
< td > (< / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > table, < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > entry  < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td >       for(entry = table-> head; entry; entry = entry-> next)< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Convenience list iterator. < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "abcbb0df08b4976d0649b826b6bacfca1" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define lh_foreach_safe< / td >
< td > (< / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > table, < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > entry, < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > tmp  < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td >       for(entry = table-> head; entry & & ((tmp = entry-> next) || 1); entry = tmp)< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > lh_foreach_safe allows calling of deletion routine while iterating.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > table< / td > < td > a struct < a class = "el" href = "structlh__table.html" > lh_table< / a > * to iterate over < / td > < / tr >
< tr > < td class = "paramname" > entry< / td > < td > a struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > * variable to hold each element < / td > < / tr >
< tr > < td class = "paramname" > tmp< / td > < td > a struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > * variable to hold a temporary pointer to the next element < / td > < / tr >
< / table >
< / dd >
< / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ac69428f2de0a6fb080b6fb373d506aa7" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define LH_FREED      (void*)-2< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > sentinel pointer value for freed slots < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a66b61772c29d85eb52b697e0b0dc0aaf" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define LH_LOAD_FACTOR      0.66< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > The fraction of filled hash buckets until an insert will cause the table to be resized. This can range from just above 0 up to 1.0. < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a032f1bd115df254dda325437203ce5fb" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > #define LH_PRIME      0x9e370001UL< / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > golden prime used in hash functions < / p >
< / div >
< / div >
< h2 class = "groupheader" > Typedef Documentation< / h2 >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a671553d0ee3c2a123190ba0f8ed2b635" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
2018-03-05 23:18:59 -05:00
< td class = "memname" > typedef void( lh_entry_free_fn)(struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *e)< / td >
2017-12-07 18:06:19 -05:00
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > callback function prototypes < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a91fd85fc81b0c7c83c62f00e84729091" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
2018-03-05 23:18:59 -05:00
< td class = "memname" > typedef int( lh_equal_fn)(const void *k1, const void *k2)< / td >
2017-12-07 18:06:19 -05:00
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > callback function prototypes < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a38bae27995dcfb6ee3fb109a9be229b2" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
2018-03-05 23:18:59 -05:00
< td class = "memname" > typedef unsigned long( lh_hash_fn)(const void *k)< / td >
2017-12-07 18:06:19 -05:00
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > callback function prototypes < / p >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a766e90057496fc6712d6be0da180a21f" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > typedef struct < a class = "el" href = "structlh__table.html" > lh_table< / a > < a class = "el" href = "structlh__table.html" > lh_table< / a > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< / div >
< / div >
< h2 class = "groupheader" > Function Documentation< / h2 >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ac8e1d61af44d9c0824d8c7980385bcd3" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int json_global_set_string_hash < / td >
< td > (< / td >
< td class = "paramtype" > const int  < / td >
< td class = "paramname" > < em > h< / em > < / td > < td > )< / td >
< td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > This function sets the hash function to be used for strings. Must be one of the JSON_C_STR_HASH_* values. < / p > < dl class = "section return" > < dt > Returns< / dt > < dd > 0 - ok, -1 if parameter was invalid < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a1294160fa0e80cee04cd745a401f43a4" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > void lh_abort < / td >
< td > (< / td >
< td class = "paramtype" > const char *  < / td >
< td class = "paramname" > < em > msg< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" >   < / td >
< td class = "paramname" > < em > ...< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Prints a message to < code > stdout< / code > , then exits the program with an exit code of < code > 1< / code > .< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > msg< / td > < td > Message format string, like for < code > printf< / code > . < / td > < / tr >
< tr > < td class = "paramname" > ...< / td > < td > Format args.< / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "deprecated" > < dt > < b > < a class = "el" href = "deprecated.html#_deprecated000008" > Deprecated:< / a > < / b > < / dt > < dd > Since it is not a good idea to exit the entire program because of an internal library failure, json-c will no longer use this function internally. However, because its interface is public, it will remain part of the API on the off chance of legacy software using it externally. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a6bf630754affe92612639542a6c49c3f" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > * lh_kchar_table_new < / td >
< td > (< / td >
< td class = "paramtype" > int  < / td >
< td class = "paramname" > < em > size< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
2018-03-05 23:18:59 -05:00
< td class = "paramtype" > < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *  < / td >
2017-12-07 18:06:19 -05:00
< td class = "paramname" > < em > free_fn< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Convenience function to create a new linkhash table with char keys.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > size< / td > < td > initial table size. < / td > < / tr >
< tr > < td class = "paramname" > free_fn< / td > < td > callback function used to free memory for entries. < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > On success, a pointer to the new linkhash table is returned. On error, a null pointer is returned. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "af8108563b961dbf5471fe2c0e51f40a5" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > * lh_kptr_table_new < / td >
< td > (< / td >
< td class = "paramtype" > int  < / td >
< td class = "paramname" > < em > size< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
2018-03-05 23:18:59 -05:00
< td class = "paramtype" > < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *  < / td >
2017-12-07 18:06:19 -05:00
< td class = "paramname" > < em > free_fn< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Convenience function to create a new linkhash table with ptr keys.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > size< / td > < td > initial table size. < / td > < / tr >
< tr > < td class = "paramname" > free_fn< / td > < td > callback function used to free memory for entries. < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > On success, a pointer to the new linkhash table is returned. On error, a null pointer is returned. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a2fed2c78f70d229edb2d00775ffe593c" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_delete < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Delete a record from the table.< / p >
< p > If a callback free function is provided then it is called for the for the item being deleted. < / p > < dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to delete from. < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to delete. < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > 0 if the item was deleted. < / dd >
< dd >
-1 if it was not found. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ae5885a71c3457190fb1dc2d6e20dde3b" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_delete_entry < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > *  < / td >
< td class = "paramname" > < em > e< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Delete a record from the table.< / p >
< p > If a callback free function is provided then it is called for the for the item being deleted. < / p > < dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to delete from. < / td > < / tr >
< tr > < td class = "paramname" > e< / td > < td > a pointer to the entry to delete. < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > 0 if the item was deleted. < / dd >
< dd >
-1 if it was not found. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a81653acf740cf8c9fe672e6cd16df0cf" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > void lh_table_free < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > < / td > < td > )< / td >
< td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Free a linkhash table.< / p >
< p > If a lh_entry_free_fn callback free function was provided then it is called for all entries in the table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > table to free. < / td > < / tr >
< / table >
< / dd >
< / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a86c0cd547be1e2c2486a73bd58e1352c" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_insert < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > v< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Insert a record into the table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to insert into. < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to insert. < / td > < / tr >
< tr > < td class = "paramname" > v< / td > < td > a pointer to the value to insert.< / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > On success, < code > 0< / code > is returned. On error, a negative value is returned. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a4558a9347a422e03a15b0b7a29b82dc3" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_insert_w_hash < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > v< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const unsigned long  < / td >
< td class = "paramname" > < em > h< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const unsigned  < / td >
< td class = "paramname" > < em > opts< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Insert a record into the table using a precalculated key hash.< / p >
< p > The hash h, which should be calculated with lh_get_hash() on k, is provided by the caller, to allow for optimization when multiple operations with the same key are known to be needed.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to insert into. < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to insert. < / td > < / tr >
< tr > < td class = "paramname" > v< / td > < td > a pointer to the value to insert. < / td > < / tr >
< tr > < td class = "paramname" > h< / td > < td > hash value of the key to insert < / td > < / tr >
< tr > < td class = "paramname" > opts< / td > < td > if set to JSON_C_OBJECT_KEY_IS_CONSTANT, sets < a class = "el" href = "structlh__entry.html#a14f40cc124c32b03f81151ae7934d2e7" > lh_entry.k_is_constant< / a > so t's free function knows to avoid freeing the key. < / td > < / tr >
< / table >
< / dd >
< / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ac9ba631c91fe80fb905f04c7cd526f2b" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_length < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > < / td > < td > )< / td >
< td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a49c27f18a174eaf126d1b7953df13cb1" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > const void* lh_table_lookup < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Lookup a record into the table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to lookup < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to lookup < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > a pointer to the found value or NULL if it does not exist. < / dd > < / dl >
< dl class = "deprecated" > < dt > < b > < a class = "el" href = "deprecated.html#_deprecated000007" > Deprecated:< / a > < / b > < / dt > < dd > Use < a class = "el" href = "linkhash_8h.html#a81c270bb0dd9d5c8a3e7ae20bc4d67f3" > lh_table_lookup_ex()< / a > instead. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "ad3b6ca2d967a6c3021ee6c39e014a918" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > * lh_table_lookup_entry < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Lookup a record in the table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to lookup < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to lookup < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > a pointer to the record structure of the value or NULL if it does not exist. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a59ecaf34ef59280952f4459b2de63677" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > struct < a class = "el" href = "structlh__entry.html" > lh_entry< / a > * lh_table_lookup_entry_w_hash < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const unsigned long  < / td >
< td class = "paramname" > < em > h< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Lookup a record in the table using a precalculated key hash.< / p >
< p > The hash h, which should be calculated with lh_get_hash() on k, is provided by the caller, to allow for optimization when multiple operations with the same key are known to be needed.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to lookup < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to lookup < / td > < / tr >
< tr > < td class = "paramname" > h< / td > < td > hash value of the key to lookup < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > a pointer to the record structure of the value or NULL if it does not exist. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a81c270bb0dd9d5c8a3e7ae20bc4d67f3" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > < a class = "el" href = "json__object_8h.html#a81f02022906fafc71eb9197049f07f73" > json_bool< / a > lh_table_lookup_ex < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const void *  < / td >
< td class = "paramname" > < em > k< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > void **  < / td >
< td class = "paramname" > < em > v< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Lookup a record in the table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > the table to lookup < / td > < / tr >
< tr > < td class = "paramname" > k< / td > < td > a pointer to the key to lookup < / td > < / tr >
< tr > < td class = "paramname" > v< / td > < td > a pointer to a where to store the found value (set to NULL if it doesn't exist). < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > whether or not the key was found < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a9c4f8a71dbe4d3390d9f7adb331beb0e" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > * lh_table_new < / td >
< td > (< / td >
< td class = "paramtype" > int  < / td >
< td class = "paramname" > < em > size< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
2018-03-05 23:18:59 -05:00
< td class = "paramtype" > < a class = "el" href = "linkhash_8h.html#a671553d0ee3c2a123190ba0f8ed2b635" > lh_entry_free_fn< / a > *  < / td >
2017-12-07 18:06:19 -05:00
< td class = "paramname" > < em > free_fn< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
2018-03-05 23:18:59 -05:00
< td class = "paramtype" > < a class = "el" href = "linkhash_8h.html#a38bae27995dcfb6ee3fb109a9be229b2" > lh_hash_fn< / a > *  < / td >
2017-12-07 18:06:19 -05:00
< td class = "paramname" > < em > hash_fn< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
2018-03-05 23:18:59 -05:00
< td class = "paramtype" > < a class = "el" href = "linkhash_8h.html#a91fd85fc81b0c7c83c62f00e84729091" > lh_equal_fn< / a > *  < / td >
2017-12-07 18:06:19 -05:00
< td class = "paramname" > < em > equal_fn< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Create a new linkhash table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > size< / td > < td > initial table size. The table is automatically resized although this incurs a performance penalty. < / td > < / tr >
< tr > < td class = "paramname" > free_fn< / td > < td > callback function used to free memory for entries when lh_table_free or lh_table_delete is called. If NULL is provided, then memory for keys and values must be freed by the caller. < / td > < / tr >
< tr > < td class = "paramname" > hash_fn< / td > < td > function used to hash keys. 2 standard ones are defined: lh_ptr_hash and lh_char_hash for hashing pointer values and C strings respectively. < / td > < / tr >
< tr > < td class = "paramname" > equal_fn< / td > < td > comparison function to compare keys. 2 standard ones defined: lh_ptr_hash and lh_char_hash for comparing pointer values and C strings respectively. < / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > On success, a pointer to the new linkhash table is returned. On error, a null pointer is returned. < / dd > < / dl >
< / div >
< / div >
2018-03-05 23:18:59 -05:00
< a class = "anchor" id = "a30c8414e31aeee7669acc938116d933f" > < / a >
2017-12-07 18:06:19 -05:00
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > int lh_table_resize < / td >
< td > (< / td >
< td class = "paramtype" > struct < a class = "el" href = "structlh__table.html" > lh_table< / a > *  < / td >
< td class = "paramname" > < em > t< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > int  < / td >
< td class = "paramname" > < em > new_size< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > Resizes the specified table.< / p >
< dl class = "params" > < dt > Parameters< / dt > < dd >
< table class = "params" >
< tr > < td class = "paramname" > t< / td > < td > Pointer to table to resize. < / td > < / tr >
< tr > < td class = "paramname" > new_size< / td > < td > New table size. Must be positive.< / td > < / tr >
< / table >
< / dd >
< / dl >
< dl class = "section return" > < dt > Returns< / dt > < dd > On success, < code > 0< / code > is returned. On error, a negative value is returned. < / dd > < / dl >
< / div >
< / div >
< / div > <!-- contents -->
<!-- start footer part -->
< hr class = "footer" / > < address class = "footer" > < small >
2018-03-05 23:18:59 -05:00
Generated on Mon Mar 5 2018 23:17:09 for json-c by   < a href = "http://www.doxygen.org/index.html" >
2017-12-07 18:06:19 -05:00
< img class = "footer" src = "doxygen.png" alt = "doxygen" / >
2018-03-05 23:18:59 -05:00
< / a > 1.8.8
2017-12-07 18:06:19 -05:00
< / small > < / address >
< / body >
< / html >