MOS Source Code
|
#include "mos/lib/sync/spinlock.h"
#include "mos/mm/slab.h"
#include "mos/mm/slab_autoinit.h"
#include <mos/lib/structures/hashmap.h>
#include <mos/moslib_global.h>
#include <mos_stdlib.h>
#include <mos_string.h>
Go to the source code of this file.
Classes | |
struct | hashmap_entry_t |
Macros | |
#define | HASHMAP_MAGIC MOS_FOURCC('H', 'M', 'a', 'p') |
Functions | |
SLAB_AUTOINIT ("hashmap_entry", hashmap_entry_slab, hashmap_entry_t) | |
void | hashmap_init (hashmap_t *map, size_t capacity, hashmap_hash_t hash_func, hashmap_key_compare_t compare_func) |
void | hashmap_deinit (hashmap_t *map) |
Deinitialize a hashmap. | |
void * | hashmap_put (hashmap_t *map, uintn key, void *value) |
void * | hashmap_get (hashmap_t *map, uintn key) |
void * | hashmap_remove (hashmap_t *map, uintn key) |
void | hashmap_foreach (hashmap_t *map, hashmap_foreach_func_t func, void *data) |
Variables | |
slab_t * | hashmap_entry_slab = NULL |
#define HASHMAP_MAGIC MOS_FOURCC('H', 'M', 'a', 'p') |
Definition at line 12 of file hashmap.c.
Referenced by hashmap_deinit(), hashmap_foreach(), hashmap_get(), hashmap_init(), hashmap_put(), and hashmap_remove().
SLAB_AUTOINIT | ( | "hashmap_entry" | , |
hashmap_entry_slab | , | ||
hashmap_entry_t | ) |
Definition at line 21 of file hashmap.c.
Referenced by hashmap_put().