2
3
4
5
6
7
8
10#ifndef GIMBAL_RING_LIST_H
11#define GIMBAL_RING_LIST_H
13#include "../core/gimbal_ctx.h"
17#define GBL_SELF_TYPE GblRingList
23typedef GblBool (*GblRingListIterFn)(
void* pValue,
void* pClosure);
24typedef int (*GblRingListCmpFn) (
const void* pVal1,
const void* pVal2,
void* pClosure);
25typedef void* (*GblRingListCopyFn)(
const void* pValue,
void* pClosure);
26typedef GBL_RESULT (*GblRingListDtorFn)(
void* pValue,
void* pClosure);
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
72 GblDoublyLinkedListNode listNode;
109 GblRingListCmpFn pFnCmp,
129 GblRingListCmpFn pFnCmp,
134#define GblRingList_copy(...) GblRingList_copyDefault_
(__VA_ARGS__)
135#define GblRingList_unref(...) GblRingList_unrefDefault_
(__VA_ARGS__)
139#define GblRingList_insertSorted(...) GblRingList_insertSortedDefault_
(__VA_ARGS__)
140#define GblRingList_splice(...) GblRingList_spliceDefault_
(__VA_ARGS__)
141#define GblRingList_popBack(...) GblRingList_popBackDefault_
(__VA_ARGS__)
142#define GblRingList_popFront(...) GblRingList_popFrontDefault_
(__VA_ARGS__)
143#define GblRingList_remove(...) GblRingList_removeDefault_
(__VA_ARGS__)
144#define GblRingList_sort(...) GblRingList_sortDefault_
(__VA_ARGS__)
145#define GblRingList_foreach(...) GblRingList_foreachDefault_
(__VA_ARGS__)
146#define GblRingList_find(...) GblRingList_findDefault_
(__VA_ARGS__)
151#define GblRingList_copyDefault_(...)
153#define GblRingList_copyDefault__(list, cpFn, cl, ...)
156#define GblRingList_unrefDefault_(...)
158#define GblRingList_unrefDefault__(list, dtor, cl, ...)
161#define GblRingList_insertSortedDefault_(...)
163#define GblRingList_insertSortedDefault__(list, data, cmp, cl, ...)
166#define GblRingList_spliceDefault_(...)
167 GblRingList_spliceDefault__
(__VA_ARGS__, -1
)
168#define GblRingList_spliceDefault__(list1, list2, index, ...)
171#define GblRingList_popBackDefault_(...)
172 GblRingList_popBackDefault__
(__VA_ARGS__, 1
)
173#define GblRingList_popBackDefault__(list, count, ...)
176#define GblRingList_popFrontDefault_(...)
177 GblRingList_popFrontDefault__
(__VA_ARGS__, 1
)
178#define GblRingList_popFrontDefault__(list, count, ...)
181#define GblRingList_removeDefault_(...)
182 GblRingList_removeDefault__
(__VA_ARGS__, 1
)
183#define GblRingList_removeDefault__(list, idx, count, ...)
186#define GblRingList_sortDefault_(...)
188#define GblRingList_sortDefault__(list, cmp, cl, ...)
191#define GblRingList_foreachDefault_(...)
192 GblRingList_foreachDefault__
(__VA_ARGS__, GBL_NULL)
193#define GblRingList_foreachDefault__(list, it, cl, ...)
196#define GblRingList_findDefault_(...)
198#define GblRingList_findDefault__(list, val, cmp, cl, ...)
#define GBL_FORWARD_DECLARE_STRUCT(S)
#define GblRingList_create(...)
#define GblRingList_insert(self,...)
#define GblRingList_insertSorted(...)
#define GblRingList_popFront(...)
#define GblRingList_pushBack(self,...)
#define GblRingList_splice(...)
#define GblRingList_foreach(...)
#define GblRingList_unref(...)
#define GblRingList_remove(...)
#define GblRingList_copy(...)
#define GblRingList_pushFront(self,...)
#define GblRingList_find(...)
#define GblRingList_sort(...)
#define GblRingList_popBack(...)
uint8_t GblBool
Basic boolean type, standardized to sizeof(char)
uint16_t GblRefCount
Type able to hold a reference counter across the codebase.
Non-intrusive circularly doubly linked list with C++-style STL API.