Learning by doing: Reading books and trying to understand the (code) examples
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

17 lines
378 B

  1. #include "keyval.h"
  2. extern void *dictionary_not_found;
  3. typedef struct dictionary {
  4. keyval **pairs;
  5. size_t length;
  6. } dictionary;
  7. dictionary *dictionary_new(void);
  8. dictionary *dictionary_copy(dictionary *in);
  9. void dictionary_free(dictionary *in);
  10. void dictionary_add(dictionary *in, char *key, void *value);
  11. void *dictionary_find(const dictionary *in, const char *key);