24#define MAX_LIST_NODES 128
30#define LIST_DEFAULT { .head = NULL, .tail = NULL, .len = 0 }
213bool list_swap(
List* list,
unsigned int idx_a,
unsigned int idx_b);
bool list_swap(List *list, unsigned int idx_a, unsigned int idx_b)
bool list_is_empty(const List *list)
void * list_get_at_idx(List *list, unsigned int idx)
void list_insert(List *list, void *data, unsigned int idx)
int list_get_len(const List *list)
void list_push_front(List *list, void *data)
ListItr rev_list_itr_create(List *list)
void list_clear(List *list)
void list_itr_remove_current_node(ListItr *itr)
ListItrDirection
ListItr direction
void * list_itr_next(ListItr *itr)
bool list_remove_data(List *list, void *data)
bool list_remove_at_idx(List *list, unsigned int idx)
void list_push_back(List *list, void *data)
ListItr list_itr_create(List *list)
ListNode * current_node
The current node in the list iterator.
ListNode * next_node
The next node in the list.
enum ListItrDirection direction
The direction of the iterator.
List * list
A pointer to the List this is iterating through.
A single entry in a List.
void * data
Pointer to generic data stored in this node.
ListNode * prev
The previous ListNode in the associated List, NULL if at the head of the list.
ListNode * next
The next ListNode in the associated List, NULL if at the tail of the list.
ListNode * head
The first entry in the list.
ListNode * tail
The last entry in the list.
int len
Number of elements in list.