libwget-stringmap(3)
β¨ libwget-stringmap β Stringmap functions β¨
okay bestie, gather round, because this one is genuinely iconic and also kind of a flex π it's the libwget-stringmap page from the Library Functions Manual, and it's basically the stringmap glow-up of the hashmap API. no cap.
πΈ NAME πΈ
libwget-stringmap β Stringmap functions
π SYNOPSIS π
π¦ Functions
wget_stringmap * wget_stringmap_create (int max)
wget_stringmap * wget_stringmap_create_nocase (int max)
typedef wget_hashmap wget_stringmap
typedef wget_hashmap wget_stringmapβ this is literally the Type of the stringmap. that's it, that's the tea β it's a typedef, a lil nickname, a rebrand.
π Detailed Description π
Stringmaps are key/value stores that perform at O(1) for insertion, searching and removing. yes bestie, constant time, every single one of them, the whole trio ate π₯
The key is a C string.
These functions are a wrapper around the Hashmap API. so like, if you already know the Hashmap API, this is that but wearing a cute lil string-colored jacket π§₯β¨
π Function Documentation π
π«Ά wget_stringmap * wget_stringmap_create (int max)
Parameters
maxβ Initial number of pre-allocated entries
Returns
- New stringmap instance
Create a new stringmap instance with initial size max. It should be free'd after use with wget_stringmap_free(). okay so like, don't ghost it, free it, that's the polite thing to do π₯Ί
The hash function is an efficient string hash algorithm originally researched by Paul Larson. shoutout Paul, the blueprint, the original main character π
The compare function is strcmp(). The key strings are compared case-sensitive. so "Hello" and "hello" are NOT the same key here, they are two different girls entirely, do not confuse them π
π§ wget_stringmap * wget_stringmap_create_nocase (int max)
Parameters
maxβ Initial number of pre-allocated entries
Returns
- New stringmap instance
Create a new stringmap instance with initial size max. It should be free'd after use with wget_stringmap_free(). same deal bestie, wget_stringmap_free() it, it deserves closure π«Ά
The hash function is an efficient string hash algorithm originally researched by Paul Larson, using lowercase'd keys. yes the legend returns, and this time he's lowercase-ing everything first, lowkey a mood π
The compare function is strcasecmp() (case-insensitive). so "Hello" and "hello"? same key. same girl. no drama, no distinguishing, we're all just vibing case-insensitively π
β Author β
Generated automatically by Doxygen for wget2 from the source code. so like, nobody hand-wrote this, the machine did it, and honestly? it ate π
and that's the page bestie, we're done!! this came to you from wget2, Version 2.3.0, and it lives at libwget-stringmap(3). go build something cute with it πβ¨π¦
π¦ where this page comes from
- fedora 43: wget2-devel 2.3.0-2.fc43 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND GFDL-1.3-or-later
- fedora 43: wget2-devel 2.3.0-2.fc43 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND GFDL-1.3-or-later
- fedora 44: wget2-devel 2.3.0-1.fc44
- fedora 44: wget2-devel 2.3.0-1.fc44
- fedora 44: wget2-devel 2.3.0-3.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND GFDL-1.3-or-later
- fedora 44: wget2-devel 2.3.0-3.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND GFDL-1.3-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms