![]() |
MPLABĀ® Harmony Graphics Suite
|
An array implementation for storing pointers. More...
#include "gfx/legato/common/legato_common.h"

Go to the source code of this file.
Data Structures | |
| struct | leArray |
| This struct represents a array. More... | |
Typedefs | |
| typedef struct leArray | leArray |
| This struct represents a array. More... | |
Functions | |
| leResult | leArray_Create (leArray *arr) |
| Create a new array. More... | |
| leResult | leArray_Resize (leArray *arr, uint32_t sz) |
| Resize array. More... | |
| leResult | leArray_PushFront (leArray *arr, void *val) |
| Push value on front. More... | |
| leResult | leArray_PopFront (leArray *arr) |
| Pop value from front. More... | |
| leResult | leArray_PushBack (leArray *arr, void *val) |
| Push value on back. More... | |
| leResult | leArray_PopBack (leArray *arr) |
| Pop value from back. More... | |
| leResult | leArray_InsertAt (leArray *arr, uint32_t idx, void *val) |
| Insert value at index. More... | |
| leResult | leArray_RemoveAt (leArray *arr, uint32_t idx) |
| Remove value at index. More... | |
| leResult | leArray_Remove (leArray *arr, void *val) |
| Remove value. More... | |
| void * | leArray_Get (const leArray *arr, uint32_t idx) |
| Get entry at index. More... | |
| leResult | leArray_Set (leArray *arr, uint32_t idx, void *val) |
| Set value at index. More... | |
| int32_t | leArray_Find (const leArray *arr, void *val) |
| Find a first index of value. More... | |
| leResult | leArray_Copy (leArray *src, leArray *dest) |
| Copy array. More... | |
| leResult | leArray_Clear (leArray *arr) |
| Clear array. More... | |
An array implementation for storing pointers.
This is an array implementation that is used internally by the Legato user interface library.
This struct represents a array.
An array is used to hold values. It has a size and capacity.
Clear array.
Removes all values from arr. Array capacity remains the same.
| arr | is the array to modify. |
Copy array.
Copies the contents of src to the array pointed to by dest.
| src | is the source array. |
| dest | is the destination array. |
Create a new array.
Creates a new array pointed to by arr.
| arr | is array to create. |
| int32_t leArray_Find | ( | const leArray * | arr, |
| void * | val | ||
| ) |
Find a first index of value.
Returns the first index of val in arr.
| arr | is the array to search. |
| val | is the value to set at index. |
| void* leArray_Get | ( | const leArray * | arr, |
| uint32_t | idx | ||
| ) |
Get entry at index.
Returns the pointer to the entry from arr at the specified idx.
| arr | is the array of entries. |
| idx | is the index at which entry is located. |

Insert value at index.
Inserts val into arr at the specified idx. All existing values from index are shifted right one place.
| arr | is the array to modify. |
| idx | is the location at which to insert value. |
| val | is value to insert. |
Pop value from back.
Removes the last value from the back of arr.
| arr | is the array to modify. |
Pop value from front.
Removes the first value from the front of arr. This function shuffles all other values forward one index.
| arr | is the array to modify. |
Push value on back.
Pushes val onto the back of arr.
| arr | is the array to modify. |
| val | is the value to push. |
Push value on front.
Pushes val onto the front of arr. This function shuffles all other values backward one index.
| arr | is the array to modify. |
| val | is the value to push. |
Remove value.
Removes the first instance of val from arr. The function shuffles all values left to fill the gap.
| arr | is the array to modify. |
| val | is the value removed. |
Remove value at index.
Removes val from arr at the specified idx.
| arr | is the array to modify. |
| idx | is the location at which to insert value. |
Resize array.
Expands (or shrinks) arr to the specified sz.
If the array shrinks, any nodes beyond the new capacity will be discarded.
| arr | is the array to resize. |
| sz | is the new size. |
Set value at index.
Sets val onto arr at the specified idx.
| arr | is the array to modify. |
| idx | is the index where the value is set. |
| val | is the value to set at index. |
1.8.18