Sound Design Toolkit  075
Physically informed sound synthesis for everyday sounds
SDTStructs.h
1 
5 #ifndef SDT_STRUCTS_H
6 #define SDT_STRUCTS_H
7 
9 typedef struct SDTHashmap SDTHashmap;
10 
14 extern SDTHashmap *SDTHashmap_new(int size);
15 
18 extern void SDTHashmap_free(SDTHashmap *x);
19 
23 extern void *SDTHashmap_get(SDTHashmap *x, char *key);
24 
29 extern int SDTHashmap_put(SDTHashmap *x, char *key, void *value);
30 
34 extern int SDTHashmap_del(SDTHashmap *x, char *key);
35 
37 extern void SDTHashmap_clear(SDTHashmap *x);
38 
39 #endif
40 
void * SDTHashmap_get(SDTHashmap *x, char *key)
Looks for an entry with the given key in the hashmap.
int SDTHashmap_put(SDTHashmap *x, char *key, void *value)
Inserts a key/value pair in the hashmap.
SDTHashmap * SDTHashmap_new(int size)
Object constructor.
struct SDTHashmap SDTHashmap
Opaque data structure for a hashmap object.
Definition: SDTStructs.h:9
void SDTHashmap_free(SDTHashmap *x)
Object destructor.
int SDTHashmap_del(SDTHashmap *x, char *key)
Deletes a key/value pair from the hashmap.
void SDTHashmap_clear(SDTHashmap *x)
Deletes all the entries in the hashmap.