2019-07-09 05:24:55 +00:00
|
|
|
#ifndef __util_h
|
|
|
|
#define __util_h
|
|
|
|
|
|
|
|
#include <stdint.h>
|
2019-07-12 04:15:25 +00:00
|
|
|
|
|
|
|
typedef struct strset_s strset_t;
|
|
|
|
|
2019-07-09 07:33:44 +00:00
|
|
|
int count_strings (const char * const *str);
|
|
|
|
void merge_strings (const char **out, const char * const *in1,
|
|
|
|
const char * const *in2);
|
2019-07-12 04:15:25 +00:00
|
|
|
void prune_strings (strset_t *strset, const char **strings, uint32_t *count);
|
2019-07-09 05:24:55 +00:00
|
|
|
|
2019-07-10 04:09:16 +00:00
|
|
|
strset_t *new_strset (const char * const *strings);
|
|
|
|
void del_strset (strset_t *strset);
|
2019-07-12 04:15:25 +00:00
|
|
|
void strset_add (strset_t *strset, const char *str);
|
2019-07-10 04:09:16 +00:00
|
|
|
int strset_contains (strset_t *strset, const char *str);
|
|
|
|
|
2019-07-09 05:24:55 +00:00
|
|
|
#endif//__util_h
|