32 lines
1.0 KiB
C
32 lines
1.0 KiB
C
#ifndef INCLUDED_C_NLPSTRINGLIST_H
|
|
#define INCLUDED_C_NLPSTRINGLIST_H
|
|
|
|
#ifndef INCLUDED_C_BASE_H
|
|
#include <c_Base.h>
|
|
#endif /*INCLUDED_C_BASE_H*/
|
|
|
|
|
|
/* ------------------------------------------------------------------------------------------------------------------ */
|
|
/* */
|
|
|
|
typedef struct {
|
|
char** items; // Array of string pointers
|
|
c_size_t count; // Current number of items in the list
|
|
c_size_t capacity; // Total allocated capacity of the items array
|
|
} c_NlpStringList_t;
|
|
|
|
/* ------------------------------------------------------------------------------------------------------------------ */
|
|
/* */
|
|
|
|
c_err_t c_NlpStringList_Init(c_NlpStringList_t* self, c_size_t capacity);
|
|
|
|
void c_NlpStringList_Destroy(c_NlpStringList_t* self);
|
|
|
|
c_err_t c_NlpStringList_Add(c_NlpStringList_t* list, const char* str, c_size_t str_length);
|
|
|
|
c_err_t c_NlpStringList_AddStr(c_NlpStringList_t* list, const char* str);
|
|
|
|
c_err_t c_NlpStringList_Remove(c_NlpStringList_t* list, c_size_t index);
|
|
|
|
#endif /*INCLUDED_C_NLPSTRINGLIST_H*/
|