|
Tinyhash
This is a library containing multiple C implementations of hashmap.
|

Go to the source code of this file.
Functions | |
| static void | th_iterator_init (th_iterator_t *it, th_generic_table_t generic_table, th_iterator_next_func_t next) |
| th_iterator_t * | th_iterator_create (th_generic_table_t generic_table, th_iterator_next_func_t next) |
| Allocate then init a new iterator. | |
| void | th_iterator_free (th_iterator_t *it) |
| Free an iterator. | |
| bool | th_iterator_next (th_iterator_t **ptr) |
| Try to get the next element. Free the iterator if it reachs the end. | |
| th_iterator_t * th_iterator_create | ( | th_generic_table_t | generic_table, |
| th_iterator_next_func_t | next ) |
Allocate then init a new iterator.
| generic_table | |
| next |
Definition at line 16 of file iterator.c.
References th_iterator_init().
Referenced by th_oa_iterator_begin(), and th_sc_iterator_begin().


| void th_iterator_free | ( | th_iterator_t * | it | ) |
Free an iterator.
| it |
Definition at line 29 of file iterator.c.
References th_iterator_init().
Referenced by th_iterator_next().


|
static |
Definition at line 5 of file iterator.c.
References th_iterator_s::current, th_iterator_s::generic_table, th_iterator_s::index, th_iterator_s::key, th_iterator_s::next, and th_iterator_s::value.
Referenced by th_iterator_create(), and th_iterator_free().

| bool th_iterator_next | ( | th_iterator_t ** | ptr | ) |
Try to get the next element. Free the iterator if it reachs the end.
| ptr |
Definition at line 35 of file iterator.c.
References th_iterator_s::next, and th_iterator_free().
