libGimbal 0.1.0
C17-Based Extended Standard Library and Cross-Language Runtime Framework
Loading...
Searching...
No Matches
gimbal_containers.h
Go to the documentation of this file.
1/*! \file
2 * \brief Containers module-wide include
3 * \ingroup containers
4 *
5 * \author Falco Girgis
6 */
7
8
9#ifndef GIMBAL_CONTAINERS_H
10#define GIMBAL_CONTAINERS_H
11
12#include "containers/gimbal_array_deque.h"
13#include "containers/gimbal_array_heap.h"
14#include "containers/gimbal_array_list.h"
15#include "containers/gimbal_array_map.h"
16#include "containers/gimbal_doubly_linked_list.h"
17#include "containers/gimbal_hash_set.h"
18#include "containers/gimbal_linked_list.h"
19#include "containers/gimbal_nary_tree.h"
20#include "containers/gimbal_ring_buffer.h"
21#include "containers/gimbal_ring_list.h"
22#include "containers/gimbal_tree_set.h"
23
24/*! \defgroup containers Containers
25 * \brief Collection of abstract container types providing C++ STL-style APIs
26
27 LibGimbal provides a rich set of abstract containers for various use-cases. Their naming schemes are such that the underlying data
28 structure is the prefix an and the API type is the suffix. For example, a GblTreeSet is a Tree-based data structure implementing a
29 set API.
30
31 LibGimbal containers have been created with the goal of interoping directly with their C++ wrapper analogs, and as such can be used
32 from either the C or C++ API. To facilitate this interop, and because we like the overall API design, the C APIs tend to mirror C++'s
33 STL APIs fairly closely and should be fairly intuitive to work with for any C++ developer.
34
35
36 ## Choosing the Right Container
37 The following table can be referenced when deciding which container type to use:
38
39 Type | Description | Header
40 -----------------------|----------------------------------------------------------------------------------|-------
41 GblLinkedListNode |Intrusive, circularly singly linked list with C++ std::vector-style API | gimbal_linked_list.h
42 GblDoublyLinkedListNode|Intrusive, circularly doubly linked list with C++ std::vector-style API | gimbal_doubly_linked_list.h
43 GblNaryTreeNode |Instrusive generic tree structure with parent + linked list of children | gimbal_nary_tree.h
44 GblArrayList |Dynamically resizable array, O(1) lookup, equivalent to C++ std::vector | gimbal_array_list.h
45 GblRingList |Non-intrusive circular doubly-linked list with high-level, convenience API | gimbal_ring_list.h
46 GblArrayDeque |Dynamically resizable array with good performance when resizing from either end | gimbal_array_deque.h
47 GblTreeSet |Binary tree-based associative set structure, analogous to std::set | gimbal_tree_set.h
48 GblHashSet |Hash table-based associative set structure, analogous to std::unordered_set | gimbal_hash_set.h
49 GblArrayMap |Resizable array-based, [K,V] container with optional binary searchability | gimbal_array_map.h
50 GblArrayHeap |Dynamic array-based, binary heap structure providing a priority queue API | gimbal_array_heap.h
51 GblRingBuffer |Fixed-capacity circular buffer backed by a contiguous array with queue semantics | gimbal_ring_buffer.h
52*/
53
54#endif // GIMBAL_CONTAINERS_H