libnds
|
A dynamically resizing array for general use. More...
Data Structures | |
struct | DynamicArray |
A resizable array. More... | |
Typedefs | |
typedef struct DynamicArray | DynamicArray |
A resizable array. | |
Functions | |
void | DynamicArrayDelete (DynamicArray *v) |
Frees memory allocated by the dynamic array. More... | |
void * | DynamicArrayGet (DynamicArray *v, unsigned int index) |
Gets the entry at the supplied index. More... | |
void * | DynamicArrayInit (DynamicArray *v, unsigned int initialSize) |
Initializes an array with the supplied initial size. More... | |
bool | DynamicArraySet (DynamicArray *v, unsigned int index, void *item) |
Sets the entry to the supplied value. More... | |
A dynamically resizing array for general use.
void DynamicArrayDelete | ( | DynamicArray * | v | ) |
Frees memory allocated by the dynamic array.
v | The array to delete |
void* DynamicArrayGet | ( | DynamicArray * | v, |
unsigned int | index | ||
) |
Gets the entry at the supplied index.
v | The array to get from. |
index | The index of the data to get. |
void* DynamicArrayInit | ( | DynamicArray * | v, |
unsigned int | initialSize | ||
) |
Initializes an array with the supplied initial size.
v | the array to initialize |
initialSize | the initial size to allocate |
bool DynamicArraySet | ( | DynamicArray * | v, |
unsigned int | index, | ||
void * | item | ||
) |
Sets the entry to the supplied value.
v | The array to set |
index | The index of the data to set (array will be resized to fit the index). |
item | The data to set. |